Skip to content

Commit 2b4e433

Browse files
Merge branch 'ag-ui-protocol:main' into kotlinsdk
2 parents 0a8d491 + ccf517f commit 2b4e433

File tree

132 files changed

+16185
-3713
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

132 files changed

+16185
-3713
lines changed

.github/workflows/dojo-e2e.yml

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ jobs:
1414
fail-fast: false
1515
matrix:
1616
include:
17+
- suite: a2a-middleware
18+
test_path: tests/a2aMiddlewareTests
19+
services: ["dojo","a2a-middleware"]
20+
wait_on: http://localhost:9999,tcp:localhost:8011,tcp:localhost:8012,tcp:localhost:8013,tcp:localhost:8014
1721
- suite: adk-middleware
1822
test_path: tests/adkMiddlewareTests
1923
services: ["dojo","adk-middleware"]
@@ -26,10 +30,14 @@ jobs:
2630
test_path: tests/crewAITests
2731
services: ["dojo","crew-ai"]
2832
wait_on: http://localhost:9999,tcp:localhost:8003
29-
- suite: langgraph
30-
test_path: tests/langgraphTests
31-
services: ["dojo","langgraph-platform-python","langgraph-platform-typescript"]
32-
wait_on: http://localhost:9999,tcp:localhost:8005,tcp:localhost:8006
33+
- suite: langgraph-python
34+
test_path: tests/langgraphPythonTests
35+
services: ["dojo","langgraph-platform-python"]
36+
wait_on: http://localhost:9999,tcp:localhost:8005
37+
- suite: langgraph-typescript
38+
test_path: tests/langgraphTypescriptTests
39+
services: ["dojo","langgraph-platform-typescript"]
40+
wait_on: http://localhost:9999,tcp:localhost:8006
3341
- suite: langgraph-fastapi
3442
test_path: tests/langgraphFastAPITests
3543
services: ["dojo","langgraph-fastapi"]
@@ -62,10 +70,10 @@ jobs:
6270
test_path: tests/serverStarterAllFeaturesTests
6371
services: ["dojo","server-starter-all"]
6472
wait_on: http://localhost:9999,tcp:localhost:8001
65-
- suite: vercel-ai-sdk
66-
test_path: tests/vercelAISdkTests
67-
services: ["dojo"]
68-
wait_on: http://localhost:9999
73+
# - suite: vercel-ai-sdk
74+
# test_path: tests/vercelAISdkTests
75+
# services: ["dojo"]
76+
# wait_on: http://localhost:9999
6977

7078
steps:
7179
- name: Checkout code

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
- name: Set up Node.js
5959
uses: actions/setup-node@v4
6060
with:
61-
node-version: '18'
61+
node-version: '22'
6262

6363
- name: Install protoc
6464
uses: arduino/setup-protoc@v3

README.md

Lines changed: 22 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
# <img src="https://github.com/user-attachments/assets/ebc0dd08-8732-4519-9b6c-452ce54d8058" alt="ag-ui Logo" width="22"/> AG-UI: The Agent-User Interaction Protocol
33

4-
AG-UI is a lightweight, event-based protocol that standardizes how AI agents connect to user-facing applications.
4+
AG-UI is an open, lightweight, event-based protocol that standardizes how AI agents connect to user-facing applications.
55
Built for simplicity and flexibility, it enables seamless integration between AI agents, real time user context, and user interfaces.
66

