@fifthrevision/axle 0.30.2 → 0.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,7 +1,6 @@
1
- import { $ as ThinkingContinuity, At as SpanOptions, B as AxleUserMessage, C as CompactionPart, Ct as EventLevel, D as SubagentAction, Dt as Span, E as ProviderToolAction, Et as LLMResult, F as TurnStatus, Ft as ToolResult, G as ContentPartCitation, H as CitationOutputSpan, I as AxleAssistantMessage, It as TraceWriter, J as ContentPartText, K as ContentPartFile, L as AxleMessage, M as Turn, Mt as SpanStatus, N as TurnMetadata, Nt as SpanType, O as TextPart, Ot as SpanData, P as TurnPart, Pt as TokenUsage, Q as MessageMetadata, R as AxleToolCallMessage, S as CitationPart, St as UsageEntry, T as FilePart, Tt as LLMResponse, U as CitationSource, V as Citation, W as ContentPart, X as ContentPartToolCall, Y as ContentPartThinking, Z as DocumentLocator, _ as ActionPart, _t as FileResolver, a as CompactionStamp, at as ModelError, b as AnnotationPlacement, bt as Stats, c as ExecutableTool, ct as ProviderOptions, d as ToolDefinition, dt as DeferredFileInfo, et as ToolResultPart, f as ToolProgressChunk, ft as FileInfo, g as TurnEvent, gt as FileResolveRequest, h as AnnotationTarget, ht as FileResolveFormat, it as ContextUsage, j as ToolAction, jt as SpanResult, k as ThinkingPart, kt as SpanEvent, l as ProviderTool, lt as ResolvedProviderTool, m as AnnotationEvent, mt as FileProviderId, n as TranscriptApplyResult, nt as AxleModelRequestOptions, o as getCompactionStamp, ot as ModelResult, p as ToolRegistry, pt as FileKind, q as ContentPartProviderTool, r as TranscriptInput, rt as AxleStopReason, s as validateCompactedMessages, st as ProviderClientOptions, t as Transcript, tt as AIProvider, u as ToolContext, ut as ToolChoice, v as ActionResult, vt as ResolvedFileSource, w as CompactionUpdate, wt as LLMRequest, x as AnnotationStatus, xt as TokenStats, y as Annotation, yt as loadFileContent, z as AxleToolCallResult } from "./transcript-D69LP3XR.js";
1
+ import { $ as ThinkingContinuity, At as SpanOptions, B as AxleUserMessage, C as CompactionPart, Ct as EventLevel, D as SubagentAction, Dt as Span, E as ProviderToolAction, Et as LLMResult, F as TurnStatus, Ft as ToolResult, G as ContentPartCitation, H as CitationOutputSpan, I as AxleAssistantMessage, It as TraceWriter, J as ContentPartText, K as ContentPartFile, L as AxleMessage, M as Turn, Mt as SpanStatus, N as TurnMetadata, Nt as SpanType, O as TextPart, Ot as SpanData, P as TurnPart, Pt as TokenUsage, Q as MessageMetadata, R as AxleToolCallMessage, S as CitationPart, St as UsageEntry, T as FilePart, Tt as LLMResponse, U as CitationSource, V as Citation, W as ContentPart, X as ContentPartToolCall, Y as ContentPartThinking, Z as DocumentLocator, _ as ActionPart, _t as FileResolver, a as CompactionStamp, at as ModelError, b as AnnotationPlacement, bt as Stats, c as ExecutableTool, ct as ToolChoice, d as ToolDefinition, dt as DeferredFileInfo, et as ToolResultPart, f as ToolProgressChunk, ft as FileInfo, g as TurnEvent, gt as FileResolveRequest, h as AnnotationTarget, ht as FileResolveFormat, it as ContextUsage, j as ToolAction, jt as SpanResult, k as ThinkingPart, kt as SpanEvent, l as ProviderTool, lt as ReasoningEffort, m as AnnotationEvent, mt as FileProviderId, n as TranscriptApplyResult, nt as AxleModelRequestOptions, o as getCompactionStamp, ot as ProviderClientOptions, p as ToolRegistry, pt as FileKind, q as ContentPartProviderTool, r as TranscriptInput, rt as AxleStopReason, s as validateCompactedMessages, st as ProviderOptions, t as Transcript, tt as AIProvider, u as ToolContext, ut as ReasoningSetting, v as ActionResult, vt as ResolvedFileSource, w as CompactionUpdate, wt as LLMRequest, x as AnnotationStatus, xt as TokenStats, y as Annotation, yt as loadFileContent, z as AxleToolCallResult } from "./transcript-IlzS5MWE.js";
2
2
  import * as z$2 from "zod";
