extrait 0.7.2 → 0.7.4

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.
@@ -7,4 +7,15 @@ export declare function aggregateUsage<T extends {
7
7
  usage?: LLMUsage;
8
8
  }>(attempts: T[]): LLMUsage | undefined;
9
9
  export declare function mergeUsage(base: LLMUsage | undefined, next: LLMUsage | undefined): LLMUsage | undefined;
10
+ /**
11
+ * Drops a trailing run of `value` that could be the start of a `<think>` /
12
+ * `</think>` tag whose remaining characters have not streamed in yet (e.g. a
13
+ * chunk ending in `<th`). Streaming consumers diff successive snapshots to emit
14
+ * deltas; without this, a partial tag is emitted as a delta and then can never
15
+ * be retracted once it resolves into a real tag that sanitization removes.
16
+ *
17
+ * Only safe for incremental streaming snapshots — never apply it to a final
18
+ * result, where a legitimate trailing `<` must survive.
19
+ */
20
+ export declare function withoutTrailingThinkTagPrefix(value: string): string;
10
21
  export declare function toStreamDataFingerprint(value: unknown): string;