docs: make Chinese README the default

This commit is contained in:
wehub-resource-sync
2026-07-13 09:55:09 +00:00
parent 7ca6b85291
commit 1144ae55ac
+100 -94
View File
@@ -1,3 +1,9 @@
<!-- WEHUB_ZH_README -->
> [!NOTE]
> 本文档由 WeHub 基于上游 README 翻译整理,属于社区翻译,非官方中文文档。
> [English](./README.en.md) · [原始项目](https://github.com/CopilotKit/CopilotKit) · [上游 README](https://github.com/CopilotKit/CopilotKit/blob/HEAD/README.md)
> 原作者、版权与许可证归属以原始项目及本仓库 LICENSE 文件为准。
<div align=center>
<img width="120" height="120" alt="FavIcon" src="https://github.com/user-attachments/assets/779de607-2b8d-4751-872b-1243e97c7d18" />
@@ -6,16 +12,16 @@
<div align=center>
[Docs](https://docs.copilotkit.ai/?ref=github_readme) ·
[Examples](https://www.copilotkit.ai/examples) ·
[Enterprise Intelligence Platform](https://go.copilotkit.ai/enterprise-intelligence-platform) ·
[文档](https://docs.copilotkit.ai/?ref=github_readme) ·
[示例](https://www.copilotkit.ai/examples) ·
[企业智能平台(Enterprise Intelligence Platform](https://go.copilotkit.ai/enterprise-intelligence-platform) ·
[Discord](https://discord.gg/6dffbvGU3D?ref=github_readme)
</div>
Build **agent-native applications** — on any framework, on any surface.
构建 **面向智能体(agent-native)的应用** —— 适用于任意框架、任意界面。
Generative UI, shared state, and human-in-the-loop workflows for React, Angular, Vue, React Native — and beyond the browser.
为 React、Angular、Vue、React Native 提供生成式 UIGenerative UI)、共享状态(shared state)和人机协同(human-in-the-loop)工作流 —— 并延伸至浏览器之外。
</div>
@@ -51,120 +57,120 @@ Generative UI, shared state, and human-in-the-loop workflows for React, Angular,
---
## What is CopilotKit
## 什么是 CopilotKit
CopilotKit is a best-in-class SDK for building full-stack agentic applications, Generative UI, and chat applications.
CopilotKit 是业界一流的 SDK,用于构建全栈智能体(agentic)应用、生成式 UI 和聊天应用。
What started as a React library is now a **multi-platform agentic framework**: the same agent can power your web app, your mobile app, and your team's Slack workspace.
最初只是一个 React 库,现已发展为 **多平台智能体框架**:同一个智能体可同时驱动你的 Web 应用、移动应用和团队的 Slack 工作区。
We are the company behind the **[AG-UI Protocol](https://github.com/ag-ui-protocol/ag-ui)** - adopted by Google, LangChain, AWS, Microsoft, Mastra, PydanticAI, and more!
我们正是 **[AG-UI Protocol](https://github.com/ag-ui-protocol/ag-ui)** 背后的公司 —— 已被 GoogleLangChainAWSMicrosoftMastraPydanticAI 等采纳!
## Quick Start
## 快速开始
Up and running in under five minutes. All you need is an LLM key (OpenAI, Anthropic, Gemini, etc.).
五分钟内即可启动运行。你只需一个 LLM API 密钥(OpenAIAnthropicGemini 等)。
```bash
npx copilotkit@latest create
```
## Agent Skills
## 智能体技能(Agent Skills
CopilotKit ships [agent skills](https://docs.copilotkit.ai) that teach your coding agent (Claude Code, Codex, Cursor, Gemini, and others) how to set up, build with, integrate, debug, and upgrade CopilotKit.
CopilotKit 提供 [agent skills](https://docs.copilotkit.ai),用于教导你的编程智能体(Claude CodeCodexCursorGemini 等)如何安装、构建、集成、调试和升级 CopilotKit
Install them into any project directory:
安装到任意项目目录:
```bash
npx copilotkit@latest skills install
```
Run it again any time to refresh to the latest skills.
随时再次运行即可更新到最新技能。
## Bring Your App to Life
## 让你的应用焕发生机
https://github.com/user-attachments/assets/72b7b4f3-b6e7-460c-a932-5746fe3c8db3
<div align="center"> Add AI to your app in 1 minute</div>
<div align="center"> 1 分钟为你的应用接入 AI</div>
**Features:**
**功能特性:**
- **Chat UI** A fully customizable chat interface that supports message streaming, tool calls, and agent responses.
- **Backend Tool Rendering** Enables agents to call backend tools that return UI components rendered directly in the client.
- **Generative UI** Allows agents to generate and update UI components dynamically at runtime based on user intent and agent state.
- **Shared State** A synchronized state layer that both agents and UI components can read from and write to in real time.
- **Human-in-the-Loop** Lets agents pause execution to request user input, confirmation, or edits before continuing.
- **Self-Learning** _(early access)_ Agents that continuously improve from user feedback via in-context reinforcement learning (CLHF).
- **Chat UI** 完全可定制的聊天界面,支持消息流式传输、工具调用和智能体响应。
- **Backend Tool Rendering** 让智能体可调用后端工具,返回的 UI 组件直接在客户端渲染。
- **Generative UI** 智能体可根据用户意图和智能体状态,在运行时动态生成并更新 UI 组件。
- **Shared State** 同步状态层,智能体和 UI 组件均可实时读写。
- **Human-in-the-Loop** 智能体可暂停执行,在继续之前请求用户输入、确认或编辑。
- **Self-Learning** _(抢先体验)_ – 通过上下文强化学习(CLHFContinuous Learning from Human Feedback)根据用户反馈持续改进的智能体。
## 🧩 Works With Your Stack
## 🧩 适配你的技术栈
One agent backend. Every frontend.
一套智能体后端。适配所有前端。
| Platform | Status | Get Started |
| 平台 | 状态 | 快速开始 |
| ------------------------------------------- | ------------ | ----------------------------------------------------------------------------------------------------------- |
| ⚛️ React / Next.js | ✅ GA | [Quickstart](https://docs.copilotkit.ai/built-in-agent/quickstart) |
| 🅰️ Angular | ✅ Supported | [Source Code - Quickstart coming soon](https://github.com/CopilotKit/CopilotKit/tree/main/packages/angular) |
| 💚 Vue | ✅ Supported | [Source Code - Quickstart coming soon](https://github.com/CopilotKit/CopilotKit/tree/main/packages/vue) |
| 📱 React Native | ✅ Supported | [Quickstart](https://docs.copilotkit.ai/react-native) |
| 💬 Slack / MS Teams / Discord / Google Chat | 🟡 Beta | [Request early access](https://go.copilotkit.ai/beyond-the-web-form) |
| ⚛️ React / Next.js | ✅ GA | [快速开始](https://docs.copilotkit.ai/built-in-agent/quickstart) |
| 🅰️ Angular | ✅ 已支持 | [源代码 - 快速入门即将推出](https://github.com/CopilotKit/CopilotKit/tree/main/packages/angular) |
| 💚 Vue | ✅ 已支持 | [源代码 - 快速入门即将推出](https://github.com/CopilotKit/CopilotKit/tree/main/packages/vue) |
| 📱 React Native | ✅ 已支持 | [快速开始](https://docs.copilotkit.ai/react-native) |
| 💬 Slack / MS Teams / Discord / Google Chat | 🟡 Beta | [申请抢先体验](https://go.copilotkit.ai/beyond-the-web-form) |
Your agent logic stays the same — AG-UI handles the wire protocol, CopilotKit handles the UI layer for each framework.
智能体逻辑保持不变 —— AG-UI 负责线协议,CopilotKit 负责各框架的 UI 层。
## 💬 Beyond the Browser: Slack & Microsoft Teams (Discord, Google Chat coming soon...)
## 💬 超越浏览器:Slack Microsoft TeamsDiscordGoogle Chat 即将推出……)
Your agents can run and generate Generative UI beyond the web app (**[Learn more](https://www.copilotkit.ai/integrations)**).
你的智能体可在 Web 应用之外运行并生成生成式 UI(**[了解更多](https://www.copilotkit.ai/integrations)**).
CopilotKit now lets you deploy the **same agent** to the places your users already work:
CopilotKit 现可让你将 **同一个智能体** 部署到用户日常工作的平台:
- **Slack** Agents as first-class Slack apps: threads, tool calls, and human-in-the-loop approvals right in the channel.
- **Microsoft Teams** Bring agentic workflows to the enterprise, where your org already lives.
- **Slack** 智能体作为一等 Slack 应用:频道内即可使用线程、工具调用和人机协同审批。
- **Microsoft Teams** 将智能体工作流带入企业,接入组织已有的协作平台。
🔒 **Early access:** We're onboarding teams now.
🔒 **抢先体验:** 我们正在为团队开通接入。
👉 **[Request early access](https://go.copilotkit.ai/beyond-the-web-form)**
👉 **[申请抢先体验](https://go.copilotkit.ai/beyond-the-web-form)**
## 🧠 Self-Learning Agents
## 🧠 自学习智能体
Improve your product by learning over time.
通过持续学习不断改进你的产品。
With **Continuous Learning from Human Feedback (CLHF)**, part of the [CopilotKit Intelligence Platform](https://www.copilotkit.ai/copilotkit-intelligence), agents improve with every interaction:
借助 **Continuous Learning from Human Feedback (CLHF)** —— [CopilotKit Intelligence Platform](https://www.copilotkit.ai/copilotkit-intelligence), 的一部分 —— 智能体在每次交互中不断进步:
- **In-context reinforcement learning** Agents automatically improve from user interactions, no model fine-tuning required.
- **Automatic prompt augmentation** Agent behavior adapts based on recent interactions and outcomes.
- **Per-user adaptation** Agents learn individual preferences and get better for each user over time.
- **Threads & persistence** Full interaction history — generative UI, human-in-the-loop, shared state — captured across sessions.
- **In-context reinforcement learning** 智能体根据用户交互自动改进,无需微调模型。
- **Automatic prompt augmentation** 智能体行为根据近期交互与结果自适应调整。
- **Per-user adaptation** 智能体学习个人偏好,随时间推移为每位用户提供更好的体验。
- **Threads & persistence** 完整交互历史 —— 生成式 UI、人机协同、共享状态 —— 跨会话持久保存。
Available via CopilotKit Cloud or self-hosted.
可通过 CopilotKit Cloud 或自托管方式使用。
🔒 **Early access:** We're onboarding teams now.
🔒 **抢先体验:** 我们正在为团队开通接入。
👉 **[Request early access](https://go.copilotkit.ai/beyond-the-web-form)**
👉 **[申请抢先体验](https://go.copilotkit.ai/beyond-the-web-form)**
https://github.com/user-attachments/assets/7372b27b-8def-40fb-a11d-1f6585f556ad
What this gives you:
你将获得:
- **CopilotKit installed** Core packages are fully set up in your app
- **Provider configured** Context, state, and hooks ready to use
- **Agent <> UI connected** Agents can stream actions and render UI immediately
- **Deployment-ready** Your app is ready to deploy
- **CopilotKit installed** 核心包已在你的应用中完整配置
- **Provider configured** 上下文、状态和 hooks 已就绪可用
- **Agent <> UI connected** 智能体可流式传输操作并即时渲染 UI
- **Deployment-ready** 你的应用已可部署
[Complete getting started guide](https://docs.copilotkit.ai/langgraph/quickstart)
[完整入门指南](https://docs.copilotkit.ai/langgraph/quickstart)
## How it works:
## 工作原理:
CopilotKit connects your UI, agents, and tools into a single interaction loop.
CopilotKit 将你的 UI、智能体和工具连接为单一交互循环。
![CopilotKit Diagram — Motion x2 6 sec version](https://github.com/user-attachments/assets/6f175d86-bd22-4c26-a13a-6013654ed542)
This enables:
由此可实现:
- Agents that ask users for input
- Tools that render UI
- Stateful workflows across steps and sessions
- One agent, deployed across web, mobile, and chat platforms
- 向用户请求输入的智能体
- 可渲染 UI 的工具
- 跨步骤与会话的有状态工作流
- 同一智能体,部署于 Web、移动和聊天平台
## ⭐️ useAgent Hook
The `useAgent` hook sits directly on AG-UI, giving you full programmatic control over the agent connection.
`useAgent` hook 直接构建于 AG-UI 之上,让你对智能体连接拥有完整的编程控制。
```ts
// Programmatically access and control your agents
@@ -179,31 +185,31 @@ return <div>
</div>
```
Check out the [useAgent docs](https://go.copilotkit.ai/useagent-docs) to learn more.
查看 [useAgent 文档](https://go.copilotkit.ai/useagent-docs) 了解更多。
https://github.com/user-attachments/assets/67928406-8abc-49a1-a851-98018b52174f
## Generative UI
## 生成式 UIGenerative UI
Generative UI is a core CopilotKit pattern that allows agents to dynamically render UI as part of their workflow.
生成式 UIGenerative UI)是 CopilotKit 的核心模式,允许智能体(agent)在工作流中动态渲染 UI。
https://github.com/user-attachments/assets/3cfacac0-4ffd-457a-96f9-d7951e4ab7b6
### Compare the Three Types
### 对比三种类型
<img width="708" height="311" alt="image" src="https://github.com/user-attachments/assets/962f49c2-31ea-43c5-b2a3-7cdde114705a" />
#### Explore:
#### 探索:
- [Static (AG-UI Protocol)](https://docs.copilotkit.ai/ag-ui-protocol)
- [Declarative (A2UI)](https://docs.copilotkit.ai/generative-ui/specs/a2ui#using-a2ui-with-copilotkit)
- [Open-Ended (MCP Apps & Open JSON)](https://docs.copilotkit.ai/generative-ui/specs/mcp-apps)
- [静态(AG-UI Protocol](https://docs.copilotkit.ai/ag-ui-protocol)
- [声明式(A2UI](https://docs.copilotkit.ai/generative-ui/specs/a2ui#using-a2ui-with-copilotkit)
- [开放式(MCP Apps & Open JSON](https://docs.copilotkit.ai/generative-ui/specs/mcp-apps)
[Generative UI educational repo](https://github.com/CopilotKit/CopilotKit/tree/main/examples/showcases/generative-ui)
[生成式 UI 教学仓库](https://github.com/CopilotKit/CopilotKit/tree/main/examples/showcases/generative-ui)
## 🖥️ AG-UI: The AgentUser Interaction Protocol
## 🖥️ AG-UI:智能体–用户交互协议(The AgentUser Interaction Protocol
Connect agent workflows to user-facing apps, with deep partnerships and 1st-party integrations across the agentic stack—including LangChain, CrewAI, Mastra, PydanticAI, and more.
将智能体工作流连接到面向用户的应用,在智能体技术栈中拥有深度合作与第一方集成——涵盖 LangChainCrewAIMastraPydanticAI 等。
[![AG-UI](https://github.com/user-attachments/assets/a625237a-cfc1-45fc-8d0c-637316b81291)](https://go.copilotkit.ai/ag-ui)
@@ -214,43 +220,43 @@ npx create-ag-ui-app my-agent-app
```
<a href="https://github.com/ag-ui-protocol/ag-ui" target="_blank">
Learn more in the AG-UI README →
AG-UI README 中了解更多
</a>
## 🤝 Community
## 🤝 社区
- [What's New](https://docs.copilotkit.ai/whats-new)
<h3>Have questions or need help?</h3>
- [最新动态](https://docs.copilotkit.ai/whats-new)
<h3>有问题或需要帮助?</h3>
<a href="https://discord.gg/6dffbvGU3D?ref=github_readme" target="_blank">
Join our Discord →
加入我们的 Discord →
</a> </br>
<a href="https://docs.copilotkit.ai/?ref=github_readme" target="_blank">
Read the Docs
阅读文档
</a> </br>
<a href="https://dashboard.operations.copilotkit.ai?ref=github_readme" target="_blank">
Try the Enterprise Intelligence Platform
试用企业智能平台(Enterprise Intelligence Platform
</a>
<h3>Stay up to date with our latest releases!</h3>
<h3>及时了解我们的最新发布!</h3>
<a href="https://www.linkedin.com/company/copilotkit/" target="_blank">
Follow us on LinkedIn →
LinkedIn 上关注我们
</a> </br>
<a href="https://x.com/copilotkit" target="_blank">
Follow us on X
在 X 上关注我们
</a>
## 🙋🏽‍♂️ Contributing
## 🙋🏽‍♂️ 贡献
Thanks for your interest in contributing to CopilotKit! 💜
感谢你有兴趣为 CopilotKit 做出贡献!💜
We value all contributions, whether it's through code, documentation, creating demo apps, or just spreading the word.
我们重视所有贡献,无论是通过代码、文档、创建演示应用,还是仅仅传播项目理念。
Here are a few useful resources to help you get started:
以下是一些实用资源,可帮助你入门:
- For code contributions, [CONTRIBUTING.md](./CONTRIBUTING.md).
- For documentation-related contributions, [check out the documentation contributions guide](https://docs.copilotkit.ai/contributing/docs-contributions?ref=github_readme).
- 如需贡献代码,请参阅 [CONTRIBUTING.md](./CONTRIBUTING.md)
- 如需贡献文档,[查看文档贡献指南](https://docs.copilotkit.ai/contributing/docs-contributions?ref=github_readme).
- Want to contribute but not sure how? [Join our Discord](https://discord.gg/6dffbvGU3D) and we'll help you out!
- 想贡献但不确定从何入手?[加入我们的 Discord](https://discord.gg/6dffbvGU3D),我们会协助你!
## 📄 License
## 📄 许可证
This repository's source code is available under the [MIT License](https://github.com/CopilotKit/CopilotKit/blob/main/LICENSE).
本仓库的源代码依据 [MIT License](https://github.com/CopilotKit/CopilotKit/blob/main/LICENSE).