pluribus-context 0.3.22 → 0.3.27

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.
Files changed (95) hide show
  1. package/CHANGELOG.md +33 -3
  2. package/README.md +9 -2
  3. package/docs/community-review-packet.md +10 -2
  4. package/docs/context-budget-receipts.md +152 -0
  5. package/docs/context-input-evidence.md +397 -0
  6. package/docs/context-receipts-for-agent-observability.md +177 -0
  7. package/docs/orchestration-search-receipts.md +102 -0
  8. package/docs/portability-fidelity-report.md +4 -2
  9. package/examples/agent-skills/context-receipts/README.md +22 -0
  10. package/examples/agent-skills/context-receipts/SKILL.md +89 -0
  11. package/examples/context-input-evidence/AGENTS.md +12 -0
  12. package/examples/context-input-evidence/agent-overlay-log.jsonl +4 -0
  13. package/examples/context-input-evidence/agent-overlay-otel-trace.json +548 -0
  14. package/examples/context-input-evidence/agent-overlay-receipt.ndjson +3 -0
  15. package/examples/context-input-evidence/agentgateway-progressive-disclosure-otel-trace.json +393 -0
  16. package/examples/context-input-evidence/agentgateway-progressive-disclosure-receipt.ndjson +4 -0
  17. package/examples/context-input-evidence/brain-remediation-otel-trace.json +645 -0
  18. package/examples/context-input-evidence/brain-remediation-receipt.ndjson +7 -0
  19. package/examples/context-input-evidence/claudekit-mcp-manager-otel-trace.json +417 -0
  20. package/examples/context-input-evidence/claudekit-mcp-manager-receipt.ndjson +5 -0
  21. package/examples/context-input-evidence/cli-progressive-disclosure-otel-trace.json +399 -0
  22. package/examples/context-input-evidence/cli-progressive-disclosure-receipt.ndjson +4 -0
  23. package/examples/context-input-evidence/compaction-otel-trace.json +711 -0
  24. package/examples/context-input-evidence/compaction-receipt.ndjson +6 -0
  25. package/examples/context-input-evidence/context-selection-otel-trace.json +627 -0
  26. package/examples/context-input-evidence/context-selection-receipt.ndjson +7 -0
  27. package/examples/context-input-evidence/convert-agent-overlay-log.mjs +156 -0
  28. package/examples/context-input-evidence/convert-agentgateway-progressive-disclosure-log.mjs +251 -0
  29. package/examples/context-input-evidence/convert-brain-remediation-log.mjs +241 -0
  30. package/examples/context-input-evidence/convert-claudekit-mcp-manager-log.mjs +253 -0
  31. package/examples/context-input-evidence/convert-cli-progressive-disclosure-log.mjs +251 -0
  32. package/examples/context-input-evidence/convert-compaction-log.mjs +224 -0
  33. package/examples/context-input-evidence/convert-context-selection-log.mjs +247 -0
  34. package/examples/context-input-evidence/convert-mcp-tool-search-log.mjs +242 -0
  35. package/examples/context-input-evidence/convert-memory-consolidation-log.mjs +240 -0
  36. package/examples/context-input-evidence/convert-memory-governance-delete-log.mjs +223 -0
  37. package/examples/context-input-evidence/convert-memory-log.mjs +226 -0
  38. package/examples/context-input-evidence/convert-memory-provenance-log.mjs +263 -0
  39. package/examples/context-input-evidence/convert-secret-scanning-log.mjs +233 -0
  40. package/examples/context-input-evidence/convert-session-log.mjs +186 -0
  41. package/examples/context-input-evidence/convert-skill-log.mjs +161 -0
  42. package/examples/context-input-evidence/convert-skill-registry-log.mjs +246 -0
  43. package/examples/context-input-evidence/convert-skill-routing-log.mjs +253 -0
  44. package/examples/context-input-evidence/convert-subagent-context-budget-log.mjs +267 -0
  45. package/examples/context-input-evidence/convert-subagent-delegation-log.mjs +264 -0
  46. package/examples/context-input-evidence/export-otel-trace.mjs +128 -0
  47. package/examples/context-input-evidence/generate-receipt.mjs +188 -0
  48. package/examples/context-input-evidence/mcp-tool-search-otel-trace.json +477 -0
  49. package/examples/context-input-evidence/mcp-tool-search-receipt.ndjson +5 -0
  50. package/examples/context-input-evidence/memory-consolidation-otel-trace.json +492 -0
  51. package/examples/context-input-evidence/memory-consolidation-receipt.ndjson +4 -0
  52. package/examples/context-input-evidence/memory-governance-delete-otel-trace.json +614 -0
  53. package/examples/context-input-evidence/memory-governance-delete-receipt.ndjson +5 -0
  54. package/examples/context-input-evidence/memory-otel-trace.json +645 -0
  55. package/examples/context-input-evidence/memory-provenance-otel-trace.json +711 -0
  56. package/examples/context-input-evidence/memory-provenance-receipt.ndjson +5 -0
  57. package/examples/context-input-evidence/memory-receipt.ndjson +4 -0
  58. package/examples/context-input-evidence/otel-trace.json +1119 -0
  59. package/examples/context-input-evidence/receipt.ndjson +6 -0
  60. package/examples/context-input-evidence/sample-agentgateway-progressive-disclosure-log.jsonl +5 -0
  61. package/examples/context-input-evidence/sample-brain-remediation-log.jsonl +9 -0
  62. package/examples/context-input-evidence/sample-claudekit-mcp-manager-log.jsonl +6 -0
  63. package/examples/context-input-evidence/sample-cli-progressive-disclosure-log.jsonl +5 -0
  64. package/examples/context-input-evidence/sample-compaction-log.jsonl +7 -0
  65. package/examples/context-input-evidence/sample-context-selection-log.jsonl +7 -0
  66. package/examples/context-input-evidence/sample-mcp-tool-search-log.jsonl +6 -0
  67. package/examples/context-input-evidence/sample-memory-consolidation-log.jsonl +5 -0
  68. package/examples/context-input-evidence/sample-memory-governance-delete-log.jsonl +6 -0
  69. package/examples/context-input-evidence/sample-memory-provenance-log.jsonl +6 -0
  70. package/examples/context-input-evidence/sample-memory-retrieval-log.jsonl +6 -0
  71. package/examples/context-input-evidence/sample-secret-scanning-log.jsonl +7 -0
  72. package/examples/context-input-evidence/sample-session-log.jsonl +6 -0
  73. package/examples/context-input-evidence/sample-skill-registry-log.jsonl +5 -0
  74. package/examples/context-input-evidence/sample-skill-routing-log.jsonl +7 -0
  75. package/examples/context-input-evidence/sample-subagent-context-budget-log.jsonl +6 -0
  76. package/examples/context-input-evidence/sample-subagent-delegation-log.jsonl +5 -0
  77. package/examples/context-input-evidence/secret-scanning-otel-trace.json +794 -0
  78. package/examples/context-input-evidence/secret-scanning-receipt.ndjson +6 -0
  79. package/examples/context-input-evidence/session-otel-trace.json +411 -0
  80. package/examples/context-input-evidence/session-receipt.ndjson +2 -0
  81. package/examples/context-input-evidence/skill-invocation-log.jsonl +4 -0
  82. package/examples/context-input-evidence/skill-otel-trace.json +548 -0
  83. package/examples/context-input-evidence/skill-receipt.ndjson +3 -0
  84. package/examples/context-input-evidence/skill-registry-otel-trace.json +471 -0
  85. package/examples/context-input-evidence/skill-registry-receipt.ndjson +5 -0
  86. package/examples/context-input-evidence/skill-routing-otel-trace.json +567 -0
  87. package/examples/context-input-evidence/skill-routing-receipt.ndjson +6 -0
  88. package/examples/context-input-evidence/subagent-context-budget-otel-trace.json +507 -0
  89. package/examples/context-input-evidence/subagent-context-budget-receipt.ndjson +5 -0
  90. package/examples/context-input-evidence/subagent-delegation-otel-trace.json +388 -0
  91. package/examples/context-input-evidence/subagent-delegation-receipt.ndjson +4 -0
  92. package/package.json +6 -2
  93. package/schemas/audit-result.schema.json +409 -71
  94. package/src/commands/audit.js +64 -3
  95. package/src/utils/version.js +1 -1
