ConnectOnion
from connectonion import Agent
agent = Agent("You are helpful", tools=[get_weather])
agent.input("What's the weather in NYC?")See the Difference
Same task, dramatically different complexity. Scroll to see real code comparisons.
Calculator Agent
vs LangChain
Type hints = automatic tool conversion. No wrappers needed.
from connectonion import Agent
def add(a: float, b: float) -> float:
return a + b
def multiply(a: float, b: float) -> float:
return a * b
agent = Agent("You are a calculator", tools=[add, multiply])
agent.input("What is 5 + 3, then multiply by 2?")from langchain.agents import Tool, AgentExecutor, create_react_agent
from langchain_openai import ChatOpenAI
from langchain.prompts import PromptTemplate
def add(input_str: str) -> str:
"""Add two numbers. Input: 'a,b'"""
a, b = map(float, input_str.split(','))
return str(a + b)
def multiply(input_str: str) -> str:
"""Multiply two numbers. Input: 'a,b'"""
a, b = map(float, input_str.split(','))
return str(a * b)
tools = [
Tool(name="add", func=add, description="Add two numbers. Input: 'a,b'"),
Tool(name="multiply", func=multiply, description="Multiply. Input: 'a,b'"),
]
template = """You are a calculator assistant.
Available tools: {tools}
Tool names: {tool_names}
Question: {input}
{agent_scratchpad}"""
prompt = PromptTemplate.from_template(template)
llm = ChatOpenAI(model="gpt-4", temperature=0)
agent = create_react_agent(llm=llm, tools=tools, prompt=prompt)
executor = AgentExecutor(agent=agent, tools=tools, verbose=True)
result = executor.invoke({"input": "What is 5 + 3, then multiply by 2?"})Browser Automation
vs OpenAI SDK
Just pass a class. Public methods become tools, self = shared state.
from connectonion import Agent
class BrowserAutomation:
def __init__(self):
self._browser = None
self._page = None
self._screenshots = []
def start_browser(self):
self._browser = launch_browser()
self._page = self._browser.new_page()
return "Browser started"
def navigate(self, url: str):
self._page.goto(url) # Uses shared state via self
return f"Navigated to {url}"
def take_screenshot(self, path: str):
self._page.screenshot(path=path)
self._screenshots.append(path)
return f"Saved: {path}"
browser = BrowserAutomation()
agent = Agent("You automate browsers", tools=[browser])from dataclasses import dataclass
from agents import Agent, Runner, function_tool
from agents.types import RunContextWrapper
@dataclass
class BrowserContext:
browser: object = None
page: object = None
screenshots: list = None
def __post_init__(self):
self.screenshots = self.screenshots or []
@function_tool
def start_browser(wrapper: RunContextWrapper[BrowserContext]):
wrapper.context.browser = launch_browser()
wrapper.context.page = wrapper.context.browser.new_page()
return "Browser started"
@function_tool
def navigate(wrapper: RunContextWrapper[BrowserContext], url: str):
wrapper.context.page.goto(url) # Access via wrapper.context
return f"Navigated to {url}"
@function_tool
def take_screenshot(wrapper: RunContextWrapper[BrowserContext], path: str):
wrapper.context.page.screenshot(path=path)
wrapper.context.screenshots.append(path)
return f"Saved: {path}"
agent = Agent(name="browser", instructions="...",
tools=[start_browser, navigate, take_screenshot])
ctx = BrowserContext()
result = await Runner.run(agent, "Open google", context=ctx)ReAct Reasoning
vs Google ADK
plugins=[re_act] - one line adds Plan + Act + Reflect loop.
from connectonion import Agent
from connectonion.useful_plugins import re_act
def search(query: str) -> str:
return f"Results for: {query}"
# Just add plugins=[re_act] - that's it!
agent = Agent(
"You are a research assistant",
tools=[search],
plugins=[re_act] # Plan + Act + Reflect loop
)
agent.input("Research the history of Python")from google.adk import Agent
from google.adk.planners import PlanReActPlanner
def search(query: str) -> dict:
"""Search for information.
Args:
query: The search query.
Returns:
dict with search results.
"""
return {"status": "success", "results": f"Results for: {query}"}
# Must use special planner class
agent = Agent(
model="gemini-2.0-flash",
planner=PlanReActPlanner(), # Special planner object
tools=[search],
)
# Run with: adk webMemory System
vs All Frameworks
Memory is just a tool. No services, no sessions, no deprecated APIs.
from connectonion import Agent, Memory
memory = Memory() # That's it!
agent = Agent(
"You remember user preferences",
tools=[memory] # Memory is just a tool
)
agent.input("Remember: I prefer dark mode")
agent.input("What are my preferences?")from langchain.memory import ConversationBufferMemory
from langchain.chains import LLMChain
from langchain_core.prompts import ChatPromptTemplate
from langchain_core.prompts.chat import MessagesPlaceholder
# Choose from 6+ memory types:
# - ConversationBufferMemory
# - ConversationSummaryMemory
# - ConversationBufferWindowMemory
# - ConversationKGMemory
# - VectorStoreRetrieverMemory
# ... and more
prompt = ChatPromptTemplate([
MessagesPlaceholder(variable_name="chat_history"),
# ... more setup
])
memory = ConversationBufferMemory(
memory_key="chat_history",
return_messages=True
)
# DEPRECATED in v0.3.1 - must migrate to LangGraphEvent Hooks
vs All Frameworks
9 event types with full agent access. Not just guardrails.
from connectonion import after_tools
def my_hook(agent):
# Access EVERYTHING:
session = agent.current_session
messages = session['messages'] # All conversation
trace = session['trace'] # Every LLM call
user_input = session['user_prompt'] # Original request
# Modify ANYTHING:
session['messages'].append({
'role': 'assistant',
'content': 'Thinking about next step...'
})
# That's it - just pass it
agent = Agent("assistant", tools=[...],
on_events=[after_tools(my_hook)])
# Available: after_user_input, before_llm, after_llm,
# before_tools, before_each_tool, after_each_tool,
# after_tools, on_error, on_completefrom agents import Agent, output_guardrail
from agents.types import OutputGuardrailTripwireTriggered
# OpenAI SDK has NO event system
# Only "guardrails" for input/output validation
@output_guardrail
async def check_output(ctx, agent, output):
# Can only validate, not modify behavior
# No access to tool execution
# No access to conversation history
if "bad" in output:
raise OutputGuardrailTripwireTriggered("Invalid")
return output
# Want ReAct? Build it yourself
# Want custom logging? No standard way
# Want approval flows? No standard wayQuick Comparison
| Feature | ConnectOnion | Others |
|---|---|---|
| Tool definition | Just a function | Decorators, wrappers, classes |
| Shared state | self.field | wrapper.context, dataclass, services |
| Add ReAct | plugins=[re_act] | Planner classes, different agent types |
| Memory | Memory as tool | Sessions, services, deprecated APIs |
| Event hooks | 12 types, full access | Guardrails only, limited callbacks |
| Built-in AI programmer | co ai | None |
| Frontend + Backend | Built-in | Build your own |
| Approval system | Plugin-based, built-in | Build your own |
| Free credits | Yes | No |
What Other Frameworks Don't Have
These aren't about writing less code. They're capabilities other frameworks haven't built at all.
Built-in AI Programmer
An AI that knows the framework inside out
Run co ai — an AI coding assistant built with ConnectOnion that writes working agent code. Fully open-source.
co ai # Opens chat with AI that deeply understands ConnectOnionBuilt-in Frontend & Backend
Just write prompt and tools — deploy
No FastAPI backend. No React frontend. No API wiring. Framework handles it all. chat.openonion.ai ready to use.
# Other frameworks:
# write agent → build FastAPI → build React → wire APIs → deploy
# ConnectOnion:
agent = Agent("support", tools=[search, reply])
host(agent) # Done. Frontend + backend included.Ready-to-Use Tool Ecosystem
Import and use — no schema, no wiring
bash, Shell, FileTools, BrowserAutomation, Gmail, Outlook, Calendar, Memory, TodoList — all built-in. Need to customize? co copy takes the source.
from connectonion import bash, Gmail, Memory, TodoList
from connectonion.useful_tools import FileTools
from connectonion.useful_tools.browser_tools import BrowserAutomation
agent = Agent("assistant", tools=[bash, Gmail(), Memory(), FileTools()])
co copy Gmail # Copies source to your project for customizationBuilt-in Approval System
Safety by default, not by effort
Dangerous operations automatically trigger approval. Plugin-based — turn it off, customize it, or replace it entirely.
from connectonion.useful_plugins import shell_approval, tool_approval
agent = Agent("assistant", tools=[bash], plugins=[shell_approval])
# Shell commands now require approval before execution
# No permission logic needed from youSkills System
Reusable workflows with auto permission scoping
User types /commit — skill loads, git commands auto-approved, permission cleared after execution. Auto-discovers Claude Code skills.
from connectonion.useful_plugins import skills
agent = Agent("assistant", tools=[bash], plugins=[skills])
# Three-level auto-discovery:
# .co/skills/ — project-level (highest priority)
# ~/.co/skills/ — user-level
# builtin/skills/ — built-in
# .claude/skills/ — Claude Code compatible (auto-loaded)Claude Code-Equivalent Plugins
Same capabilities, open to any agent
auto_compact, subagents, ulw, tool_approval — these mirror Claude Code's internal capabilities. ConnectOnion makes them available to every agent you build.
from connectonion.useful_plugins import auto_compact, subagents, ulw
agent = Agent("researcher", tools=[search], plugins=[
auto_compact, # Auto-compress context at 90% capacity
subagents, # Spawn sub-agents with independent tools
ulw, # Ultra Light Work — fully autonomous mode
])Multi-Agent Trust System
Zero token cost for 90% of trust decisions
Fast Rules handle trust before LLM involvement. Blocklist, whitelist, invite codes — all resolved instantly. Only edge cases go to LLM.
agent = Agent("production", trust="careful")
# careful: whitelist → allow, unknown → ask LLM, blocked → deny
# Three presets for different stages:
# "open" — development (allow all)
# "careful" — staging (whitelist + LLM fallback)
# "strict" — production (whitelist only)AI Agents Building AI Agents
Why write code when you can describe what you want? ConnectOnion enables meta-agents that build, test, and deploy other agents.
🤔Traditional Development
- ✗Write boilerplate, test, debug, repeat
- ✗Manual tool integration for every agent
- ✗Hours spent on repetitive patterns
- ✗Human bottleneck in agent creation
✨AI-First with ConnectOnion
- ✓Describe your agent, let AI build it
- ✓Meta-agents generate, test, and deploy
- ✓Ship agents in minutes, not hours
- ✓AI handles the boring parts
Why AI-First Development Wins
10x Faster Development
Meta-agents generate production-ready code in minutes. What took hours now takes seconds.
Self-Improving Agents
Agents analyze their own execution, identify issues, and generate fixes automatically.
Zero Boilerplate
Focus on what you want to build, not how. AI handles imports, error handling, and best practices.
Real-World Example
Build an email automation agent using a meta-agent:
"Create an agent that monitors my inbox and replies to customer questions about pricing"
- ✓ Generated Gmail integration tool
- ✓ Created pricing knowledge base
- ✓ Built reply agent with context
- ✓ Added tests and error handling
- ✓ Agent deployed and running
Time saved: 4 hours • Lines of code written by you: 0
No credit card required • Free tier available
OpenOnion for macOS
Native menu bar app for managing your AI agents. Beautiful, fast, and always one click away.
Native Design
Beautiful polished UI following Apple HIG. Feels right at home on macOS.
Live Stats
Track uptime, requests, and status in real-time with elegant stats card.
Full Settings
Configure models, keys, and preferences through native tabbed interface.
Quick Access
Open chat, view logs, and control agents directly from menu bar.
Download for macOS
Fully code-signed and notarized • macOS 12+ • Universal Binary
Start Free - No API Key Needed
Get started immediately with free credits for GPT-4o, Claude, and Gemini.
What You Can Build
Functions = Tools
No wrappers. No decorators. Just functions.
Deploy Anywhere
From your laptop. No AWS needed.
Connect Agents
Build agent networks. Like the internet, but for AI.
Production Ready
Built for production from day one
Auto Log
.co/logs/
@xray
Breakpoints
Plugins
Just functions
Human Loop
Approval flows
For basic agents. No boilerplate.
Production features when you need them.
Not framework code. Just Python.
Ready to Start?
60 seconds to your first agent. No AWS. Just code.
