gestura_core_pipeline/lib.rs
1//! Public pipeline types, persona, and reflection models for Gestura.
2//!
3//! `gestura-core-pipeline` defines the stable data model shared across the
4//! agent execution stack: request/response types, persona defaults, compaction
5//! strategy, paused-execution state, and reflection/evaluation structures.
6//!
7//! ## Design role
8//!
9//! This crate intentionally contains the *types and prompt assets* of the
10//! pipeline rather than the full runtime implementation. The concrete pipeline
11//! orchestration lives in `gestura-core`, where it can coordinate tools,
12//! context, streaming, sessions, and provider selection.
13//!
14//! In other words:
15//!
16//! - this crate owns the pipeline vocabulary
17//! - `gestura-core` owns the pipeline execution engine
18//!
19//! ## High-signal exports
20//!
21//! - `AgentRequest`, `AgentResponse`: the primary request/response types used by
22//! CLI, GUI, and tests
23//! - `RequestSource`, `RequestMetadata`: request origin and routing metadata
24//! - `PipelineConfig`: runtime configuration for pipeline execution
25//! - `CompactionStrategy`: context-compaction policy shared with sessions
26//! - `PausedExecutionState`: resumable execution state for confirmation flows
27//! - `default_system_prompt`: the default runtime persona prompt
28//! - `reflection` and `reflection_eval`: quality signals and evaluation helpers
29//!
30//! ## Architecture boundary
31//!
32//! Downstream code should usually import these types through
33//! `gestura_core::pipeline::*` so the facade remains the stable public entry
34//! point. Depending on this crate directly is most appropriate when working on
35//! pipeline data structures, persona content, or reflection logic in isolation.
36//!
37//! ## Documentation direction
38//!
39//! The goal is for `cargo doc` to surface pipeline concepts here, while more
40//! operational or end-user workflow documentation stays outside the API docs.
41
42pub mod persona;
43pub mod reflection;
44pub mod reflection_eval;
45pub mod types;
46
47// Re-export key types at crate root for convenience.
48pub use gestura_core_foundation::outcomes::{OutcomeSignal, OutcomeSignalKind};
49pub use persona::default_system_prompt;
50pub use reflection::{AgentReflection, QualitySignals, ReflectionConfig};
51pub use reflection_eval::{
52 ReflectionEvalCase, ReflectionEvalReport, ReflectionEvalSummary, ReflectionEvalToolOutcome,
53 ReflectionEvalToolResult, ReflectionEvalTurn, builtin_reflection_eval_cases,
54 evaluate_reflection_case, evaluate_reflection_cases,
55};
56pub use types::{
57 AgentRequest, AgentResponse, CompactionStrategy, Message, PausedExecutionState, PipelineConfig,
58 RequestMetadata, RequestSource, SessionLlmInfo, TokenLimitStatus, ToolCallRecord, ToolResult,
59};