打开运行时,用于构建类似代理产品的 Claude 代码和文档
Event-driven, long-running AI Agent framework with enterprise-grade persistence and multi-agent collaboration.
One-liner setup (install dependencies and build):
./quickstart.shOr install as a dependency:
npm install @shareai-lab/kode-sdkSet environment variables:
export ANTHROPIC_API_KEY=sk-...
export ANTHROPIC_MODEL_ID=claude-sonnet-4-20250514 # optional, default: claude-sonnet-4-20250514
export ANTHROPIC_BASE_URL=https://api.anthropic.com # optional, default: https://api.anthropic.com$env:ANTHROPIC_API_KEY="sk-..."
$env:ANTHROPIC_MODEL_ID="claude-sonnet-4-20250514" # optional, default: claude-sonnet-4-20250514
$env:ANTHROPIC_BASE_URL="https://api.anthropic.com" # optional, default: https://api.anthropic.comMinimal example:
…Run examples:
npm run example:getting-started # Minimal chat
npm run example:agent-inbox # Event-driven inbox
npm run example:approval # Tool approval workflow
npm run example:room # Multi-agent collaboration
npm run example:opensandbox # OpenSandbox basic usageOpenSandbox quick config:
export OPEN_SANDBOX_API_KEY=... # optional (required only when auth is enabled)
export OPEN_SANDBOX_ENDPOINT=http://127.0.0.1:8080 # optional
export OPEN_SANDBOX_IMAGE=ubuntu # optionalFor production deployments serving many users, we recommend the Worker Microservice Pattern:
…Key Principles:
See docs/en/guides/architecture.md for detailed deployment guides.
| Provider | Streaming | Tools | Reasoning | Files |
|---|---|---|---|---|
| Anthropic | ✅ | ✅ | ✅ Extended Thinking | ✅ |
| OpenAI | ✅ | ✅ | ✅ | ✅ |
| Gemini | ✅ | ✅ | ✅ | ✅ |
Note: OpenAI-compatible services (DeepSeek, GLM, Qwen, Minimax, OpenRouter, etc.) can be used via
OpenAIProviderwith custombaseURLconfiguration. See Providers Guide for details.
| Section | Description |
|---|---|
| Getting Started | |
| Installation | Setup and configuration |
| Quickstart | Build your first Agent |
| Concepts | Core concepts explained |
| Guides | |
| Events | Three-channel event system |
| Tools | Built-in tools & custom tools |
| E2B Sandbox | E2B cloud sandbox integration |
| OpenSandbox | OpenSandbox self-hosted sandbox integration |
| Skills | Skills system for reusable prompts |
| Providers | Model provider configuration |
| Database | SQLite/PostgreSQL persistence |
| Resume & Fork | Crash recovery & branching |
| Project | |
| Contribution Guide | How to contribute |
| Reference | |
| API Reference | Complete API documentation |
| Examples | All examples explained |
MIT
暂无开放 Issues,或尚未同步最近议题。