adk_cli/lib.rs
1//! # adk-cli
2#![allow(clippy::result_large_err)]
3//!
4//! Command-line launcher for ADK agents.
5//!
6//! ## Overview
7//!
8//! This crate provides:
9//!
10//! - [`Launcher`] — embeddable CLI that gives any agent a REPL and a web server
11//! - [`console::run_console`] — quick one-call REPL for examples
12//! - [`serve::run_serve`] — quick one-call HTTP server for examples
13//!
14//! ## Quick Start
15//!
16//! ```rust,no_run
17//! use adk_cli::Launcher;
18//! use std::sync::Arc;
19//!
20//! #[tokio::main]
21//! async fn main() -> adk_core::Result<()> {
22//! // let agent = create_your_agent()?;
23//! // Launcher::new(Arc::new(agent)).run().await?;
24//! Ok(())
25//! }
26//! ```
27//!
28//! ## Modes
29//!
30//! - **Interactive**: rustyline REPL with history, streaming output, and think-block rendering
31//! - **Server**: HTTP server with web UI (`serve --port 8080`)
32
33pub mod console;
34pub mod launcher;
35pub mod serve;
36
37pub use launcher::Launcher;