What is an Agent Framework?

2 min read Updated

An agent framework is a software library that provides abstractions for building AI agents, handling concerns like tool management, state persistence, conversation flow, multi-agent coordination, and LLM integration.

WHY IT MATTERS

Building an AI agent from scratch means solving tool calling, state management, error handling, memory, and orchestration yourself. Agent frameworks handle these concerns so developers can focus on business logic.

The landscape has matured rapidly. LangGraph offers stateful graph-based agents. CrewAI specialises in multi-agent teams. OpenAI's Agents SDK provides a minimal, production-focused approach. PydanticAI emphasises type safety. Each makes different tradeoffs between flexibility and simplicity.

Critically, most major frameworks now support MCP natively — meaning they can connect to MCP servers (and MCP proxies like PolicyLayer) out of the box. This decouples agent development from policy enforcement: build your agent in whatever framework you prefer, then add policy governance by pointing it at PolicyLayer.

Running agents against MCP servers? Route them through PolicyLayer and every tool call is checked against policy first.

PUT POLICY ON YOUR TOOL CALLS →

Enforced before the call runs. Nothing to install.

HOW POLICYLAYER USES THIS

PolicyLayer works with any agent framework that supports MCP — which includes Claude Desktop, Cursor, Windsurf, VS Code Copilot, LangChain, OpenAI Agents SDK, PydanticAI, and more. Because PolicyLayer is a transparent MCP proxy, no framework-specific plugin or SDK is needed. Point the framework's MCP client at PolicyLayer, define your YAML policies, and tool calls are governed automatically.

FREQUENTLY ASKED QUESTIONS

Which agent frameworks work with PolicyLayer?
Any framework with MCP client support: Claude Desktop, Cursor, Windsurf, VS Code Copilot, LangChain/LangGraph, OpenAI Agents SDK, PydanticAI, CrewAI, AutoGen, and others. If it speaks MCP, it works with PolicyLayer.
Do I need a framework-specific plugin for PolicyLayer?
No. PolicyLayer is a transparent MCP proxy — it operates at the protocol level, not the framework level. You configure your framework's MCP client to connect to PolicyLayer instead of the server directly. No plugin needed.
Do I need a framework to build an agent?
No. Many production agents are built with just an LLM API and a while loop. Frameworks help when you need state management, multi-agent coordination, or complex tool orchestration. Either way, PolicyLayer enforces policies.

FURTHER READING

Take your agents live. Without losing control.

Route your MCP traffic through PolicyLayer. Every tool call is checked against your policy before it runs: allow, deny, or require approval. Per-identity grants. Full audit log. Live in minutes.

Instant setup, no code required.

43,000+ MCP servers and 220,000+ tools scanned and risk-classified.

// GET IN TOUCH

Have a question or want to learn more? Send us a message.

Message sent.

We'll get back to you soon.