gglib_core/domain/
mod.rs

1//! Core domain types.
2//!
3//! These types represent the pure domain model, independent of any
4//! infrastructure concerns (database, filesystem, etc.).
5//!
6//! # Structure
7//!
8//! - `agent` - Agent loop types (`AgentConfig`, `AgentMessage`, `AgentEvent`, etc.)
9//! - `model` - Model types (`Model`, `NewModel`)
10//! - `mcp` - MCP server types (`McpServer`, `NewMcpServer`, etc.)
11//! - `chat` - Chat conversation and message types
12//! - `gguf` - GGUF metadata and capability types
13//! - `capabilities` - Model capability detection and inference
14//! - `thinking` - Thinking/reasoning tag parsing and streaming accumulation
15
16pub mod agent;
17pub mod capabilities;
18pub mod chat;
19pub mod council;
20pub mod gguf;
21pub mod inference;
22pub mod mcp;
23mod model;
24
25// Re-export model types at the domain level for convenience
26pub use model::{
27    Model, ModelFile, ModelFilterOptions, NewModel, NewModelFile, RangeValues, SYSTEM_TAG_PREFIX,
28    is_system_tag,
29};
30
31// Re-export inference types at the domain level for convenience
32pub use inference::InferenceConfig;
33
34// Re-export MCP types at the domain level for convenience
35pub use mcp::{
36    McpEnvEntry, McpLifecycle, McpServer, McpServerConfig, McpServerStatus, McpServerType, McpTool,
37    McpToolResult, NewMcpServer, SEARCH_RESULTS_CAP, ToolIndex, ToolSummary, UpdateMcpServer,
38};
39
40// Re-export chat types at the domain level for convenience
41pub use chat::{
42    Conversation, ConversationUpdate, Message, MessageRole, NewConversation, NewMessage,
43};
44
45// Re-export GGUF types at the domain level for convenience
46pub use gguf::{
47    CapabilityFlags, GgufCapabilities, GgufMetadata, GgufValue, RawMetadata, ReasoningDetection,
48    ToolCallingDetection,
49};
50
51// Re-export agent types at the domain level for convenience
52pub use agent::{
53    AGENT_EVENT_CHANNEL_CAPACITY, AgentConfig, AgentConfigError, AgentEvent, AgentMessage,
54    AssistantContent, DEFAULT_MAX_ITERATIONS, DEFAULT_MAX_PARALLEL_TOOLS,
55    DEFAULT_MAX_STAGNATION_STEPS, LlmStreamEvent, MAX_ITERATIONS_CEILING,
56    MAX_PARALLEL_TOOLS_CEILING, MAX_TOOL_TIMEOUT_MS_CEILING, MIN_CONTEXT_BUDGET_CHARS,
57    MIN_TOOL_TIMEOUT_MS, ToolCall, ToolDefinition, ToolResult,
58};
59
60// Re-export capability types at the domain level for convenience
61pub use capabilities::{
62    ChatMessage, MessageContent, ModelCapabilities, capabilities_from_architecture,
63    infer_from_chat_template, transform_messages_for_capabilities,
64};
65
66// Re-export orchestrator types at the domain level for convenience
67pub use council::{
68    ApprovalKind, CouncilEvent, HitlMode, MAX_DEPTH, MAX_NODES, NodeId, NodeStatus, TaskGraph,
69    TaskGraphError, TaskNode,
70};