updated the start.sh
This PR is about the start.sh script by adding an interactive model provider selection feature. Users can now choose between running Morphik with local models via Ollama or cloud models via OpenAI/Anthropic.
Changes
- Added interactive prompt for model provider selection
- Implemented Ollama setup with appropriate model configuration
- Added OpenAI/Anthropic API key collection and validation
- Updated environment file handling for API keys
Screenshots
Bug Report
| Name | Severity | Example test case | Description |
|---|---|---|---|
| Unnecessary API Key Prompts | Low | Choose option 2 (OpenAI/Anthropic) during setup, and observe prompts for both API keys even if only one provider is intended. | The script prompts for both OpenAI and Anthropic API keys regardless of which provider the user intends to use. It should only prompt for the key of the provider the user wants to use. |
| Unconditional API Key Removal | Low | Have OPENAI_API_KEY and/or ANTHROPIC_API_KEY defined in the .env file. Run start.sh and choose option 2. | The script removes any existing OPENAI_API_KEY and ANTHROPIC_API_KEY entries from the .env file before potentially adding a new entry. This might lead to unexpected behavior if the user had previously set different keys or values. |
Comments? Email us.
when choosing ollama local model ,according to this (from morphik.toml): Ollama models (modify api_base based on your deployment)
- Local Ollama: "http://localhost:11434" (default)
- Morphik in Docker, Ollama local: "http://host.docker.internal:11434"
- Both in Docker: "http://ollama:11434"
Should there be 2 choices: local (Morphik in Docker, Ollama local) and ollama local in docker (Both in Docker)?
Plus, would it be possible to choose the models from a list for the agent and the completion? If not, would it be interesting to do it from the UI (when using UI...)