@iowarp/clio-coder 0.3.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.
Files changed (226) hide show
  1. package/CHANGELOG.md +407 -0
  2. package/CODE_OF_CONDUCT.md +21 -0
  3. package/CONTRIBUTING.md +224 -0
  4. package/LICENSE +202 -0
  5. package/NOTICE +9 -0
  6. package/README.md +798 -0
  7. package/SECURITY.md +72 -0
  8. package/assets/clio-coder-logo-128.webp +0 -0
  9. package/damage-control-rules.yaml +419 -0
  10. package/dist/acp-UMLFVA3F.js +92 -0
  11. package/dist/agents-Q4MYPMUW.js +91 -0
  12. package/dist/auth-O6HYIJ6J.js +521 -0
  13. package/dist/chunk-262G75JS.js +35 -0
  14. package/dist/chunk-26BZQOAD.js +1281 -0
  15. package/dist/chunk-2J63S4SF.js +508 -0
  16. package/dist/chunk-3DANZDGR.js +717 -0
  17. package/dist/chunk-4UQA7NCT.js +29 -0
  18. package/dist/chunk-527KG6XR.js +497 -0
  19. package/dist/chunk-5LDRNKX2.js +1063 -0
  20. package/dist/chunk-5N2FG33Q.js +25 -0
  21. package/dist/chunk-67MTHP2E.js +135 -0
  22. package/dist/chunk-6CWDTGUC.js +20 -0
  23. package/dist/chunk-7BHLZB3A.js +2115 -0
  24. package/dist/chunk-7RBKDI66.js +348 -0
  25. package/dist/chunk-AMFR5YA3.js +541 -0
  26. package/dist/chunk-BBUH4VAA.js +1224 -0
  27. package/dist/chunk-BYEU76JP.js +899 -0
  28. package/dist/chunk-CLJ5HLUD.js +458 -0
  29. package/dist/chunk-D5YD55AR.js +116 -0
  30. package/dist/chunk-DXQNI4PC.js +61 -0
  31. package/dist/chunk-E3NYWENM.js +1004 -0
  32. package/dist/chunk-GNGDQYDU.js +34688 -0
  33. package/dist/chunk-GOTUR54M.js +9 -0
  34. package/dist/chunk-HBU5MTAM.js +41 -0
  35. package/dist/chunk-HMYNFFY4.js +28 -0
  36. package/dist/chunk-JPOWPFCU.js +1010 -0
  37. package/dist/chunk-JWHCJDCI.js +1215 -0
  38. package/dist/chunk-KBR4MZZR.js +41 -0
  39. package/dist/chunk-KKKPTZLM.js +93 -0
  40. package/dist/chunk-ME6DNWIU.js +66 -0
  41. package/dist/chunk-NI4DEJMC.js +88 -0
  42. package/dist/chunk-O4EJEDHO.js +659 -0
  43. package/dist/chunk-PIDUD6M2.js +31 -0
  44. package/dist/chunk-PS4PFJQP.js +29459 -0
  45. package/dist/chunk-QV47YRF4.js +48 -0
  46. package/dist/chunk-RQDWMVRB.js +279 -0
  47. package/dist/chunk-TFSSEXL6.js +136 -0
  48. package/dist/chunk-TKHQ4DGZ.js +8290 -0
  49. package/dist/chunk-TPOCL34A.js +2876 -0
  50. package/dist/chunk-UGYAX5YI.js +565 -0
  51. package/dist/chunk-UHTSULZS.js +461 -0
  52. package/dist/chunk-UU3R62TT.js +128 -0
  53. package/dist/chunk-UWIJNAOB.js +3906 -0
  54. package/dist/chunk-VOO7NYPP.js +914 -0
  55. package/dist/chunk-VPAWTYLY.js +117 -0
  56. package/dist/chunk-WD6AJM35.js +1216 -0
  57. package/dist/chunk-X3BR7HWV.js +115 -0
  58. package/dist/chunk-X3NE4WVW.js +120 -0
  59. package/dist/chunk-XNISANGE.js +1395 -0
  60. package/dist/chunk-XV4ZJ6ZM.js +3177 -0
  61. package/dist/cli/index.js +236 -0
  62. package/dist/clio-KIQ5SNDS.js +53 -0
  63. package/dist/components-JVHMUBEB.js +653 -0
  64. package/dist/config-ZFCDBMDC.js +372 -0
  65. package/dist/configure-G4E3A2PG.js +27 -0
  66. package/dist/context-CDXTP2MP.js +293 -0
  67. package/dist/context-E3KIFVXI.js +185 -0
  68. package/dist/context-clear-3F4PLXOS.js +102 -0
  69. package/dist/context-index-Q7YSYTR3.js +106 -0
  70. package/dist/docs-YIETIWZI.js +280 -0
  71. package/dist/doctor-M5HJJZOL.js +61 -0
  72. package/dist/domains/agents/builtins/architect.md +33 -0
  73. package/dist/domains/agents/builtins/coder.md +31 -0
  74. package/dist/domains/agents/builtins/context-bootstrap.md +38 -0
  75. package/dist/domains/agents/builtins/debugger.md +30 -0
  76. package/dist/domains/agents/builtins/documenter.md +31 -0
  77. package/dist/domains/agents/builtins/git-master.md +30 -0
  78. package/dist/domains/agents/builtins/provenance.md +30 -0
  79. package/dist/domains/agents/builtins/researcher.md +71 -0
  80. package/dist/domains/agents/builtins/scout.md +42 -0
  81. package/dist/domains/agents/builtins/tester.md +31 -0
  82. package/dist/domains/agents/builtins/verifier.md +30 -0
  83. package/dist/domains/agents/builtins/wiki-writer.md +41 -0
  84. package/dist/eval-B3KZZESM.js +2674 -0
  85. package/dist/evidence-V67CHM35.js +233 -0
  86. package/dist/evolve-YDZSUQYA.js +518 -0
  87. package/dist/extensions-SRG7XCAH.js +207 -0
  88. package/dist/fleet-CA2CRTVG.js +760 -0
  89. package/dist/fleet-preflight-CLIAX7YR.js +21 -0
  90. package/dist/init-2OZDJE2D.js +227 -0
  91. package/dist/memory-3PIQQAKX.js +207 -0
  92. package/dist/models-DY35XI7Y.js +237 -0
  93. package/dist/paths-5OMXW7Z4.js +57 -0
  94. package/dist/preload-KZVHET2B.js +11 -0
  95. package/dist/reset-PIFYNOS3.js +216 -0
  96. package/dist/run-3VSPP24F.js +735 -0
  97. package/dist/share-D36RQCXM.js +241 -0
  98. package/dist/skills-F2MRLELY.js +445 -0
  99. package/dist/skills-eval-E2ZTW4PL.js +932 -0
  100. package/dist/targets-DZMEZAH4.js +977 -0
  101. package/dist/trace-7NYCUI2J.js +250 -0
  102. package/dist/uninstall-AD3JWHBB.js +322 -0
  103. package/dist/upgrade-WYYBKGDY.js +301 -0
  104. package/dist/usage-ULIDAGFF.js +755 -0
  105. package/dist/version-ROZ6CZKH.js +16 -0
  106. package/dist/wiki-generate-PKFIX6OB.js +377 -0
  107. package/dist/worker/entry.js +1739 -0
  108. package/docs/README.md +93 -0
  109. package/docs/acp.md +120 -0
  110. package/docs/alcf-provider.md +72 -0
  111. package/docs/architecture.md +172 -0
  112. package/docs/artifact-versions.md +54 -0
  113. package/docs/built-in-agents.md +265 -0
  114. package/docs/capacity-and-scheduling.md +97 -0
  115. package/docs/commands-and-modes.md +554 -0
  116. package/docs/config-knobs-audit.md +115 -0
  117. package/docs/configuration-and-targets.md +812 -0
  118. package/docs/context-engine.md +236 -0
  119. package/docs/dispatch-architecture-rationale.md +126 -0
  120. package/docs/documentation-coverage.md +46 -0
  121. package/docs/documentation-guide.md +166 -0
  122. package/docs/environment-variables.md +105 -0
  123. package/docs/eval-runner.md +205 -0
  124. package/docs/evals-internal.md +298 -0
  125. package/docs/evidence-and-memory.md +243 -0
  126. package/docs/evolution.md +143 -0
  127. package/docs/exit-codes-and-output.md +74 -0
  128. package/docs/extensions-and-sharing.md +306 -0
  129. package/docs/fleet-demo-runbook.md +179 -0
  130. package/docs/fleet-dispatch.md +591 -0
  131. package/docs/glossary.md +75 -0
  132. package/docs/html/agents_blueprint.html +936 -0
  133. package/docs/html/alcf_blueprint.html +324 -0
  134. package/docs/html/architecture_blueprint.html +850 -0
  135. package/docs/html/commands_blueprint.html +794 -0
  136. package/docs/html/config_knobs_audit_blueprint.html +178 -0
  137. package/docs/html/configuration_blueprint.html +1080 -0
  138. package/docs/html/context_blueprint.html +603 -0
  139. package/docs/html/documentation_blueprint.html +832 -0
  140. package/docs/html/environment_blueprint.html +404 -0
  141. package/docs/html/eval_blueprint.html +743 -0
  142. package/docs/html/evals_internal_blueprint.html +190 -0
  143. package/docs/html/evolution_blueprint.html +674 -0
  144. package/docs/html/extensions_blueprint.html +2065 -0
  145. package/docs/html/fleet_dispatch_blueprint.html +286 -0
  146. package/docs/html/index.html +919 -0
  147. package/docs/html/lifecycle_blueprint.html +723 -0
  148. package/docs/html/memory_blueprint.html +699 -0
  149. package/docs/html/middleware_blueprint.html +664 -0
  150. package/docs/html/models_blueprint.html +2366 -0
  151. package/docs/html/observability_blueprint.html +683 -0
  152. package/docs/html/provider_adapter_blueprint.html +245 -0
  153. package/docs/html/safety_blueprint.html +1386 -0
  154. package/docs/html/shared.css +571 -0
  155. package/docs/html/shared.js +143 -0
  156. package/docs/html/skills_blueprint.html +671 -0
  157. package/docs/html/soak_blueprint.html +182 -0
  158. package/docs/html/tool_usage_blueprint.html +350 -0
  159. package/docs/html/tools_blueprint.html +2249 -0
  160. package/docs/html/trace_blueprint.html +235 -0
  161. package/docs/html/tui_design_blueprint.html +314 -0
  162. package/docs/html/validation_blueprint.html +961 -0
  163. package/docs/html/worker_dispatch_blueprint.html +231 -0
  164. package/docs/installation-and-lifecycle.md +308 -0
  165. package/docs/middleware-and-components.md +148 -0
  166. package/docs/model-catalog.md +189 -0
  167. package/docs/observability.md +233 -0
  168. package/docs/proactive-memory.md +452 -0
  169. package/docs/prompt-envelope-and-tools.md +142 -0
  170. package/docs/provider-adapter-cookbook.md +148 -0
  171. package/docs/release-cut-checklist.md +138 -0
  172. package/docs/safety-model.md +357 -0
  173. package/docs/scientific-validation.md +105 -0
  174. package/docs/session-lifecycle.md +156 -0
  175. package/docs/skills-marketplace.md +46 -0
  176. package/docs/tool-usage.md +527 -0
  177. package/docs/trace-store.md +132 -0
  178. package/docs/troubleshooting.md +33 -0
  179. package/docs/tui-design.md +239 -0
  180. package/docs/worker-dispatch-mechanics.md +242 -0
  181. package/package.json +132 -0
  182. package/skills/README.md +408 -0
  183. package/skills/git/commit-crafting/SKILL.md +79 -0
  184. package/skills/git/commit-crafting/evals.md +92 -0
  185. package/skills/git/create-pr/SKILL.md +116 -0
  186. package/skills/git/create-pr/evals.md +114 -0
  187. package/skills/git/investigate-issue/SKILL.md +139 -0
  188. package/skills/git/investigate-issue/evals.md +94 -0
  189. package/skills/git/resolve-merge-conflicts/SKILL.md +96 -0
  190. package/skills/git/resolve-merge-conflicts/evals.md +58 -0
  191. package/skills/git/review-changes/SKILL.md +103 -0
  192. package/skills/git/review-changes/evals.md +85 -0
  193. package/skills/git/worktree-create/SKILL.md +92 -0
  194. package/skills/git/worktree-create/evals.md +97 -0
  195. package/skills/git/worktree-create/references/worktree-setup.md +66 -0
  196. package/skills/git/worktree-merge/SKILL.md +95 -0
  197. package/skills/git/worktree-merge/evals.md +114 -0
  198. package/skills/skill-marketplace.json +261 -0
  199. package/skills/workflow/cut-it/SKILL.md +86 -0
  200. package/skills/workflow/cut-it/evals.md +42 -0
  201. package/src/domains/agents/builtins/architect.md +33 -0
  202. package/src/domains/agents/builtins/coder.md +31 -0
  203. package/src/domains/agents/builtins/context-bootstrap.md +38 -0
  204. package/src/domains/agents/builtins/debugger.md +30 -0
  205. package/src/domains/agents/builtins/documenter.md +31 -0
  206. package/src/domains/agents/builtins/git-master.md +30 -0
  207. package/src/domains/agents/builtins/provenance.md +30 -0
  208. package/src/domains/agents/builtins/researcher.md +71 -0
  209. package/src/domains/agents/builtins/scout.md +42 -0
  210. package/src/domains/agents/builtins/tester.md +31 -0
  211. package/src/domains/agents/builtins/verifier.md +30 -0
  212. package/src/domains/agents/builtins/wiki-writer.md +41 -0
  213. package/src/domains/agents/fleets/build-review.md +34 -0
  214. package/src/domains/agents/fleets/build-test.md +35 -0
  215. package/src/domains/agents/fleets/sdlc.md +86 -0
  216. package/src/domains/prompts/fragments/identity/clio-worker.md +11 -0
  217. package/src/domains/prompts/fragments/identity/clio.md +26 -0
  218. package/src/domains/prompts/fragments/operating/contract.md +64 -0
  219. package/src/domains/prompts/fragments/safety/auto-edit.md +14 -0
  220. package/src/domains/prompts/fragments/safety/full-auto.md +14 -0
  221. package/src/domains/prompts/fragments/safety/read-only.md +13 -0
  222. package/src/domains/prompts/fragments/safety/suggest.md +13 -0
  223. package/src/domains/prompts/fragments/wiki/page.md +75 -0
  224. package/src/domains/prompts/fragments/wiki/plan.md +48 -0
  225. package/src/domains/providers/models/cloud-models/alcf.yaml +40 -0
  226. package/src/domains/providers/models/local-models/clio-local-coding-targets.yaml +993 -0
