Skip to content

Commit ddea8d0

Browse files
authored
feat(runtime, react): Scaffold Intelligence runner and agent (CopilotKit#3348)
<!-- Thank you for sending the PR! We appreciate you spending the time to work on these changes. Help us understand your motivation by explaining why you decided to make this change. **Please PLEASE reach out to us first before starting any significant work on new or existing features.** By the time you've gotten here, you're looking at creating a pull request so hopefully we're not too late. We love community contributions! That said, we want to make sure we're all on the same page before you start. Investing a lot of time and effort just to find out it doesn't align with the upstream project feels awful, and we don't want that to happen. It also helps to make sure the work you're planning isn't already in progress. As described in our contributing guide, please file an issue first: https://github.com/ag-ui-protocol/ag-ui/issues Or, reach out to us on Discord: https://discord.com/invite/6dffbvGU3D You can learn more about contributing to copilotkit here: https://github.com/copilotkit/copilotkit/blob/master/CONTRIBUTING.md Happy contributing! --> ## What does this PR do? This PR adds an initial scaffolding of the CopilotKit Intelligence agent runner and React agent classes. Both will be part of the new threads-enabled feature set, and will be iterated upon in subsequent PRs. For this PR, the React agent is not tied into `useAgent`, so it cannot currently be interacted with. Also, in this PR, docs that describe the agent and runner architecture are not updated, as it is assumed that these classes may change substantially and rapidly in the very near term. A big part of this PR is the integration of the Phoenix JS client SDK to enable the IntelligenceAgent and IntelligenceAgentRunner to connect to the Intelligence platform's Phoenix server. That allows threaded AG-UI messages to be streamed from to and from the platform, instead of directly from agent runner to client agent hook. The message structure for the Phoenix connection is still in flux. Note: while the SQLite-backed agent runner is in a separate package, the IntelligenceAgentRunner was intentionally placed along side the `ProxiedCopilotRuntimeAgent` to make it that much easier to switch from the latter to the former if desired. ## Related PRs and Issues - https://linear.app/copilotkit/issue/ENT-59 - https://linear.app/copilotkit/issue/ENT-54 ## Checklist - [x] I have read the [Contribution Guide](https://github.com/copilotkit/copilotkit/blob/master/CONTRIBUTING.md) - [ ] If the PR changes or adds functionality, I have updated the relevant documentation
2 parents ef376df + 5322f2b commit ddea8d0

12 files changed

Lines changed: 1607 additions & 3 deletions

File tree

packages/v2/core/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
"dependencies": {
4242
"@ag-ui/client": "0.0.46",
4343
"@copilotkitnext/shared": "workspace:*",
44+
"phoenix": "^1.8.4",
4445
"rxjs": "7.8.1",
4546
"zod": "^3.25.75",
4647
"zod-to-json-schema": "^3.24.6"

0 commit comments

Comments
 (0)