phi_agent/agent/mod.rs
1//! Agent construction and lifecycle management.
2//!
3//! This module provides:
4//! - [`base_agent_builder`] — a pre-configured `AgentBuilder` factory
5//! - [`PhiAgent`] — a thin wrapper around `AgentRuntime` with a simplified API
6//! - [`PhiAgentConfig`] — tool-agnostic agent configuration
7//! - Context compression middleware (feature-gated)
8
9pub mod builder;
10/// PhiAgent struct and configuration — the primary public API.
11pub mod factory;
12
13#[cfg(feature = "compression")]
14pub use agent_works::compression::CompressionMiddleware;
15pub use builder::{
16 base_agent_builder, base_agent_builder_with_excludes, base_agent_builder_with_options, clear_compression_cache,
17 run_compact_session,
18};
19pub use factory::{PhiAgent, PhiAgentConfig};