jinfanzheng/kode-sdk-csharp
Kode Agent SDK for .NET - Event-driven AI Agent runtime supporting Anthropic Claude and OpenAI GPT models with tool calling, state management, and event streaming
46 stars15 forksUpdated Jan 26, 2026
npx skills add jinfanzheng/kode-sdk-csharpREADME
Kode Agent SDK for .NET
中文版: 查看中文 README
A powerful AI Agent runtime SDK built on .NET 10, supporting Anthropic Claude and OpenAI GPT models, with comprehensive capabilities for tool calling, state management, event streaming, and more. Designed for building production-grade AI applications.
Project Background
Kode Agent SDK for .NET is the C# implementation of Kode SDK, providing feature parity with the TypeScript version:
- Event-Driven Architecture - Three-channel event system (Progress, Control, Monitor) for separation of concerns
- Complete State Management - Support for persistence, crash recovery, and resumable execution
- Flexible Tool System - 20+ built-in tools with support for custom tools and MCP protocol
- Multi-Model Support - Anthropic Claude, OpenAI GPT, and compatible APIs
- Enterprise Features - Permission control, sandbox execution, dependency injection, logging integration
Table of Contents
- Features
- Sandbox (Local vs Docker)
- Architecture Overview
- Quick Start
- Event Subscriptions
- Custom Tools
- Model Providers
- Dependency Injection
- MCP Integration
- Permission Control
- Built-in Tools
- State Persistence
- Project Structure
- Documentation
- Running Examples
- License
- Contributing
- Community
- Related Links
Features
| Feature | Description | Documentation |
|---|---|---|
| Multi-Model Support | Support for Anthropic Claude (Claude 4, 3.5) and OpenAI GPT (GPT-4o, o1) series models, plus compatible APIs | Model Providers |
| Rich Tool System | 20+ built-in tools (file system, shell, todo management, etc.), support for custom tools and MCP protocol | Tool Development Guide |
| Three-Channel Event Stream | Progress (real-time output), Control (approval flow), Monitor (logging) separated architecture | Event System Details |
| State Persistence | JSON file storage and Redis distributed storage, support for session recovery and resumable execution | State Storage |
| Permission Control | Fine-grained tool permission management, support for auto-approval, manual approval, and deny policies | Permission Control System |
| Sandbox Execution | Secure command execution environment, support for local and Docker sandboxes | Sandbox Environments |
| Source Generator | Compile-time tool schema generation, zero reflection overhead, type-safe | Tool Development Guide |
| MCP Integration | Native Model Context Protocol support, easy integration with external tool ecosystem | MCP Protocol Integration |
| Dependency Injection | Complete Microsoft.Extensions.DependencyInjection support | Dependency Injection |
| Template System | Predefined agent templates for quick creation of scenario-specific agents | [Sub-Agent Delegation] |
...
Publisher
Statistics
Stars46
Forks15
Open Issues0
LicenseMIT License
CreatedJan 17, 2026