3
- import { ZodObject, z } from "zod";
4
-
3
+ import { ZodObject, z as z$1 } from "zod";
5
4
  //#region src/tools/webSearch.d.ts
6
5
  interface WebSearchRequest {
7
6
  query: string;
@@ -37,13 +36,13 @@ interface BraveWebSearchOptions {
37
36
  freshness?: "pd" | "pw" | "pm" | "py" | `${string}to${string}`;
38
37
  timeoutMs?: number;
39
38
  }
40
- declare function braveWebSearch(options: BraveWebSearchOptions): WebSearchBackend;
39
+ export declare function braveWebSearch(options: BraveWebSearchOptions): WebSearchBackend;
41
40
  //#endregion
42
41
  //#region src/config.d.ts
43
42
  interface AxleConfiguration {
44
43
  webSearchFallback?: WebSearchBackend;
45
44
  }
46
- declare function configureAxle(options: AxleConfiguration): void;
45
+ export declare function configureAxle(options: AxleConfiguration): void;
47
46
  //#endregion
48
47
  //#region src/mcp/MCP.d.ts
49
48
  interface MCPStdioConfig {
@@ -60,7 +59,7 @@ interface MCPHttpConfig {
60
59
  headers?: Record<string, string>;
61
60
  }
62
61
  type MCPConfig = MCPStdioConfig | MCPHttpConfig;
63
- declare class MCP {
62
+ export declare class MCP {
64
63
  private config;
65
64
  private client;
66
65
  private transport;
@@ -94,7 +93,7 @@ declare class MCP {
94
93
  //#region src/core/parse.d.ts
95
94
  type OutputSchema = z$2.ZodTypeAny;
96
95
  type ParsedSchema<T extends OutputSchema> = z$2.output<T>;
97
- declare function parseResponse<T extends OutputSchema>(rawValue: string, schema?: T): ParsedSchema<T> | string;
96
+ export declare function parseResponse<T extends OutputSchema>(rawValue: string, schema?: T): ParsedSchema<T> | string;
98
97
  //#endregion
99
98
  //#region src/core/Instruct.d.ts
100
99
  type InstructInputs = Record<string, unknown>;
@@ -113,7 +112,7 @@ interface InstructOptions<TSchema extends OutputSchema | undefined = OutputSchem
113
112
  vars?: InstructVarsMode;
114
113
  metadata?: MessageMetadata;
115
114
  }
116
- declare class Instruct<TSchema extends OutputSchema | undefined = undefined> {
115
+ export declare class Instruct<TSchema extends OutputSchema | undefined = undefined> {
117
116
  prompt: string;
118
117
  inputs: InstructInputs;
119
118
  files: FileInfo[];
@@ -161,7 +160,7 @@ type LogFn = (entry: LogEntry) => void;
161
160
  * reconstruct the trace skeleton from the log stream alone. The full span tree
162
161
  * also reaches a real span exporter via a separate writer.
163
162
  */
164
- declare class LogWriter implements TraceWriter {
163
+ export declare class LogWriter implements TraceWriter {
165
164
  private readonly log;
166
165
  constructor(log: LogFn);
167
166
  onSpanStart(): void;
@@ -174,7 +173,7 @@ interface TracerOptions {
174
173
  minLevel?: EventLevel;
175
174
  writers?: TraceWriter[];
176
175
  }
177
- declare class Tracer {
176
+ export declare class Tracer {
178
177
  private rec;
179
178
  constructor(options?: TracerOptions);
180
179
  get minLevel(): EventLevel;
@@ -186,7 +185,7 @@ declare class Tracer {
186
185
  }
187
186
  //#endregion
188
187
  //#region src/errors/AxleError.d.ts
189
- declare class AxleError extends Error {
188
+ export declare class AxleError extends Error {
190
189
  readonly code: string;
191
190
  readonly id?: string;
192
191
  readonly details?: Record<string, any>;
@@ -207,7 +206,7 @@ declare class AxleError extends Error {
207
206
  }
208
207
  //#endregion
209
208
  //#region src/errors/AxleAbortError.d.ts
210
- declare class AxleAbortError extends AxleError {
209
+ export declare class AxleAbortError extends AxleError {
211
210
  readonly reason: unknown;
212
211
  readonly messages?: AxleMessage[];
213
212
  readonly partial?: AxleAssistantMessage;
@@ -233,7 +232,7 @@ declare class AxleAbortError extends AxleError {
233
232
  }
234
233
  //#endregion
235
234
  //#region src/errors/AxleToolFatalError.d.ts
236
- declare class AxleToolFatalError extends AxleError {
235
+ export declare class AxleToolFatalError extends AxleError {
237
236
  readonly toolName?: string;
238
237
  readonly messages?: AxleMessage[];
239
238
  readonly partial?: AxleAssistantMessage;
@@ -291,7 +290,7 @@ type AxleFailure = {
291
290
  };
292
291
  /** @deprecated Use AxleFailure. */
293
292
  type GenerateError = AxleFailure;
294
- type GenerateResult<TResponse = AxleAssistantMessage> = {
293
+ type StreamResult<TResponse = AxleAssistantMessage> = {
295
294
  ok: true;
296
295
  response: TResponse;
297
296
  messages: AxleMessage[];
@@ -319,7 +318,7 @@ type GenerateResult<TResponse = AxleAssistantMessage> = {
319
318
  */
320
319
  stopped?: "max-steps" | "token-limit";
321
320
  };
322
- type StreamResult<TResponse = AxleAssistantMessage> = GenerateResult<TResponse>;
321
+ type GenerateResult<TResponse = AxleAssistantMessage> = StreamResult<TResponse>;
323
322
  //#endregion
324
323
  //#region src/utils/utils.d.ts
325
324
  interface Handle<T> {
@@ -541,8 +540,10 @@ type CompactionCallback = (state: {
541
540
  }, context: {
542
541
  usage: ContextUsage;
543
542
  signal?: AbortSignal;
544
- trigger: CompactionTrigger; /** Engine-generated id for this compaction; the emitted part shares it. */
545
- id: string; /** Update transient reader-facing state on the running part. */
543
+ trigger: CompactionTrigger;
544
+ /** Engine-generated id for this compaction; the emitted part shares it. */
545
+ id: string;
546
+ /** Update transient reader-facing state on the running part. */
546
547
  emit: (update: CompactionUpdate) => void;
547
548
  }) => MaybePromise<{
548
549
  messages: AxleMessage[];
@@ -574,7 +575,7 @@ interface SendMessageOptions extends AxleModelRequestOptions {
574
575
  }
575
576
  //#endregion
576
577
  //#region src/core/agent/Agent.d.ts
577
- declare class Agent {
578
+ export declare class Agent {
578
579
  readonly provider: AIProvider;
579
580
  readonly model: string;
580
581
  readonly name?: string;
@@ -686,35 +687,55 @@ declare class Agent {
686
687
  * tools, and MCP clients. Harness runtime services such as file resolvers
687
688
  * should be layered onto the returned config by the host.
688
689
  */
689
- declare function createAgentConfig(definition: AgentDefinition, resolver: AgentDefinitionResolver): Promise<AgentConfig>;
690
+ export declare function createAgentConfig(definition: AgentDefinition, resolver: AgentDefinitionResolver): Promise<AgentConfig>;
690
691
  //#endregion
691
692
  //#region src/compaction/PromptCompactor.d.ts
692
693
  interface PromptCompactorOptions {
693
694
  provider: AIProvider;
694
695
  model: string;
695
696
  prompt: string;
697
+ /** Estimated context size at which automatic triggers compact. */
696
698
  thresholdTokens: number;
697
- targetTokens: number;
698
- recentUserMessages?: number;
699
- reasoning?: boolean;
699
+ /** Requested summary length, in words. Default 1000. */
700
+ summaryWords?: number;
701
+ /**
702
+ * Budget for recent user messages kept verbatim. Defaults to a tenth of
703
+ * `thresholdTokens`; 0 keeps none.
704
+ */
705
+ appendixTokens?: number;
706
+ reasoning?: ReasoningSetting;
700
707
  providerOptions?: ProviderOptions;
701
708
  }
702
- declare class PromptCompactor {
709
+ /**
710
+ * Prompt-based compactor: summarizes the conversation with the configured
711
+ * model and appends recent user messages verbatim.
712
+ *
713
+ * The summary side is words-native: `summaryWords` steers the prompt, the
714
+ * result is measured in words, one relative-shrink rewrite runs if it lands
715
+ * over ~1.3× the request, and word-boundary truncation is the last resort.
716
+ * The request sends no output cap, so thinking models reason within the
717
+ * provider's own ceiling. The appendix side stays token-denominated: up to
718
+ * the last ten user messages, evicted oldest-first to fit `appendixTokens`.
719
+ *
720
+ * @experimental Compaction is under active design and may change in any release.
721
+ */
722
+ export declare class PromptCompactor {
703
723
  private readonly provider;
704
724
  private readonly model;
705
725
  private readonly prompt;
706
726
  private readonly thresholdTokens;
707
- private readonly targetTokens;
708
- private readonly recentUserMessages;
727
+ private readonly summaryWords;
728
+ private readonly appendixTokens;
709
729
  private readonly reasoning;
710
730
  private readonly providerOptions;
711
731
  constructor(options: PromptCompactorOptions);
712
732
  readonly shouldCompactOnTrigger: ShouldCompactOnTriggerCallback;
713
733
  readonly compact: CompactionCallback;
734
+ private generateSummary;
714
735
  }
715
736
  //#endregion
716
737
  //#region src/errors/AxleAgentAbortError.d.ts
717
- declare class AxleAgentAbortError extends AxleAbortError {
738
+ export declare class AxleAgentAbortError extends AxleAbortError {
718
739
  readonly turn?: Turn;
719
740
  constructor(message?: string, options?: {
720
741
  reason?: unknown;
@@ -739,7 +760,7 @@ declare class AxleAgentAbortError extends AxleAbortError {
739
760
  }
740
761
  //#endregion
741
762
  //#region src/errors/InstructVariableError.d.ts
742
- declare class InstructVariableError extends AxleError {
763
+ export declare class InstructVariableError extends AxleError {
743
764
  readonly missingVariables: string[];
744
765
  constructor(missingVariables: string[]);
745
766
  toJSON(): {
@@ -754,7 +775,7 @@ declare class InstructVariableError extends AxleError {
754
775
  }
755
776
  //#endregion
756
777
  //#region src/errors/TaskError.d.ts
757
- declare class TaskError extends AxleError {
778
+ export declare class TaskError extends AxleError {
758
779
  constructor(message: string, options?: {
759
780
  id?: string;
760
781
  taskType?: string;
@@ -765,7 +786,7 @@ declare class TaskError extends AxleError {
765
786
  }
766
787
  //#endregion
767
788
  //#region src/providers/anthropic/provider.d.ts
768
- declare function anthropic(apiKey: string, options?: ProviderClientOptions): AIProvider;
789
+ export declare function anthropic(apiKey: string, options?: ProviderClientOptions): AIProvider;
769
790
  //#endregion
770
791
  //#region src/providers/chatcompletions/utils.d.ts
771
792
  type ChatCompletionsVendor = "openrouter" | "together";
@@ -775,9 +796,9 @@ interface ChatCompletionsOptions extends ProviderClientOptions {
775
796
  apiKey?: string;
776
797
  vendor?: ChatCompletionsVendor;
777
798
  }
778
- declare function chatCompletions(baseUrl: string, options?: ChatCompletionsOptions): AIProvider;
779
- declare function chatCompletions(baseUrl: string, apiKey?: string): AIProvider;
780
- declare function chatCompletions(baseUrl: string, apiKey: string, options?: Omit<ChatCompletionsOptions, "apiKey">): AIProvider;
799
+ export declare function chatCompletions(baseUrl: string, options?: ChatCompletionsOptions): AIProvider;
800
+ export declare function chatCompletions(baseUrl: string, apiKey?: string): AIProvider;
801
+ export declare function chatCompletions(baseUrl: string, apiKey: string, options?: Omit<ChatCompletionsOptions, "apiKey">): AIProvider;
781
802
  //#endregion
782
803
  //#region src/providers/context.d.ts
783
804
  interface ContextEstimateInput {
@@ -788,52 +809,10 @@ interface ContextEstimateInput {
788
809
  messages: AxleMessage[];
789
810
  limit?: number;
790
811
  }
791
- declare function estimateContextUsage(input: ContextEstimateInput): ContextUsage;
812
+ export declare function estimateContextUsage(input: ContextEstimateInput): ContextUsage;
792
813
  //#endregion
793
814
  //#region src/providers/gemini/provider.d.ts
794
- declare function gemini(apiKey: string, options?: ProviderClientOptions): AIProvider;
795
- //#endregion
796
- //#region src/providers/generate.d.ts
797
- interface GenerateParams extends AxleModelRequestOptions {
798
- provider: AIProvider;
799
- model: string;
800
- messages: Array<AxleMessage>;
801
- system?: string;
802
- tools?: ExecutableTool[];
803
- providerTools?: ProviderTool[];
804
- registry?: ToolRegistry;
805
- onToolCall?: ToolCallCallback;
806
- maxSteps?: number;
807
- /**
808
- * Context budget for the tool loop, in tokens. Checked at each request
809
- * boundary against the previous model call's reported usage (effective
810
- * input + output); when crossed, the loop returns `stopped: "token-limit"`
811
- * with everything accumulated so far.
812
- */
813
- maxContextTokens?: number;
814
- span?: Span;
815
- fileResolver?: FileResolver;
816
- }
817
- interface GenerateInstructParams<TSchema extends OutputSchema | undefined> extends Omit<GenerateParams, "messages"> {
818
- messages?: Array<AxleMessage>;
819
- instruct: Instruct<TSchema>;
820
- }
821
- type GenerateInstructResult<TSchema extends OutputSchema | undefined> = GenerateResult<InstructResponse<TSchema>>;
822
- declare function generate<TSchema extends OutputSchema | undefined>(options: GenerateInstructParams<TSchema>): Promise<GenerateInstructResult<TSchema>>;
823
- declare function generate(options: GenerateParams): Promise<GenerateResult>;
824
- //#endregion
825
- //#region src/providers/generateStep.d.ts
826
- interface GenerateStepParams extends AxleModelRequestOptions {
827
- provider: AIProvider;
828
- model: string;
829
- messages: Array<AxleMessage>;
830
- system?: string;
831
- tools?: Array<ToolDefinition>;
832
- providerTools?: Array<ResolvedProviderTool>;
833
- span?: Span;
834
- fileResolver?: FileResolver;
835
- }
836
- declare function generateStep(props: GenerateStepParams): Promise<ModelResult>;
815
+ export declare function gemini(apiKey: string, options?: ProviderClientOptions): AIProvider;
837
816
  //#endregion
838
817
  //#region src/providers/stream.d.ts
839
818
  type StreamEvent = {
@@ -869,11 +848,10 @@ type StreamEvent = {
869
848
  providerMetadata?: Record<string, unknown>;
870
849
  } | {
871
850
  type: "thinking:start";
872
- redacted?: boolean;
873
851
  continuity?: ThinkingContinuity;
874
852
  providerMetadata?: Record<string, unknown>;
875
853
  } | {
876
- type: "thinking:delta";
854
+ type: "thinking:raw-delta";
877
855
  delta: string;
878
856
  accumulated: string;
879
857
  } | {
@@ -882,12 +860,12 @@ type StreamEvent = {
882
860
  accumulated: string;
883
861
  } | {
884
862
  type: "thinking:update";
885
- redacted?: boolean;
886
863
  continuity?: ThinkingContinuity;
887
864
  providerMetadata?: Record<string, unknown>;
888
865
  } | {
889
866
  type: "thinking:end";
890
- final: string;
867
+ summary?: string;
868
+ raw?: string;
891
869
  } | {
892
870
  type: "tool:request";
893
871
  id: string;
@@ -974,11 +952,23 @@ type StreamInstructResult<TSchema extends OutputSchema | undefined> = StreamResu
974
952
  interface StreamInstructHandle<TSchema extends OutputSchema | undefined> extends Omit<StreamHandle, "final"> {
975
953
  readonly final: Promise<StreamInstructResult<TSchema>>;
976
954
  }
977
- declare function stream<TSchema extends OutputSchema | undefined>(options: StreamInstructParams<TSchema>): StreamInstructHandle<TSchema>;
978
- declare function stream(options: StreamParams): StreamHandle;
955
+ export declare function stream<TSchema extends OutputSchema | undefined>(options: StreamInstructParams<TSchema>): StreamInstructHandle<TSchema>;
956
+ export declare function stream(options: StreamParams): StreamHandle;
957
+ export declare function stream(options: StreamParams | StreamInstructParams<any>): StreamHandle;
958
+ //#endregion
959
+ //#region src/providers/generate.d.ts
960
+ type GenerateParams = StreamParams;
961
+ type GenerateInstructParams<TSchema extends OutputSchema | undefined> = StreamInstructParams<TSchema>;
962
+ type GenerateInstructResult<TSchema extends OutputSchema | undefined> = StreamInstructResult<TSchema>;
963
+ /**
964
+ * The non-streaming return shape of `stream()`: the same request, the same
965
+ * tool loop, and the same result, resolved as a promise instead of a handle.
966
+ */
967
+ export declare function generate<TSchema extends OutputSchema | undefined>(options: GenerateInstructParams<TSchema>): Promise<GenerateInstructResult<TSchema>>;
968
+ export declare function generate(options: GenerateParams): Promise<GenerateResult>;
979
969
  //#endregion
980
970
  //#region src/providers/openai/provider.d.ts
981
- declare function openai(apiKey: string, options?: ProviderClientOptions): AIProvider;
971
+ export declare function openai(apiKey: string, options?: ProviderClientOptions): AIProvider;
982
972
  //#endregion
983
973
  //#region src/tools/agentTool.d.ts
984
974
  interface CreateAgentToolOptions<TSchema extends ZodObject<any>> {
@@ -986,12 +976,12 @@ interface CreateAgentToolOptions<TSchema extends ZodObject<any>> {
986
976
  description: string;
987
977
  schema: TSchema;
988
978
  /** Create the child agent for this tool call. Fresh agents are recommended. */
989
- createAgent: (input: z.infer<TSchema>, ctx: ToolContext) => MaybePromise<Agent>;
979
+ createAgent: (input: z$1.infer<TSchema>, ctx: ToolContext) => MaybePromise<Agent>;
990
980
  /**
991
981
  * Convert tool input into the child-agent user prompt. Defaults to a compact
992
982
  * JSON task payload.
993
983
  */
994
- prompt?: string | ((input: z.infer<TSchema>) => string);
984
+ prompt?: string | ((input: z$1.infer<TSchema>) => string);
995
985
  /** Per-send request overrides for the child agent. */
996
986
  request?: AxleModelRequestOptions;
997
987
  }
@@ -1006,7 +996,7 @@ interface CreateAgentToolOptions<TSchema extends ZodObject<any>> {
1006
996
  * @experimental Shapes related to subagent rendering may change in a minor
1007
997
  * release.
1008
998
  */
1009
- declare function createAgentTool<TSchema extends ZodObject<any>>(options: CreateAgentToolOptions<TSchema>): ExecutableTool<TSchema>;
999
+ export declare function createAgentTool<TSchema extends ZodObject<any>>(options: CreateAgentToolOptions<TSchema>): ExecutableTool<TSchema>;
1010
1000
  //#endregion
1011
1001
  //#region src/tools/parallelize.d.ts
1012
1002
  interface ParallelizeOptions {
@@ -1042,12 +1032,12 @@ interface ParallelToolResult<TInput = unknown> {
1042
1032
  * @experimental The generated tool's result parts (`ParallelToolResult`) may
1043
1033
  * change in a minor release.
1044
1034
  */
1045
- declare function parallelize<TSchema extends ZodObject<any>>(tool: ExecutableTool<TSchema>, options?: ParallelizeOptions): ExecutableTool<ZodObject<{
1046
- items: z.ZodArray<TSchema>;
1035
+ export declare function parallelize<TSchema extends ZodObject<any>>(tool: ExecutableTool<TSchema>, options?: ParallelizeOptions): ExecutableTool<ZodObject<{
1036
+ items: z$1.ZodArray<TSchema>;
1047
1037
  }>>;
1048
1038
  //#endregion
1049
1039
  //#region src/turns/eventBuilder.d.ts
1050
- declare class TurnEventBuilder {
1040
+ export declare class TurnEventBuilder {
1051
1041
  private currentTurnId;
1052
1042
  private currentTurnTiming;
1053
1043
  private currentTextPart;
@@ -1078,7 +1068,7 @@ interface SimpleWriterOptions {
1078
1068
  /** Custom output function (default: console.log) */
1079
1069
  output?: (line: string) => void;
1080
1070
  }
1081
- declare class SimpleWriter implements TraceWriter {
1071
+ export declare class SimpleWriter implements TraceWriter {
1082
1072
  private minLevel;
1083
1073
  private showInternal;
1084
1074
  private showTimestamp;
@@ -1111,15 +1101,9 @@ declare class SimpleWriter implements TraceWriter {
1111
1101
  onEvent(span: SpanData, event: SpanEvent): void;
1112
1102
  }
1113
1103
  //#endregion
1114
- //#region src/store/types.d.ts
1115
- interface FileStore {
1116
- read(path: string): Promise<string | null>;
1117
- write(path: string, content: string): Promise<void>;
1118
- }
1119
- //#endregion
1120
1104
  //#region src/utils/stats.d.ts
1121
- declare function createStats(): Stats;
1122
- declare function addStats(total: Stats, usage?: Stats): void;
1123
- declare function mergeStats(...usages: Array<Stats | undefined>): Stats;
1105
+ export declare function createStats(): Stats;
1106
+ export declare function addStats(total: Stats, usage?: Stats): void;
1107
+ export declare function mergeStats(...usages: Array<Stats | undefined>): Stats;
1124
1108
  //#endregion
1125
- export { type AIProvider, type ActionPart, type ActionResult, Agent, type AgentConfig, type AgentDefinition, type AgentDefinitionRequestOptions, type AgentDefinitionResolver, type AgentErrorResult, type AgentHandle, type AgentResult, type AgentSession, type Annotation, type AnnotationEvent, type AnnotationPlacement, type AnnotationStatus, type AnnotationTarget, type AutomaticCompactionTrigger, AxleAbortError, AxleAgentAbortError, type AxleAssistantMessage, type AxleConfiguration, AxleError, type AxleFailure, type AxleMessage, type AxleModelRequestOptions, AxleStopReason, type AxleToolCallMessage, type AxleToolCallResult, AxleToolFatalError, type AxleUserMessage, type BraveWebSearchOptions, type ChatCompletionsOptions, type ChatCompletionsVendor, type Citation, type CitationOutputSpan, type CitationPart, type CitationSource, type CompactionCallback, type CompactionConfig, type CompactionPart, type CompactionStamp, type CompactionTrigger, type CompactionUpdate, type ContentPart, type ContentPartCitation, type ContentPartFile, type ContentPartProviderTool, type ContentPartText, type ContentPartThinking, type ContentPartToolCall, type ContextUsage, type CreateAgentToolOptions, type DeferredFileInfo, type DocumentLocator, type EventLevel, type ExecutableTool, type FileInfo, type FileKind, type FilePart, type FileProviderId, type FileResolveFormat, type FileResolveRequest, type FileResolver, type FileStore, type GenerateError, type GenerateInstructParams, type GenerateInstructResult, type GenerateParams, type GenerateResult, type Handle, Instruct, type InstructContextSection, type InstructInputs, type InstructOptions, type InstructRenderOptions, type InstructResponse, InstructVariableError, type InstructVarsMode, type LLMRequest, type LLMResponse, type LLMResult, type LogEntry, type LogFn, LogWriter, MCP, type MCPConfig, type MCPHttpConfig, type MCPStdioConfig, type MaybePromise, type MessageMetadata, type ObservabilityOptions, type OutputSchema, type ParallelToolResult, type ParallelizeOptions, type ParsedSchema, PromptCompactor, type PromptCompactorOptions, type ProviderClientOptions, type ProviderDefinition, type ProviderOptions, type ProviderTool, type ProviderToolAction, type ProviderToolDefinitionRef, type ResolvedAgentDefinition, type ResolvedFileSource, type SavedAgent, type SendMessageOptions, type ShouldCompactOnTriggerCallback, SimpleWriter, type SimpleWriterOptions, type Span, type SpanData, type SpanEvent, type SpanOptions, type SpanResult, type SpanStatus, type SpanType, type Stats, type StreamEvent, type StreamEventCallback, type StreamHandle, type StreamInstructHandle, type StreamInstructParams, type StreamInstructResult, type StreamParams, type StreamResult, type SubagentAction, TaskError, type TextPart, type ThinkingContinuity, type ThinkingPart, type TokenStats, type TokenUsage, type ToolAction, type ToolBatchCompleteCallback, type ToolChoice, type ToolContext, type ToolDefinition, type ToolDefinitionRef, type ToolProgressChunk, ToolRegistry, type ToolResult, type ToolResultPart, type TraceWriter, Tracer, type TracerOptions, Transcript, type TranscriptApplyResult, type TranscriptInput, type Turn, type TurnEvent, TurnEventBuilder, type TurnEventCallback, type TurnMetadata, type TurnPart, type TurnStatus, type UsageEntry, type WebSearchBackend, type WebSearchBackendContext, type WebSearchRequest, type WebSearchResponse, type WebSearchResult, addStats, anthropic, braveWebSearch, chatCompletions, configureAxle, createAgentConfig, createAgentTool, createStats, estimateContextUsage, gemini, generate, generateStep, getCompactionStamp, loadFileContent, mergeStats, openai, parallelize, parseResponse, stream, validateCompactedMessages };
1109
+ export { type AIProvider, type ActionPart, type ActionResult, type AgentConfig, type AgentDefinition, type AgentDefinitionRequestOptions, type AgentDefinitionResolver, type AgentErrorResult, type AgentHandle, type AgentResult, type AgentSession, type Annotation, type AnnotationEvent, type AnnotationPlacement, type AnnotationStatus, type AnnotationTarget, type AutomaticCompactionTrigger, type AxleAssistantMessage, type AxleConfiguration, type AxleFailure, type AxleMessage, type AxleModelRequestOptions, AxleStopReason, type AxleToolCallMessage, type AxleToolCallResult, type AxleUserMessage, type BraveWebSearchOptions, type ChatCompletionsOptions, type ChatCompletionsVendor, type Citation, type CitationOutputSpan, type CitationPart, type CitationSource, type CompactionCallback, type CompactionConfig, type CompactionPart, type CompactionStamp, type CompactionTrigger, type CompactionUpdate, type ContentPart, type ContentPartCitation, type ContentPartFile, type ContentPartProviderTool, type ContentPartText, type ContentPartThinking, type ContentPartToolCall, type ContextUsage, type CreateAgentToolOptions, type DeferredFileInfo, type DocumentLocator, type EventLevel, type ExecutableTool, type FileInfo, type FileKind, type FilePart, type FileProviderId, type FileResolveFormat, type FileResolveRequest, type FileResolver, type GenerateError, type GenerateInstructParams, type GenerateInstructResult, type GenerateParams, type GenerateResult, type Handle, type InstructContextSection, type InstructInputs, type InstructOptions, type InstructRenderOptions, type InstructResponse, type InstructVarsMode, type LLMRequest, type LLMResponse, type LLMResult, type LogEntry, type LogFn, type MCPConfig, type MCPHttpConfig, type MCPStdioConfig, type MaybePromise, type MessageMetadata, type ObservabilityOptions, type OutputSchema, type ParallelToolResult, type ParallelizeOptions, type ParsedSchema, type PromptCompactorOptions, type ProviderClientOptions, type ProviderDefinition, type ProviderOptions, type ProviderTool, type ProviderToolAction, type ProviderToolDefinitionRef, type ReasoningEffort, type ReasoningSetting, type ResolvedAgentDefinition, type ResolvedFileSource, type SavedAgent, type SendMessageOptions, type ShouldCompactOnTriggerCallback, type SimpleWriterOptions, type Span, type SpanData, type SpanEvent, type SpanOptions, type SpanResult, type SpanStatus, type SpanType, type Stats, type StreamEvent, type StreamEventCallback, type StreamHandle, type StreamInstructHandle, type StreamInstructParams, type StreamInstructResult, type StreamParams, type StreamResult, type SubagentAction, type TextPart, type ThinkingContinuity, type ThinkingPart, type TokenStats, type TokenUsage, type ToolAction, type ToolBatchCompleteCallback, type ToolChoice, type ToolContext, type ToolDefinition, type ToolDefinitionRef, type ToolProgressChunk, ToolRegistry, type ToolResult, type ToolResultPart, type TraceWriter, type TracerOptions, Transcript, type TranscriptApplyResult, type TranscriptInput, type Turn, type TurnEvent, type TurnEventCallback, type TurnMetadata, type TurnPart, type TurnStatus, type UsageEntry, type WebSearchBackend, type WebSearchBackendContext, type WebSearchRequest, type WebSearchResponse, type WebSearchResult, getCompactionStamp, loadFileContent, validateCompactedMessages };