👋 you can use this project with Visual Studio Code Dev Containers. Take a look at the
.devcontainer.json
file. The Docker image is defined int this repository https://github.com/genai-for-all/go-workspace.
HTTP_PORT=8888 LLM=deepseek-coder OLLAMA_BASE_URL=http://ollama:11434 docker compose --profile container up
The first time only, you must wait for the complete downloading of the model.
To do for the first time only:
LLM=deepseek-coder ollama pull ${LLM}
HTTP_PORT=8888 LLM=deepseek-coder OLLAMA_BASE_URL=http://host.docker.internal:11434 docker compose --profile webapp up
🚧 This is a work in progress
curl -H "Content-Type: application/json" http://localhost:8080/prompt \
-d '{
"question": "what are structs in Golang?"
}'
All in containers
HTTP_PORT=8888 LLM=deepseek-coder OLLAMA_BASE_URL=http://ollama:11434 docker compose --profile container up --build
Use the Ollama local install (like on macOS)
HTTP_PORT=8888 LLM=deepseek-coder OLLAMA_BASE_URL=http://host.docker.internal:11434 docker compose --profile webapp up --build
For developping the application, use the watch
command of Docker Compose
All in containers
HTTP_PORT=8888 LLM=deepseek-coder OLLAMA_BASE_URL=http://ollama:11434 docker compose --profile container watch
Use the Ollama local install (like on macOS)
HTTP_PORT=8888 LLM=deepseek-coder OLLAMA_BASE_URL=http://host.docker.internal:11434 docker compose --profile webapp watch