Pydantic AI integration for LiveKit Agents
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
调研方向
Start with the existing LangGraph adapter in livekit-plugins/livekit-plugins-langchain/livekit/plugins/langchain/langgraph.py, and with the llm_node() hook the issue mentions, to see how LiveKit's chat history and streamed responses are wired. The first step is agreeing on scope with maintainers, not writing code. Done means an agreed design for a Pydantic AI adapter or a documented example, covering history sync on interruption.
由索引模型根据 Issue 内容生成。
描述
Feature Type
Would make my life easier
Feature Description
Hi everyone,
I’d like to use a Pydantic AI agent with LiveKit, keeping its tools and logic in Pydantic AI while LiveKit handles speech and turn-taking.
The use case I have in mind is a support assistant available through both web chat and phone calls. It could reuse the same customer lookup and knowledge-base tools across both channels.
I couldn’t find a dedicated Pydantic AI adapter here. A reusable integration would help with streaming responses and keeping conversation history consistent. Interruptions seem particularly important: when LiveKit updates its history after a caller interrupts, Pydantic AI’s history would need to reflect that too.
Workarounds / Alternatives
A custom llm_node() could call Pydantic AI and stream its responses. That seems workable, but applications would still need to handle message conversion, tool-call history, and cancellation.
Having that behavior documented and tested in one place would make this easier to use reliably.
Additional Context
I noticed the existing LangGraph adapter.
Would a similar adapter make sense for Pydantic AI, or would a documented example be a better starting point?
I’d be happy to contribute the implementation, tests, and a small example. I wanted to discuss the approach and agree on a manageable scope before starting.
- 主要语言
- Python
- 星标
- 14.6k
- 派生
- 3.9k
- 平均合并
- 2 天 23 小时
- 30 天内合并 PR
- 258
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
livekit/agents 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 62/100
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 78/100
维护者通常 1 天内回复
-
ci: unit tests pin Python 3.12 while the package advertises 3.14 support可能重新可做 @huong8373tt-beep 于 7 天前认领,目前没有进行中的 PR。 未关闭
难度 2/5 1-3 小时 新手友好度 74/100
维护者通常 1 天内回复
-
Assistant markup is stripped from chat history when expressive mode is off可能已有人在做 @ShivamSharma43 于 28 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
docs: openai.LLM vs openai.responses.LLM for HTTP OpenAI-compat hosts可能重新可做 @AbarnaaSree 于 68 天前认领,目前没有进行中的 PR。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
相似的 Issue
-
follow-up needs-triage S3: minor
难度 2/5 1-3 小时 新手友好度 72/100
manaflow-ai/cmux#36856 · 1 条评论 ·
维护者通常 1 天内回复
-
documentation good first issue help wanted
难度 1/5 1-3 小时 新手友好度 90/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 73/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
-
Shell framework build fails at "copy the shader libraries": the iOS shader libraries are now one file b-<chain>.img可能已有人在做 @xiaofeng-han 今天认领。 未关闭build ios
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复