adk_rust/lib.rs
1//! # Agent Development Kit (ADK) for Rust
2//!
3//! [](https://crates.io/crates/adk-rust)
4//! [](https://docs.rs/adk-rust)
5//! [](https://github.com/zavora-ai/adk-rust/blob/main/LICENSE)
6//!
7//! A flexible and modular framework for developing and deploying AI agents in Rust.
8//! While optimized for Gemini and the Google ecosystem, ADK is model-agnostic,
9//! deployment-agnostic, and compatible with other frameworks.
10//!
11//! ## Quick Start
12//!
13//! Create your first AI agent in minutes:
14//!
15//! ```ignore
16//! use adk_rust::prelude::*;
17//! use adk_rust::Launcher;
18//! use std::sync::Arc;
19//!
20//! #[tokio::main]
21//! async fn main() -> Result<(), Box<dyn std::error::Error>> {
22//! let api_key = std::env::var("GOOGLE_API_KEY")?;
23//! let model = GeminiModel::new(&api_key, "gemini-2.5-flash")?;
24//!
25//! let agent = LlmAgentBuilder::new("assistant")
26//! .description("A helpful AI assistant")
27//! .instruction("You are a friendly assistant. Answer questions concisely.")
28//! .model(Arc::new(model))
29//! .build()?;
30//!
31//! // Run in interactive console mode
32//! Launcher::new(Arc::new(agent)).run().await?;
33//! Ok(())
34//! }
35//! ```
36//!
37//! ## Installation
38//!
39//! Add to your `Cargo.toml`:
40//!
41//! ```toml
42//! [dependencies]
43//! adk-rust = "0.1"
44//! tokio = { version = "1.40", features = ["full"] }
45//! dotenv = "0.15" # For loading .env files
46//! ```
47//!
48//! ### Feature Presets
49//!
50//! ```toml
51//! # Full (default) - Everything included
52//! adk-rust = "0.1"
53//!
54//! # Minimal - Agents + Gemini + Runner only
55//! adk-rust = { version = "0.1", default-features = false, features = ["minimal"] }
56//!
57//! # Custom - Pick exactly what you need
58//! adk-rust = { version = "0.1", default-features = false, features = [
59//! "agents", "gemini", "tools", "sessions"
60//! ] }
61//! ```
62//!
63//! ## Agent Types
64//!
65//! ADK-Rust provides several agent types for different use cases:
66//!
67//! ### LlmAgent - AI-Powered Reasoning
68//!
69//! The core agent type that uses Large Language Models for intelligent reasoning:
70//!
71//! ```no_run
72//! use adk_rust::prelude::*;
73//! use std::sync::Arc;
74//!
75//! # async fn example() -> Result<()> {
76//! let api_key = std::env::var("GOOGLE_API_KEY").map_err(|e| AdkError::Config(e.to_string()))?;
77//! let model = GeminiModel::new(&api_key, "gemini-2.5-flash")?;
78//!
79//! let agent = LlmAgentBuilder::new("researcher")
80//! .description("Research assistant with web search")
81//! .instruction("Search for information and provide detailed summaries.")
82//! .model(Arc::new(model))
83//! .tool(Arc::new(GoogleSearchTool::new())) // Add tools
84//! .build()?;
85//! # Ok(())
86//! # }
87//! ```
88//!
89//! ### Workflow Agents - Deterministic Pipelines
90//!
91//! For predictable, multi-step workflows:
92//!
93//! ```no_run
94//! use adk_rust::prelude::*;
95//! use std::sync::Arc;
96//!
97//! # async fn example() -> Result<()> {
98//! # let researcher: Arc<dyn Agent> = todo!();
99//! # let writer: Arc<dyn Agent> = todo!();
100//! # let reviewer: Arc<dyn Agent> = todo!();
101//! // Sequential: Execute agents in order
102//! let pipeline = SequentialAgent::new(
103//! "content_pipeline",
104//! vec![researcher, writer, reviewer]
105//! );
106//!
107//! // Parallel: Execute agents concurrently
108//! # let analyst1: Arc<dyn Agent> = todo!();
109//! # let analyst2: Arc<dyn Agent> = todo!();
110//! let parallel = ParallelAgent::new(
111//! "multi_analysis",
112//! vec![analyst1, analyst2]
113//! );
114//!
115//! // Loop: Iterate until condition met
116//! # let refiner: Arc<dyn Agent> = todo!();
117//! let loop_agent = LoopAgent::new("iterative_refiner", vec![refiner])
118//! .with_max_iterations(5);
119//! # Ok(())
120//! # }
121//! ```
122//!
123//! ### Multi-Agent Systems
124//!
125//! Build hierarchical agent systems with automatic delegation:
126//!
127//! ```no_run
128//! use adk_rust::prelude::*;
129//! use std::sync::Arc;
130//!
131//! # async fn example() -> Result<()> {
132//! # let model: Arc<dyn Llm> = todo!();
133//! # let code_agent: Arc<dyn Agent> = todo!();
134//! # let test_agent: Arc<dyn Agent> = todo!();
135//! let coordinator = LlmAgentBuilder::new("coordinator")
136//! .description("Development team coordinator")
137//! .instruction("Delegate coding tasks to specialists.")
138//! .model(model)
139//! .sub_agent(code_agent) // Delegate to sub-agents
140//! .sub_agent(test_agent)
141//! .build()?;
142//! # Ok(())
143//! # }
144//! ```
145//!
146//! ## Tools
147//!
148//! Give your agents capabilities beyond conversation:
149//!
150//! ### Function Tools - Custom Operations
151//!
152//! Convert any async function into a tool:
153//!
154//! ```no_run
155//! use adk_rust::prelude::*;
156//! use adk_rust::serde_json::{json, Value};
157//! use std::sync::Arc;
158//!
159//! async fn get_weather(_ctx: Arc<dyn ToolContext>, args: Value) -> Result<Value> {
160//! let city = args["city"].as_str().unwrap_or("Unknown");
161//! // Your weather API call here
162//! Ok(json!({
163//! "temperature": 72.0,
164//! "conditions": "Sunny",
165//! "city": city
166//! }))
167//! }
168//!
169//! # fn example() -> Result<()> {
170//! let weather_tool = FunctionTool::new(
171//! "get_weather",
172//! "Get current weather for a city",
173//! get_weather,
174//! );
175//! # Ok(())
176//! # }
177//! ```
178//!
179//! ### Built-in Tools
180//!
181//! Ready-to-use tools included with ADK:
182//!
183//! - [`GoogleSearchTool`](tool::GoogleSearchTool) - Web search via Google
184//! - [`ExitLoopTool`](tool::ExitLoopTool) - Control loop termination
185//! - [`LoadArtifactsTool`](tool::LoadArtifactsTool) - Access stored artifacts
186//!
187//! ### MCP Tools - External Integrations
188//!
189//! Connect to Model Context Protocol servers using the `rmcp` crate:
190//!
191//! ```ignore
192//! use adk_rust::prelude::*;
193//! use adk_rust::tool::McpToolset;
194//! use rmcp::{ServiceExt, transport::TokioChildProcess};
195//! use tokio::process::Command;
196//!
197//! # async fn example() -> Result<(), Box<dyn std::error::Error>> {
198//! // Connect to an MCP server (e.g., filesystem, database)
199//! let client = ().serve(TokioChildProcess::new(
200//! Command::new("npx")
201//! .arg("-y")
202//! .arg("@anthropic/mcp-server-filesystem")
203//! .arg("/path/to/dir")
204//! )?).await?;
205//!
206//! let mcp_tools = McpToolset::new(client);
207//!
208//! // Add all MCP tools to your agent
209//! # let builder: LlmAgentBuilder = todo!();
210//! let agent = builder.toolset(Arc::new(mcp_tools)).build()?;
211//! # Ok(())
212//! # }
213//! ```
214//!
215//! ## Sessions & State
216//!
217//! Manage conversation context and working memory:
218//!
219//! ```no_run
220//! use adk_rust::prelude::*;
221//! use adk_rust::session::{SessionService, CreateRequest};
222//! use adk_rust::serde_json::json;
223//! use std::collections::HashMap;
224//!
225//! # async fn example() -> Result<()> {
226//! let session_service = InMemorySessionService::new();
227//!
228//! // Create a session
229//! let session = session_service.create(CreateRequest {
230//! app_name: "my_app".to_string(),
231//! user_id: "user_123".to_string(),
232//! session_id: None,
233//! state: HashMap::new(),
234//! }).await?;
235//!
236//! // Read state (State trait provides read access)
237//! let state = session.state();
238//! let config = state.get("app:config"); // Returns Option<Value>
239//! # Ok(())
240//! # }
241//! ```
242//!
243//! ## Callbacks
244//!
245//! Intercept and customize agent behavior:
246//!
247//! ```no_run
248//! use adk_rust::prelude::*;
249//! use std::sync::Arc;
250//!
251//! # async fn example() -> Result<()> {
252//! # let model: Arc<dyn Llm> = todo!();
253//! let agent = LlmAgentBuilder::new("monitored_agent")
254//! .model(model)
255//! // Modify or inspect model responses
256//! .after_model_callback(Box::new(|_ctx, response| {
257//! Box::pin(async move {
258//! println!("Model responded");
259//! Ok(Some(response)) // Return modified response or None to keep original
260//! })
261//! }))
262//! // Track tool usage
263//! .before_tool_callback(Box::new(|_ctx| {
264//! Box::pin(async move {
265//! println!("Tool about to be called");
266//! Ok(None) // Continue execution
267//! })
268//! }))
269//! .build()?;
270//! # Ok(())
271//! # }
272//! ```
273//!
274//! ## Artifacts
275//!
276//! Store and retrieve binary data (images, files, etc.):
277//!
278//! ```no_run
279//! use adk_rust::prelude::*;
280//! use adk_rust::artifact::{ArtifactService, SaveRequest, LoadRequest};
281//!
282//! # async fn example() -> Result<()> {
283//! let artifact_service = InMemoryArtifactService::new();
284//!
285//! // Save an artifact
286//! let response = artifact_service.save(SaveRequest {
287//! app_name: "my_app".to_string(),
288//! user_id: "user_123".to_string(),
289//! session_id: "session_456".to_string(),
290//! file_name: "sales_chart.png".to_string(),
291//! part: Part::Text { text: "chart data".to_string() },
292//! version: None,
293//! }).await?;
294//!
295//! // Load an artifact
296//! let loaded = artifact_service.load(LoadRequest {
297//! app_name: "my_app".to_string(),
298//! user_id: "user_123".to_string(),
299//! session_id: "session_456".to_string(),
300//! file_name: "sales_chart.png".to_string(),
301//! version: None,
302//! }).await?;
303//! # Ok(())
304//! # }
305//! ```
306//!
307//! ## Deployment Options
308//!
309//! ### Console Mode (Interactive CLI)
310//!
311//! ```no_run
312//! use adk_rust::prelude::*;
313//! use adk_rust::Launcher;
314//! use std::sync::Arc;
315//!
316//! # async fn example() -> Result<()> {
317//! # let agent: Arc<dyn Agent> = todo!();
318//! // Interactive chat in terminal
319//! Launcher::new(agent).run().await?;
320//! # Ok(())
321//! # }
322//! ```
323//!
324//! ### Server Mode (REST API)
325//!
326//! ```bash
327//! # Run your agent as a web server
328//! cargo run -- serve --port 8080
329//! ```
330//!
331//! Provides endpoints:
332//! - `POST /chat` - Send messages
333//! - `GET /sessions` - List sessions
334//! - `GET /health` - Health check
335//!
336//! ### Agent-to-Agent (A2A) Protocol
337//!
338//! Expose your agent for inter-agent communication:
339//!
340//! ```no_run
341//! use adk_rust::server::{create_app_with_a2a, ServerConfig};
342//! use adk_rust::AgentLoader;
343//!
344//! # async fn example() -> adk_rust::Result<()> {
345//! # let agent_loader: std::sync::Arc<dyn AgentLoader> = todo!();
346//! # let session_service: std::sync::Arc<dyn adk_rust::session::SessionService> = todo!();
347//! // Create server with A2A protocol support
348//! let config = ServerConfig::new(agent_loader, session_service);
349//! let app = create_app_with_a2a(config, Some("http://localhost:8080"));
350//!
351//! // Run the server (requires axum dependency)
352//! // let listener = tokio::net::TcpListener::bind("0.0.0.0:8080").await?;
353//! // axum::serve(listener, app).await?;
354//! # Ok(())
355//! # }
356//! ```
357//!
358//! ## Observability
359//!
360//! Built-in OpenTelemetry support for production monitoring:
361//!
362//! ```no_run
363//! use adk_rust::telemetry::{init_telemetry, init_with_otlp};
364//!
365//! # fn example() -> Result<(), Box<dyn std::error::Error>> {
366//! // Basic telemetry with console logging
367//! init_telemetry("my-agent-service")?;
368//!
369//! // Or with OTLP export for distributed tracing
370//! // init_with_otlp("my-agent-service", "http://localhost:4317")?;
371//!
372//! // All agent operations now emit traces and metrics
373//! # Ok(())
374//! # }
375//! ```
376//!
377//! ## Architecture
378//!
379//! ADK-Rust uses a layered architecture for modularity:
380//!
381//! ```text
382//! ┌─────────────────────────────────────────────────────────────┐
383//! │ Application Layer │
384//! │ Launcher • REST Server • A2A │
385//! ├─────────────────────────────────────────────────────────────┤
386//! │ Runner Layer │
387//! │ Agent Execution • Event Streaming │
388//! ├─────────────────────────────────────────────────────────────┤
389//! │ Agent Layer │
390//! │ LlmAgent • CustomAgent • Sequential • Parallel • Loop │
391//! ├─────────────────────────────────────────────────────────────┤
392//! │ Service Layer │
393//! │ Models • Tools • Sessions • Artifacts • Memory │
394//! └─────────────────────────────────────────────────────────────┘
395//! ```
396//!
397//! ## Feature Flags
398//!
399//! | Feature | Description | Default |
400//! |---------|-------------|---------|
401//! | `agents` | Agent implementations | ✅ |
402//! | `models` | Model integrations | ✅ |
403//! | `gemini` | Gemini model support | ✅ |
404//! | `tools` | Tool system | ✅ |
405//! | `mcp` | MCP integration | ✅ |
406//! | `sessions` | Session management | ✅ |
407//! | `artifacts` | Artifact storage | ✅ |
408//! | `memory` | Semantic memory | ✅ |
409//! | `runner` | Execution runtime | ✅ |
410//! | `server` | HTTP server | ✅ |
411//! | `telemetry` | OpenTelemetry | ✅ |
412//! | `cli` | CLI launcher | ✅ |
413//!
414//! ## Examples
415//!
416//! The [examples directory](https://github.com/zavora-ai/adk-rust/tree/main/examples)
417//! contains working examples for every feature:
418//!
419//! - **Agents**: LLM agent, workflow agents, multi-agent systems
420//! - **Tools**: Function tools, Google Search, MCP integration
421//! - **Sessions**: State management, conversation history
422//! - **Callbacks**: Logging, guardrails, caching
423//! - **Deployment**: Console, server, A2A protocol
424//!
425//! ## Related Crates
426//!
427//! ADK-Rust is composed of modular crates that can be used independently:
428//!
429//! - [`adk-core`](https://docs.rs/adk-core) - Core traits and types
430//! - [`adk-agent`](https://docs.rs/adk-agent) - Agent implementations
431//! - [`adk-model`](https://docs.rs/adk-model) - LLM integrations
432//! - [`adk-tool`](https://docs.rs/adk-tool) - Tool system
433//! - [`adk-session`](https://docs.rs/adk-session) - Session management
434//! - [`adk-artifact`](https://docs.rs/adk-artifact) - Artifact storage
435//! - [`adk-runner`](https://docs.rs/adk-runner) - Execution runtime
436//! - [`adk-server`](https://docs.rs/adk-server) - HTTP server
437//! - [`adk-telemetry`](https://docs.rs/adk-telemetry) - Observability
438
439#![warn(missing_docs)]
440#![cfg_attr(docsrs, feature(doc_cfg))]
441
442// ============================================================================
443// Core (always available)
444// ============================================================================
445
446/// Core traits and types.
447///
448/// Always available regardless of feature flags. Includes:
449/// - [`Agent`] - The fundamental trait for all agents
450/// - [`Tool`] / [`Toolset`] - For extending agents with capabilities
451/// - [`Session`] / [`State`] - For managing conversation context
452/// - [`Event`] - For streaming agent responses
453/// - [`AdkError`] / [`Result`] - Unified error handling
454pub use adk_core::*;
455
456// Re-export common dependencies for convenience
457pub use anyhow;
458pub use async_trait::async_trait;
459pub use futures;
460pub use serde;
461pub use serde_json;
462pub use tokio;
463
464// ============================================================================
465// Component Modules (feature-gated)
466// ============================================================================
467
468/// Agent implementations (LLM, Custom, Workflow agents).
469///
470/// Provides the core agent types:
471/// - [`LlmAgent`](agent::LlmAgent) - AI-powered agent using LLMs
472/// - [`CustomAgent`](agent::CustomAgent) - Implement custom agent logic
473/// - [`SequentialAgent`](agent::SequentialAgent) - Execute agents in sequence
474/// - [`ParallelAgent`](agent::ParallelAgent) - Execute agents concurrently
475/// - [`LoopAgent`](agent::LoopAgent) - Iterative execution until condition met
476///
477/// Available with feature: `agents`
478#[cfg(feature = "agents")]
479#[cfg_attr(docsrs, doc(cfg(feature = "agents")))]
480pub mod agent {
481 pub use adk_agent::*;
482}
483
484/// Model integrations (Gemini, etc.).
485///
486/// Provides LLM implementations:
487/// - [`GeminiModel`](model::GeminiModel) - Google's Gemini models
488///
489/// ADK is model-agnostic - implement the [`Llm`] trait for other providers.
490///
491/// Available with feature: `models`
492#[cfg(feature = "models")]
493#[cfg_attr(docsrs, doc(cfg(feature = "models")))]
494pub mod model {
495 pub use adk_model::*;
496}
497
498/// Tool system and built-in tools.
499///
500/// Give agents capabilities beyond conversation:
501/// - [`FunctionTool`](tool::FunctionTool) - Wrap async functions as tools
502/// - [`GoogleSearchTool`](tool::GoogleSearchTool) - Web search
503/// - [`ExitLoopTool`](tool::ExitLoopTool) - Control loop agents
504/// - [`McpToolset`](tool::McpToolset) - MCP server integration
505///
506/// Available with feature: `tools`
507#[cfg(feature = "tools")]
508#[cfg_attr(docsrs, doc(cfg(feature = "tools")))]
509pub mod tool {
510 pub use adk_tool::*;
511}
512
513/// Session management.
514///
515/// Manage conversation context and state:
516/// - [`InMemorySessionService`](session::InMemorySessionService) - In-memory sessions
517/// - Session creation, retrieval, and lifecycle
518/// - State management with scoped prefixes
519///
520/// Available with feature: `sessions`
521#[cfg(feature = "sessions")]
522#[cfg_attr(docsrs, doc(cfg(feature = "sessions")))]
523pub mod session {
524 pub use adk_session::*;
525}
526
527/// Artifact storage.
528///
529/// Store and retrieve binary data:
530/// - [`InMemoryArtifactService`](artifact::InMemoryArtifactService) - In-memory storage
531/// - Version tracking for artifacts
532/// - Namespace scoping
533///
534/// Available with feature: `artifacts`
535#[cfg(feature = "artifacts")]
536#[cfg_attr(docsrs, doc(cfg(feature = "artifacts")))]
537pub mod artifact {
538 pub use adk_artifact::*;
539}
540
541/// Memory system with semantic search.
542///
543/// Long-term memory for agents:
544/// - [`InMemoryMemoryService`](memory::InMemoryMemoryService) - In-memory storage
545/// - Semantic search capabilities
546/// - Memory retrieval and updates
547///
548/// Available with feature: `memory`
549#[cfg(feature = "memory")]
550#[cfg_attr(docsrs, doc(cfg(feature = "memory")))]
551pub mod memory {
552 pub use adk_memory::*;
553}
554
555/// Agent execution runtime.
556///
557/// The engine that manages agent execution:
558/// - [`Runner`](runner::Runner) - Executes agents with full context
559/// - [`RunnerConfig`](runner::RunnerConfig) - Configuration options
560/// - Event streaming and tool coordination
561///
562/// Available with feature: `runner`
563#[cfg(feature = "runner")]
564#[cfg_attr(docsrs, doc(cfg(feature = "runner")))]
565pub mod runner {
566 pub use adk_runner::*;
567}
568
569/// HTTP server (REST + A2A).
570///
571/// Deploy agents as web services:
572/// - REST API for chat interactions
573/// - A2A (Agent-to-Agent) protocol support
574/// - Web UI integration
575///
576/// Available with feature: `server`
577#[cfg(feature = "server")]
578#[cfg_attr(docsrs, doc(cfg(feature = "server")))]
579pub mod server {
580 pub use adk_server::*;
581}
582
583/// Telemetry (OpenTelemetry integration).
584///
585/// Production observability:
586/// - Distributed tracing
587/// - Metrics collection
588/// - Log correlation
589///
590/// Available with feature: `telemetry`
591#[cfg(feature = "telemetry")]
592#[cfg_attr(docsrs, doc(cfg(feature = "telemetry")))]
593pub mod telemetry {
594 pub use adk_telemetry::*;
595}
596
597/// Graph-based workflow engine (LangGraph-inspired).
598///
599/// Build complex agent workflows with:
600/// - [`StateGraph`](graph::StateGraph) - Graph builder with nodes and edges
601/// - [`GraphAgent`](graph::GraphAgent) - ADK Agent integration
602/// - [`Checkpointer`](graph::Checkpointer) - Persistent state for human-in-the-loop
603/// - [`Router`](graph::Router) - Conditional edge routing helpers
604/// - Cycle support with recursion limits
605/// - Streaming execution modes
606///
607/// Available with feature: `graph`
608#[cfg(feature = "graph")]
609#[cfg_attr(docsrs, doc(cfg(feature = "graph")))]
610pub mod graph {
611 pub use adk_graph::*;
612}
613
614/// Dynamic UI generation for agents.
615///
616/// Enables agents to render rich user interfaces via tool calls:
617/// - [`UiToolset`](ui::UiToolset) - All UI rendering tools
618/// - [`UiResponse`](ui::UiResponse) - UI component tree
619/// - [`UiEvent`](ui::UiEvent) - User interaction events
620/// - [`UiUpdate`](ui::UiUpdate) - Streaming UI updates
621///
622/// Available with feature: `ui`
623#[cfg(feature = "ui")]
624#[cfg_attr(docsrs, doc(cfg(feature = "ui")))]
625pub mod ui {
626 pub use adk_ui::*;
627}
628
629/// CLI launcher for running agents.
630///
631/// Quick way to run agents in console or server mode:
632/// - [`Launcher`] - Main entry point for CLI apps
633/// - [`SingleAgentLoader`] - Load a single agent
634///
635/// Available with feature: `cli`
636#[cfg(feature = "cli")]
637#[cfg_attr(docsrs, doc(cfg(feature = "cli")))]
638pub use adk_cli::{Launcher, SingleAgentLoader};
639
640// ============================================================================
641// Prelude
642// ============================================================================
643
644/// Convenience prelude for common imports.
645///
646/// Import everything you need with a single line:
647///
648/// ```
649/// use adk_rust::prelude::*;
650/// ```
651///
652/// This includes:
653/// - Core traits: `Agent`, `Tool`, `Llm`, `Session`
654/// - Agent builders: `LlmAgentBuilder`, `CustomAgentBuilder`
655/// - Workflow agents: `SequentialAgent`, `ParallelAgent`, `LoopAgent`
656/// - Models: `GeminiModel`
657/// - Tools: `FunctionTool`, `GoogleSearchTool`, `McpToolset`
658/// - Services: `InMemorySessionService`, `InMemoryArtifactService`
659/// - Runtime: `Runner`, `RunnerConfig`
660/// - Common types: `Arc`, `Result`, `Content`, `Event`
661pub mod prelude {
662 // Core types (always available)
663 pub use crate::{
664 AdkError, Agent, BeforeModelResult, Content, Event, EventStream, InvocationContext, Llm,
665 LlmRequest, LlmResponse, Part, Result, RunConfig, Session, State, Tool, ToolContext,
666 Toolset,
667 };
668
669 // Agents
670 #[cfg(feature = "agents")]
671 pub use crate::agent::{
672 ConditionalAgent, CustomAgent, CustomAgentBuilder, LlmAgent, LlmAgentBuilder, LoopAgent,
673 ParallelAgent, SequentialAgent,
674 };
675
676 // Models
677 #[cfg(feature = "models")]
678 pub use crate::model::GeminiModel;
679
680 // Tools
681 #[cfg(feature = "tools")]
682 pub use crate::tool::{
683 BasicToolset, ExitLoopTool, FunctionTool, GoogleSearchTool, LoadArtifactsTool, McpToolset,
684 };
685
686 // Sessions
687 #[cfg(feature = "sessions")]
688 pub use crate::session::InMemorySessionService;
689
690 // Artifacts
691 #[cfg(feature = "artifacts")]
692 pub use crate::artifact::InMemoryArtifactService;
693
694 // Memory
695 #[cfg(feature = "memory")]
696 pub use crate::memory::InMemoryMemoryService;
697
698 // Runner
699 #[cfg(feature = "runner")]
700 pub use crate::runner::{Runner, RunnerConfig};
701
702 // Graph workflows
703 #[cfg(feature = "graph")]
704 pub use crate::graph::{GraphAgent, NodeOutput, Router, StateGraph, END, START};
705
706 // UI
707 #[cfg(feature = "ui")]
708 pub use crate::ui::UiToolset;
709
710 // Common re-exports
711 pub use crate::anyhow::Result as AnyhowResult;
712 pub use crate::async_trait;
713 pub use std::sync::Arc;
714}