mirror of
https://github.com/Shubhamsaboo/awesome-llm-apps.git
synced 2026-07-16 23:44:06 -05:00
How can I change the browser-mcp-agent to use the local Ollama? #82
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Clailton on GitHub (Sep 3, 2025).
Thank you very much for sharing this MCPs server. I am very interested in using the browser-mcp-agent, but I would like to point it to my local Ollama. In the code, I couldn't find where I could point to get it via the API: localhost:11434. I appreciate any help in advance.
@Shubhamsaboo commented on GitHub (Sep 8, 2025):
@AndrewHoh can help? Not sure if it works with Ollama though.
@AndrewHoh commented on GitHub (Sep 8, 2025):
For sure, it's a pretty small change to get it to work with your local Ollama. If the completion call looks like OpenAI, which most models follow:
You just need to update the
mcp_agent.config.yamlto includeHere's the source code to what the config would have after you add this part to the config - https://github.com/lastmile-ai/mcp-agent/blob/main/examples/model_providers/mcp_basic_ollama_agent/mcp_agent.config.yaml
@Clailton commented on GitHub (Sep 9, 2025):
I put the settings you indicated, but it gave the message, below the Response, I think it didn't recognize them: Error: OpenAI API key not provided
@AndrewHoh commented on GitHub (Sep 9, 2025):
Interesting, can you share how your
mcp_agent.config.yamllooks like?One test could be to see if you are able to run the app in https://github.com/lastmile-ai/mcp-agent/tree/main/examples/model_providers/mcp_basic_ollama_agent
@Clailton commented on GitHub (Sep 12, 2025):
Here is the mcp_agent.config.yaml. I also tried to put the base_url and api_key parameters in the mcp_agent.secrets.yaml, but it also had no effect. Thank you for your help.
@AndrewHoh commented on GitHub (Sep 12, 2025):
ahh, I figured it out. Apologies for the confusion.
Your
mcp_agent.config.yamllooks correct. It's actually that there is an unnecessary call in mybrowser_mcp_agent/main.py codethat checks for an OPENAI_API_KEY as an environment variable. Removing that should solve everything.It should look like this afterwards:
@Shubhamsaboo commented on GitHub (Sep 23, 2025):
Closing this since no response from the issue author. Thanks @AndrewHoh for the help!