Troubleshooting
Models not discovered at startup
Symptom: PrivateGPT starts but shows no models, or API calls return a “no models available” error.
Causes and fixes:
-
LLM server not running. Make sure your LLM server is up before starting PrivateGPT.
-
Wrong
OPENAI_API_BASE. Verify the URL matches your server’s address and includes/v1. -
Auto-discovery disabled. Check that
PGPT_LLM_AUTO_DISCOVER_MODELSis not set tofalse.
Connection refused inside Docker
When running PrivateGPT in Docker and pointing at a server on the host machine, localhost refers to the container, not the host.
macOS / Windows: use host.docker.internal:
Linux: use --network host instead:
Context window overflow
Symptom: Long conversations or large documents produce truncated responses or errors from the LLM server.
Cause: Without a tokenizer endpoint (Ollama), PrivateGPT estimates token count at 4 chars = 1 token, which can be inaccurate.
Fix: Set context_window explicitly in a detailed model profile to a value below the model’s actual limit:
Embedding dimensions mismatch
Symptom: Error message containing Embedding dimensions mismatch during ingestion or retrieval.
Cause: The vector store was initialized with a different embedding model (different output dimensions) than the one currently configured.
Fix: Either:
- Switch back to the original embedding model, or
- Wipe the vector store and re-ingest your documents:
Ensure embed_dim in your profile matches the model’s output dimension (e.g. 1024 for mxbai-embed-large):
Tokenizer download fails (HuggingFace gated models)
Symptom: Startup fails with an authentication error when downloading a tokenizer from HuggingFace.
Cause: The model’s tokenizer repository is gated and requires a HuggingFace token.
Fix:
- Request access to the model on HuggingFace.
- Generate an access token.
- Pass the token via environment variable:
Or set it in your profile:
Port already in use
Symptom: [Errno 48] Address already in use on startup.
Fix: Change the port with the --port flag:
Or for Docker:
Profile file not found
Symptom: FileNotFoundError: Settings file not found for profile 'foo'.
Cause: PGPT_PROFILES=foo was set but settings-foo.yaml does not exist in the settings folder.
Fix: Make sure the file exists and is in the correct location. For Docker, it must be mounted:

