Most 'agent orchestration frameworks' are just 400 lines of a while-loop wrapped in three layers of YAML
I've lost count of how many codebases I've opened where a simple 3-tool workflow is buried under five abstract base classes, callback managers, and YAML graph definitions from an "agent framework."
Then something breaks in production—a tool times out or a JSON schema fails—and you spend 40 minutes stepping through framework internals just to find out what messages[] list was actually sent to the model.
At its core, an agent is just:
pythonfor _ in range(MAX_STEPS): resp = call_llm(messages, tools) if not resp.tool_calls: return resp.text messages.extend(run_tools(resp.tool_calls))
Write the loop yourself. You'll understand every retry, every timeout, and every token spent.