The runtime for AI agents.
Project description
AgentFabric
The Runtime for AI Agents
Memory · Tools · Permissions · Observability · Scheduling · Pipelines · Studio
Getting Started · Core Concepts · Documentation · Architecture · Contributing · License
Overview
AgentFabric is an open-source runtime layer for AI agents. It provides the foundational infrastructure — memory, tools, permissions, observability, scheduling, pipelines, and a desktop studio — that every agent needs to be production-ready.
AgentFabric is not another agent framework. It does not replace LangGraph, CrewAI, AutoGen, or the OpenAI SDK. It works alongside them, providing the infrastructure layer underneath.
┌──────────────────────────────────────────────────┐
│ YOUR APPLICATION │
└──────────────────┬───────────────────────────────┘
│
┌──────────────────▼───────────────────────────────┐
│ YOUR FRAMEWORK (optional) │
│ LangGraph · CrewAI · AutoGen · OpenAI SDK │
└──────────────────┬───────────────────────────────┘
│
╔══════════════════▼═══════════════════════════════╗
║ AgentFabric Runtime ║
║ Memory · Tools · Permissions · Observability ║
║ Scheduler · Pipelines · EventBus · Plugins ║
║ Knowledge Graph · Workspaces · Agent Teams ║
╚══════════════════════════════════════════════════╝
⚡ Getting Started
Installation
pip install agent-fabric
Create Your First Agent
from agent_fabric import Agent
agent = Agent("researcher")
result = agent.run("What are the latest breakthroughs in quantum computing?")
print(result.text)
No configuration files. No server to start. No database to set up. API keys are read from environment variables.
export OPENAI_API_KEY="sk-..."
📖 Core Concepts
Agents
An agent is an autonomous entity that can think, use tools, remember information, and collaborate with other agents.
from agent_fabric import Agent
agent = Agent(
name="analyst",
model="gpt-4o",
system_prompt="You are a data analyst.",
)
result = agent.run("Analyze the trends in this dataset")
Tools
Tools give agents the ability to interact with the outside world. Create custom tools with the @tool decorator:
from agent_fabric import Agent, tool
@tool("Search the web for information")
def web_search(query: str) -> str:
# Your search implementation
return results
@tool("Read a webpage and extract its content")
def read_url(url: str) -> str:
# Your implementation
return content
agent = Agent("researcher", tools=[web_search, read_url])
Memory
Agents automatically persist memory across sessions. You can also use memory directly:
from agent_fabric import memory
memory.store("Project deadline is March 15th", tags=["projects", "deadlines"])
results = memory.search("upcoming deadlines")
Agent Teams
Multiple agents can collaborate on complex tasks:
from agent_fabric import Agent, Team
researcher = Agent("researcher", role="Research topics thoroughly")
writer = Agent("writer", role="Write clear, engaging content")
reviewer = Agent("reviewer", role="Review and improve quality")
team = Team(
agents=[researcher, writer, reviewer],
strategy="sequential",
)
result = team.run("Create a comprehensive report on AI infrastructure")
Pipelines
Define multi-step workflows as directed acyclic graphs:
# pipeline.yaml
name: morning-briefing
nodes:
- id: scan_news
type: skill
skill: research
inputs: { topic: "Top AI news today" }
- id: scan_emails
type: tool
tool: gmail_read
inputs: { filter: "is:unread" }
- id: compile
type: agent
agent: writer
depends_on: [scan_news, scan_emails]
from agent_fabric import Pipeline, Schedule
pipeline = Pipeline.from_yaml("pipeline.yaml")
# Run once
pipeline.run()
# Or schedule it
Schedule(pipeline, cron="0 8 * * *") # Every day at 8 AM
Bring Your Own Agent
Already have an existing agent? Add AgentFabric infrastructure without rewriting it:
from agent_fabric import enhance
# Your existing agent — any Python class
class MyExistingBot:
def run(self, task):
return openai.chat.completions.create(...)
bot = enhance(MyExistingBot(), memory=True, observe=True)
bot.run("Analyze this data")
# Now it has persistent memory, logging, and metrics
Framework Adapters
Use AgentFabric with your existing framework:
from agent_fabric.adapters import LangGraphAdapter
agent = LangGraphAdapter(my_langgraph_app)
agent.run("Do research")
# Your LangGraph agent now has AgentFabric memory and observability
Adapters are available for OpenAI Agents SDK, LangGraph, and CrewAI.
🏗️ Architecture
AgentFabric is built as a modular runtime with the following core systems:
| System | Purpose |
|---|---|
| Agent Runtime | Agent lifecycle management, execution, state, and multi-agent team coordination |
| Memory Engine | Persistent storage with full-text search and optional vector/semantic search |
| Knowledge Graph | Structured relationships between entities for contextual understanding |
| Tool Runtime | Extensible tool execution with automatic schema generation and permission enforcement |
| Skill System | Declarative, composable high-level capabilities that bundle tools, prompts, and workflows |
| Pipeline Engine | DAG-based workflow execution with parallel processing, branching, and error handling |
| Scheduler | Cron, interval, and event-based scheduling with execution history |
| Event Bus | Async message-passing system for inter-component and inter-agent communication |
| Permissions | Capability-based security model controlling tool access, memory access, and operations |
| Observability | Structured logging, token usage tracking, latency metrics, and execution history |
| Plugin System | Package-based extensibility for adding new tools, skills, and integrations |
| Workspaces | Isolated environments with independent memory, configuration, and state |
Design Principles
- Embedded by default — The SDK runs in-process. No server, no database setup, no infrastructure to manage.
- Zero configuration — Sensible defaults for everything. Configuration files are optional and only needed for customization.
- Progressive complexity — Simple use cases require simple code. Advanced capabilities are available when needed.
- Framework agnostic — Works with any agent framework or no framework at all.
- À la carte — Use the full runtime or individual components independently.
- Local first — All data stays on your machine by default. No cloud dependency.
🖥️ AgentFabric Studio
AgentFabric Studio is a desktop application for managing your AI infrastructure visually.
| Module | Description |
|---|---|
| Dashboard | Active agents, running pipelines, events, and resource usage at a glance |
| Agent Manager | Start, stop, configure, and debug agents with real-time log streaming |
| Memory Explorer | Search, browse, and visualize the knowledge graph |
| Pipeline Editor | Visual drag-and-drop DAG editor with live execution status |
| Plugin Store | Browse and install integrations |
| Logs & Observability | Real-time event stream, execution history, token usage, and performance metrics |
Built with Tauri and SvelteKit for a lightweight, fast, cross-platform experience.
agentfabric studio
⚡ Why AgentFabric? Comparison vs Competitors
| Feature | AgentFabric | LangChain | CrewAI | AutoGPT |
|---|---|---|---|---|
| Primary Focus | Agent Infrastructure & Runtime | Chain Prompting & Orchestration | Role-based Agent Teams | Autonomous Task Execution |
| Persistent Memory & Graph | Built-in SQLite + FTS5 + Knowledge Graph | Requires External Vector DB | Basic Short/Long-Term Memory | Basic File/JSON Memory |
| BYOA & Framework Adapters | LangGraph, CrewAI, OpenAI SDK, Custom | Self-contained | Self-contained | Self-contained |
| Model Context Protocol (MCP) | Bidirectional (Server & Client) | Community wrappers | Limited | No |
| Desktop & Terminal Studio | Tauri Desktop Studio + Rich TUI | No | No | Web UI |
🔌 Ecosystem
LLM Providers
AgentFabric is model-agnostic. Configure your preferred provider:
| Provider | Package |
|---|---|
| OpenAI (GPT-4o, o3, o4-mini) | agent-fabric-openai |
| Anthropic (Claude) | agent-fabric-anthropic |
| Google (Gemini) | agent-fabric-google |
| Ollama (Local models) | agent-fabric-ollama |
Plugins
Extend AgentFabric with integrations:
| Plugin | Capabilities |
|---|---|
| GitHub | Repository management, PR reviews, issue triage, CI status |
| Gmail | Read, send, search emails; inbox triage; email drafting |
| Slack | Send/read messages, channel digests, standup summaries |
| Notion | Page management, search, meeting notes, knowledge sync |
| Calendar | Events, scheduling, free slot detection, daily agenda |
MCP Compatibility
AgentFabric supports the Model Context Protocol:
- Expose AgentFabric tools as MCP servers for use in Claude Desktop, Cursor, and other MCP clients
- Consume external MCP servers as AgentFabric tools
🧑💻 SDK Reference
Quick Reference
from agent_fabric import Agent, Team, Pipeline, Schedule
from agent_fabric import tool, memory, enhance
from agent_fabric import Runtime
| Import | Purpose |
|---|---|
Agent |
Create and run agents |
Team |
Multi-agent collaboration |
Pipeline |
DAG-based workflows |
Schedule |
Automated scheduling |
tool |
@tool decorator for custom tools |
memory |
Direct memory access |
enhance |
Add AgentFabric to existing agents |
Runtime |
Advanced runtime configuration |
Runtime Configuration
For advanced use cases, configure the runtime explicitly:
from agent_fabric import Runtime, Agent
runtime = Runtime(
workspace="my-project",
provider="anthropic",
model="claude-sonnet-4",
memory_backend="qdrant",
)
agent = Agent("analyst", runtime=runtime)
CLI
agentfabric run "Research AI trends" # One-shot agent
agentfabric agent start <name> # Start a persistent agent
agentfabric agent list # List running agents
agentfabric memory search "query" # Search memory
agentfabric pipeline run pipeline.yaml # Run a pipeline
agentfabric schedule create --cron "..." # Create a schedule
agentfabric studio # Open the Studio
agentfabric plugin list # List installed plugins
agentfabric workspace list # List workspaces
📖 Documentation
| Resource | Description |
|---|---|
| Getting Started | Installation, first agent, basic concepts |
| Core Concepts | Agents, tools, memory, teams, pipelines |
| SDK Reference | Complete API documentation |
| CLI Reference | All CLI commands and options |
| Plugin Development | How to create and publish plugins |
| Architecture Guide | System design and internals |
| API Reference | REST and WebSocket API documentation |
🤝 Contributing
We welcome contributions of all kinds — bug reports, feature requests, documentation improvements, and code contributions.
Please read our Contributing Guide for development setup, coding standards, and the contribution process.
📄 License
AgentFabric is licensed under the Apache License 2.0.
AgentFabric — The foundational infrastructure layer for AI-native applications.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file agentfabric_sdk-0.1.0b1.tar.gz.
File metadata
- Download URL: agentfabric_sdk-0.1.0b1.tar.gz
- Upload date:
- Size: 16.3 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
79481a3915239d0d122998b7086ee3d8b99ad0715500d25992a3623edec290b3
|
|
| MD5 |
2cd94caa54b8ad84223cd34e25b896b8
|
|
| BLAKE2b-256 |
c40289fc2f2eea134e8aa55569b2b20a6b9fbb038dab44162b92ef609d78fbfc
|
File details
Details for the file agentfabric_sdk-0.1.0b1-py3-none-any.whl.
File metadata
- Download URL: agentfabric_sdk-0.1.0b1-py3-none-any.whl
- Upload date:
- Size: 106.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ea6ef36799ff27017040c37e41e63c15d07b44cdc5083f84cfb4dfd9566db7a3
|
|
| MD5 |
3ce4bdd4fbe63cf475f97520880fd4de
|
|
| BLAKE2b-256 |
dc47ed9ec8702b6e601f52b4435efdfd2d130d644df5b295e006b70ba7837407
|