@@ -0,0 +1,683 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Clio Coder Observability & Receipt Viewer</title>
7
+
8
+ <!-- Fonts -->
9
+
10
+ <style>
11
+ :root {
12
+ --bg-dark: #090d16;
13
+ --bg-card: rgba(17, 24, 39, 0.7);
14
+ --border-card: rgba(255, 255, 255, 0.08);
15
+ --text-main: #f3f4f6;
16
+ --text-muted: #9ca3af;
17
+ --text-dark: #4b5563;
18
+
19
+ /* Glowing Neon Colors */
20
+ --color-cyan: #00f0ff;
21
+ --color-cyan-rgb: 0, 240, 255;
22
+ --color-purple: #bd00ff;
23
+ --color-purple-rgb: 189, 0, 255;
24
+ --color-emerald: #10b981;
25
+ --color-emerald-rgb: 16, 185, 129;
26
+ --color-amber: #f59e0b;
27
+ --color-amber-rgb: 245, 158, 11;
28
+ --color-rose: #ef4444;
29
+ --color-rose-rgb: 239, 68, 68;
30
+
31
+ --font-sans: "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
32
+ --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
33
+ }
34
+
35
+ * {
36
+ box-sizing: border-box;
37
+ margin: 0;
38
+ padding: 0;
39
+ }
40
+
41
+ body {
42
+ background-color: var(--bg-dark);
43
+ background-image:
44
+ radial-gradient(circle at 10% 15%, rgba(var(--color-cyan-rgb), 0.04) 0%, transparent 35%),
45
+ radial-gradient(circle at 90% 85%, rgba(var(--color-purple-rgb), 0.04) 0%, transparent 35%),
46
+ radial-gradient(circle at 50% 50%, #0c1220 0%, var(--bg-dark) 100%);
47
+ color: var(--text-main);
48
+ font-family: var(--font-sans);
49
+ min-height: 100vh;
50
+ display: flex;
51
+ flex-direction: column;
52
+ overflow-x: hidden;
53
+ }
54
+
55
+ .container {
56
+ max-width: 1400px;
57
+ margin: 0 auto;
58
+ padding: 2rem;
59
+ flex: 1;
60
+ display: flex;
61
+ flex-direction: column;
62
+ width: 100%;
63
+ }
64
+
65
+ /* Header styling */
66
+ header {
67
+ border-bottom: 1px solid var(--border-card);
68
+ padding-bottom: 1.5rem;
69
+ margin-bottom: 2rem;
70
+ display: flex;
71
+ justify-content: space-between;
72
+ align-items: center;
73
+ flex-wrap: wrap;
74
+ gap: 1rem;
75
+ }
76
+
77
+ .header-logo {
78
+ display: flex;
79
+ align-items: center;
80
+ gap: 1rem;
81
+ }
82
+
83
+ .logo-box {
84
+ width: 48px;
85
+ height: 48px;
86
+ background: rgba(255, 255, 255, 0.02);
87
+ border: 1px solid var(--border-card);
88
+ border-radius: 10px;
89
+ display: flex;
90
+ align-items: center;
91
+ justify-content: center;
92
+ box-shadow: 0 0 15px rgba(var(--color-cyan-rgb), 0.1);
93
+ }
94
+
95
+ h1 {
96
+ font-size: 1.6rem;
97
+ font-weight: 800;
98
+ letter-spacing: -0.02em;
99
+ }
100
+
101
+ .subtitle {
102
+ font-size: 0.85rem;
103
+ color: var(--text-muted);
104
+ margin-top: 0.15rem;
105
+ }
106
+
107
+ .version-tag {
108
+ background: rgba(255, 255, 255, 0.03);
109
+ border: 1px solid var(--border-card);
110
+ padding: 0.4rem 0.8rem;
111
+ border-radius: 8px;
112
+ font-size: 0.8rem;
113
+ font-family: var(--font-mono);
114
+ display: flex;
115
+ align-items: center;
116
+ gap: 0.5rem;
117
+ }
118
+
119
+ .version-dot {
120
+ width: 6px;
121
+ height: 6px;
122
+ background-color: var(--color-cyan);
123
+ border-radius: 50%;
124
+ box-shadow: 0 0 8px var(--color-cyan);
125
+ }
126
+
127
+ .back-link {
128
+ color: var(--text-muted);
129
+ text-decoration: none;
130
+ font-size: 0.85rem;
131
+ display: flex;
132
+ align-items: center;
133
+ gap: 0.35rem;
134
+ transition: color 0.2s;
135
+ }
136
+ .back-link:hover {
137
+ color: var(--color-cyan);
138
+ }
139
+
140
+ /* Split Pane Layout */
141
+ .split-viewer {
142
+ display: grid;
143
+ grid-template-columns: 320px 1fr;
144
+ gap: 1.5rem;
145
+ flex: 1;
146
+ min-height: 550px;
147
+ }
148
+
149
+ .left-panel {
150
+ background: var(--bg-card);
151
+ border: 1px solid var(--border-card);
152
+ border-radius: 12px;
153
+ backdrop-filter: blur(12px);
154
+ display: flex;
155
+ flex-direction: column;
156
+ overflow: hidden;
157
+ }
158
+
159
+ .panel-header {
160
+ padding: 1rem;
161
+ border-bottom: 1px solid var(--border-card);
162
+ background: rgba(0, 0, 0, 0.2);
163
+ }
164
+
165
+ .filter-input {
166
+ width: 100%;
167
+ padding: 0.5rem 0.75rem;
168
+ background: rgba(0, 0, 0, 0.3);
169
+ border: 1px solid var(--border-card);
170
+ border-radius: 6px;
171
+ color: #fff;
172
+ font-size: 0.85rem;
173
+ font-family: var(--font-sans);
174
+ }
175
+ .filter-input:focus {
176
+ outline: none;
177
+ border-color: var(--color-cyan);
178
+ }
179
+
180
+ .category-group {
181
+ padding: 0.75rem 0;
182
+ border-bottom: 1px solid rgba(255, 255, 255, 0.03);
183
+ }
184
+ .category-title {
185
+ font-size: 0.7rem;
186
+ font-weight: 700;
187
+ text-transform: uppercase;
188
+ letter-spacing: 0.05em;
189
+ color: var(--text-dark);
190
+ padding: 0.25rem 1rem;
191
+ }
192
+
193
+ .item-list {
194
+ list-style: none;
195
+ display: flex;
196
+ flex-direction: column;
197
+ }
198
+
199
+ .item-row {
200
+ padding: 0.6rem 1rem;
201
+ font-size: 0.8rem;
202
+ font-family: var(--font-mono);
203
+ cursor: pointer;
204
+ display: flex;
205
+ justify-content: space-between;
206
+ align-items: center;
207
+ transition: all 0.2s;
208
+ border-left: 2px solid transparent;
209
+ color: var(--text-muted);
210
+ }
211
+ .item-row:hover {
212
+ background: rgba(255, 255, 255, 0.02);
213
+ color: #fff;
214
+ }
215
+ .item-row.active {
216
+ background: rgba(var(--color-cyan-rgb), 0.03);
217
+ border-left-color: var(--color-cyan);
218
+ color: var(--color-cyan);
219
+ }
220
+
221
+ .right-panel {
222
+ background: var(--bg-card);
223
+ border: 1px solid var(--border-card);
224
+ border-radius: 12px;
225
+ backdrop-filter: blur(12px);
226
+ display: flex;
227
+ flex-direction: column;
228
+ overflow: hidden;
229
+ }
230
+
231
+ .viewer-header {
232
+ padding: 1rem 1.5rem;
233
+ border-bottom: 1px solid var(--border-card);
234
+ background: rgba(0, 0, 0, 0.2);
235
+ display: flex;
236
+ justify-content: space-between;
237
+ align-items: center;
238
+ flex-wrap: wrap;
239
+ gap: 1rem;
240
+ }
241
+
242
+ .viewer-title {
243
+ font-size: 0.95rem;
244
+ font-weight: 600;
245
+ font-family: var(--font-mono);
246
+ color: #fff;
247
+ display: flex;
248
+ align-items: center;
249
+ gap: 0.5rem;
250
+ }
251
+
252
+ .viewer-actions {
253
+ display: flex;
254
+ align-items: center;
255
+ gap: 0.75rem;
256
+ }
257
+
258
+ .btn {
259
+ background: rgba(255, 255, 255, 0.03);
260
+ border: 1px solid var(--border-card);
261
+ color: var(--text-main);
262
+ padding: 0.4rem 0.8rem;
263
+ border-radius: 6px;
264
+ font-size: 0.8rem;
265
+ font-family: var(--font-sans);
266
+ cursor: pointer;
267
+ transition: all 0.2s;
268
+ display: inline-flex;
269
+ align-items: center;
270
+ gap: 0.35rem;
271
+ }
272
+ .btn:hover {
273
+ background: rgba(255, 255, 255, 0.08);
274
+ border-color: var(--color-cyan);
275
+ }
276
+ .btn-verify {
277
+ background: rgba(var(--color-cyan-rgb), 0.1);
278
+ border-color: var(--color-cyan);
279
+ color: var(--color-cyan);
280
+ }
281
+ .btn-verify:hover {
282
+ background: rgba(var(--color-cyan-rgb), 0.2);
283
+ }
284
+
285
+ .viewer-body {
286
+ flex: 1;
287
+ padding: 1.5rem;
288
+ overflow: auto;
289
+ display: flex;
290
+ flex-direction: column;
291
+ gap: 1rem;
292
+ }
293
+
294
+ .path-bar {
295
+ background: #05080e;
296
+ border: 1px solid var(--border-card);
297
+ padding: 0.5rem 1rem;
298
+ border-radius: 6px;
299
+ font-family: var(--font-mono);
300
+ font-size: 0.75rem;
301
+ color: var(--text-muted);
302
+ display: flex;
303
+ justify-content: space-between;
304
+ align-items: center;
305
+ }
306
+
307
+ .code-view {
308
+ background: #05080e;
309
+ border: 1px solid var(--border-card);
310
+ border-radius: 8px;
311
+ padding: 1.25rem;
312
+ font-family: var(--font-mono);
313
+ font-size: 0.85rem;
314
+ line-height: 1.5;
315
+ overflow-x: auto;
316
+ white-space: pre-wrap;
317
+ flex: 1;
318
+ color: #e5e7eb;
319
+ }
320
+
321
+ .verification-status-panel {
322
+ padding: 1.25rem;
323
+ border-radius: 8px;
324
+ font-family: var(--font-mono);
325
+ font-size: 0.8rem;
326
+ line-height: 1.5;
327
+ display: none;
328
+ white-space: pre-wrap;
329
+ }
330
+ .verification-status-panel.success {
331
+ display: block;
332
+ background: rgba(16, 185, 129, 0.03);
333
+ border: 1px solid rgba(16, 185, 129, 0.2);
334
+ color: #6ee7b7;
335
+ }
336
+ .verification-status-panel.error {
337
+ display: block;
338
+ background: rgba(239, 68, 68, 0.03);
339
+ border: 1px solid rgba(239, 68, 68, 0.2);
340
+ color: #fca5a5;
341
+ }
342
+
343
+ .status-badge {
344
+ padding: 0.15rem 0.4rem;
345
+ border-radius: 4px;
346
+ font-size: 0.7rem;
347
+ font-weight: 700;
348
+ text-transform: uppercase;
349
+ }
350
+ .status-success { background: rgba(16, 185, 129, 0.1); border: 1px solid var(--color-emerald); color: var(--color-emerald); }
351
+ .status-failure { background: rgba(239, 68, 68, 0.1); border: 1px solid var(--color-rose); color: var(--color-rose); }
352
+ .status-info { background: rgba(0, 240, 255, 0.1); border: 1px solid var(--color-cyan); color: var(--color-cyan); }
353
+
354
+ footer {
355
+ text-align: center;
356
+ margin-top: 3rem;
357
+ border-top: 1px solid rgba(255, 255, 255, 0.05);
358
+ padding-top: 1.5rem;
359
+ color: var(--text-dark);
360
+ font-size: 0.8rem;
361
+ }
362
+ </style>
363
+ </head>
364
+ <body>
365
+
366
+ <div class="container">
367
+ <!-- Header -->
368
+ <header>
369
+ <div class="header-logo">
370
+ <div class="logo-box">
371
+ <svg viewBox="0 0 64 64" width="32" height="32" role="img" aria-label="Clio Coder logo"><title>Clio Coder logo</title><rect x="8" y="8" width="48" height="48" rx="12" fill="rgba(0,240,255,0.12)" stroke="rgba(0,240,255,0.65)"/><path d="M32 14 16 23l16 9 16-9-16-9Z" fill="none" stroke="#00f0ff" stroke-width="3" stroke-linejoin="round"/><path d="M16 32l16 9 16-9M16 41l16 9 16-9" fill="none" stroke="#bd00ff" stroke-width="3" stroke-linecap="round" stroke-linejoin="round"/></svg>
372
+ </div>
373
+ <div>
374
+ <h1>Observability Viewer</h1>
375
+ <div class="subtitle">Interactive Split Panel & Run Receipt Verification Sandbox</div>
376
+ </div>
377
+ </div>
378
+ <div style="display:flex; align-items:center; gap: 1rem;">
379
+ <a href="index.html" class="back-link">
380
+ <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><title>Icon</title><line x1="19" y1="12" x2="5" y2="12"/><polyline points="12 19 5 12 12 5"/></svg>
381
+ Back to Hub
382
+ </a>
383
+ <div class="version-tag">
384
+ <div class="version-dot"></div>
385
+ Clio Coder v0.3.0
386
+ </div>
387
+ </div>
388
+ </header>
389
+
390
+ <!-- Split Viewer Panel -->
391
+ <div class="split-viewer">
392
+
393
+ <!-- Left Panel: Lists -->
394
+ <div class="left-panel">
395
+ <div class="panel-header">
396
+ <input type="text" class="filter-input" id="filter-box" placeholder="Type to filter artifacts..." oninput="filterArtifacts()">
397
+ </div>
398
+
399
+ <div style="flex: 1; overflow-y: auto;">
400
+ <div class="category-group" id="group-Receipts">
401
+ <div class="category-title">Receipts</div>
402
+ <ul class="item-list" id="list-Receipts">
403
+ <!-- Rendered dynamically -->
404
+ </ul>
405
+ </div>
406
+ <div class="category-group" id="group-Dispatch">
407
+ <div class="category-title">Dispatch outputs</div>
408
+ <ul class="item-list" id="list-Dispatch">
409
+ <!-- Rendered dynamically -->
410
+ </ul>
411
+ </div>
412
+ <div class="category-group" id="group-Tool">
413
+ <div class="category-title">Tool outputs</div>
414
+ <ul class="item-list" id="list-Tool">
415
+ <!-- Rendered dynamically -->
416
+ </ul>
417
+ </div>
418
+ <div class="category-group" id="group-Compaction">
419
+ <div class="category-title">Compaction summaries</div>
420
+ <ul class="item-list" id="list-Compaction">
421
+ <!-- Rendered dynamically -->
422
+ </ul>
423
+ </div>
424
+ </div>
425
+ </div>
426
+
427
+ <!-- Right Panel: View & Inspect -->
428
+ <div class="right-panel">
429
+ <div class="viewer-header">
430
+ <div class="viewer-title" id="viewer-title">
431
+ <span class="status-badge status-info" id="viewer-badge">Receipt</span>
432
+ <span id="viewer-filename">run-9a3c9f28.json</span>
433
+ </div>
434
+ <div class="viewer-actions">
435
+ <button type="button" class="btn btn-verify" id="verify-btn" onclick="runIntegrityVerification()">
436
+ <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><title>Icon</title><path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"/></svg>
437
+ Verify Checksum (v)
438
+ </button>
439
+ <button type="button" class="btn" onclick="showBackingPath()">
440
+ <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><title>Icon</title><circle cx="12" cy="12" r="10"/><line x1="12" y1="16" x2="12" y2="12"/><line x1="12" y1="8" x2="12.01" y2="8"/></svg>
441
+ Backing Path (o)
442
+ </button>
443
+ </div>
444
+ </div>
445
+
446
+ <div class="viewer-body">
447
+ <div class="path-bar">
448
+ <span id="backing-path-display">~/.local/state/clio-coder/receipts/run-9a3c9f28.json</span>
449
+ <span style="font-size:0.7rem; color:var(--text-dark);" id="capped-indicator">Lines: 12</span>
450
+ </div>
451
+
452
+ <div class="verification-status-panel" id="verification-panel">
453
+ </div>
454
+
455
+ <pre class="code-view" id="artifact-content-pre"></pre>
456
+ </div>
457
+ </div>
458
+
459
+ </div>
460
+
461
+ <footer>
462
+ <p>Clio Coder Visual Specification Blueprint. Product Version v0.3.0. Designed with high-performance dark aesthetics.</p>
463
+ </footer>
464
+ </div>
465
+
466
+ <script>
467
+ const ARTIFACTS = {
468
+ "receipts-1": {
469
+ name: "run-9a3c9f28.json",
470
+ category: "Receipts",
471
+ path: "~/.local/state/clio-coder/receipts/run-9a3c9f28.json",
472
+ badge: "Receipt",
473
+ badgeClass: "status-info",
474
+ content: `{
475
+ "runId": "run-9a3c9f28",
476
+ "command": "npm run build && npm run test:smoke",
477
+ "exitCode": 0,
478
+ "startedAt": "2026-06-12T08:12:00Z",
479
+ "finishedAt": "2026-06-12T08:12:45Z",
480
+ "receiptIntegrity": "sha256-abc874fde3c99a0042188ffabec12530164c676643",
481
+ "filesCreated": [
482
+ "dist/cli/index.js",
483
+ "dist/worker/entry.js"
484
+ ]
485
+ }`,
486
+ verifySuccess: true,
487
+ verifyLog: `[INFO] Read ~/.local/state/clio-coder/receipts/run-9a3c9f28.json
488
+ [INFO] Validating required receipt fields and value ranges:
489
+ - runId: run-9a3c9f28 (VALID)
490
+ - command: 'npm run build && npm run test:smoke' (VALID)
491
+ - exitCode: 0 (VALID)
492
+ [INFO] Read ~/.local/state/clio-coder/runs.json
493
+ [INFO] Found matching run envelope in global runs ledger.
494
+ [INFO] Recomputing receipt integrity checksum:
495
+ - Expected: sha256-abc874fde3c99a0042188ffabec12530164c676643
496
+ - Computed: sha256-abc874fde3c99a0042188ffabec12530164c676643
497
+ [SUCCESS] Receipt integrity verification PASSED.`
498
+ },
499
+ "receipts-2": {
500
+ name: "run-0428fa8e.json",
501
+ category: "Receipts",
502
+ path: "~/.local/state/clio-coder/receipts/run-0428fa8e.json",
503
+ badge: "Receipt",
504
+ badgeClass: "status-info",
505
+ content: `{
506
+ "runId": "run-0428fa8e",
507
+ "command": "sbatch run_sim.sh",
508
+ "exitCode": 1,
509
+ "startedAt": "2026-06-12T08:15:00Z",
510
+ "finishedAt": "2026-06-12T08:15:02Z",
511
+ "receiptIntegrity": "sha256-fffffffffffffffff99999999999999999999999",
512
+ "filesCreated": []
513
+ }`,
514
+ verifySuccess: false,
515
+ verifyLog: `[INFO] Read ~/.local/state/clio-coder/receipts/run-0428fa8e.json
516
+ [INFO] Validating required receipt fields and value ranges:
517
+ - runId: run-0428fa8e (VALID)
518
+ - command: 'sbatch run_sim.sh' (VALID)
519
+ - exitCode: 1 (WARNING: non-zero exit code)
520
+ [INFO] Read ~/.local/state/clio-coder/runs.json
521
+ [ERROR] Missing or unmatched run envelope in global runs ledger runs.json.
522
+ [ERROR] Receipt integrity checksum mismatch:
523
+ - Expected: sha256-fffffffffffffffff99999999999999999999999
524
+ - Computed: sha256-000000000000000000000000000000000000000
525
+ [FAILURE] Receipt integrity verification FAILED.`
526
+ },
527
+ "dispatch-1": {
528
+ name: "runs.json",
529
+ category: "Dispatch",
530
+ badge: "Ledger",
531
+ badgeClass: "status-success",
532
+ path: "~/.local/state/clio-coder/runs.json",
533
+ content: `[
534
+ {
535
+ "runId": "run-9a3c9f28",
536
+ "status": "success",
537
+ "cwd": "/workspace/clio-coder",
538
+ "timestamp": 1781259120000
539
+ },
540
+ {
541
+ "runId": "run-b209d841",
542
+ "status": "success",
543
+ "cwd": "/workspace/clio-coder",
544
+ "timestamp": 1781259180000
545
+ }
546
+ ]`,
547
+ verifySuccess: true,
548
+ verifyLog: `[INFO] Global runs ledger validation is read-only. Use 'Verify' on individual receipts.`
549
+ },
550
+ "tool-1": {
551
+ name: "bashExecution-out.log",
552
+ category: "Tool",
553
+ badge: "Output",
554
+ badgeClass: "status-success",
555
+ path: "/workspace/clio-coder/.clio-coder/tmp/bashExecution-out.log",
556
+ content: `✔ All tests passed (12 specs)
557
+ ℹ Checking boundary constraints...
558
+ ✔ Boundary checks passed.
559
+ [incremental reader: file capped at first 50,000 lines]`,
560
+ verifySuccess: true,
561
+ verifyLog: `[INFO] Plain text execution log verified. Verification not applicable to raw tool outputs.`
562
+ },
563
+ "compaction-1": {
564
+ name: "current.jsonl",
565
+ category: "Compaction",
566
+ badge: "Summary",
567
+ badgeClass: "status-info",
568
+ path: "~/.local/state/clio-coder/sessions/cwd_hash_a9e3/sess_7a3d90f/current.jsonl",
569
+ content: `{"turn": 1, "compactionSummary": "Initialized project with local settings targets: deepseek-r1:8b"}
570
+ {"turn": 4, "compactionSummary": "Masked 6 stale tool observations older than excludeLastTurns."}
571
+ {"turn": 5, "compactionSummary": "LLM summary compaction executed: compressed 15,200 tokens into 1,200 summary tokens."}`,
572
+ verifySuccess: true,
573
+ verifyLog: `[INFO] History compaction ledger format verified.`
574
+ }
575
+ };
576
+
577
+ let activeKey = "receipts-1";
578
+
579
+ function initList() {
580
+ // Clear
581
+ document.getElementById("list-Receipts").innerHTML = "";
582
+ document.getElementById("list-Dispatch").innerHTML = "";
583
+ document.getElementById("list-Tool").innerHTML = "";
584
+ document.getElementById("list-Compaction").innerHTML = "";
585
+
586
+ Object.keys(ARTIFACTS).forEach(key => {
587
+ const art = ARTIFACTS[key];
588
+ const row = document.createElement("li");
589
+ row.className = `item-row ${key === activeKey ? 'active' : ''}`;
590
+ row.id = `item-${key}`;
591
+ row.onclick = () => selectArtifact(key);
592
+ row.innerHTML = `
593
+ <span>${art.name}</span>
594
+ <span style="font-size:0.65rem; color:var(--text-dark);">${art.badge}</span>
595
+ `;
596
+
597
+ document.getElementById(`list-${art.category}`).appendChild(row);
598
+ });
599
+ }
600
+
601
+ function selectArtifact(key) {
602
+ activeKey = key;
603
+ document.querySelectorAll(".item-row").forEach(el => { el.classList.remove("active"); });
604
+ document.getElementById(`item-${key}`).classList.add("active");
605
+
606
+ const art = ARTIFACTS[key];
607
+ document.getElementById("viewer-filename").innerText = art.name;
608
+ document.getElementById("viewer-badge").innerText = art.badge;
609
+ document.getElementById("viewer-badge").className = `status-badge ${art.badgeClass}`;
610
+ document.getElementById("backing-path-display").innerText = art.path;
611
+
612
+ const codeEl = document.getElementById("artifact-content-pre");
613
+ codeEl.textContent = art.content;
614
+
615
+ const lines = art.content.split("\n").length;
616
+ document.getElementById("capped-indicator").innerText = `Lines: ${lines}`;
617
+
618
+ // Reset verification panel
619
+ const panel = document.getElementById("verification-panel");
620
+ panel.style.display = "none";
621
+ panel.className = "verification-status-panel";
622
+
623
+ // Toggle verify button visibility based on category
624
+ const verifyBtn = document.getElementById("verify-btn");
625
+ if (art.category === "Receipts") {
626
+ verifyBtn.style.display = "inline-flex";
627
+ } else {
628
+ verifyBtn.style.display = "none";
629
+ }
630
+ }
631
+
632
+ function runIntegrityVerification() {
633
+ const art = ARTIFACTS[activeKey];
634
+ const panel = document.getElementById("verification-panel");
635
+
636
+ panel.style.display = "block";
637
+ panel.textContent = art.verifyLog;
638
+
639
+ if (art.verifySuccess) {
640
+ panel.className = "verification-status-panel success";
641
+ } else {
642
+ panel.className = "verification-status-panel error";
643
+ }
644
+ }
645
+
646
+ function showBackingPath() {
647
+ const art = ARTIFACTS[activeKey];
648
+ alert(`Backing absolute path:\n${art.path}`);
649
+ }
650
+
651
+ function filterArtifacts() {
652
+ const q = document.getElementById("filter-box").value.toLowerCase();
653
+
654
+ Object.keys(ARTIFACTS).forEach(key => {
655
+ const art = ARTIFACTS[key];
656
+ const row = document.getElementById(`item-${key}`);
657
+ if (art.name.toLowerCase().includes(q) || art.category.toLowerCase().includes(q)) {
658
+ row.style.display = "flex";
659
+ } else {
660
+ row.style.display = "none";
661
+ }
662
+ });
663
+ }
664
+
665
+ // Keybindings support
666
+ document.addEventListener("keydown", (e) => {
667
+ if (e.key === "v" || e.key === "V") {
668
+ const art = ARTIFACTS[activeKey];
669
+ if (art.category === "Receipts") {
670
+ runIntegrityVerification();
671
+ }
672
+ } else if (e.key === "o" || e.key === "O") {
673
+ showBackingPath();
674
+ }
675
+ });
676
+
677
+ window.onload = () => {
678
+ initList();
679
+ selectArtifact(activeKey);
680
+ };
681
+ </script>
682
+ </body>
683
+ </html>