77
---
@@ -14,15 +14,7 @@ Built for simplicity and flexibility, it enables seamless integration between AI
1414
![MIT](https://img.shields.io/github/license/copilotkit/copilotkit?color=%236963ff&label=License)
1515
![Discord](https://img.shields.io/discord/1379082175625953370?logo=discord&logoColor=%23FFFFFF&label=Discord&color=%236963ff)
1616

17-
<a href="https://discord.gg/Jd3FzfdJa8" target="_blank">
18-
Join our Discord →
19-
</a> &nbsp;&nbsp;&nbsp;
20-
<a href="https://ag-ui.com/" target="_blank">
21-
Read the Docs →
22-
</a> &nbsp;&nbsp;&nbsp;
23-
<a href="https://x.com/CopilotKit" target="_blank">
24-
Follow us →
25-
</a>
17+
<a href="https://discord.gg/Jd3FzfdJa8" target="_blank"> Join our Discord → </a> &nbsp;&nbsp;&nbsp; <a href="https://ag-ui.com/" target="_blank"> Read the Docs → </a> &nbsp;&nbsp;&nbsp; <a href="https://dojo.ag-ui.com/" target="_blank"> Go to the AG-UI Dojo → </a> &nbsp;&nbsp;&nbsp; <a href="https://x.com/CopilotKit" target="_blank"> Follow us → </a>
2618

2719
<img width="4096" height="1752" alt="Your application-AG-UI protocol" src="https://github.com/user-attachments/assets/dc58c64c-3257-490a-b827-e163475f4166" />
2820

@@ -31,9 +23,12 @@ Create a new AG-UI application in seconds:
3123
```bash
3224
npx create-ag-ui-app my-agent-app
3325
```
34-
<h3>Building AG-UI Integrations (new frameworks):</h3>
3526

36-
- [Build new integrations (Quickstart)](https://go.copilotkit.ai/agui-contribute)
27+
<h3> Useful Links:</h3>
28+
29+
- [The AG-UI Dojo](https://dojo.ag-ui.com/)
30+
- [Build AG-UI-powered applications(Quickstart)](https://docs.ag-ui.com/quickstart/applications)
31+
- [Build new AG-UI framework integrations (Quickstart)](https://go.copilotkit.ai/agui-contribute)
3732
- [Book a call to discuss an AG-UI integration with a new framework](https://calendly.com/markus-copilotkit/ag-ui)
3833
- [Join the Discord Community](https://discord.gg/Jd3FzfdJa8)
3934

@@ -87,14 +82,14 @@ AG-UI was born from CopilotKit's initial partnership with LangGraph and CrewAI -
8782
| Framework | Status | AG-UI Resources | Integrations |
8883
| ------------------------------------------------------------------ | ------------------------ | ---------------------------------------------------------------------------- | ------------------------ |
8984
| No-framework | ✅ Supported | ➡️ Docs coming soon | |
90-
| [LangGraph](https://www.langchain.com/langgraph) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/langgraph/) [Demos](https://dojo.ag-ui.com/langgraph-fastapi/feature/shared_state) | Partnership |
91-
| [CrewAI](https://crewai.com/) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/crewai-flows) [Demos](https://dojo.ag-ui.com/crewai/feature/shared_state) | Partnership |
92-
| [Mastra](https://mastra.ai/) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/mastra/) [Demos](https://dojo.ag-ui.com/mastra/feature/shared_state) | 1st party |
93-
| [AG2](https://ag2.ai/) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/ag2/) [Demos](https://dojo.ag-ui.com/ag2/feature/shared_state) | 1st party |
94-
| [Agno](https://github.com/agno-agi/agno) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/agno/) [Demos](https://dojo.ag-ui.com/agno/feature/shared_state) | 1st party |
95-
| [LlamaIndex](https://github.com/run-llama/llama_index) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/llamaindex/) [Demos](https://dojo.ag-ui.com/llamaindex/feature/shared_state) | 1st party |
96-
| [Pydantic AI](https://github.com/pydantic/pydantic-ai) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/pydantic-ai/) [Demos](https://dojo.ag-ui.com/pydantic-ai/feature/shared_state) | 1st party |
97-
| [Google ADK](https://google.github.io/adk-docs/get-started/) | 🛠️ [PR](https://github.com/ag-ui-protocol/ag-ui/pull/274) | | 1st party |
85+
| [LangGraph](https://www.langchain.com/langgraph) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/langgraph/) 🎮 [Demos](https://dojo.ag-ui.com/langgraph-fastapi/feature/shared_state) | Partnership |
86+
| [Mastra](https://mastra.ai/) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/mastra/) 🎮 [Demos](https://dojo.ag-ui.com/mastra) | 1st party |
87+
| [Pydantic AI](https://github.com/pydantic/pydantic-ai) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/pydantic-ai/) 🎮 [Demos](https://dojo.ag-ui.com/pydantic-ai/feature/shared_state) | 1st party |
88+
| [Google ADK](https://google.github.io/adk-docs/get-started/) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/adk) 🎮 [Demos](https://dojo.ag-ui.com/adk-middleware) | Partnership |
89+
| [Agno](https://github.com/agno-agi/agno) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/agno/) 🎮 [Demos](https://dojo.ag-ui.com/agno) | 1st party |
90+
| [LlamaIndex](https://github.com/run-llama/llama_index) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/llamaindex/) 🎮 [Demos](https://dojo.ag-ui.com/llamaindex/feature/shared_state) | 1st party |
91+
| [CrewAI](https://crewai.com/) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/crewai-flows) 🎮 [Demos](https://dojo.ag-ui.com/crewai/feature/shared_state) | Partnership |
92+
| [AG2](https://ag2.ai/) | ✅ Supported | ➡️ [Docs](https://docs.copilotkit.ai/ag2/) | 1st party |
9893
| [AWS Bedrock Agents](https://aws.amazon.com/bedrock/agents/) | 🛠️ In Progress || 1st party |
9994
| [AWS Strands Agents](https://github.com/strands-agents/sdk-python) | 🛠️ In Progress || 1st Party |
10095
| [Vercel AI SDK](https://github.com/vercel/ai) | 🛠️ In Progress || Community |
@@ -117,8 +112,8 @@ AG-UI was born from CopilotKit's initial partnership with LangGraph and CrewAI -
117112
[View all supported frameworks →](https://ag-ui.com/frameworks)
118113

119114

120-
## ✨ Hello World App
121-
115+
## Examples
116+
### Hello World App
122117

123118
Video:
124119

@@ -128,12 +123,13 @@ https://agui-demo.vercel.app/
128123

129124

130125

131-
## 🧩 AG-UI Showcase: The AG-UI Dojo (Building-Blocks Viewer)
132-
The [AG-UI Dojo](https://dojo.ag-ui.com/langgraph-fastapi/feature/shared_state) showcases many of the building blocks that AG-UI supports ([AG-UI Dojo Source Code](https://github.com/ag-ui-protocol/ag-ui/tree/main/typescript-sdk/apps/dojo)) with each Agent Framework integration.
126+
## The AG-UI Dojo (Building-Blocks Viewer)
127+
The AG-UI Dojo demonstrates AG-UI's core building blocks through simple, focused examples—each just 50-200 lines of code.
128+
129+
View the source code for the Dojo and all framework integrations [here](https://github.com/ag-ui-protocol/ag-ui/tree/main/typescript-sdk/apps/dojo).
133130

134-
The building blocks are designed to be simple and focused -- between 50-200 lines of code.
131+
https://github.com/user-attachments/assets/c298eea8-3f39-4a94-b968-7712429b0c49
135132

136-
https://github.com/user-attachments/assets/a67d3d54-36b2-4c7a-ac69-a0ca01365d5b
137133

138134

139135
## 🙋🏽‍♂️ Contributing to AG-UI

docs/ag_ui.md

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
# AG‑UI: The Agent–User Interaction Protocol
2+
3+
*A horizontal standard to bring AI agents into user‑facing frontend applications.*
4+
5+
AG‑UI is the boundary layer where agents and users meet. It standardizes how agent state, UI intents, and user interactions flow between your model/agent runtime and your app’s frontend—so you can ship reliable, debuggable, user‑friendly agentic features fast.
6+
7+
---
8+
9+
## Built with the ecosystem
10+
11+
**First‑party partnerships & integrations**
12+
13+
> **Logo strip goes here** (e.g., LangGraph • CrewAI • Autogen 2 • LlamaIndex • Mastra • Pydantic AI • Vercel AI SDK • Next.js)
14+
15+
Short blurb: *AG‑UI works across leading agent frameworks and frontend stacks, with shared vocabulary and primitives that keep your UX consistent as your agents evolve.*
16+
17+
---
18+
19+
## Building blocks (today & upcoming)
20+
21+
- **Streaming chat** — Token‑level and tool‑event streaming for responsive UIs.
22+
- **Static generative UI** — Render model output into stable, typed components.
23+
- **Declarative generative UI** — Let agents propose UI trees; app decides what to mount.
24+
- **Frontend tools** — Safe, typed tool calls that bridge agent logic to app actions.
25+
- **Interrupts & human‑in‑the‑loop** — Pause, approve, edit, or steer mid‑flow.
26+
- **In‑chat + in‑app interactions** — Chat commands alongside regular app controls.
27+
- **Attachments & multimodality** — Files, images, audio, and structured payloads.
28+
- **Thinking steps** — Expose summaries/redactions of chain‑of‑thought artifacts to users, safely.
29+
- **Sub‑agent calls** — Orchestrate nested agents and delegate specialized tasks.
30+
- **Agent steering** — Guardrails, policies, and UX affordances to keep agents on track.
31+
32+
> **CTA to deeper docs***See the full capability map in the docs.*
33+
34+
---
35+
36+
## Design patterns
37+
38+
Explore reusable interaction patterns for agentic UX:
39+
40+
- **Link‑out:** [AI‑UI Design Patterns →](/patterns) *(placeholder URL)*
41+
42+
---
43+
44+
## Why AG‑UI
45+
46+
**Agentic apps break the classic request/response contract.** Agents run for longer, stream work as they go, and make nondeterministic choices that can affect your UI and state. AG‑UI defines a clean, observable boundary so frontends remain predictable while agents stay flexible.
47+
48+
### What’s hard about user‑facing agents
49+
50+
- Agents are **long‑running** and **stream** intermediate work—often across multi‑turn sessions.
51+
- Agents are **nondeterministic** and can **control UI** in ways that must be supervised.
52+
- Apps must mix **structured + unstructured IO** (text, voice, tool calls, state updates).
53+
- Agents need **composition**: agents **call sub‑agents**, often non-deterministically.
54+
55+
With AG‑UI, these become deliberate, well‑typed interactions rather than ad‑hoc wiring.
56+
57+
---
58+
59+
## Deeper proof (docs, demos, code)
60+
61+
| Framework / Platform | What works today | Docs | Demo |
62+
| ----------------------- | -------------------------------------- | --------- | --------- |
63+
| LangGraph | Streams, tools, interrupts, sub‑agents | [Docs](#) | [Demo](#) |
64+
| CrewAI | Tools, action routing, steering | [Docs](#) | [Demo](#) |
65+
| Autogen 2 | Multi‑agent orchestration, messaging | [Docs](#) | [Demo](#) |
66+
| LlamaIndex | Query/agent routing, UI intents | [Docs](#) | [Demo](#) |
67+
| OpenAI Realtime | Live stream, events, attachments | [Docs](#) | [Demo](#) |
68+
| Vercel AI SDK / Next.js | Edge streaming, SSR hydration | [Docs](#) | [Demo](#) |
69+
70+
> **Note:** Replace placeholders with actual URLs to docs and demos.
71+
72+
---
73+
74+
## Quick links
75+
76+
- **Get started***/docs/getting-started* (placeholder)
77+
- **Concepts***/docs/concepts/agent-ui-boundary* (placeholder)
78+
- **Reference***/docs/reference* (placeholder)
79+
- **Patterns***/patterns* (placeholder)
80+
81+
---
82+
83+
## Optional section: How AG‑UI fits
84+
85+
- **Protocol**: Events, intents, and payload schemas shared by agents & apps.
86+
- **Runtime adapters**: Bindings for popular agent frameworks.
87+
- **Frontend kit**: Lightweight client + components to handle streaming & interrupts.
88+
- **Observability hooks**: Surface interaction timelines for debugging & learning.
89+
90+
*(Include a simple diagram later: Agent(s) ⇄ AG‑UI Boundary ⇄ App UI/State)*
91+

docs/concepts/agents.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ foundation for:
4040
import { AbstractAgent } from "@ag-ui/client"
4141

4242
class MyAgent extends AbstractAgent {
43-
protected run(input: RunAgentInput): RunAgent {
43+
run(input: RunAgentInput): RunAgent {
4444
// Implementation details
4545
}
4646
}
@@ -89,7 +89,7 @@ You can create custom agents to integrate with any AI service by extending
8989
class CustomAgent extends AbstractAgent {
9090
// Custom properties and methods
9191

92-
protected run(input: RunAgentInput): RunAgent {
92+
run(input: RunAgentInput): RunAgent {
9393
// Implement the agent's logic
9494
}
9595
}
@@ -113,7 +113,7 @@ import {
113113
import { Observable } from "rxjs"
114114

115115
class SimpleAgent extends AbstractAgent {
116-
protected run(input: RunAgentInput): RunAgent {
116+
run(input: RunAgentInput): RunAgent {
117117
const { threadId, runId } = input
118118

119119
return () =>

docs/concepts/architecture.mdx

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,35 @@ architecture that enables seamless, efficient communication between front-end
88
applications and AI agents. This document covers the core architectural
99
components and concepts.
1010

11-
## Overview
11+
## Design Principles
12+
13+
AG-UI is designed to be lightweight and minimally opinionated, making it easy to
14+
integrate with a wide range of agent implementations. The protocol's flexibility
15+
comes from its simple requirements:
16+
17+
1. **Event-Driven Communication**: Agents need to emit any of the 16
18+
standardized event types during execution, creating a stream of updates that
19+
clients can process.
20+
21+
2. **Bidirectional Interaction**: Agents accept input from users, enabling
22+
collaborative workflows where humans and AI work together seamlessly.
23+
24+
The protocol includes a built-in middleware layer that maximizes compatibility
25+
in two key ways:
26+
27+
- **Flexible Event Structure**: Events don't need to match AG-UI's format
28+
exactly—they just need to be AG-UI-compatible. This allows existing agent
29+
frameworks to adapt their native event formats with minimal effort.
30+
31+
- **Transport Agnostic**: AG-UI doesn't mandate how events are delivered,
32+
supporting various transport mechanisms including Server-Sent Events (SSE),
33+
webhooks, WebSockets, and more. This flexibility lets developers choose the
34+
transport that best fits their architecture.
35+
36+
This pragmatic approach makes AG-UI easy to adopt without requiring major
37+
changes to existing agent implementations or frontend applications.
38+
39+
## Architectural Overview
1240

1341
AG-UI follows a client-server architecture that standardizes communication
1442
between agents and applications:

0 commit comments

Comments
 (0)