@absolutejs/voice 0.0.22-beta.295 → 0.0.22-beta.296
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/README.md +1 -1
- package/dist/index.js +16 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -2807,7 +2807,7 @@ app.use(
|
|
|
2807
2807
|
);
|
|
2808
2808
|
```
|
|
2809
2809
|
|
|
2810
|
-
`createVoiceOperationsRecordRoutes(...)` links the call/session timeline, transcript, replay, provider decisions, tools, handoffs, guardrail decisions, audit, reviews, ops tasks, integration events, and sink delivery attempts into one debuggable object. Provider decisions include both older provider-routing events and explicit `provider.decision` traces, so the call log can show the surface, selected provider, fallback provider, and human-readable reason for each runtime choice. Use `/voice-operations/:sessionId` as the first place to investigate failed calls, blocked assistant output, blocked tool payloads, provider failures, handoff failures, slow turns, and campaign attempts. The same mount also exposes incident handoff Markdown at `/voice-operations/:sessionId/incident.md` and `/api/voice-operations/:sessionId/incident.md` for support tooling, including an `assistant.guardrail` blocked-stage summary when
|
|
2810
|
+
`createVoiceOperationsRecordRoutes(...)` links the call/session timeline, transcript, replay, provider decisions, tools, handoffs, guardrail decisions, audit, reviews, ops tasks, integration events, and sink delivery attempts into one debuggable object. Provider decisions include both older provider-routing events and explicit `provider.decision` traces, so the call log can show the surface, selected provider, fallback provider, and human-readable reason for each runtime choice. Use `/voice-operations/:sessionId` as the first place to investigate failed calls, blocked assistant output, blocked tool payloads, provider failures, handoff failures, slow turns, and campaign attempts. The same mount also exposes incident handoff Markdown at `/voice-operations/:sessionId/incident.md` and `/api/voice-operations/:sessionId/incident.md` for support tooling, including provider-decision summaries and an `assistant.guardrail` blocked-stage summary when those trace events exist.
|
|
2811
2811
|
|
|
2812
2812
|
Use `evaluateVoiceOperationsRecordGuardrails(...)` when a proof pack or deploy gate needs JSON evidence that guardrails actually ran, blocked the expected stages, and produced named proofs/rule IDs. Use `assertVoiceOperationsRecordGuardrails(...)` in tests or smoke scripts when missing guardrail evidence should fail fast:
|
|
2813
2813
|
|
package/dist/index.js
CHANGED
|
@@ -26435,6 +26435,18 @@ var renderVoiceOperationsRecordIncidentMarkdown = (record) => {
|
|
|
26435
26435
|
const outcomes = outcomeLabels(record.outcome);
|
|
26436
26436
|
const topErrors = record.traceEvents.filter((event) => event.type === "session.error").map((event) => getString17(event.payload.error)).filter((error) => typeof error === "string").slice(0, 3);
|
|
26437
26437
|
const openTasks = record.tasks?.tasks.filter((task) => task.status !== "done").map((task) => task.title).slice(0, 3) ?? [];
|
|
26438
|
+
const providerDecisions = record.providerDecisions.filter((decision) => decision.provider || decision.selectedProvider || decision.fallbackProvider || decision.reason).slice(0, 5);
|
|
26439
|
+
const providerDecisionLines = providerDecisions.length ? providerDecisions.map((decision) => {
|
|
26440
|
+
const provider = decision.provider ?? decision.selectedProvider ?? decision.fallbackProvider ?? "provider";
|
|
26441
|
+
const parts = [
|
|
26442
|
+
decision.surface ? `surface=${decision.surface}` : undefined,
|
|
26443
|
+
decision.status ? `status=${decision.status}` : undefined,
|
|
26444
|
+
decision.selectedProvider ? `selected=${decision.selectedProvider}` : undefined,
|
|
26445
|
+
decision.fallbackProvider ? `fallback=${decision.fallbackProvider}` : undefined,
|
|
26446
|
+
decision.reason ? `reason=${decision.reason}` : undefined
|
|
26447
|
+
].filter((part) => typeof part === "string");
|
|
26448
|
+
return `- ${provider}: ${parts.join("; ") || "decision recorded"}`;
|
|
26449
|
+
}) : ["- none recorded"];
|
|
26438
26450
|
return [
|
|
26439
26451
|
`# Voice incident handoff: ${record.sessionId}`,
|
|
26440
26452
|
"",
|
|
@@ -26448,6 +26460,10 @@ var renderVoiceOperationsRecordIncidentMarkdown = (record) => {
|
|
|
26448
26460
|
`- Top errors: ${topErrors.join("; ") || "none"}`,
|
|
26449
26461
|
`- Guardrails: ${String(record.guardrails.blocked)} blocked / ${String(record.guardrails.warned)} warned / ${String(record.guardrails.total)} decisions`,
|
|
26450
26462
|
"",
|
|
26463
|
+
"## Provider decisions",
|
|
26464
|
+
"",
|
|
26465
|
+
...providerDecisionLines,
|
|
26466
|
+
"",
|
|
26451
26467
|
renderVoiceOperationsRecordGuardrailMarkdown(record),
|
|
26452
26468
|
"",
|
|
26453
26469
|
"## Next checks",
|