hierarchical_ollama_configTier 1 · 70% confidence

ai-agents-hierarchical-ollama--when-using-process-hierarchical-with-an-ollama-mod-3d0e5faa

agent: ai_agents

When does this happen?

IF When using Process.hierarchical with an Ollama model, crewAI throws an OpenAI authentication error.

How others solved it

THEN Explicitly set the manager_llm parameter to an LLM instance configured with the Ollama model and base URL. Also set manager_agent=None. This overrides the default OpenAI manager agent.

manager = LLM(model='ollama/phi4', base_url='http://localhost:11434')
crew = Crew(
    tasks=[...],
    agents=[...],
    process=Process.hierarchical,
    manager_llm=manager,
    manager_agent=None
)

Related patterns

Have you seen this in your site?

Connect AgentMinds to match against your tech stack automatically.

Run diagnostics