@tangle-network/agent-app 0.60.219 → 0.60.221

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.
@@ -500,6 +500,7 @@ export interface ChatTurnCompleteInput<TContext> {
500
500
  }
501
501
  /** Where a finished turn's trace goes, and the host's labels for its root span. Metadata only: never content. */
502
502
  export interface ChatTurnTraceOptions<TContext> {
503
+ /** Default: `createIntelligenceTurnTraceSink({ project: projectId })`, which reads the Sandbox product key from the environment. */
503
504
  sink?: TurnTraceSink;
504
505
  /** Labels for the root span, e.g. the workspace id. Called once per exported turn. */
505
506
  labels?(info: {
@@ -682,12 +683,16 @@ export interface CreateChatTurnRoutesOptions<TContext = void> {
682
683
  /** Trace flush handed to `waitUntil` (OTLP export). */
683
684
  traceFlush?(context: TContext): Promise<void>;
684
685
  /**
685
- * Where each finished turn's trace goes (`createIntelligenceTurnTraceSink`). The route always records the
686
- * turn's trace (`ChatTurnProduceArgs.trace`) and reports its summary to `lifecycle`; this sends the spans on.
687
- * The sink runs under `waitUntil` after the lifecycle hooks and after the turn lock is released, and its failure never fails a turn. A turn handed
688
- * to a durable owner (`handoffCompletion`) is exported by that owner, not here.
686
+ * Where each finished turn's trace goes. On by default: omit it and every turn goes to Tangle Intelligence under
687
+ * `projectId` (`createIntelligenceTurnTraceSink`); pass `{ sink, labels }` to send it elsewhere or label it.
688
+ * The route always records the turn's trace (`ChatTurnProduceArgs.trace`), reports its summary to `lifecycle`, and
689
+ * writes one `agent_app_turn_trace` log line per turn (first text, coverage, time per kind); this sends the spans on.
690
+ * The sink runs under `waitUntil` after the lifecycle hooks and after the turn lock is released, and its failure never
691
+ * fails a turn. A turn handed to a durable owner (`handoffCompletion`) is exported when this request's live
692
+ * projection ends, failed only when the projection saw an error. `false` is the only opt-out, and
693
+ * `agent-app-signoff defaults` fails it until the app's `signoff.config.mjs` gives the reason.
689
694
  */
690
- turnTrace?: ChatTurnTraceOptions<TContext>;
695
+ turnTrace?: ChatTurnTraceOptions<TContext> | false;
691
696
  /** Compose the interaction-answer endpoints (`/interactions`). Omit when the
692
697
  * product has no sidecar ask channel. */
693
698
  interactions?: InteractionAnswerRouteOptions;
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  runRouterTurn
3
- } from "./chunk-NHCS55QI.js";
3
+ } from "./chunk-DMXEPYB5.js";
4
4
 
5
5
  // src/runtime/protected-model.ts
6
6
  import {
@@ -219,4 +219,4 @@ export {
219
219
  createRouterProtectedModelPort,
220
220
  runProtectedRouterTurn
221
221
  };
222
- //# sourceMappingURL=chunk-MAOTZ77B.js.map
222
+ //# sourceMappingURL=chunk-A5DGO2XT.js.map
@@ -3793,4 +3793,4 @@ export {
3793
3793
  isTerminalPromptEvent,
3794
3794
  detectInteractiveQuestion
3795
3795
  };
3796
- //# sourceMappingURL=chunk-RDLOC7BJ.js.map
3796
+ //# sourceMappingURL=chunk-C7WAGXQN.js.map