Ollama base_url param

#3 · closed · 2 comments

View on GitHub ↗

jcpraud

Hi, As I'm using Ollama on a dedicated host, I quickly added these: - /config.py line 16: LLM_BASEURL = "http://myollamahost:11434" - /core/rag_system.py line 24: llm = ChatOllama(model=config.LLM_MODEL, temperature=config.LLM_TEMPERATURE, base_url=config.LLM_BASEURL) Not sure this would break something if I made a PR... Now, other tweaks I made in the code surely will, so I'll avoid breaking this excellent project ;) Cheers, JC

Comments

GiovanniPasq

Hi JC, Thank you for the feedback! The `config.py` file is indeed designed exactly for what you did: allowing quick customizations to fit specific environments. Regarding your suggestion, I've decided to keep only the strictly essential parameters in the default version to maintain compatibility across different providers (like Gemini or OpenAI), where a custom base URL isn't typically required. Adding too many provider-specific variables might clutter the configuration for general users. However, your tweak is a perfect example of how the modular structure allows anyone to extend the code for their own infrastructure. **I'm planning to release v1.9 soon, which will include a dedicated "Customization" section in the documentation.** I'll make sure to include tips on how to handle custom host configurations like yours for Ollama users. Thanks for sharing your solution! Kind regards, Giovanni

GiovanniPasq

Hi JC, As mentioned earlier, the documentation has been updated with a section on custom configurations, including more details and some customization examples. You can view the changes in this commit: https://github.com/GiovanniPasq/agentic-rag-for-dummies/commit/953ec520b12acca78343aca9fdc7fb30f1011979 Thank you and kind regards, Giovanni