Skip to main content

a3s_code_core/
lib.rs

1//! A3S Code Core Library
2//!
3//! Harness-driven runtime for coding agents.
4//!
5//! `Agent` and `AgentSession` are the primary 2.0 API. Lower-level session
6//! runtime state is internal; persistence data flows through `store::SessionData`.
7//!
8//! ## Quick Start
9//!
10//! ```rust,no_run
11//! use a3s_code_core::{Agent, AgentEvent};
12//!
13//! # async fn run() -> anyhow::Result<()> {
14//! // From an ACL-compatible config file path (.acl)
15//! let agent = Agent::new("agent.acl").await?;
16//!
17//! // Create a workspace-bound session
18//! let session = agent.session_async("/my-project", None).await?;
19//!
20//! // Non-streaming
21//! let result = session.send("What files handle auth?", None).await?;
22//! println!("{}", result.text);
23//!
24//! // Streaming (AgentEvent is #[non_exhaustive])
25//! let (mut rx, _handle) = session.stream("Refactor auth", None).await?;
26//! while let Some(event) = rx.recv().await {
27//!     match event {
28//!         AgentEvent::TextDelta { text } => print!("{text}"),
29//!         AgentEvent::End { .. } => break,
30//!         _ => {} // required: #[non_exhaustive]
31//!     }
32//! }
33//! # Ok(())
34//! # }
35//! ```
36//!
37//! ## Disposable Workers
38//!
39//! ```rust,no_run
40//! use a3s_code_core::{Agent, SessionOptions, WorkerAgentSpec};
41//!
42//! # async fn run() -> anyhow::Result<()> {
43//! let agent = Agent::new("agent.acl").await?;
44//! let frontend = WorkerAgentSpec::implementer(
45//!     "frontend-cow",
46//!     "Small verified frontend fixes",
47//! )
48//! .with_model_ref("openai/gpt-4o")
49//! .with_max_steps(24);
50//!
51//! let session = agent.session_async(
52//!     "/my-project",
53//!     Some(SessionOptions::new().with_worker_agent(frontend)),
54//! ).await?;
55//! # Ok(())
56//! # }
57//! ```
58//!
59//! ## Architecture
60//!
61//! ```text
62//! Agent (config-driven facade)
63//!   +-- AgentSession (workspace-bound execution API)
64//!       +-- internal turn runner
65//!       +-- ContextAssembler / ContextProvider
66//!       +-- ToolSelector
67//!       +-- ToolExecutor
68//!       +-- ProgramExecutor (PTC)
69//!       +-- SkillRegistry
70//!       +-- Permission / confirmation
71//!       +-- Trace / artifacts / verification evidence
72//!
73//! Advanced infrastructure:
74//!   +-- optional lane queues for explicit external/hybrid dispatch
75//! ```
76
77pub(crate) mod agent;
78pub(crate) mod agent_api;
79pub mod agent_protocol;
80pub mod agent_protocol_harness;
81pub mod agent_protocol_host;
82pub(crate) mod bounded_io;
83pub mod budget;
84pub mod capability;
85pub(crate) mod child_run;
86pub mod code_intelligence;
87pub mod cognitive_context;
88pub mod commands;
89pub(crate) mod compaction;
90pub mod config;
91pub mod context;
92pub mod core_event_log;
93pub mod core_identity;
94pub mod durable_memory;
95pub mod dynamic_workflow;
96pub mod embedding;
97pub mod error;
98pub mod evaluation;
99pub mod event_protocol;
100pub mod execution_identity;
101pub mod flow_graph;
102pub(crate) mod git;
103pub mod harness_evidence;
104pub mod hitl;
105pub mod hooks;
106pub mod host_env;
107pub(crate) mod language;
108pub mod llm;
109pub mod loop_checkpoint;
110pub mod mcp;
111pub mod memory;
112#[cfg(feature = "headless-search")]
113pub mod moli_runtime;
114pub mod orchestration;
115pub(crate) mod ordered_parallel;
116pub mod permissions;
117pub mod planning;
118pub mod program;
119pub(crate) mod prompts;
120pub mod queue;
121pub mod release;
122pub mod research;
123pub mod retention;
124pub(crate) mod retry;
125pub mod rl_trajectory;
126pub mod run;
127pub mod run_control;
128pub(crate) mod safety_gate;
129pub mod sandbox;
130pub mod sdk_capabilities;
131#[cfg(feature = "headless-search")]
132pub mod search_runtime;
133pub mod security;
134#[cfg(feature = "serve")]
135pub mod serve;
136pub mod session_checkpoint;
137pub(crate) mod session_lane_queue;
138pub mod skills;
139pub(crate) mod sse;
140pub mod state_graph;
141pub mod store;
142pub mod subagent;
143pub mod subagent_task_tracker;
144pub mod task_scheduler;
145pub mod telemetry;
146#[cfg(feature = "telemetry")]
147pub mod telemetry_otel;
148#[cfg(test)]
149pub(crate) mod test_support;
150pub(crate) mod text;
151pub(crate) mod tool_confirmation;
152pub mod tools;
153pub mod trace;
154pub mod use_runtime_tasks;
155pub mod verification;
156pub mod workspace;
157
158// Re-export key types at crate root for ergonomic usage
159pub use agent::{AgentEvent, AgentExecutionFailure, AgentResult, ModelMiddlewareHealthSnapshot};
160pub use agent_api::{
161    Agent, AgentRunSpawn, AgentSession, ProjectedFlowHandle, ProjectedUiHandle, ReadFileOptions,
162    SessionBuilder, SessionOptions, ToolCallResult,
163};
164pub use agent_protocol::{
165    AgentProtocolChangeSetRequestV1, AgentProtocolChangeSetV1, AgentProtocolCommandActionV1,
166    AgentProtocolCommandReceiptV1, AgentProtocolCommandV1, AgentProtocolError,
167    AgentProtocolEventPageRequestV1, AgentProtocolEventPageV1, AgentProtocolEventRecordV1,
168    AgentProtocolRunCancelV1, AgentProtocolRunIdentityV1, AgentProtocolRunRecoverExactV1,
169    AgentProtocolRunRecoverV1, AgentProtocolRunStartV1, AgentProtocolRunStateV1,
170    AGENT_PROTOCOL_CHANGE_SET_ENCODING_V1, AGENT_PROTOCOL_CHANGE_SET_FORMAT_V1,
171    AGENT_PROTOCOL_CHANGE_SET_HTTP_PATH_V1, AGENT_PROTOCOL_COMMAND_HTTP_PATH_V1,
172    AGENT_PROTOCOL_EVENT_PAGE_HTTP_PATH_V1, AGENT_PROTOCOL_MAX_CHANGE_SET_BYTES,
173    AGENT_PROTOCOL_MAX_CHANGE_SET_RESPONSE_BYTES, AGENT_PROTOCOL_MAX_EVENTS_PER_PAGE,
174    AGENT_PROTOCOL_MAX_EVENT_METADATA_BYTES, AGENT_PROTOCOL_MAX_EVENT_PAGE_BYTES,
175    AGENT_PROTOCOL_MAX_EVENT_PAYLOAD_BYTES, AGENT_PROTOCOL_MAX_EVENT_RECORD_BYTES,
176    AGENT_PROTOCOL_MAX_EVENT_TYPE_BYTES, AGENT_PROTOCOL_MAX_ID_BYTES,
177    AGENT_PROTOCOL_MAX_PROMPT_BYTES, AGENT_PROTOCOL_MAX_REASON_BYTES, AGENT_PROTOCOL_V1,
178};
179pub use agent_protocol_harness::{
180    AgentProtocolCheckpointRecoveryError, AgentProtocolHarness, AgentProtocolHarnessError,
181    AGENT_PROTOCOL_HARNESS_MAX_SESSIONS,
182};
183pub use agent_protocol_host::{
184    AgentProtocolExactRecoveryError, AgentProtocolHost, AgentProtocolHostError,
185};
186pub use code_intelligence::{
187    CodeDiagnostic, CodeDiagnosticSeverity, CodeIntelligenceCapabilities, CodeIntelligenceError,
188    CodeIntelligenceLanguageStatus, CodeIntelligenceResult, CodeIntelligenceState,
189    CodeIntelligenceStatus, CodeLocation, CodePosition, CodeQueryResult, CodeRange, CodeSymbolKind,
190    DocumentRevision, DocumentSnapshot, DocumentSymbol, LanguageId, LocalCodeIntelligence,
191    NavigationKind, SymbolInformation, WorkspaceCodeIntelligence,
192};
193pub use cognitive_context::{
194    CognitiveContextDocumentV1, CognitiveContextError, CognitiveContextLimits,
195    CognitiveContextProvider, CognitiveContextRequestV1, CognitiveContextResponseV1,
196    CognitiveContextResult, CognitiveContextSession, CognitiveKnowledgeBindingV1,
197    CognitiveKnowledgeCitationV1, CognitivePackageBindingV1,
198    COGNITIVE_CONTEXT_REQUEST_DIGEST_DOMAIN, COGNITIVE_CONTEXT_REQUEST_SCHEMA,
199    COGNITIVE_CONTEXT_RESPONSE_SCHEMA, COGNITIVE_KNOWLEDGE_BINDING_SCHEMA,
200    COGNITIVE_PACKAGE_BINDING_SCHEMA, OKF_KNOWLEDGE_CITATION_SCHEMA,
201    OKF_KNOWLEDGE_READ_REQUEST_SCHEMA, OKF_KNOWLEDGE_SEARCH_REQUEST_SCHEMA,
202};
203pub use config::{
204    AutoDelegationConfig, CodeConfig, ModelConfig, ModelCost, ModelLimit, ModelModalities,
205    OsConfig, ProviderConfig,
206};
207pub use core_event_log::{
208    CoreEventLog, CoreEventLogError, CoreLogAppendOutcomeV1, CoreLogEntryV1, CoreLogPageV1,
209    CoreLogVerificationV1, CORE_LOG_ENTRY_DIGEST_DOMAIN_V1, CORE_LOG_ENTRY_SCHEMA_V1,
210    CORE_LOG_GENESIS_PREVIOUS_DIGEST,
211};
212pub use core_identity::{
213    ArtifactRef, CapabilityStamp, CoreEventIdentity, CoreIdentity, CoreIdentityError,
214    EvidenceCursor, LogicalClock, ManualLogicalClock, OperationId, SourceRevision,
215    SystemLogicalClock, CORE_EVENT_IDENTITY_DIGEST_DOMAIN_V1, CORE_EVENT_IDENTITY_SCHEMA_V1,
216    CORE_EVENT_PAYLOAD_DIGEST_DOMAIN_V1, CORE_IDENTITY_MAX_ARTIFACT_BYTES,
217    CORE_IDENTITY_MAX_EVENT_TYPE_BYTES, CORE_IDENTITY_MAX_ID_BYTES,
218    CORE_IDENTITY_MAX_MEDIA_TYPE_BYTES, CORE_IDENTITY_MAX_PAYLOAD_BYTES, CORE_IDENTITY_SCHEMA_V1,
219};
220pub use durable_memory::{
221    DurableMemoryActivation, DurableMemoryBindingV1, DurableMemoryMode, DurableMemoryRecallChannel,
222    DurableMemoryRecallHit, DurableMemoryRecallPolicy, DurableMemoryRecallPreview,
223    DurableMemorySemanticBindingV1, DurableMemorySemanticError, DurableMemorySemanticRecall,
224    DurableMemorySemanticRecallPolicy, DurableMemorySemanticRefreshCheckpoint,
225    DurableMemorySemanticRefreshReceipt, DurableMemorySession, DurableMemoryUse,
226    DURABLE_MEMORY_BINDING_SCHEMA_VERSION, DURABLE_MEMORY_CONTEXT_ID_PROFILE_V1,
227    DURABLE_MEMORY_CONTEXT_ID_PROFILE_V2, DURABLE_MEMORY_HYBRID_BINDING_SCHEMA_VERSION,
228    DURABLE_MEMORY_RETRIEVAL_PROFILE_V1, DURABLE_MEMORY_SEMANTIC_BINDING_SCHEMA_V1,
229    DURABLE_MEMORY_SEMANTIC_FUSION_PROFILE_V1,
230    DURABLE_MEMORY_SEMANTIC_REFRESH_CHECKPOINT_SCHEMA_V1,
231    DURABLE_MEMORY_SEMANTIC_REFRESH_PROFILE_V1,
232};
233pub use dynamic_workflow::{
234    dynamic_workflow_claim_identity, dynamic_workflow_continuation_identity,
235    dynamic_workflow_execution_plan, dynamic_workflow_step_identity, dynamic_workflow_store_path,
236    register_dynamic_workflow, register_dynamic_workflow_with_event_store,
237    register_dynamic_workflow_with_scheduler, CrossProcessFlowEventStore,
238    DynamicWorkflowAdmissionStats, DynamicWorkflowControl, DynamicWorkflowControlDiagnostics,
239    DynamicWorkflowControlSnapshot, DynamicWorkflowHealthSnapshot, DynamicWorkflowRuntime,
240    DynamicWorkflowScriptLimits, DynamicWorkflowTool, DYNAMIC_WORKFLOW_RUNTIME_BUILD_ID,
241    DYNAMIC_WORKFLOW_STORE_RELATIVE_PATH,
242};
243pub use embedding::{
244    EmbeddingBatchRequest, EmbeddingBatchResponse, EmbeddingError, EmbeddingExecution,
245    EmbeddingExecutor, EmbeddingExecutorConfig, EmbeddingFailureKind, EmbeddingInput,
246    EmbeddingNormalization, EmbeddingProvider, EmbeddingProviderDescriptor, EmbeddingProviderError,
247    EmbeddingResult, EmbeddingVector,
248};
249pub use error::SessionBuildResource;
250pub use error::{CodeError, Result};
251pub use evaluation::{
252    digest_bytes, digest_json, validate_digest, AuxiliaryCapabilityProfileV1, AuxiliaryExecutor,
253    AuxiliaryModeV1, AuxiliaryRunContextV1, AuxiliaryRunError, AuxiliaryRunHandle,
254    AuxiliaryRunOutputV1, AuxiliaryRunService, AuxiliaryRunSnapshotV1, AuxiliaryRunSpecV1,
255    AuxiliaryRunStateV1, EvaluationBoundaryV1, EvaluationDispatch, EvaluationDispatchClaimOutcome,
256    EvaluationDispatchLedger, EvaluationDispatchLedgerError, EvaluationDispatchOutcome,
257    EvaluationPlanV1, EvaluationPolicy, EvaluationProtocolError, EvaluationRecordV1,
258    EvaluationResultSink, EvaluationResultV1, EvaluationStoreError, EvaluationSupervisor,
259    EvaluationWireEnvelopeV1, EvaluationWireKindDescriptorV1, EvaluationWireKindV1,
260    EvaluationWireTypeV1, EvaluationWriteOutcomeV1, EventCursorV1, EvidenceArtifactV1,
261    EvidenceContentModeV1, EvidenceError, EvidenceEventV1, EvidenceLimitsV1, EvidenceReadRequestV1,
262    EvidenceReader, EvidenceRunStateV1, EvidenceSnapshotV1, ExecutionFactInputV1,
263    ExecutionFactJournal, ExecutionFactKindV1, ExecutionFactPageV1, ExecutionFactRecorder,
264    ExecutionFactSnapshotV1, ExecutionFactV1, ExecutionFrameV1, ExecutionTargetV1,
265    FactAppendOutcomeV1, FileEvaluationDispatchLedger, FileEvaluationResultStore, IdentityError,
266    InMemoryAuxiliaryRunService, InMemoryEvaluationDispatchLedger, InMemoryEvaluationResultStore,
267    InMemoryExecutionFactJournal, JournalError, RunEvidenceReader, StructuredAuxiliaryExecutor,
268    SupervisorError, AUXILIARY_MAX_OUTPUT_BYTES, AUXILIARY_MAX_STEPS, AUXILIARY_OUTPUT_SCHEMA_V1,
269    AUXILIARY_RUN_SCHEMA_V1, AUXILIARY_SNAPSHOT_SCHEMA_V1, EVALUATION_DISPATCH_LEASE_GRACE_MS,
270    EVALUATION_DISPATCH_LEDGER_DEFAULT_MAX_RECORDS, EVALUATION_DISPATCH_LEDGER_MAX_BYTES,
271    EVALUATION_DISPATCH_LEDGER_SCHEMA_V1, EVALUATION_DISPATCH_MIN_LEASE_MS,
272    EVALUATION_MAX_COOLDOWN_MS, EVALUATION_MAX_ID_BYTES, EVALUATION_MAX_PENDING,
273    EVALUATION_PLAN_SCHEMA_V1, EVALUATION_PROTOCOL_MAX_MESSAGE_BYTES,
274    EVALUATION_PROTOCOL_SCHEMA_V1, EVALUATION_PROTOCOL_VERSION_V1, EVALUATION_RECORD_SCHEMA_V1,
275    EVALUATION_RESULT_SCHEMA_V1, EVALUATION_RESULT_STORE_DEFAULT_MAX_RECORDS,
276    EVALUATION_RESULT_STORE_MAX_BYTES, EVALUATION_RESULT_STORE_SCHEMA_V1,
277    EVALUATION_WIRE_KIND_DESCRIPTORS_V1, EVIDENCE_MAX_ARTIFACTS, EVIDENCE_MAX_ARTIFACT_BYTES,
278    EVIDENCE_MAX_EVENTS, EVIDENCE_MAX_EVENT_BYTES, EVIDENCE_MAX_PROMPT_BYTES,
279    EVIDENCE_MAX_RESULT_BYTES, EVIDENCE_SNAPSHOT_SCHEMA_V1, EXECUTION_FACT_SCHEMA_V1,
280    EXECUTION_FRAME_SCHEMA_V1, EXECUTION_TARGET_SCHEMA_V1,
281};
282pub use event_protocol::{
283    run_event_envelope_v1, AgentEventProjectionV1, AgentEventTypeV1, EventEnvelopeV1,
284    EventProtocolError, AGENT_EVENT_TYPES_V1, EVENT_ENVELOPE_V1_VERSION,
285};
286pub use flow_graph::{
287    run_object_id as flow_run_object_id, step_object_id as flow_step_object_id,
288    FileFlowDecisionLedger, FlowDecision, FlowDecisionClaimOutcome, FlowDecisionClaimState,
289    FlowDecisionDispatchError, FlowDecisionDispatcher, FlowDecisionHealthSnapshot,
290    FlowDecisionHealthStatus, FlowDecisionLedger, FlowDecisionRequest, FlowDecisionSink,
291    FlowDecisionStep, FlowGraphHealthSnapshot, FlowGraphHealthStatus, FlowGraphObserver,
292    MemoryFlowDecisionLedger, FLOW_GRAPH_SOURCE,
293};
294pub use harness_evidence::{
295    HarnessEvidenceError, ModelInputKindV1, ModelInputSnapshotV1, ModelPresentationApplicationV1,
296    ModelPresentationSnapshotV1, ModelUsageSnapshotV1, RunCapabilitySnapshotV1,
297    RunPolicyCeilingSnapshotV1, ToolRequestOriginV1, ToolRequestSnapshotV1,
298    ToolResultContextUsageV1, WorkspaceCapabilitySnapshotV1,
299    WorkspaceRetrievalCapabilitySnapshotV1, MODEL_INPUT_SNAPSHOT_V1_SCHEMA,
300    MODEL_PRESENTATION_SNAPSHOT_V1_SCHEMA, MODEL_USAGE_SNAPSHOT_V1_SCHEMA,
301    RUN_CAPABILITY_SNAPSHOT_V1_SCHEMA, TOOL_REQUEST_SNAPSHOT_V1_SCHEMA,
302};
303pub use llm::{
304    clear_http_metrics_callback, set_http_metrics_callback, AnthropicClient, Attachment,
305    ContentBlock, HttpMetricsCallback, HttpMetricsRecord, ImageSource, LlmClient, LlmResponse,
306    Message, ModelGenerationAdmission, ModelGenerationAdmissionError, ModelGenerationConcurrency,
307    ModelGenerationPermit, ModelGenerationPool, ModelGenerationPoolError,
308    ModelGenerationPoolHealthSnapshot, OpenAiClient, TokenUsage,
309};
310#[cfg(feature = "headless-search")]
311pub use moli_runtime::{
312    default_moli_version, ensure_moli, moli_runtime_info, packaged_moli, MoliRuntimeInfo,
313    MOLI_RUNTIME_INFO_SCHEMA_V1,
314};
315pub use orchestration::{
316    execute_loop, execute_pipeline, execute_steps_parallel, execute_steps_parallel_resumable,
317    workflow_step_execution_identity, workflow_step_result_receipt, AgentExecutor, AgentStepSpec,
318    BudgetSnapshot, LoopDecision, PipelineStage, StepOutcome, Workflow, WorkflowBudget,
319    WorkflowBuilder, WorkflowCheckpoint, WorkflowEvent, WorkflowStepRecord,
320    WORKFLOW_CHECKPOINT_SCHEMA_VERSION,
321};
322pub use prompts::{AgentStyle, DetectionConfidence, PlanningMode, SystemPromptSlots};
323pub use research::{
324    ResearchArtifactKindV1, ResearchCitationV1, ResearchClaimStatusV1, ResearchClaimV1,
325    ResearchContractError, ResearchEventV1, ResearchEvidenceCompletenessV1,
326    ResearchEvidenceFactKindV1, ResearchEvidenceFactV1, ResearchEvidenceGraphV1,
327    ResearchProtocolError, ResearchProvenanceReceiptV1, ResearchReproducibilityManifestV1,
328    ResearchReproducibilityV1, ResearchRerunLineageV1, ResearchReviewBatchV1,
329    ResearchReviewCategoryV1, ResearchReviewFindingV1, ResearchReviewLocationV1,
330    ResearchReviewSeverityV1, ResearchReviewStatusV1, ResearchRunStatusV1, ResearchRunV1,
331    ResearchWireEnvelopeV1, ResearchWireKindDescriptorV1, ResearchWireKindV1, ResearchWireTypeV1,
332    ResearchWorkflowPlanV1, ResearchWorkflowStepV1, RESEARCH_ARTIFACT_KINDS,
333    RESEARCH_CITATION_SCHEMA_V1, RESEARCH_CLAIM_SCHEMA_V1, RESEARCH_EVENT_SCHEMA_V1,
334    RESEARCH_EVIDENCE_FACT_SCHEMA_V1, RESEARCH_EVIDENCE_GRAPH_SCHEMA_V1,
335    RESEARCH_MAX_EVIDENCE_GRAPH_CITATIONS, RESEARCH_MAX_EVIDENCE_GRAPH_CLAIMS,
336    RESEARCH_MAX_REVIEW_FINDINGS, RESEARCH_MAX_WORKFLOW_STEPS, RESEARCH_PROTOCOL_MAX_MESSAGE_BYTES,
337    RESEARCH_PROTOCOL_SCHEMA_V1, RESEARCH_PROTOCOL_VERSION_V1,
338    RESEARCH_PROVENANCE_RECEIPT_SCHEMA_V1, RESEARCH_REPRODUCIBILITY_MANIFEST_SCHEMA_V1,
339    RESEARCH_RERUN_LINEAGE_SCHEMA_V1, RESEARCH_REVIEW_BATCH_SCHEMA_V1,
340    RESEARCH_REVIEW_FINDING_SCHEMA_V1, RESEARCH_RUN_SCHEMA_V1, RESEARCH_WIRE_KIND_DESCRIPTORS_V1,
341    RESEARCH_WORKFLOW_PLAN_SCHEMA_V1, RESEARCH_WORKFLOW_STEP_SCHEMA_V1,
342};
343pub use rl_trajectory::{RlTrajectoryConfig, RlTrajectoryMode, RlTrajectoryRecorder};
344pub use run::{
345    ActiveToolSnapshot, InMemoryRunStore, RunEventRecord, RunHandle, RunRecord, RunReservation,
346    RunSnapshot, RunStatus, RunWorkspaceChangeSet, RunWorkspaceChangeSetError,
347};
348pub use run_control::{
349    InterruptRequest, RunControlCommand, RunControlError, RunControlErrorInfo, RunControlOperation,
350    RunControlReceipt, RunControlReceiptState, RunControlRequest, RunControlSnapshot, SteerRequest,
351    RUN_CONTROL_MAX_ID_BYTES, RUN_CONTROL_MAX_INPUT_BYTES, RUN_CONTROL_MAX_QUEUE,
352    RUN_CONTROL_MAX_REASON_BYTES, RUN_CONTROL_MAX_SEEN_REQUESTS, RUN_CONTROL_RECEIPT_SCHEMA_V1,
353    RUN_CONTROL_REQUEST_SCHEMA_V1,
354};
355pub use sdk_capabilities::{
356    sdk_capabilities, sdk_capabilities_schema, SdkCapability, SDK_CAPABILITIES_SCHEMA_V1,
357};
358pub use session_checkpoint::{
359    SdkSessionCheckpointExportV1, SessionCheckpointDescriptorV1, SessionCheckpointError,
360    SessionCheckpointExportSink, SessionCheckpointExportV1, SessionCheckpointPayloadV1,
361    SessionLogicalResumeEvidenceV1, SessionSnapshotEvidenceV1,
362    SESSION_CHECKPOINT_DESCRIPTOR_SCHEMA_V1, SESSION_CHECKPOINT_ENCODING_V1,
363    SESSION_CHECKPOINT_FORMAT_V1, SESSION_CHECKPOINT_LOGICAL_RESUME_SEMANTICS_V1,
364    SESSION_CHECKPOINT_MAX_CONTENT_BYTES, SESSION_CHECKPOINT_MEDIA_TYPE_V1,
365    SESSION_CHECKPOINT_PAYLOAD_SCHEMA_V1, SESSION_LOGICAL_RESUME_EVIDENCE_SCHEMA_V1,
366    SESSION_SNAPSHOT_EVIDENCE_SCHEMA_V1,
367};
368pub use state_graph::{
369    graph_event_head, Behavior, BehaviorContext, BehaviorError, EventFilter, ExternalEvent,
370    ExternalProjectionOutcome, FileGraphEventStore, FnBehavior, GraphDiff, GraphEvent,
371    GraphEventRecord, GraphEventStore, GraphObject, GraphPatch, GraphRelation, GraphRuntime,
372    GraphSaveOutcome, MemoryGraphEventStore, ObjectId, PatchOperation, RelationId, ReplayError,
373    RuntimeError as GraphRuntimeError, RuntimeLimits, StateGraph, GRAPH_EVENT_SCHEMA_VERSION,
374};
375pub use subagent::{
376    AgentDefinition, AgentRegistry, CattleAgentKind, CattleAgentSpec, ConfirmationInheritance,
377    WorkerAgentKind, WorkerAgentSpec,
378};
379pub use subagent_task_tracker::{
380    InMemorySubagentTaskTracker, SubagentProgressEntry, SubagentStatus, SubagentTaskSnapshot,
381};
382pub use task_scheduler::{
383    TaskLease, TaskPriority, TaskPriorityCounts, TaskScheduler, TaskSchedulerConfig,
384    TaskSchedulerError, TaskSchedulerHealthSnapshot, TaskSchedulerQuota,
385    TaskSchedulerQuotaHealthSnapshot, TaskSchedulerQuotaSnapshot, TaskSchedulerStats,
386    TASK_SCHEDULER_MAX_QUOTAS, TASK_SCHEDULER_MAX_SCOPE_BYTES,
387    TASK_SCHEDULER_QUOTA_HEALTH_RETENTION,
388};
389pub use tools::{
390    ImmutableContentAdapter, ImmutableContentAdapterBindingV1, ImmutableContentAdapterSession,
391    ImmutableContentDescriptorV1, ImmutableContentError, ImmutableContentKindV1,
392    ImmutableContentReferenceV1, ImmutableContentResult, ImmutableContentWriteRequestV1,
393    SdkImmutableContentWriteRequestV1, ToolPresentationError, ToolPresentationModeV1,
394    ToolPresentationProfileV1, IMMUTABLE_CONTENT_ADAPTER_BINDING_SCHEMA_V1,
395    IMMUTABLE_CONTENT_DESCRIPTOR_SCHEMA_V1, IMMUTABLE_CONTENT_REFERENCE_SCHEMA_V1,
396    TOOL_PRESENTATION_PROFILE_V1_SCHEMA, TOOL_RESULT_CONTENT_MEDIA_TYPE,
397};
398pub use tools::{ToolCapabilities, ToolErrorKind, ToolOutputKind, ToolResultTrustV1};
399pub use use_runtime_tasks::{
400    UsePlanScope, UsePlanScopeKind, UseProjectedLifecycleIdentity, UseRuntimeTaskDispatcher,
401    UseRuntimeTaskError, UseRuntimeTaskExecutionV1, UseRuntimeTaskProjectionAdapter,
402    UseRuntimeTaskProjectionV1, UseRuntimeTaskRequestV1, UseRuntimeTaskResult,
403    MAX_USE_RUNTIME_TASK_ARGUMENTS, MAX_USE_RUNTIME_TASK_ARGUMENT_BYTES,
404    MAX_USE_RUNTIME_TASK_OUTPUT_BYTES, MAX_USE_RUNTIME_TASK_TIMEOUT_MS,
405    USE_RUNTIME_TASK_REQUEST_SCHEMA, USE_RUNTIME_TASK_RESULT_SCHEMA,
406};
407pub use workspace::{
408    ChunkCatalogLimits, ChunkCatalogSnapshot, ChunkingConfig, CommandOutput, CommandOutputObserver,
409    CommandOutputSummary, CommandRequest, CustomWorkspaceChunkingStrategy,
410    FixedWindowChunkingOptions, LexicalSearchHit, LexicalSearchRequest, LexicalSearchResult,
411    LocalWorkspaceAccessPolicy, LocalWorkspaceBackend, LocalWorkspaceFile,
412    LocalWorkspaceFileStatus, LocalWorkspaceManifest, LocalWorkspaceManifestSnapshot,
413    ManifestWorkspaceBackend, RecentWorkspaceFile, RecursiveChunkingOptions, RemoteGitBackend,
414    RemoteGitBackendConfig, RemoteGitConflict, VirtualPathResolver, WorkspaceCapabilities,
415    WorkspaceChunk, WorkspaceChunkCatalog, WorkspaceChunkId, WorkspaceChunkRange,
416    WorkspaceChunkingError, WorkspaceChunkingInput, WorkspaceChunkingStrategy,
417    WorkspaceCommandRunner, WorkspaceDirEntry, WorkspaceEligibilityPolicy,
418    WorkspaceEmbeddingBatchMetrics, WorkspaceError, WorkspaceFileChange, WorkspaceFileChangeKind,
419    WorkspaceFileSystem, WorkspaceFileSystemExt, WorkspaceFileType, WorkspaceGit,
420    WorkspaceGitBranch, WorkspaceGitCheckoutOutput, WorkspaceGitCheckoutRequest,
421    WorkspaceGitCommit, WorkspaceGitCreateBranchRequest, WorkspaceGitCreateWorktreeRequest,
422    WorkspaceGitDiffRequest, WorkspaceGitRemote, WorkspaceGitRemoveWorktreeRequest,
423    WorkspaceGitStash, WorkspaceGitStashProvider, WorkspaceGitStashRequest, WorkspaceGitStatus,
424    WorkspaceGitWorktree, WorkspaceGitWorktreeMutation, WorkspaceGitWorktreeProvider,
425    WorkspaceGlobRequest, WorkspaceGlobResult, WorkspaceGrepOutcome, WorkspaceGrepRequest,
426    WorkspaceGrepResult, WorkspaceHybridChannelRank, WorkspaceHybridChannelStatus,
427    WorkspaceHybridFallbackReason, WorkspaceHybridSearchHit, WorkspaceHybridSearchRequest,
428    WorkspaceHybridSearchResult, WorkspaceIndexError, WorkspaceLexicalEngine, WorkspacePath,
429    WorkspacePathResolver, WorkspacePersistentIndex, WorkspacePersistentIndexPhase,
430    WorkspacePersistentIndexStatus, WorkspaceRef, WorkspaceRerankAlgorithm,
431    WorkspaceRerankFallbackReason, WorkspaceRerankMode, WorkspaceRerankOptions,
432    WorkspaceRerankStatus, WorkspaceResult, WorkspaceRetrievalChannel, WorkspaceRetrievalError,
433    WorkspaceRetrievalOptions, WorkspaceRetrievalPhase, WorkspaceRetrievalResult,
434    WorkspaceRetrievalRuntime, WorkspaceRetrievalStatus, WorkspaceSearch,
435    WorkspaceSemanticFallbackReason, WorkspaceSemanticIndexLimits, WorkspaceSemanticSearchHit,
436    WorkspaceSemanticSearchRequest, WorkspaceSemanticSearchResult, WorkspaceServices,
437    WorkspaceServicesBuilder, WorkspaceTextRange, WorkspaceTextReader, WorkspaceVersionConflict,
438    WorkspaceWriteOutcome,
439};
440#[cfg(feature = "s3")]
441pub use workspace::{S3BackendConfig, S3WorkspaceBackend};