Open Agent Sdk Rust
Description
Open Agent SDK - A Rust framework for building autonomous AI agents
Installation
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open the source below and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
README
Open Agent SDK (Rust)
A lightweight, open-source Rust SDK for building AI agents. Run the full agent loop in-process — no CLI or subprocess required. Deploy anywhere: cloud, serverless, Docker, CI/CD.
Also available in [TypeScript](https://github.com/codeany-ai/open-agent-sdk-typescript) and [Go](https://github.com/codeany-ai/open-agent-sdk-go).
Features
- Multi-Provider — Supports both Anthropic Messages API and OpenAI Chat Completions API, with auto-detection by model name
- Agent Loop — Streaming agentic loop with tool execution, multi-turn conversations, and cost tracking
- 25+ Built-in Tools — Bash, Read, Write, Edit, Glob, Grep, WebFetch, WebSearch, Agent (subagents), AskUser, Tasks, Teams, Plans, Worktrees, Todos, Cron, LSP, Config, MCP Resources, ToolSearch
- Session Persistence — Save, load, fork, and resume conversations across sessions
- MCP Support — Connect to MCP servers via stdio, HTTP, and SSE transports
- Permission System — Configurable tool approval with allow/deny rules and filesystem path validation
- Hook System — 20+ hook events: PreToolUse, PostToolUse, SessionStart/End, SubagentStart/Stop, TaskCreated/Completed, FileChanged, PreCompact/PostCompact, and more
- Extended Thinking — Support for extended thinking with budget tokens
- Cost Tracking — Per-model token usage and pricing for Anthropic, OpenAI, and DeepSeek models
- Custom Tools — Implement the
Tooltrait to add your own tools - Auto-Compaction — Multi-tier context compression (micro-compact, LLM summarization, image stripping)
- Sandbox Config — Network and filesystem restrictions for tool execution
- File State Cache — LRU cache for file state tracking and staleness detection
Quick Start
[dependencies]
open-agent-sdk = "0.1.0"
tokio = { version = "1", features = ["full"] }
use open_agent_sdk::{Agent, AgentOptions, SDKMessage};
use open_agent_sdk::types;
#[tokio::main]
async fn main() {
let m
Related Skills
Agency Agents
A complete AI agency at your fingertips - From frontend wizards to Reddit community ninjas, from whimsy inject
AI Firecrawl
🔥 The API to search, scrape, and interact with the web for AI
AI Artifacts Builder
Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web tech
AI CrewAI
Framework for orchestrating role-playing, autonomous AI agents. By fostering collaborative intelligence, CrewA
AI TrendRadar
⭐AI-driven public opinion & trend monitor with multi-platform aggregation, RSS, and smart alerts.🎯 告别信息过载,你的
AI mem0
| Universal memory layer for AI Agents | 51341 | 221 | 1 |
AI