# Table of Contents - [Table of Contents](#table-of-contents) - [Build MegaService Docker Image](#build-megaservice-docker-image) - [Build UI Docker Image](#build-ui-docker-image) - [Generate a HuggingFace Access Token](#generate-a-huggingface-access-token) - [Troubleshooting](#troubleshooting) ## Build MegaService Docker Image To construct the Megaservice of ArbPostHearingAssistant, the [GenAIExamples](https://github.com/opea-project/GenAIExamples.git) repository is utilized. Build MegaService Docker image via command below: ```bash git clone https://github.com/opea-project/GenAIExamples.git cd GenAIExamples/ArbPostHearingAssistant docker build --no-cache -t opea/arb-post-hearing-assistant:latest --build-arg https_proxy=$https_proxy --build-arg http_proxy=$http_proxy -f Dockerfile . ``` ## Build UI Docker Image Build frontend Docker image via below command: ```bash cd GenAIExamples/ArbPostHearingAssistant/ui docker build -t opea/arb-post-hearing-assistant-gradio-ui:latest --build-arg https_proxy=$https_proxy --build-arg http_proxy=$http_proxy -f ./docker/Dockerfile . ``` ## Generate a HuggingFace Access Token Some HuggingFace resources, such as certain models, are only accessible if the developer has an access token. If you don't have a HuggingFace access token, you can create one by registering at [HuggingFace](https://huggingface.co/) and following [these steps](https://huggingface.co/docs/transformers.js/en/guides/private#step-1-generating-a-user-access-token). ## Troubleshooting 1. If you get errors like "Access Denied", [validate micro service](./README.md#validate-microservices) first. A simple example: ```bash http_proxy="" curl http://${host_ip}:8008/generate \ -X POST \ -d '{"inputs":" ### System: Please translate the following Golang codes into Python codes. ### Original codes: '\'''\'''\''Golang \npackage main\n\nimport \"fmt\"\nfunc main() {\n fmt.Println(\"Hello, World!\");\n '\'''\'''\'' ### Translated codes:","parameters":{"max_tokens":17, "do_sample": true}}' \ -H 'Content-Type: application/json' ``` 2. (Docker only) If all microservices work well, check the port ${host_ip}:7777, the port may be allocated by other users, you can modify the `compose.yaml`. 3. (Docker only) If you get errors like "The container name is in use", change container name in `compose.yaml`.