@@ -0,0 +1,6 @@
1
+ {"trace_id":"b114e37ddabd418e3b5923f1d450419b","span_id":"d5bb33f2d4e47385","name":"context.compaction.started","time":"2026-05-21T20:42:00.000Z","attributes":{"session.id":"cc-session-compaction-demo","gen_ai.conversation.id":"conv-compaction-demo","agent.name":"claude-code","context.compaction.id_hash":"sha256:a9d76c33b957","context.compaction.reason":"context_window_pressure","context.compaction.trigger":"auto_compact_threshold","context.compaction.token_count.before_bucket":"over_50k","context.compaction.token_threshold_bucket":"over_50k","context.compaction.window_bucket":"near_limit","context.compaction.objective.before_hash":"sha256:9ba7841fb5937a230ca939d954270b8dd6a97ce7865de32d5b69e92fcfeccb9e","privacy.raw_prompt_recorded":false,"privacy.raw_context_recorded":false,"privacy.raw_tool_output_recorded":false}}
2
+ {"trace_id":"b114e37ddabd418e3b5923f1d450419b","span_id":"d5bb33f2d4e47385","name":"context.compaction.item.evaluated","time":"2026-05-21T20:42:01.000Z","attributes":{"session.id":"cc-session-compaction-demo","gen_ai.conversation.id":"conv-compaction-demo","context.compaction.id_hash":"sha256:a9d76c33b957","context.item.id_hash":"sha256:4844ae62f2b3","context.item.kind":"system_instructions","context.item.source":"CLAUDE.md","context.item.source.hash":"sha256:6ebdb617a8104a7756d0cf36578ab01103dc9f07e4dc6feb751296b9c402faf7","context.item.semantic_role":"project_invariants","context.item.action":"preserved","context.item.token_count_bucket":"under_10k","context.item.summary_token_count_bucket":"","context.item.drop_reason":"","context.item.raw_text_hash":"sha256:458ce883acaa084ed112ead055254de22b0fe3f6a8caedeb833a48f3e4e59b6b","context.item.raw_text_recorded":false,"context.item.reconstructable_from_hash":false,"privacy.raw_context_recorded":false,"privacy.raw_tool_output_recorded":false}}
3
+ {"trace_id":"b114e37ddabd418e3b5923f1d450419b","span_id":"d5bb33f2d4e47385","name":"context.compaction.item.evaluated","time":"2026-05-21T20:42:02.000Z","attributes":{"session.id":"cc-session-compaction-demo","gen_ai.conversation.id":"conv-compaction-demo","context.compaction.id_hash":"sha256:a9d76c33b957","context.item.id_hash":"sha256:4bc8d608411f","context.item.kind":"skill","context.item.source":"skills/payment-debug/SKILL.md","context.item.source.hash":"sha256:e8967e35c8dc7f47a346b1b7093c558c80221d7b320fef7680d68581e12058e0","context.item.semantic_role":"debugging_method","context.item.action":"summarized","context.item.token_count_bucket":"under_10k","context.item.summary_token_count_bucket":"under_1k","context.item.drop_reason":"","context.item.raw_text_hash":"sha256:09e17bbb81a251d366637b22b552a713eb98a29be209554efb5ed42157ab7560","context.item.raw_text_recorded":false,"context.item.reconstructable_from_hash":false,"privacy.raw_context_recorded":false,"privacy.raw_tool_output_recorded":false}}
4
+ {"trace_id":"b114e37ddabd418e3b5923f1d450419b","span_id":"d5bb33f2d4e47385","name":"context.compaction.item.evaluated","time":"2026-05-21T20:42:03.000Z","attributes":{"session.id":"cc-session-compaction-demo","gen_ai.conversation.id":"conv-compaction-demo","context.compaction.id_hash":"sha256:a9d76c33b957","context.item.id_hash":"sha256:abecb190b0ea","context.item.kind":"tool_result","context.item.source":"bash:test-output","context.item.source.hash":"sha256:91e2a0301cffc358beea0b9ed1d23d286b83f42b34f7ffe1ab22e027bd0018a6","context.item.semantic_role":"bulk_log_output","context.item.action":"dropped","context.item.token_count_bucket":"over_50k","context.item.summary_token_count_bucket":"","context.item.drop_reason":"reconstructable_from_command_and_artifact_hash","context.item.raw_text_hash":"sha256:b1f8a98f19ed91b4ab4ce0d4509e6e3aaa5b8a9c804f4defd12a827746480d75","context.item.raw_text_recorded":false,"context.item.reconstructable_from_hash":true,"privacy.raw_context_recorded":false,"privacy.raw_tool_output_recorded":false}}
5
+ {"trace_id":"b114e37ddabd418e3b5923f1d450419b","span_id":"d5bb33f2d4e47385","name":"context.compaction.item.evaluated","time":"2026-05-21T20:42:04.000Z","attributes":{"session.id":"cc-session-compaction-demo","gen_ai.conversation.id":"conv-compaction-demo","context.compaction.id_hash":"sha256:a9d76c33b957","context.item.id_hash":"sha256:37a8b3a07424","context.item.kind":"mcp_memory","context.item.source":"mcp://memory/project/payments","context.item.source.hash":"sha256:921c8939159f676422ca672db2894f4dfd2324b99fad66f3c86ca964679f5b72","context.item.semantic_role":"prior_decision","context.item.action":"preserved_hash_only","context.item.token_count_bucket":"under_10k","context.item.summary_token_count_bucket":"","context.item.drop_reason":"","context.item.raw_text_hash":"sha256:3face426faae65f26a76d0840c61fa56affd0c0b0318b0f186ff84f3c5111f50","context.item.raw_text_recorded":false,"context.item.reconstructable_from_hash":true,"privacy.raw_context_recorded":false,"privacy.raw_tool_output_recorded":false}}
6
+ {"trace_id":"b114e37ddabd418e3b5923f1d450419b","span_id":"d5bb33f2d4e47385","name":"context.compaction.completed","time":"2026-05-21T20:42:07.000Z","attributes":{"session.id":"cc-session-compaction-demo","gen_ai.conversation.id":"conv-compaction-demo","context.compaction.id_hash":"sha256:a9d76c33b957","context.compaction.token_count.after_bucket":"over_50k","context.compaction.summary.hash":"sha256:1c98c76de94127fe2e2a0972bbfb6e4c918f97cc9e565470d5f73bf857e598d2","context.compaction.objective.after_hash":"sha256:73b9a724c15213fb555b3de5b33d49c50bb40a4cee526379729a3562ab814bf9","context.compaction.item.count":4,"context.compaction.items.dropped":1,"context.compaction.items.summarized":1,"context.compaction.items.preserved":2,"context.compaction.audit_gap":"cannot_prove_semantic_equivalence_without_eval","privacy.raw_summary_recorded":false,"privacy.raw_prompt_recorded":false,"privacy.raw_context_recorded":false,"privacy.raw_tool_output_recorded":false}}
@@ -0,0 +1,627 @@
1
+ {
2
+ "resourceSpans": [
3
+ {
4
+ "resource": {
5
+ "attributes": [
6
+ {
7
+ "key": "service.name",
8
+ "value": {
9
+ "stringValue": "pluribus-context-selection-demo"
10
+ }
11
+ },
12
+ {
13
+ "key": "service.version",
14
+ "value": {
15
+ "stringValue": "0.0.0-fixture"
16
+ }
17
+ },
18
+ {
19
+ "key": "deployment.environment.name",
20
+ "value": {
21
+ "stringValue": "local-fixture"
22
+ }
23
+ }
24
+ ]
25
+ },
26
+ "scopeSpans": [
27
+ {
28
+ "scope": {
29
+ "name": "pluribus.context_selection.demo",
30
+ "version": "0.0.0-fixture"
31
+ },
32
+ "spans": [
33
+ {
34
+ "traceId": "ec2ab62b2c92404de29df8a710f94182",
35
+ "spanId": "c7d2e18b2755d6bf",
36
+ "parentSpanId": "",
37
+ "name": "agent.session",
38
+ "kind": 1,
39
+ "startTimeUnixNano": "1779476400000000000",
40
+ "endTimeUnixNano": "1779477300001000000",
41
+ "attributes": [
42
+ {
43
+ "key": "session.id",
44
+ "value": {
45
+ "stringValue": "demo-session-context-selection"
46
+ }
47
+ },
48
+ {
49
+ "key": "gen_ai.conversation.id",
50
+ "value": {
51
+ "stringValue": "demo-conversation-context-selection"
52
+ }
53
+ },
54
+ {
55
+ "key": "gen_ai.agent.name",
56
+ "value": {
57
+ "stringValue": "coding-agent"
58
+ }
59
+ },
60
+ {
61
+ "key": "gen_ai.operation.name",
62
+ "value": {
63
+ "stringValue": "agent_session"
64
+ }
65
+ }
66
+ ],
67
+ "events": [
68
+ {
69
+ "name": "context.input.selection.evaluated",
70
+ "timeUnixNano": "1779476400000000000",
71
+ "attributes": [
72
+ {
73
+ "key": "session.id",
74
+ "value": {
75
+ "stringValue": "demo-session-context-selection"
76
+ }
77
+ },
78
+ {
79
+ "key": "gen_ai.conversation.id",
80
+ "value": {
81
+ "stringValue": "demo-conversation-context-selection"
82
+ }
83
+ },
84
+ {
85
+ "key": "context.selection.strategy",
86
+ "value": {
87
+ "stringValue": "embedding_top_k_plus_rules"
88
+ }
89
+ },
90
+ {
91
+ "key": "context.selection.policy",
92
+ "value": {
93
+ "stringValue": "select_top_k_then_suppress_duplicates"
94
+ }
95
+ },
96
+ {
97
+ "key": "context.input.candidate_count",
98
+ "value": {
99
+ "intValue": "17"
100
+ }
101
+ },
102
+ {
103
+ "key": "context.input.selected_count",
104
+ "value": {
105
+ "intValue": "5"
106
+ }
107
+ },
108
+ {
109
+ "key": "context.input.suppressed_count",
110
+ "value": {
111
+ "intValue": "12"
112
+ }
113
+ },
114
+ {
115
+ "key": "context.input.delivered_hash_count",
116
+ "value": {
117
+ "intValue": "5"
118
+ }
119
+ },
120
+ {
121
+ "key": "context.input.selected_token_bucket",
122
+ "value": {
123
+ "stringValue": "8k-16k"
124
+ }
125
+ },
126
+ {
127
+ "key": "context.input.suppressed_token_bucket",
128
+ "value": {
129
+ "stringValue": "16k-32k"
130
+ }
131
+ },
132
+ {
133
+ "key": "context.selection.operator_question",
134
+ "value": {
135
+ "stringValue": "did_we_load_too_much_or_the_wrong_context"
136
+ }
137
+ },
138
+ {
139
+ "key": "context.decision.relevance_evaluator",
140
+ "value": {
141
+ "stringValue": "not_available_yet"
142
+ }
143
+ },
144
+ {
145
+ "key": "context.selection.audit_gap",
146
+ "value": {
147
+ "stringValue": "selection receipt proves delivery pressure, not semantic relevance"
148
+ }
149
+ }
150
+ ]
151
+ },
152
+ {
153
+ "name": "context.input.loaded",
154
+ "timeUnixNano": "1779476401000000000",
155
+ "attributes": [
156
+ {
157
+ "key": "session.id",
158
+ "value": {
159
+ "stringValue": "demo-session-context-selection"
160
+ }
161
+ },
162
+ {
163
+ "key": "gen_ai.conversation.id",
164
+ "value": {
165
+ "stringValue": "demo-conversation-context-selection"
166
+ }
167
+ },
168
+ {
169
+ "key": "context.input.kind",
170
+ "value": {
171
+ "stringValue": "agent_instructions"
172
+ }
173
+ },
174
+ {
175
+ "key": "context.input.source.id_hash",
176
+ "value": {
177
+ "stringValue": "sha256:a54ff182c7e8acf56acfd6e4b9c3ff41e2c41a31c9b211b2deb9df75d9a478f9"
178
+ }
179
+ },
180
+ {
181
+ "key": "context.input.source.role",
182
+ "value": {
183
+ "stringValue": "repo_guidance"
184
+ }
185
+ },
186
+ {
187
+ "key": "context.input.selection.rank",
188
+ "value": {
189
+ "intValue": "1"
190
+ }
191
+ },
192
+ {
193
+ "key": "context.input.selection.status",
194
+ "value": {
195
+ "stringValue": "selected"
196
+ }
197
+ },
198
+ {
199
+ "key": "context.input.delivery.status",
200
+ "value": {
201
+ "stringValue": "delivered"
202
+ }
203
+ },
204
+ {
205
+ "key": "context.input.delivered.hash",
206
+ "value": {
207
+ "stringValue": "sha256:bf73e0731b3961ebe198b0e40caa1bc0883e1f75eb2aeccced905d0dc182e7a7"
208
+ }
209
+ },
210
+ {
211
+ "key": "context.input.token_bucket",
212
+ "value": {
213
+ "stringValue": "1k-2k"
214
+ }
215
+ },
216
+ {
217
+ "key": "context.input.audit_gap",
218
+ "value": {
219
+ "stringValue": "hashes and counts prove selected/delivered identity, not semantic usefulness"
220
+ }
221
+ }
222
+ ]
223
+ },
224
+ {
225
+ "name": "context.input.loaded",
226
+ "timeUnixNano": "1779476402000000000",
227
+ "attributes": [
228
+ {
229
+ "key": "session.id",
230
+ "value": {
231
+ "stringValue": "demo-session-context-selection"
232
+ }
233
+ },
234
+ {
235
+ "key": "gen_ai.conversation.id",
236
+ "value": {
237
+ "stringValue": "demo-conversation-context-selection"
238
+ }
239
+ },
240
+ {
241
+ "key": "context.input.kind",
242
+ "value": {
243
+ "stringValue": "memory"
244
+ }
245
+ },
246
+ {
247
+ "key": "context.input.source.id_hash",
248
+ "value": {
249
+ "stringValue": "sha256:3839eefef40812535ecd0108076f0f6e86745f9d7419b6b9850929f93d4c4b57"
250
+ }
251
+ },
252
+ {
253
+ "key": "context.input.source.role",
254
+ "value": {
255
+ "stringValue": "historical_debugging_pattern"
256
+ }
257
+ },
258
+ {
259
+ "key": "context.input.selection.rank",
260
+ "value": {
261
+ "intValue": "2"
262
+ }
263
+ },
264
+ {
265
+ "key": "context.input.selection.status",
266
+ "value": {
267
+ "stringValue": "selected"
268
+ }
269
+ },
270
+ {
271
+ "key": "context.input.delivery.status",
272
+ "value": {
273
+ "stringValue": "delivered"
274
+ }
275
+ },
276
+ {
277
+ "key": "context.input.delivered.hash",
278
+ "value": {
279
+ "stringValue": "sha256:3950ef86bfdb700b1cbc88e3db5d45a91d293bb83dd46903e899fb0186453623"
280
+ }
281
+ },
282
+ {
283
+ "key": "context.input.token_bucket",
284
+ "value": {
285
+ "stringValue": "2k-4k"
286
+ }
287
+ },
288
+ {
289
+ "key": "context.input.audit_gap",
290
+ "value": {
291
+ "stringValue": "hashes and counts prove selected/delivered identity, not semantic usefulness"
292
+ }
293
+ }
294
+ ]
295
+ },
296
+ {
297
+ "name": "context.input.loaded",
298
+ "timeUnixNano": "1779476403000000000",
299
+ "attributes": [
300
+ {
301
+ "key": "session.id",
302
+ "value": {
303
+ "stringValue": "demo-session-context-selection"
304
+ }
305
+ },
306
+ {
307
+ "key": "gen_ai.conversation.id",
308
+ "value": {
309
+ "stringValue": "demo-conversation-context-selection"
310
+ }
311
+ },
312
+ {
313
+ "key": "context.input.kind",
314
+ "value": {
315
+ "stringValue": "code_search_result"
316
+ }
317
+ },
318
+ {
319
+ "key": "context.input.source.id_hash",
320
+ "value": {
321
+ "stringValue": "sha256:70b20a8c5db2c5d8ddc7dfc5fb9fa4229ef16b1241f3d829d9ba0ffda49f8eca"
322
+ }
323
+ },
324
+ {
325
+ "key": "context.input.source.role",
326
+ "value": {
327
+ "stringValue": "code_search_candidate"
328
+ }
329
+ },
330
+ {
331
+ "key": "context.input.selection.rank",
332
+ "value": {
333
+ "intValue": "3"
334
+ }
335
+ },
336
+ {
337
+ "key": "context.input.selection.status",
338
+ "value": {
339
+ "stringValue": "selected"
340
+ }
341
+ },
342
+ {
343
+ "key": "context.input.delivery.status",
344
+ "value": {
345
+ "stringValue": "delivered"
346
+ }
347
+ },
348
+ {
349
+ "key": "context.input.delivered.hash",
350
+ "value": {
351
+ "stringValue": "sha256:1dacce0964177f19b6a05325bfab4a956f278e318bf5ca6cf03dd001a7dd5d1d"
352
+ }
353
+ },
354
+ {
355
+ "key": "context.input.token_bucket",
356
+ "value": {
357
+ "stringValue": "1k-2k"
358
+ }
359
+ },
360
+ {
361
+ "key": "context.input.audit_gap",
362
+ "value": {
363
+ "stringValue": "hashes and counts prove selected/delivered identity, not semantic usefulness"
364
+ }
365
+ }
366
+ ]
367
+ },
368
+ {
369
+ "name": "context.input.loaded",
370
+ "timeUnixNano": "1779476404000000000",
371
+ "attributes": [
372
+ {
373
+ "key": "session.id",
374
+ "value": {
375
+ "stringValue": "demo-session-context-selection"
376
+ }
377
+ },
378
+ {
379
+ "key": "gen_ai.conversation.id",
380
+ "value": {
381
+ "stringValue": "demo-conversation-context-selection"
382
+ }
383
+ },
384
+ {
385
+ "key": "context.input.kind",
386
+ "value": {
387
+ "stringValue": "ticket"
388
+ }
389
+ },
390
+ {
391
+ "key": "context.input.source.id_hash",
392
+ "value": {
393
+ "stringValue": "sha256:4470e9befbfae6913de14eb09f6d9c2069b1f4a01f154264765938c0473bfe45"
394
+ }
395
+ },
396
+ {
397
+ "key": "context.input.source.role",
398
+ "value": {
399
+ "stringValue": "user_report"
400
+ }
401
+ },
402
+ {
403
+ "key": "context.input.selection.rank",
404
+ "value": {
405
+ "intValue": "4"
406
+ }
407
+ },
408
+ {
409
+ "key": "context.input.selection.status",
410
+ "value": {
411
+ "stringValue": "selected"
412
+ }
413
+ },
414
+ {
415
+ "key": "context.input.delivery.status",
416
+ "value": {
417
+ "stringValue": "delivered"
418
+ }
419
+ },
420
+ {
421
+ "key": "context.input.delivered.hash",
422
+ "value": {
423
+ "stringValue": "sha256:242489d93c8174b1c3dc66c4eff3d4f51d8a9f963f0f58fbe8c12461aa665e38"
424
+ }
425
+ },
426
+ {
427
+ "key": "context.input.token_bucket",
428
+ "value": {
429
+ "stringValue": "2k-4k"
430
+ }
431
+ },
432
+ {
433
+ "key": "context.input.audit_gap",
434
+ "value": {
435
+ "stringValue": "hashes and counts prove selected/delivered identity, not semantic usefulness"
436
+ }
437
+ }
438
+ ]
439
+ },
440
+ {
441
+ "name": "context.input.loaded",
442
+ "timeUnixNano": "1779476405000000000",
443
+ "attributes": [
444
+ {
445
+ "key": "session.id",
446
+ "value": {
447
+ "stringValue": "demo-session-context-selection"
448
+ }
449
+ },
450
+ {
451
+ "key": "gen_ai.conversation.id",
452
+ "value": {
453
+ "stringValue": "demo-conversation-context-selection"
454
+ }
455
+ },
456
+ {
457
+ "key": "context.input.kind",
458
+ "value": {
459
+ "stringValue": "tool_result"
460
+ }
461
+ },
462
+ {
463
+ "key": "context.input.source.id_hash",
464
+ "value": {
465
+ "stringValue": "sha256:a026e83f2de180e6fe2e79e5ccb54d8da34286eb743d2a3b826f9a48bcafceb6"
466
+ }
467
+ },
468
+ {
469
+ "key": "context.input.source.role",
470
+ "value": {
471
+ "stringValue": "recent_tool_output"
472
+ }
473
+ },
474
+ {
475
+ "key": "context.input.selection.rank",
476
+ "value": {
477
+ "intValue": "5"
478
+ }
479
+ },
480
+ {
481
+ "key": "context.input.selection.status",
482
+ "value": {
483
+ "stringValue": "selected"
484
+ }
485
+ },
486
+ {
487
+ "key": "context.input.delivery.status",
488
+ "value": {
489
+ "stringValue": "delivered"
490
+ }
491
+ },
492
+ {
493
+ "key": "context.input.delivered.hash",
494
+ "value": {
495
+ "stringValue": "sha256:6ea22c80d5b1ca9746d744221876bd35c11811d12d808780607c553d6e887955"
496
+ }
497
+ },
498
+ {
499
+ "key": "context.input.token_bucket",
500
+ "value": {
501
+ "stringValue": "2k-4k"
502
+ }
503
+ },
504
+ {
505
+ "key": "context.input.audit_gap",
506
+ "value": {
507
+ "stringValue": "hashes and counts prove selected/delivered identity, not semantic usefulness"
508
+ }
509
+ }
510
+ ]
511
+ },
512
+ {
513
+ "name": "context.decision.relevance.evaluated",
514
+ "timeUnixNano": "1779477300000000000",
515
+ "attributes": [
516
+ {
517
+ "key": "session.id",
518
+ "value": {
519
+ "stringValue": "demo-session-context-selection"
520
+ }
521
+ },
522
+ {
523
+ "key": "gen_ai.conversation.id",
524
+ "value": {
525
+ "stringValue": "demo-conversation-context-selection"
526
+ }
527
+ },
528
+ {
529
+ "key": "decision.id_hash",
530
+ "value": {
531
+ "stringValue": "sha256:066a1a74ff7660561d4e42de2c3136bb98c8c37713afd9d6b36f8da8a6c4e2db"
532
+ }
533
+ },
534
+ {
535
+ "key": "context.input.selected_count",
536
+ "value": {
537
+ "intValue": "5"
538
+ }
539
+ },
540
+ {
541
+ "key": "context.input.suppressed_count",
542
+ "value": {
543
+ "intValue": "12"
544
+ }
545
+ },
546
+ {
547
+ "key": "context.input.delivered_hash_count",
548
+ "value": {
549
+ "intValue": "5"
550
+ }
551
+ },
552
+ {
553
+ "key": "context.decision.input_hashes",
554
+ "value": {
555
+ "arrayValue": {
556
+ "values": [
557
+ {
558
+ "stringValue": "sha256:bf73e0731b3961ebe198b0e40caa1bc0883e1f75eb2aeccced905d0dc182e7a7"
559
+ }
560
+ ]
561
+ }
562
+ }
563
+ },
564
+ {
565
+ "key": "context.decision.relevance.decisive_count",
566
+ "value": {
567
+ "intValue": "0"
568
+ }
569
+ },
570
+ {
571
+ "key": "context.decision.relevance.supporting_count",
572
+ "value": {
573
+ "intValue": "1"
574
+ }
575
+ },
576
+ {
577
+ "key": "context.decision.relevance.unused_count",
578
+ "value": {
579
+ "intValue": "4"
580
+ }
581
+ },
582
+ {
583
+ "key": "context.decision.relevance.unknown_count",
584
+ "value": {
585
+ "intValue": "0"
586
+ }
587
+ },
588
+ {
589
+ "key": "context.decision.relevance.accounted_count",
590
+ "value": {
591
+ "intValue": "5"
592
+ }
593
+ },
594
+ {
595
+ "key": "context.decision.relevance.invariant",
596
+ "value": {
597
+ "stringValue": "selected_count == decisive_count + supporting_count + unused_count + unknown_count; decisive_count + supporting_count <= selected_count"
598
+ }
599
+ },
600
+ {
601
+ "key": "context.decision.relevance.outcome",
602
+ "value": {
603
+ "stringValue": "over_selected_one_supporting_four_unused"
604
+ }
605
+ },
606
+ {
607
+ "key": "context.decision.evaluator",
608
+ "value": {
609
+ "stringValue": "human_review"
610
+ }
611
+ },
612
+ {
613
+ "key": "context.decision.audit_gap",
614
+ "value": {
615
+ "stringValue": "post-hoc relevance explains usefulness; prior selection receipt only proves what crossed the boundary"
616
+ }
617
+ }
618
+ ]
619
+ }
620
+ ]
621
+ }
622
+ ]
623
+ }
624
+ ]
625
+ }
626
+ ]
627
+ }
@@ -0,0 +1,7 @@
1
+ {"trace_id":"ec2ab62b2c92404de29df8a710f94182","span_id":"c7d2e18b2755d6bf","name":"context.input.selection.evaluated","time":"2026-05-22T19:00:00.000Z","attributes":{"session.id":"demo-session-context-selection","gen_ai.conversation.id":"demo-conversation-context-selection","context.selection.strategy":"embedding_top_k_plus_rules","context.selection.policy":"select_top_k_then_suppress_duplicates","context.input.candidate_count":17,"context.input.selected_count":5,"context.input.suppressed_count":12,"context.input.delivered_hash_count":5,"context.input.selected_token_bucket":"8k-16k","context.input.suppressed_token_bucket":"16k-32k","context.selection.operator_question":"did_we_load_too_much_or_the_wrong_context","context.decision.relevance_evaluator":"not_available_yet","context.selection.audit_gap":"selection receipt proves delivery pressure, not semantic relevance"}}
2
+ {"trace_id":"ec2ab62b2c92404de29df8a710f94182","span_id":"c7d2e18b2755d6bf","name":"context.input.loaded","time":"2026-05-22T19:00:01.000Z","attributes":{"session.id":"demo-session-context-selection","gen_ai.conversation.id":"demo-conversation-context-selection","context.input.kind":"agent_instructions","context.input.source.id_hash":"sha256:a54ff182c7e8acf56acfd6e4b9c3ff41e2c41a31c9b211b2deb9df75d9a478f9","context.input.source.role":"repo_guidance","context.input.selection.rank":1,"context.input.selection.status":"selected","context.input.delivery.status":"delivered","context.input.delivered.hash":"sha256:bf73e0731b3961ebe198b0e40caa1bc0883e1f75eb2aeccced905d0dc182e7a7","context.input.token_bucket":"1k-2k","context.input.audit_gap":"hashes and counts prove selected/delivered identity, not semantic usefulness"}}
3
+ {"trace_id":"ec2ab62b2c92404de29df8a710f94182","span_id":"c7d2e18b2755d6bf","name":"context.input.loaded","time":"2026-05-22T19:00:02.000Z","attributes":{"session.id":"demo-session-context-selection","gen_ai.conversation.id":"demo-conversation-context-selection","context.input.kind":"memory","context.input.source.id_hash":"sha256:3839eefef40812535ecd0108076f0f6e86745f9d7419b6b9850929f93d4c4b57","context.input.source.role":"historical_debugging_pattern","context.input.selection.rank":2,"context.input.selection.status":"selected","context.input.delivery.status":"delivered","context.input.delivered.hash":"sha256:3950ef86bfdb700b1cbc88e3db5d45a91d293bb83dd46903e899fb0186453623","context.input.token_bucket":"2k-4k","context.input.audit_gap":"hashes and counts prove selected/delivered identity, not semantic usefulness"}}
4
+ {"trace_id":"ec2ab62b2c92404de29df8a710f94182","span_id":"c7d2e18b2755d6bf","name":"context.input.loaded","time":"2026-05-22T19:00:03.000Z","attributes":{"session.id":"demo-session-context-selection","gen_ai.conversation.id":"demo-conversation-context-selection","context.input.kind":"code_search_result","context.input.source.id_hash":"sha256:70b20a8c5db2c5d8ddc7dfc5fb9fa4229ef16b1241f3d829d9ba0ffda49f8eca","context.input.source.role":"code_search_candidate","context.input.selection.rank":3,"context.input.selection.status":"selected","context.input.delivery.status":"delivered","context.input.delivered.hash":"sha256:1dacce0964177f19b6a05325bfab4a956f278e318bf5ca6cf03dd001a7dd5d1d","context.input.token_bucket":"1k-2k","context.input.audit_gap":"hashes and counts prove selected/delivered identity, not semantic usefulness"}}
5
+ {"trace_id":"ec2ab62b2c92404de29df8a710f94182","span_id":"c7d2e18b2755d6bf","name":"context.input.loaded","time":"2026-05-22T19:00:04.000Z","attributes":{"session.id":"demo-session-context-selection","gen_ai.conversation.id":"demo-conversation-context-selection","context.input.kind":"ticket","context.input.source.id_hash":"sha256:4470e9befbfae6913de14eb09f6d9c2069b1f4a01f154264765938c0473bfe45","context.input.source.role":"user_report","context.input.selection.rank":4,"context.input.selection.status":"selected","context.input.delivery.status":"delivered","context.input.delivered.hash":"sha256:242489d93c8174b1c3dc66c4eff3d4f51d8a9f963f0f58fbe8c12461aa665e38","context.input.token_bucket":"2k-4k","context.input.audit_gap":"hashes and counts prove selected/delivered identity, not semantic usefulness"}}
6
+ {"trace_id":"ec2ab62b2c92404de29df8a710f94182","span_id":"c7d2e18b2755d6bf","name":"context.input.loaded","time":"2026-05-22T19:00:05.000Z","attributes":{"session.id":"demo-session-context-selection","gen_ai.conversation.id":"demo-conversation-context-selection","context.input.kind":"tool_result","context.input.source.id_hash":"sha256:a026e83f2de180e6fe2e79e5ccb54d8da34286eb743d2a3b826f9a48bcafceb6","context.input.source.role":"recent_tool_output","context.input.selection.rank":5,"context.input.selection.status":"selected","context.input.delivery.status":"delivered","context.input.delivered.hash":"sha256:6ea22c80d5b1ca9746d744221876bd35c11811d12d808780607c553d6e887955","context.input.token_bucket":"2k-4k","context.input.audit_gap":"hashes and counts prove selected/delivered identity, not semantic usefulness"}}
7
+ {"trace_id":"ec2ab62b2c92404de29df8a710f94182","span_id":"c7d2e18b2755d6bf","name":"context.decision.relevance.evaluated","time":"2026-05-22T19:15:00.000Z","attributes":{"session.id":"demo-session-context-selection","gen_ai.conversation.id":"demo-conversation-context-selection","decision.id_hash":"sha256:066a1a74ff7660561d4e42de2c3136bb98c8c37713afd9d6b36f8da8a6c4e2db","context.input.selected_count":5,"context.input.suppressed_count":12,"context.input.delivered_hash_count":5,"context.decision.input_hashes":["sha256:bf73e0731b3961ebe198b0e40caa1bc0883e1f75eb2aeccced905d0dc182e7a7"],"context.decision.relevance.decisive_count":0,"context.decision.relevance.supporting_count":1,"context.decision.relevance.unused_count":4,"context.decision.relevance.unknown_count":0,"context.decision.relevance.accounted_count":5,"context.decision.relevance.invariant":"selected_count == decisive_count + supporting_count + unused_count + unknown_count; decisive_count + supporting_count <= selected_count","context.decision.relevance.outcome":"over_selected_one_supporting_four_unused","context.decision.evaluator":"human_review","context.decision.audit_gap":"post-hoc relevance explains usefulness; prior selection receipt only proves what crossed the boundary"}}