trpc-group / trpc-agent-go
trpc-agent-go is a powerful Go framework for building intelligent agent systems using large language models (LLMs) and tools.
View on GitHubAI Architecture Analysis
This repository is indexed by RepoMind. By analyzing trpc-group/trpc-agent-go in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.
Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context on-demand, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.
Repository Overview (README excerpt)
Crawler viewEnglish | 中文 tRPC-Agent-Go **A powerful Go framework for building intelligent agent systems** that transforms how you create AI applications. Build autonomous agents that think, remember, collaborate, and act with unprecedented ease. **Why tRPC-Agent-Go?** • **Intelligent Reasoning**: Advanced hierarchical planners and multi-agent orchestration • **Rich Tool Ecosystem**: Seamless integration with external APIs, databases, and services • **Persistent Memory**: Long-term state management and contextual awareness • **Multi-Agent Collaboration**: Chain, parallel, and graph-based agent workflows • **GraphAgent**: Type-safe graph workflows with multi-conditional routing, functionally equivalent to LangGraph for Go • **Agent Skills**: Reusable workflows with safe execution • **Artifacts**: Versioned storage for files produced by agents and tools • **Prompt Caching**: Automatic cost optimization with 90% savings on cached content • **Evaluation & Benchmarks**: Eval sets + metrics to measure quality over time • **UI & Server Integration**: AG-UI (Agent-User Interaction), and Agent-to-Agent (A2A) interoperability • **Production Ready**: Built-in telemetry, tracing, and enterprise-grade reliability • **High Performance**: Optimized for scalability and low latency Use Cases **Perfect for building:** • **Customer Support Bots** - Intelligent agents that understand context and solve complex queries • **Data Analysis Assistants** - Agents that query databases, generate reports, and provide insights • **DevOps Automation** - Smart deployment, monitoring, and incident response systems • **Business Process Automation** - Multi-step workflows with human-in-the-loop capabilities • **Research & Knowledge Management** - RAG-powered agents for document analysis and Q&A Key Features Multi-Agent Orchestration Advanced Memory System Rich Tool Integration Production Observability Agent Skills also accepts an HTTP(S) URL (for example, a or archive). The payload is downloaded and cached locally (set to override the cache location). If you wire Skills through with , consider also setting so Markdown fenced code blocks embedded in assistant text do not auto-execute while is enabled. Evaluation & Benchmarks Table of Contents • tRPC-Agent-Go • Use Cases • Key Features • Multi-Agent Orchestration • Advanced Memory System • Rich Tool Integration • Production Observability • Agent Skills • Evaluation \& Benchmarks • Table of Contents • Documentation • Quick Start • Prerequisites • Run the Example • Basic Usage • Stop / Cancel a Run • Examples • 1. Tool Usage • 2. LLM-Only Agent • 3. Multi-Agent Runners • 4. Graph Agent • 5. Memory • 6. Knowledge • 7. Telemetry \& Tracing • 8. MCP Integration • 9. AG-UI Demo • 10. Evaluation • 11. Agent Skills • 12. Artifacts • 13. A2A Interop • 14. Gateway Server • Architecture Overview • **Execution Flow** • Using Built-in Agents • Multi-Agent Collaboration Example • Contributing • **Ways to Contribute** • **Quick Contribution Setup** • Acknowledgements • **Enterprise Validation** • **Open Source Inspiration** • Star History • License • **Star us on GitHub** • **Report Issues** • **Join Discussions** Documentation Ready to dive into tRPC-Agent-Go? Our documentation covers everything from basic concepts to advanced techniques, helping you build powerful AI applications with confidence. Whether you're new to AI agents or an experienced developer, you'll find detailed guides, practical examples, and best practices to accelerate your development journey. Quick Start > **See it in Action**: _[Demo GIF placeholder - showing agent reasoning and tool usage]_ Prerequisites • Go 1.21 or later • LLM provider API key (OpenAI, DeepSeek, etc.) • 5 minutes to build your first intelligent agent Run the Example **Get started in 3 simple steps:** **What you'll see:** • **Interactive chat** with your AI agent • **Real-time streaming** responses • **Tool usage** (calculator + time tools) • **Multi-turn conversations** with memory Try asking: "What's the current time? Then calculate 15 \* 23 + 100" Basic Usage Dynamic Agent per Request Sometimes your Agent must be created **per request** (for example: different prompt, model, tools, sandbox instance). In that case, you can let Runner build a fresh Agent for every : Stop / Cancel a Run If you want to interrupt a running agent, **cancel the context** you passed to (recommended). This stops model calls and tool calls safely and lets the runner clean up. Important: **do not** just “break” your event loop and walk away — the agent goroutine may keep running and can block on channel writes. Always cancel, then keep draining the event channel until it is closed. Option A: Ctrl+C (terminal programs) Convert Ctrl+C into context cancellation: Option B: Cancel from your code Option C: Cancel by (for servers / background runs) For more details (including detached cancellation, resume, and server cancel routes), see and . Examples The directory contains runnable demos covering every major feature. • Tool Usage • examples/agenttool – Wrap agents as callable tools. • examples/multitools – Multiple tools orchestration. • examples/duckduckgo – Web search tool integration. • examples/filetoolset – File operations as tools. • examples/fileinput – Provide files as inputs. • examples/agenttool shows streaming and non-streaming patterns. • LLM-Only Agent Example: examples/llmagent • Wrap any chat-completion model as an . • Configure system instructions, temperature, max tokens, etc. • Receive incremental updates while the model streams. • Multi-Agent Runners Example: examples/multiagent • **ChainAgent** – linear pipeline of sub-agents. • **ParallelAgent** – run sub-agents concurrently and merge results. • **CycleAgent** – iterate until a termination condition is met. • Graph Agent Example: examples/graph • **GraphAgent** – demonstrates building and executing complex, conditional workflows using the and packages. It shows how to cons…