1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
//! Engine Interface Abstractions
//!
//! This module defines the contract between the agent engine and external
//! consumers (TUI, servers, CLI tools, etc.).
//!
//! # Architecture
//!
//! The interface is message-based and transport-agnostic:
//!
//! ```text
//! Consumer Interface Engine
//! │ │
//! │◄─────── EventSink ────────────────│ (events out)
//! │ │
//! │─────── InputSource ──────────────►│ (input in)
//! │ │
//! │◄────── PermissionRegistry ───────►│ (request/response)
//! ```
//!
//! # Components
//!
//! - [`EventSink`] - Receives events from the engine (text, tools, errors)
//! - [`InputSource`] - Provides input to the engine (user messages, commands)
//! - [`PermissionPolicy`] - Automatic handling of permission requests
//!
//! # Built-in Implementations
//!
//! - [`ChannelEventSink`] - Channel-backed sink (default, used by TUI)
//! - [`ChannelInputSource`] - Channel-backed source (default, used by TUI)
//! - [`StdoutEventSink`] - Simple stdout sink for CLI tools
//! - [`AutoApprovePolicy`] - Auto-approve all permissions (headless/trusted)
//! - [`DenyAllPolicy`] - Deny all permissions (sandboxed)
//! - [`InteractivePolicy`] - Always ask user (default for TUI)
pub use ;
pub use ;
pub use ;