@iowarp/clio-coder 0.5.0 → 0.5.2
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/.claude-plugin/marketplace.json +4 -4
- package/CHANGELOG.md +35 -0
- package/CONTRIBUTING.md +9 -0
- package/README.md +12 -9
- package/ROADMAP.md +30 -5
- package/dist/{acp-KS7ARGV6.js → acp-F6PGOFZ4.js} +2 -2
- package/dist/{agents-YOGJ2YEJ.js → agents-ZHP4R6EX.js} +22 -21
- package/dist/assets/codewiki.json +1 -1
- package/dist/{auth-CEDCO6O6.js → auth-N75U2H3Z.js} +4 -4
- package/dist/{chunk-D3KWFOUT.js → chunk-23UIXH6Z.js} +3 -3
- package/dist/{chunk-ZR5YA6ZF.js → chunk-36XVK5P5.js} +5 -5
- package/dist/{chunk-AVSR2HKI.js → chunk-3DZ4LPLS.js} +6 -6
- package/dist/{chunk-LYJJ6546.js → chunk-3GSPCWFX.js} +12 -12
- package/dist/{chunk-CRHPCPZP.js → chunk-4KC4CHKJ.js} +2 -2
- package/dist/{chunk-4VDHLCF5.js → chunk-4WJBWKMI.js} +2 -2
- package/dist/{chunk-KBUTSJSR.js → chunk-4XBYHXGK.js} +2 -2
- package/dist/{chunk-6W75D37F.js → chunk-53P775GE.js} +6 -3
- package/dist/{chunk-XZWSP67B.js → chunk-5APYAXCB.js} +2 -2
- package/dist/{chunk-D65E25JG.js → chunk-67HPYNTJ.js} +2 -2
- package/dist/{chunk-5JQR5B4D.js → chunk-6KV4KCQZ.js} +4 -4
- package/dist/{chunk-V4XJWDHR.js → chunk-6UKFRTXI.js} +2 -1
- package/dist/{chunk-NDPF2N2L.js → chunk-7DW7CJW2.js} +2 -2
- package/dist/{chunk-5KQEUIWM.js → chunk-7LUEQODV.js} +4 -4
- package/dist/{chunk-LNOXCGN2.js → chunk-7UFDIOBT.js} +3 -3
- package/dist/{chunk-DXSETN72.js → chunk-7WUGNN43.js} +2 -2
- package/dist/{chunk-V35KZDUZ.js → chunk-AA3GRZWS.js} +2 -2
- package/dist/{chunk-X4CEFOSG.js → chunk-ADO3OQIC.js} +4 -4
- package/dist/{chunk-UX2L5CUD.js → chunk-AI36V3ON.js} +3 -3
- package/dist/{chunk-B7GY6QER.js → chunk-B26OUMJW.js} +2 -2
- package/dist/{chunk-LAR7DX5E.js → chunk-B5TASTCK.js} +153 -62
- package/dist/{chunk-TGWZXJ7L.js → chunk-BEMQK5Q7.js} +92 -84
- package/dist/{chunk-RNDCROSG.js → chunk-CNXU7TR2.js} +3 -3
- package/dist/{chunk-3JLTRPN7.js → chunk-CVMUXT64.js} +35 -66
- package/dist/{chunk-733ZBT5P.js → chunk-E74MJF6G.js} +4 -4
- package/dist/{chunk-T2MDZES3.js → chunk-EBMTBE76.js} +3 -3
- package/dist/{chunk-OZ76TLGU.js → chunk-EEITU7S6.js} +2 -2
- package/dist/{chunk-GRHOXDKB.js → chunk-ELDJWJKM.js} +97 -14
- package/dist/{chunk-GCQFN7YI.js → chunk-EMYEQLWO.js} +2 -2
- package/dist/{chunk-LTWH2ACR.js → chunk-EQPFEDFV.js} +222 -127
- package/dist/{chunk-TDGYTWM6.js → chunk-F4I3H56H.js} +2 -2
- package/dist/chunk-F6KCJO3U.js +523 -0
- package/dist/{chunk-FGSQHUCK.js → chunk-F6VKWTTY.js} +5 -5
- package/dist/{chunk-UJD5MPP6.js → chunk-FLNXQQ5B.js} +2 -2
- package/dist/{chunk-EX57VVWW.js → chunk-FOSRJ2VZ.js} +4 -4
- package/dist/{chunk-ZARZ4POR.js → chunk-G5ZDQQE3.js} +3 -3
- package/dist/{chunk-HQVN7G4F.js → chunk-G62JBPXN.js} +7 -7
- package/dist/{chunk-ZJPORZTC.js → chunk-GIAI7A2K.js} +2 -2
- package/dist/chunk-GPTR6OTU.js +2551 -0
- package/dist/{chunk-EZD2BXGP.js → chunk-GUFQPTQK.js} +2 -2
- package/dist/{chunk-OPD7GL6F.js → chunk-H6FQVNZC.js} +8 -7
- package/dist/chunk-H7REJ7L5.js +80 -0
- package/dist/{chunk-EYTLV3W3.js → chunk-HTWTORF7.js} +2 -2
- package/dist/{chunk-DF6PI6GN.js → chunk-I6UKQPGS.js} +3 -3
- package/dist/{chunk-ISHUS7HC.js → chunk-JRW236JT.js} +3 -3
- package/dist/{chunk-DE2LU267.js → chunk-KKAJGT3B.js} +3 -2
- package/dist/{chunk-OV62D6KO.js → chunk-KQMYL5GR.js} +3 -3
- package/dist/{chunk-QDUUOZ3S.js → chunk-KWMFC7FN.js} +3 -3
- package/dist/{chunk-R7FGRZNF.js → chunk-LXYHCCIZ.js} +9 -9
- package/dist/{chunk-NFSK2VNU.js → chunk-LZMTVVN4.js} +2 -2
- package/dist/{chunk-62UK7AGW.js → chunk-M5PMRZSR.js} +397 -44
- package/dist/chunk-MMZMM6SW.js +131 -0
- package/dist/{chunk-FFYTC2KQ.js → chunk-MNABNEBX.js} +2 -2
- package/dist/{chunk-XMDBTYCH.js → chunk-N3CWOGVF.js} +3 -3
- package/dist/{chunk-VYRQHORQ.js → chunk-NMQSO6Z6.js} +4 -3
- package/dist/{chunk-R2UUNSNQ.js → chunk-O3ZAF7UY.js} +18 -5
- package/dist/{chunk-4SYHGVDE.js → chunk-OQNCLZI4.js} +4 -4
- package/dist/{chunk-EG4ARXPC.js → chunk-OX6QTA4N.js} +3 -3
- package/dist/{chunk-P4GNZPXO.js → chunk-OYUS3UZP.js} +2 -2
- package/dist/{chunk-OQ2EOAHA.js → chunk-PF36KOGI.js} +291 -112
- package/dist/{chunk-55RMDDFM.js → chunk-PGQG7ZMW.js} +2 -2
- package/dist/{chunk-CBAQPTDU.js → chunk-PIU6BXXW.js} +2 -2
- package/dist/{chunk-EKV4UBCM.js → chunk-PZBQUJ2F.js} +2 -2
- package/dist/{chunk-7RET77VB.js → chunk-Q2HKY32Y.js} +2 -2
- package/dist/{chunk-U6YTUVOX.js → chunk-Q4RMNWMZ.js} +4 -4
- package/dist/chunk-Q6FRR3AQ.js +48 -0
- package/dist/{chunk-6RJMYYIE.js → chunk-QJSIAJBY.js} +3 -3
- package/dist/{chunk-DOUISWEE.js → chunk-QOJ4ERMU.js} +5 -5
- package/dist/{chunk-IFPDAD7R.js → chunk-RWSRKXLT.js} +3 -3
- package/dist/{chunk-T33IYTZM.js → chunk-SAASVMIY.js} +3 -3
- package/dist/{chunk-2DTIWSAW.js → chunk-SEQDH6JC.js} +3 -3
- package/dist/{chunk-BRCOSE7O.js → chunk-SZUO5BSE.js} +2 -2
- package/dist/{chunk-HOEDA42N.js → chunk-T7HZ7KJF.js} +2 -2
- package/dist/{chunk-OJXOA6YU.js → chunk-TL6LNERH.js} +2 -2
- package/dist/{chunk-UCINIRHW.js → chunk-TPCZXWLT.js} +3 -3
- package/dist/{chunk-ZUKUCZYZ.js → chunk-TQ2KTH4A.js} +2 -2
- package/dist/{chunk-4WOOTKFD.js → chunk-U3FETNQB.js} +341 -20
- package/dist/{chunk-5B3RTYAK.js → chunk-UGDSB4AN.js} +2 -2
- package/dist/{chunk-VKHLUZNO.js → chunk-UZ7YBL43.js} +3 -3
- package/dist/{chunk-QNUQ7K7D.js → chunk-VKMSEO7Y.js} +4 -4
- package/dist/{chunk-IN7DGBVS.js → chunk-VLX5VZ35.js} +5 -5
- package/dist/{chunk-SJGS3GDI.js → chunk-WAGBMMNX.js} +5 -5
- package/dist/{chunk-BFOSV5EZ.js → chunk-WX2YCH7F.js} +2 -2
- package/dist/{chunk-3LT34CAM.js → chunk-XBIGUILU.js} +32 -17
- package/dist/{chunk-XDHUDE5K.js → chunk-XKYBFRWR.js} +5 -5
- package/dist/{chunk-U5QU5ZOD.js → chunk-XYPWFSU5.js} +3 -3
- package/dist/{chunk-YBUECLAF.js → chunk-YEJQDODA.js} +2 -2
- package/dist/{chunk-YQ6XEFVK.js → chunk-Z74OGONW.js} +39 -7
- package/dist/{chunk-I4ELN5BX.js → chunk-ZTNOEJRI.js} +2 -2
- package/dist/cli/index.js +26 -26
- package/dist/{clio-K2PBVCEM.js → clio-4IKFE25F.js} +2 -2
- package/dist/{clio-context-tools-GR4OHFSO.js → clio-context-tools-OHJXYX4R.js} +25 -23
- package/dist/{code-nav-4X3OI6DK.js → code-nav-XPM3MY5I.js} +7 -7
- package/dist/{config-Q5J7UBAB.js → config-343YS25T.js} +43 -41
- package/dist/{config-graph-P3555574.js → config-graph-WI263KDX.js} +43 -41
- package/dist/{configure-KIJ32ZO6.js → configure-GZDG4HER.js} +21 -21
- package/dist/{context-LFBQOSXT.js → context-4OFO7N7Y.js} +12 -12
- package/dist/{context-WBH3KSVR.js → context-JLK2RLOG.js} +42 -40
- package/dist/{context-NNLBES2Y.js → context-O6DIWCF6.js} +23 -21
- package/dist/{context-clear-YOHMQ6SQ.js → context-clear-MR7KOGQI.js} +42 -40
- package/dist/{context-working-set-MRAEVDNV.js → context-working-set-YZAD3KWO.js} +14 -13
- package/dist/{data-tool-JJPBGMQJ.js → data-tool-EKD7DFHG.js} +7 -7
- package/dist/{detail-RHJOTGN4.js → detail-YZPHFEVJ.js} +43 -41
- package/dist/{dispatch-runner-NC7PYNIO.js → dispatch-runner-VKVXVTWJ.js} +44 -42
- package/dist/{doctor-S5KZ2GTN.js → doctor-53AVQXAO.js} +17 -16
- package/dist/{doctor-deep-2EJQSHIZ.js → doctor-deep-BLRB2NCG.js} +5 -5
- package/dist/{eval-3D6M36N7.js → eval-P3BQSLQE.js} +21 -20
- package/dist/{evidence-XNVPPLVK.js → evidence-6LLI6SZH.js} +44 -42
- package/dist/{evidence-6IYN52ET.js → evidence-HTN3JLUO.js} +42 -40
- package/dist/{evidence-JVECPI3F.js → evidence-NJRE3R5H.js} +42 -40
- package/dist/{evolve-TLPUDJDM.js → evolve-WWZHJVJP.js} +42 -40
- package/dist/{fleet-WKVBF5SZ.js → fleet-GGZ4BVJE.js} +64 -62
- package/dist/{fleet-6RJWIOEO.js → fleet-QG3IIWWM.js} +44 -42
- package/dist/{fleet-commands-L6WFT7KZ.js → fleet-commands-J2ZIKISQ.js} +7 -7
- package/dist/{fleet-decisions-BTQMWU5A.js → fleet-decisions-Y2Q7375Q.js} +8 -8
- package/dist/{fleet-graph-553DZ67Q.js → fleet-graph-TCBCCCBP.js} +11 -11
- package/dist/{fleet-inspect-236FZPRB.js → fleet-inspect-KOLKBC56.js} +44 -42
- package/dist/{fleet-preflight-NZQHABWO.js → fleet-preflight-44UNCC4Y.js} +27 -25
- package/dist/{fleet-validate-7NLAE26R.js → fleet-validate-K2FXRZVA.js} +13 -13
- package/dist/{fleet-verify-E3RO6A5W.js → fleet-verify-AS444WDW.js} +42 -40
- package/dist/{fleet-view-KMZQY7YJ.js → fleet-view-X4JU4J6O.js} +43 -41
- package/dist/gui/ops-worker.js +9 -9
- package/dist/gui/reads-worker.js +9 -8
- package/dist/{init-DV5B6HQG.js → init-VSOWFHVL.js} +54 -52
- package/dist/{interactive-OXGYZYAS.js → interactive-JRCBENLZ.js} +1733 -577
- package/dist/{interop-J7UOBOSF.js → interop-JR6BCY7R.js} +10 -10
- package/dist/{inventory-OEGIL6PY.js → inventory-3JUGLVJI.js} +43 -41
- package/dist/{library-ROZAMUIL.js → library-7BOH3Y7N.js} +15 -15
- package/dist/{library-B3UPGY4V.js → library-7PFONXUI.js} +9 -9
- package/dist/{library-MXQA5DLT.js → library-TUYZMFIA.js} +7 -7
- package/dist/{library-import-2LTWOVBD.js → library-import-TJVXKLDK.js} +10 -10
- package/dist/{library-inventory-LJ3XHLWO.js → library-inventory-MD3AYTP4.js} +9 -9
- package/dist/{library-validation-DARHHUNW.js → library-validation-ZDLITEA3.js} +7 -7
- package/dist/{mcp-2GSPYQ54.js → mcp-EFCWUPUR.js} +3 -3
- package/dist/{memory-J3STUUIK.js → memory-Q2YVOKK5.js} +42 -40
- package/dist/{models-Y3GMFJ2V.js → models-M7BOCW7F.js} +17 -16
- package/dist/{monitor-LHNH577J.js → monitor-2HD3MC67.js} +47 -45
- package/dist/{orchestrator-DTAPXULA.js → orchestrator-OUW3ZN6Y.js} +1894 -226
- package/dist/{panes-A743ONZ5.js → panes-TTPPSYCL.js} +3 -3
- package/dist/{preload-OJBMAIXF.js → preload-A47C2NUF.js} +42 -40
- package/dist/{providers-CMETPZNS.js → providers-T43W7EL4.js} +4 -4
- package/dist/{resources-FY6XYFN2.js → resources-TP6X2V6W.js} +20 -11
- package/dist/{run-H64MEVTA.js → run-LDSBPMCS.js} +61 -59
- package/dist/{share-CAFMMQLM.js → share-URHKKMHR.js} +9 -9
- package/dist/{skills-ERKQUC7L.js → skills-E477MOOO.js} +13 -11
- package/dist/{skills-eval-CQ23MYQK.js → skills-eval-AIBR2L7H.js} +583 -93
- package/dist/{skills-inventory-TVUYJDVN.js → skills-inventory-HLMKY3R5.js} +13 -11
- package/dist/{slash-commands-ROG3KIFJ.js → slash-commands-LIIZKA5Y.js} +28 -26
- package/dist/{startup-background-KDWCQMWT.js → startup-background-JR2KDK6R.js} +43 -41
- package/dist/{steer-KKYXJSH4.js → steer-D7RTAPCM.js} +3 -3
- package/dist/{system-ZDW44ZGX.js → system-X2P5N4IY.js} +14 -13
- package/dist/{targets-AJWA6E7Z.js → targets-VFFAKUFM.js} +25 -24
- package/dist/{tasks-6L2JJRC5.js → tasks-ERAWZA22.js} +6 -6
- package/dist/{terminal-lease-YFUSDPAD.js → terminal-lease-V2N2BIKQ.js} +2 -2
- package/dist/{trace-LA5MVR4Y.js → trace-MA5BT7XY.js} +3 -3
- package/dist/{usage-XSILDHKF.js → usage-WYFY2L6M.js} +50 -48
- package/dist/{verifiers-ECA5GIHL.js → verifiers-TYIW2XKF.js} +7 -7
- package/dist/{verify-R6QQCCEB.js → verify-242UFYTP.js} +6 -6
- package/dist/{web-fetch-PVZNMBOB.js → web-fetch-LRAGYU6Y.js} +3 -3
- package/dist/{wiki-generate-RP22WP5K.js → wiki-generate-OFKOX2T6.js} +53 -51
- package/dist/worker/entry.js +31 -29
- package/docs/architecture/architecture.md +1 -0
- package/docs/architecture/context-engine.md +4 -2
- package/docs/architecture/observability.md +6 -4
- package/docs/architecture/prompt-envelope-and-tools.md +1 -1
- package/docs/architecture/session-lifecycle.md +1 -1
- package/docs/architecture/tui-design.md +12 -9
- package/docs/gui/parity/02-slash-and-surfaces.md +1 -1
- package/docs/guide/commands-and-modes.md +91 -5
- package/docs/guide/configuration-and-targets.md +2 -2
- package/docs/guide/context-continuity.md +49 -0
- package/docs/guide/proactive-memory.md +6 -3
- package/library/registry.yaml +292 -32
- package/library/skills/README.md +27 -2
- package/library/skills/context/context-handoff/SKILL.md +10 -4
- package/library/skills/meta/clio-coder-dev/SKILL.md +92 -88
- package/library/skills/meta/clio-coder-dev/evals.md +51 -46
- package/library/skills/meta/clio-coder-dev/plugin.json +2 -2
- package/library/skills/meta/clio-coder-dev/references/change-map.md +49 -0
- package/library/skills/meta/clio-coder-test/SKILL.md +89 -142
- package/library/skills/meta/clio-coder-test/evals.md +58 -62
- package/library/skills/meta/clio-coder-test/plugin.json +2 -2
- package/library/skills/meta/clio-coder-test/references/harness.md +3 -3
- package/library/skills/meta/clio-coder-test/references/lifecycle-validation.md +30 -0
- package/library/skills/meta/clio-coder-test/references/test-map.md +60 -89
- package/library/skills/registry.yaml +5 -5
- package/library/skills/skill-marketplace.json +12 -14
- package/package.json +1 -1
- package/src/cli/skills-eval.ts +1064 -54
- package/src/cli/usage.ts +2 -2
- package/src/core/clio-repo.ts +3 -0
- package/src/core/tool-names.ts +1 -0
- package/src/domains/context/budget/inspection.ts +9 -0
- package/src/domains/context/budget/live-view.ts +418 -0
- package/src/domains/context/budget/pressure.ts +393 -0
- package/src/domains/context/budget/request-fit.ts +15 -0
- package/src/domains/evidence/build.ts +24 -0
- package/src/domains/gateway/mcp/client.ts +1 -1
- package/src/domains/memory/commit-state.ts +160 -0
- package/src/domains/memory/operations.ts +18 -10
- package/src/domains/memory/prompt-cache.ts +95 -0
- package/src/domains/memory/prompt-section.ts +50 -7
- package/src/domains/memory/relevance.ts +93 -0
- package/src/domains/memory/restoration.ts +78 -0
- package/src/domains/memory/store.ts +39 -1
- package/src/domains/middleware/memory-intervention.ts +116 -24
- package/src/domains/observability/background-memory-usage.ts +1 -1
- package/src/domains/observability/cost.ts +3 -3
- package/src/domains/observability/extension.ts +1 -1
- package/src/domains/observability/metrics.ts +1 -1
- package/src/domains/prompts/compiler.ts +1 -1
- package/src/domains/prompts/extension.ts +38 -1
- package/src/domains/quota/anthropic-max-provider.ts +134 -0
- package/src/domains/quota/anthropic-usage.ts +220 -0
- package/src/domains/quota/antigravity-provider.ts +339 -0
- package/src/domains/quota/cache.ts +87 -0
- package/src/domains/quota/claude-code-provider.ts +169 -0
- package/src/domains/quota/codex-provider.ts +237 -0
- package/src/domains/quota/presentation.ts +240 -0
- package/src/domains/quota/registry.ts +23 -0
- package/src/domains/quota/service.ts +93 -0
- package/src/domains/quota/summary-feed.ts +86 -0
- package/src/domains/quota/types.ts +84 -0
- package/src/domains/resources/index.ts +11 -0
- package/src/domains/resources/skills/catalog-view.ts +571 -0
- package/src/domains/resources/skills/lexical-match.ts +136 -0
- package/src/domains/resources/skills/loader.ts +38 -0
- package/src/domains/resources/skills/promotion.ts +1 -55
- package/src/domains/resources/skills/provenance-pin.ts +50 -20
- package/src/domains/safety/action-classifier.ts +1 -0
- package/src/domains/session/compaction/branch-summary.ts +4 -1
- package/src/domains/session/compaction/compact.ts +18 -2
- package/src/domains/session/compaction/cut-point.ts +20 -1
- package/src/domains/session/compaction/tokens.ts +48 -3
- package/src/domains/session/context-accounting.ts +8 -1
- package/src/domains/session/continuity/carry.ts +59 -0
- package/src/domains/session/continuity/contract.ts +592 -0
- package/src/domains/session/continuity/evidence.ts +290 -0
- package/src/domains/session/continuity/fold.ts +1075 -0
- package/src/domains/session/continuity/note.ts +79 -0
- package/src/domains/session/continuity/operator-request.ts +104 -0
- package/src/domains/session/continuity/persistence.ts +408 -0
- package/src/domains/session/continuity/ports.ts +231 -0
- package/src/domains/session/continuity/projection.ts +538 -0
- package/src/domains/session/continuity/validate.ts +352 -0
- package/src/domains/session/entries.ts +50 -3
- package/src/domains/session/index.ts +48 -0
- package/src/domains/session/migrations/index.ts +7 -3
- package/src/domains/session/tree/fork.ts +15 -1
- package/src/domains/session/usage.ts +2 -2
- package/src/engine/acp/commands.ts +1 -1
- package/src/engine/agent.ts +133 -9
- package/src/engine/session.ts +13 -6
- package/src/entry/orchestrator.ts +116 -33
- package/src/interactive/chat-loop-messages.ts +2 -2
- package/src/interactive/chat-loop.ts +219 -63
- package/src/interactive/chat-renderer.ts +99 -8
- package/src/interactive/context-overlay.ts +24 -3
- package/src/interactive/continuity-controller.ts +526 -0
- package/src/interactive/dispatch-board.ts +21 -3
- package/src/interactive/footer/dashboard.ts +25 -1
- package/src/interactive/footer/key-hints.ts +2 -2
- package/src/interactive/footer/pages.ts +70 -27
- package/src/interactive/footer/widgets.ts +32 -7
- package/src/interactive/footer-panel.ts +1 -1
- package/src/interactive/interactive-application.ts +7 -2
- package/src/interactive/interactive-input-runtime.ts +2 -2
- package/src/interactive/interactive-presentation.ts +15 -0
- package/src/interactive/interactive-slash-runtime.ts +45 -8
- package/src/interactive/interactive-tickers.ts +7 -1
- package/src/interactive/model-session-replay.ts +130 -3
- package/src/interactive/output-reserve.ts +35 -0
- package/src/interactive/overlay-general-openers.ts +12 -8
- package/src/interactive/overlay-key-routing.ts +6 -9
- package/src/interactive/overlay-lifecycle.ts +10 -6
- package/src/interactive/overlay-session-lifecycle.ts +21 -14
- package/src/interactive/quota-view.ts +229 -0
- package/src/interactive/session-last-turn.ts +1 -1
- package/src/interactive/session-transcript.ts +2 -1
- package/src/interactive/session-usage-reseed.ts +2 -2
- package/src/interactive/side-question.ts +2 -2
- package/src/interactive/slash-commands.ts +28 -9
- package/src/interactive/turn-context.ts +686 -63
- package/src/interactive/turn-middleware.ts +39 -6
- package/src/interactive/turn-persistence.ts +15 -2
- package/src/interactive/turn-prewarm.ts +1 -1
- package/src/interactive/turn-runtime.ts +48 -5
- package/src/interactive/{cost-overlay.ts → usage-overlay.ts} +121 -33
- package/src/interactive/welcome-dashboard.ts +26 -3
- package/src/tools/agent-tools.ts +3 -1
- package/src/tools/bootstrap.ts +6 -0
- package/src/tools/builtin-tool-catalog.ts +9 -0
- package/src/tools/context/index.ts +148 -113
- package/src/tools/context/surface.ts +11 -7
- package/src/tools/core-bootstrap.ts +4 -0
- package/src/tools/observation.ts +8 -2
- package/src/tools/policy.ts +3 -0
- package/src/tools/self-compact.ts +31 -0
- package/src/tools/surface.ts +1 -0
- package/src/tools/tasks.ts +1 -1
- package/dist/chunk-CTFPFW3H.js +0 -44
- package/dist/chunk-EOJPDNUP.js +0 -1325
- package/dist/chunk-I4Y4WKZR.js +0 -386
|
@@ -85,6 +85,8 @@ An `EvidenceIndexRow` has the following schema:
|
|
|
85
85
|
|
|
86
86
|
## Cross-Session Usage Facts
|
|
87
87
|
|
|
88
|
+
Everything in this section describes what Clio itself recorded. Subscription quota is a separate source with separate meaning: `src/domains/quota/**` reads what each connected provider account reports about its own windows and credits, account-wide and shared across your sessions and devices, and nothing in that domain enters the cost ledger, the evidence spine, or the trace store. The `/usage` overlay shows both and keeps them in separate views, because a session's recorded tokens cannot be converted into a percentage of a provider's plan. See [Subscription quota and session usage](../guide/commands-and-modes.md#subscription-quota-and-session-usage).
|
|
89
|
+
|
|
88
90
|
`clio-coder usage report` folds the local archive into one window of facts. Its token and cost facts come from two inputs: the per-session ledgers, folded through the session domain's `ledgerUsageCalls`, and the out-of-turn usage store described below. Both the text report and `--json` carry the same fields.
|
|
89
91
|
|
|
90
92
|
| Field | Where it appears | Meaning |
|
|
@@ -92,7 +94,7 @@ An `EvidenceIndexRow` has the following schema:
|
|
|
92
94
|
| `apiCalls` | `tokens in window: <total> over <n> model calls` and the `tokens` JSON fact | Provider calls folded in the window, out-of-turn rounds included. |
|
|
93
95
|
| `input`, `output`, `cacheRead`, `cacheWrite`, `reasoningTokens`, `totalTokens` | the same line and fact | Provider-reported token breakdown for those calls. |
|
|
94
96
|
| `costUsd` | `provider-reported cost in window` and the `tokens` fact | Provider-reported cost. Never estimated. |
|
|
95
|
-
| `turns` | `turns in window` and the `tokens` fact | Folded calls that were turns, so labelled calls are subtracted exactly as `/
|
|
97
|
+
| `turns` | `turns in window` and the `tokens` fact | Folded calls that were turns, so labelled calls are subtracted exactly as `/usage` subtracts them. |
|
|
96
98
|
| `sideQuestions` | `side questions in window` and the `tokens` fact | `/btw` rounds in the window. |
|
|
97
99
|
| `handoffs` | `handoffs in window` and the `tokens` fact | `/handoff` extraction rounds in the window. |
|
|
98
100
|
| `prewarms` | `pre-warms in window` and the `tokens` fact | Prompt pre-warm rounds in the window. |
|
|
@@ -120,7 +122,7 @@ The row reads `top expected reason none` when the session recorded verdicts but
|
|
|
120
122
|
|
|
121
123
|
### The Out-of-Turn Usage Store
|
|
122
124
|
|
|
123
|
-
A `/btw` side question and a `/handoff` extraction round are real provider calls that append nothing to the session JSONL, by design: a fleet run briefs its workers from the transcript, and a question the operator asked to orient themselves must not become context those workers inherit. The spend still has to be recorded somewhere durable, so it goes to `<stateDir>/usage/out-of-turn.jsonl`, one JSON line per priced call, written by the chat loop at the same moment it reports the call to `/
|
|
125
|
+
A `/btw` side question and a `/handoff` extraction round are real provider calls that append nothing to the session JSONL, by design: a fleet run briefs its workers from the transcript, and a question the operator asked to orient themselves must not become context those workers inherit. The spend still has to be recorded somewhere durable, so it goes to `<stateDir>/usage/out-of-turn.jsonl`, one JSON line per priced call, written by the chat loop at the same moment it reports the call to `/usage`.
|
|
124
126
|
|
|
125
127
|
The file is append-only NDJSON kept as a bounded ring (capped at 1000 rows, rewritten atomically under the shared state-file lock when it grows past the cap). Reads are tolerant: a malformed line is reported as a diagnostic on stderr and skipped.
|
|
126
128
|
|
|
@@ -155,9 +157,9 @@ Failed compaction attempts record one `failed-compaction` row per invoked summar
|
|
|
155
157
|
|
|
156
158
|
New failed-compaction rows preserve missing usage fields as `null`. Positive partial-response facts survive an error that resets missing fields to zero. Ambiguous failed zeros remain unknown, reasoning is separate from ordinary output/total tokens, and an absent total is not inferred. Positive adapter prices are labeled `estimated`; zero or missing pricing is `unknown`, not a free-call claim. Existing numeric rows and historical checkpoints remain readable without rewriting them.
|
|
157
159
|
|
|
158
|
-
`clio-coder usage report` includes these calls in its known subtotals, labels the failed-attempt count, and exposes `failedCompaction.knownUsage`, `erroredKnownUsage`, and per-field `unobservedUsageCalls` in the token and model JSON facts. A field with missing coverage and no known positive amount is `null`, including cost-only or wholly unobserved failures. Text output identifies incomplete subtotals. The live `/
|
|
160
|
+
`clio-coder usage report` includes these calls in its known subtotals, labels the failed-attempt count, and exposes `failedCompaction.knownUsage`, `erroredKnownUsage`, and per-field `unobservedUsageCalls` in the token and model JSON facts. A field with missing coverage and no known positive amount is `null`, including cost-only or wholly unobserved failures. Text output identifies incomplete subtotals. The live `/usage` view records positive known contributions under a failed-compaction label; its numeric token counters remain known subtotals. These figures do not certify provider billing or complete spending. The existing session-cost ceiling checks the numeric known sum, so unreported cost does not become an enforced complete-cost bound.
|
|
159
161
|
|
|
160
|
-
In v0.5.
|
|
162
|
+
In v0.5.1, eval tracked/stdout folds omit the failed-compaction sidecar, and live `/usage` reseeding reads the session ledger rather than this store. A later usage report can therefore include retained failed-compaction amounts that those views omit. These consumer projections remain separate; retained known amounts must not be presented as complete cross-surface billing.
|
|
161
163
|
|
|
162
164
|
A failed or empty summary produces no checkpoint. Required failed-compaction usage appends are flushed and a write failure remains an explicit operation error; no model call is repeated to repair accounting. If checkpoint append throws, Clio checks that checkpoint's exact identity in the original ledger before choosing the sidecar: an already written checkpoint is not counted again, and proven absence permits the sidecar. An unreadable or malformed ledger that leaves persistence ambiguous fails visibly without a speculative duplicate write. This is the existing bounded usage store, not a new recovery store; its 1000-row retention and unknown telemetry limits still apply.
|
|
163
165
|
|
|
@@ -316,7 +316,7 @@ Timing and cache behavior are persisted per API call, so a finished session can
|
|
|
316
316
|
|
|
317
317
|
Native session timing uses a monotonic clock from each stream invocation, before the provider's response-header wait, to its first observed output (`ttftMs`) and completion (`apiMs`). A tool-loop continuation starts a new clock; no output leaves TTFT null, and a genuine rounded zero remains zero. Historical values are not rewritten and may omit the pre-header wait. Eval prefers these durable native call records. Its stdout-only fallback starts at the provider's `message_start` event, which can arrive after headers, so fallback spans are not complete request latency and must not be compared as equivalent measurements.
|
|
318
318
|
|
|
319
|
-
For aggregate cost and token facts across sessions, use `clio-coder usage report --days <n>`. Inside the TUI, `/
|
|
319
|
+
For aggregate cost and token facts across sessions, use `clio-coder usage report --days <n>`. Inside the TUI, `/usage` shows session totals and `/context` opens the context-window ledger overlay.
|
|
320
320
|
|
|
321
321
|
## Self-documentation retrieval
|
|
322
322
|
|
|
@@ -167,7 +167,7 @@ cancels the whole handoff with nothing written in either session.
|
|
|
167
167
|
The extraction round itself runs on the out-of-turn seam `/btw` uses: one call
|
|
168
168
|
against the session's live target and model, the compiled message history as
|
|
169
169
|
read-only input, no tools, and no entry in the ledger. Its provider usage is
|
|
170
|
-
reported to `/
|
|
170
|
+
reported to `/usage` under a handoffs row and excluded from the turn count.
|
|
171
171
|
|
|
172
172
|
### Streaming Turn Settlement During Session Transitions
|
|
173
173
|
|
|
@@ -203,7 +203,7 @@ Interactive startup uses one terminal lease across both boot stages. Stage 0 own
|
|
|
203
203
|
The header has two operational modes: a framed launchpad dashboard on fresh start, and a single live session row after prompt admission. Source: `src/interactive/welcome-dashboard.ts`; contracts: `tests/extended/welcome-boot-header.test.ts`.
|
|
204
204
|
|
|
205
205
|
- **Launchpad (before the first prompt): framed panel dashboard.** A boxed container (`buildWelcomeDashboardLines`) enclosed by `╭─ Clio Coder v<version> ─╮` and `╰─╯`:
|
|
206
|
-
- **11 Detail Rows:** Subhead/title ("Built for the code behind science."), model route status (`routeRow`), workspace path, permissions/autonomy (`stats.autonomy`), guidance ("Ask Clio how to use or extend her."), target inventory (`stats.targets`), and fleet recipes inventory (`stats.fleet`).
|
|
206
|
+
- **11 Detail Rows:** Subhead/title ("Built for the code behind science."), model route status (`routeRow`), workspace path, permissions/autonomy (`stats.autonomy`), guidance ("Ask Clio how to use or extend her."), target inventory (`stats.targets`), and fleet recipes inventory (`stats.fleet`). A `Subscriptions` field (`stats.quota`) joins the list between Targets and Fleet once a cached quota reading exists, wrapping at the detail-column width rather than clipping, and is absent entirely when no account is connected.
|
|
207
207
|
- **Responsive Layout:** Renders wordmark ASCII art on the left at ≥76 columns (`sideBySide`), and rotating hint cards on the right at ≥160 columns (`WELCOME_HINT_MIN_WIDTH`) cycling commands and shortcuts every 15 seconds.
|
|
208
208
|
- **Action Row:** A horizontal rule (`├─┤`) separates details from the action row (`actionRow`), which prints the next step or work blocker: no route or model (`/model`), route unavailable or degraded (`/settings targets`), malformed handbook (`CLIO-CODER.md malformed · /context to inspect`), uninitialized handbook (`describe a task · /context init to index this repo`), stale handbook (`describe a task · /context refresh to update it`), or default `describe a task · <SubmitKey> to send · / for commands`.
|
|
209
209
|
|
|
@@ -211,7 +211,7 @@ The header has two operational modes: a framed launchpad dashboard on fresh star
|
|
|
211
211
|
|
|
212
212
|
- **Session header (after the first prompt): exactly one row, and live.**
|
|
213
213
|
```
|
|
214
|
-
>C_ Clio Coder v0.5.
|
|
214
|
+
>C_ Clio Coder v0.5.1 · dynamo · qwen3.8-27b · ~/iowarp/clio-coder · main*
|
|
215
215
|
```
|
|
216
216
|
Collapsed via `sessionRow`, this line tracks mid-session model or branch mutations. It preserves identity (`>C_ Clio Coder v<version>`), active route, workspace tail, and git dirty state (`*`), dropping readiness and onboarding hints owned by the footer. Under extreme width pressure, the route is preserved longest, outliving workspace and version labels.
|
|
217
217
|
|
|
@@ -267,12 +267,12 @@ Starting Clio · you can type now
|
|
|
267
267
|
Source: `src/interactive/footer/dashboard.ts`, `src/interactive/footer/pages.ts`.
|
|
268
268
|
|
|
269
269
|
- **Compact Mode (Two-Line Ambient Strip)**:
|
|
270
|
-
- **Line 1 (Workload & Identity)**: Active phase (`accent` e.g. `Ready`) and worker counts (`agent` e.g. `· 2 active`) · Target/model identity (`fitIdentityLabel`) · Thinking level (`reason`) on the left; Context meter bar (8–14 cells) and token occupancy (`used / contextWindow`) on the right.
|
|
271
|
-
- **Line 2 (Status & Hints)**: Urgent input
|
|
270
|
+
- **Line 1 (Workload & Identity)**: Active phase (`accent` e.g. `Ready`) and worker counts (`agent` e.g. `· 2 active`) · Target/model identity (`fitIdentityLabel`) · Selected model’s weekly quota (`weekly N% left`, when the local credential owner and model group are known) · Thinking level (`reason`) on the left; Context meter bar (8–14 cells) and token occupancy (`used / contextWindow`) on the right.
|
|
271
|
+
- **Line 2 (Status & Hints)**: Persistent workspace cwd and Git branch/dirty (`*`) on the left; rotating shortcut hints on the right. Urgent input prompts (`Ctrl+C again to quit`, `Ctrl+G → choose key`), active notices (`• text`), and demo tips borrow only the hint area. Quota never occupies this row.
|
|
272
272
|
- **Expanded Mode (`Alt+U`)**: Renders across one-quarter of the viewport (minimum 8 rows), keeping the composer anchored below. Repeated presses cycle through three responsive pages (`DASHBOARD_PAGES`) and closed:
|
|
273
273
|
1. `Activity`: Live agent phase, tool counts, session metrics, active worker cards (route, task, token usage, tool calls, timing, budget, `/view dispatch:<id>`), and finished worker history.
|
|
274
274
|
2. `Context`: Context meter bar and category occupancy grid (system, tools, files, turns, memory), compaction/cache telemetry, headroom.
|
|
275
|
-
3. `Status`: Cost & Connections (session cost, MCP servers, plugins, extensions) and Local Machine metrics (CPU, memory, disk I/O sampled on 2s cadence), plus memory bank entries and free tokens.
|
|
275
|
+
3. `Status`: A session line (recorded tokens and tracked cost) above one compact row per connected subscription account (`renderQuotaAccounts`, `src/interactive/quota-view.ts`), then Cost & Connections (session cost, MCP servers, plugins, extensions) and Local Machine metrics (CPU, memory, disk I/O sampled on 2s cadence), plus memory bank entries and free tokens.
|
|
276
276
|
|
|
277
277
|
### 5.4 State Choreography Table
|
|
278
278
|
|
|
@@ -418,17 +418,20 @@ Agents and Fleets label plugin provider packages as `[plugin]` and show only the
|
|
|
418
418
|
|
|
419
419
|
## 8. Shared Vocabulary
|
|
420
420
|
|
|
421
|
-
One quantity gets one word, and every surface that shows it uses that word. A user comparing the transcript, the footer, and an overlay is checking whether Clio is telling a consistent story; a synonym reads as a discrepancy. The current vocabulary is owned by `src/interactive/chat-panel.ts`, `src/interactive/
|
|
421
|
+
One quantity gets one word, and every surface that shows it uses that word. A user comparing the transcript, the footer, and an overlay is checking whether Clio is telling a consistent story; a synonym reads as a discrepancy. The current vocabulary is owned by `src/interactive/chat-panel.ts`, `src/interactive/usage-overlay.ts`, `src/interactive/status/reasoning.ts`, and `src/interactive/thinking-level-policy.ts`; there is no standalone `usage-vocabulary` contract test in the current tree.
|
|
422
422
|
|
|
423
423
|
| Concept | Word | Surfaces |
|
|
424
424
|
| --- | --- | --- |
|
|
425
|
-
| One model API call | `call` | Chat panel `turn · in N over M calls`, `/
|
|
426
|
-
| One user-to-assistant exchange | `turn` | Chat panel `turn · …`, `/
|
|
425
|
+
| One model API call | `call` | Chat panel `turn · in N over M calls`, `/usage` `model calls`, `/usage` `(avg/call …)` |
|
|
426
|
+
| One user-to-assistant exchange | `turn` | Chat panel `turn · …`, `/usage` `turns` |
|
|
427
427
|
| Provider-reported reasoning tokens | `reasoning N provider` | Chat panel |
|
|
428
428
|
| Reasoning tokens estimated from displayed text | `reasoning ≈N estimated` | Chat panel; the footer carries the same `≈` on `r≈N` |
|
|
429
|
-
| Reasoning tokens in the cost tally | `reasoning N provider-reported only` | `/
|
|
429
|
+
| Reasoning tokens in the cost tally | `reasoning N provider-reported only` | `/usage`. This tally never estimates, so it disagrees with the panel on a model that reports nothing, and the row says which one it is. |
|
|
430
430
|
| Thinking level a model cannot turn off | `forced` | Editor rail, model overlay, thinking cycle (`thinkingLevelDisplayWord`) |
|
|
431
431
|
| Thinking level on a model with only on and off | `on` / `off` | Same surfaces |
|
|
432
|
+
| Consumed share of a subscription window | `N% used` | `/usage` Accounts, dashboard Status, welcome `Subscriptions`. A filled meter cell always means consumed capacity. |
|
|
433
|
+
| Unconsumed share of the same window | `N% remaining` in a detailed meter, `N% left` in a compact badge | `/usage` Accounts and Status print `remaining` beside `used`; the compact footer, worker cards, and fleet islands carry `weekly N% left`. |
|
|
434
|
+
| A limit belonging to the account rather than to this session | `Shared <account>` | Worker cards, fleet islands, `/usage` Workers. Never a measured per-worker share. |
|
|
432
435
|
|
|
433
436
|
### 8.1 Slash-Command Failures
|
|
434
437
|
|
|
@@ -24,7 +24,7 @@ Two rows in the source are **corrupt Markdown**: an unescaped `|` inside the ope
|
|
|
24
24
|
| 12 | Oracle advisory | `/oracle <question>` | **Absent** | No read-only record-briefed advisory operation exists. |
|
|
25
25
|
| 13 | Council | `/council <task>` | **Partial** | Runs reconstructs the roster, plan approval, rounds, and synthesis shape from the ledger. Member voices are **host-only-by-design**; starting and sharing a council are absent. |
|
|
26
26
|
| 14 | Agent reference | `/agents` | **Present** | Capability atlas provides the graphical recipe reference. |
|
|
27
|
-
| 15 |
|
|
27
|
+
| 15 | Usage record | `/usage` | **Partial** | Exact tokens and historical reported cost exist, but live session cost, budget provenance, and provider-normalized totals are incomplete. |
|
|
28
28
|
| 16 | Context family | `/context view \| compact \| recall \| init \| refresh \| reset` | **Partial** | `[RECONSTRUCTED]` — the source row is corrupt for the same reason. Verified against `src/interactive/slash-commands.ts:1695-1705`, whose `kinds` are `context-view, compact, context-recall, init, context-clear, context-refresh`. Reconstructed gap, consistent with the `Project context` row in part 1 and the `Context meter and overlay` row below: effective context sources and earlier replay are visible; live window pressure, working-set state, compaction, recall, and reset have no GUI surface. |
|
|
29
29
|
| 17 | Fleet | `/fleet` settings and `/fleet run` preview/approval | **Partial** | Global dispatch status exists; fleet plan selection, variable binding, preview, approval, and run are absent. |
|
|
30
30
|
| 18 | Decision ledger | `/decisions` | **Absent** | No typed decision-board projection reaches the GUI. |
|
|
@@ -250,7 +250,7 @@ The registry table below lists the available interactive slash commands. On a ba
|
|
|
250
250
|
| `/oracle` | `/oracle <question>` | Ask a read-only advisor to challenge a question against this session's settled decisions |
|
|
251
251
|
| `/council` | `/council [--roster <name>] [--rounds <n>] [--synthesis <judge\|vote\|none>] <task>` | Ask a roster of read-only members the same task, with an optional vote or judge synthesis |
|
|
252
252
|
| `/agents` | `/agents` | Open the Library on Agents. |
|
|
253
|
-
| `/
|
|
253
|
+
| `/usage` | `/usage` | Show subscription quota, credits, and session token and cost totals |
|
|
254
254
|
| `/doctor` | `/doctor [deep]` | Show a diagnostic report with errors and warnings first and full wrapped check details; `deep` adds live tool probes on the session's targets and a validation-contract dry run at the session's autonomy. See [Doctor](doctor.md). |
|
|
255
255
|
| `/context` | `/context compact [instructions] \| /context recall <ref> \| /context init [--preview] [--heuristic] [--adopt] [--global] [--propose\|--apply\|--rewrite] \| /context refresh \| /context reset` | Context hub: window overlay plus compact, recall, init, refresh, and reset |
|
|
256
256
|
| `/fleet` | `/fleet [run [--var <key=value>] <name>]` | Open Fleet Runs, or run a fleet contract with an approval preview. Configure fleets with `/settings fleet`. |
|
|
@@ -270,6 +270,92 @@ The registry table below lists the available interactive slash commands. On a ba
|
|
|
270
270
|
| `/fork` | `/fork` | Fork from an assistant turn |
|
|
271
271
|
| `/export` | `/export [path]` | Export a self-contained HTML transcript by default; a `.md` path writes Markdown |
|
|
272
272
|
|
|
273
|
+
### Subscription quota and session usage
|
|
274
|
+
|
|
275
|
+
`/usage` replaces `/cost`. There is no alias: `/cost` is no longer a command.
|
|
276
|
+
The overlay keeps the token and cost accounting `/cost` carried and adds what
|
|
277
|
+
the connected subscription accounts report. It is a live view of this session
|
|
278
|
+
and of your accounts right now; `clio-coder usage report` remains the separate
|
|
279
|
+
command for folding token and cost facts across past sessions.
|
|
280
|
+
|
|
281
|
+
| View | What it shows |
|
|
282
|
+
| --- | --- |
|
|
283
|
+
| Accounts | Subscription and credit meters, every reported model group, remaining capacity, reset countdowns and local reset times with an explicit time zone, and stale or expired readings |
|
|
284
|
+
| Session | Recorded token and cost totals, cache traffic, reasoning, and the background-call categories (side questions, handoffs, pre-warms, memory steps) |
|
|
285
|
+
| Models | Each model's share of recorded processed tokens, including cache traffic, plus its detailed token and cost breakdown |
|
|
286
|
+
| Workers | Active and recent runs, recorded tokens and cost, context usage, and the shared account limit when the local credential owner is known |
|
|
287
|
+
|
|
288
|
+
Press 1–4, Tab/Shift+Tab, or ←/→ to change views; ↑/↓ or PgUp/PgDn to scroll;
|
|
289
|
+
Home/End or Ctrl+Home/Ctrl+End to jump to either end; and Esc to close. Each
|
|
290
|
+
view keeps its own scroll position while the overlay stays open.
|
|
291
|
+
|
|
292
|
+
#### Used, left, and what a percentage describes
|
|
293
|
+
|
|
294
|
+
One direction per label, on every surface. A filled meter cell always means
|
|
295
|
+
consumed capacity, and the detailed meters in Accounts and Status label that
|
|
296
|
+
number `used` and print the complement beside it as `remaining`. Compact badges
|
|
297
|
+
carry the other direction and say so: `weekly 9% used` in a detailed meter is
|
|
298
|
+
the same reading as `weekly 91% left` in a footer badge.
|
|
299
|
+
|
|
300
|
+
Subscription percentages describe an account-wide provider window shared across
|
|
301
|
+
your sessions and devices. Session tokens and costs describe only what this
|
|
302
|
+
process recorded, and the two cannot be converted into each other. Context
|
|
303
|
+
occupancy is a third quantity again: it measures one request against a model's
|
|
304
|
+
window, not an account against its plan.
|
|
305
|
+
|
|
306
|
+
#### Where quota appears outside the overlay
|
|
307
|
+
|
|
308
|
+
The welcome header, the compact footer, the expanded dashboard, worker cards,
|
|
309
|
+
and fleet islands read the same cached readings the overlay does.
|
|
310
|
+
|
|
311
|
+
- The **welcome launchpad** carries a `Subscriptions` field beside the wordmark,
|
|
312
|
+
wrapped so every connected account and the free local-inference row stay visible.
|
|
313
|
+
- The **compact footer** shows the selected model's weekly headroom on line 1,
|
|
314
|
+
beside the model identity, and only when the account and model group are
|
|
315
|
+
identifiable. Line 2 always keeps the working directory and Git branch or dirty
|
|
316
|
+
state; notices, tips, and urgent prompts borrow the rotating hint area beside
|
|
317
|
+
them. Quota never takes line 2, and the footer never promotes an unrelated
|
|
318
|
+
account's busier window in place of the selected model's.
|
|
319
|
+
- The expanded dashboard's **Status** page puts the session total above the
|
|
320
|
+
account meters, **Activity** shows shared account headroom on worker cards, and
|
|
321
|
+
**Context** states that request occupancy and account limits are different
|
|
322
|
+
quantities.
|
|
323
|
+
|
|
324
|
+
#### What Clio does not claim
|
|
325
|
+
|
|
326
|
+
Worker badges are shared account headroom, not a measured per-worker share.
|
|
327
|
+
Clio does not infer a worker's subscription consumption from its token counts or
|
|
328
|
+
from account deltas, and a badge appears only for a supported local credential
|
|
329
|
+
owner and the matching model group. Antigravity's Gemini group stays distinct
|
|
330
|
+
from its Claude and GPT group. Remote workers and generic transports stay
|
|
331
|
+
unlinked rather than being attributed to an account that may not be theirs.
|
|
332
|
+
Clio's own `openai-codex` sign-in is separate storage from the Codex CLI's
|
|
333
|
+
`auth.json`, so a Codex CLI reading is never attributed to an `openai-codex`
|
|
334
|
+
worker.
|
|
335
|
+
|
|
336
|
+
Local inference is listed at `$0.00` with no subscription window consumed. No
|
|
337
|
+
saved-quota figure is claimed, because per-target token attribution does not
|
|
338
|
+
exist yet.
|
|
339
|
+
|
|
340
|
+
#### Reads, caching, and failures
|
|
341
|
+
|
|
342
|
+
Quota reads are read-only. They read stored credentials and never refresh a
|
|
343
|
+
token, write a credential, or start a sign-in. An expired credential is reported
|
|
344
|
+
as expired with the provider's own sign-in guidance rather than repaired.
|
|
345
|
+
|
|
346
|
+
A reading is cached for about five minutes and refreshed lazily when a surface
|
|
347
|
+
that shows it is rendered, never on a background timer. A failed refresh keeps
|
|
348
|
+
the last good reading and marks it `STALE` rather than blanking the account. A
|
|
349
|
+
provider that reports no window for a period reports nothing for it: Codex sends
|
|
350
|
+
a weekly window and no 5h window, and Clio prints the rows a provider actually
|
|
351
|
+
sent instead of a fixed shape. Where a provider sends its own severity word,
|
|
352
|
+
that word wins over Clio's thresholds.
|
|
353
|
+
|
|
354
|
+
Two credentials on one Anthropic subscription (an `anthropic-max` sign-in and a
|
|
355
|
+
Claude Code sign-in) report identical windows, so they are folded into one
|
|
356
|
+
account and the apparent budget is not doubled. Accounts that merely happen to
|
|
357
|
+
show equal percentages are never merged.
|
|
358
|
+
|
|
273
359
|
### Notes on individual commands
|
|
274
360
|
|
|
275
361
|
The notes below explain commands whose behavior needs more than a usage line.
|
|
@@ -345,7 +431,7 @@ context every worker inherits. Esc closes the overlay, and cancels the round if
|
|
|
345
431
|
is still streaming. `/btw` during an in-flight turn is refused with a notice
|
|
346
432
|
rather than queued, because a side question answered after the run it was asked
|
|
347
433
|
during has already missed its moment. The round's token usage still shows in
|
|
348
|
-
`/
|
|
434
|
+
`/usage`, labeled as a side question, because it was a real call and cost real
|
|
349
435
|
money; it is deliberately not counted as a turn.
|
|
350
436
|
|
|
351
437
|
`/council [--roster <name>] [--rounds <n>] [--synthesis judge|vote|none] <task>`
|
|
@@ -564,7 +650,7 @@ not a potentially double-counted total. Supported GPU drivers expose utilization
|
|
|
564
650
|
and VRAM through sysfs. Missing counters stay unavailable; WSL measurements are
|
|
565
651
|
labeled as guest measurements and do not describe the Windows host or remote GPU.
|
|
566
652
|
Counter resets wait for a fresh baseline instead of showing negative rates. Memory
|
|
567
|
-
bank and context-engine activity remain visible. `/
|
|
653
|
+
bank and context-engine activity remain visible. `/usage`, `/mcp`, `/library`, `/context`, and
|
|
568
654
|
Fleet Runs retain deeper inspection. Narrow or short terminals explicitly indicate
|
|
569
655
|
when detail does not fit.
|
|
570
656
|
|
|
@@ -1047,9 +1133,9 @@ The footer owns live activity. Transcript actions have static running or outcome
|
|
|
1047
1133
|
|
|
1048
1134
|
The Clio TUI maximizes operational focus, ergonomics, and discoverability:
|
|
1049
1135
|
|
|
1050
|
-
- **Welcome Launchpad & Session Header:** Prior to your first prompt, Clio renders a framed launchpad dashboard (`src/interactive/welcome-dashboard.ts`) with 11 detail rows (model route status, workspace path, permissions/autonomy, guidance, target inventory, and fleet recipes), accompanied by ASCII wordmark art at ≥76 columns and rotating hints at ≥160 columns. A bottom action row indicates the immediate step or blocker (`describe a task · Enter to send · / for commands`, or route blockers such as `/model` or `/settings targets`). On prompt submission, the launchpad collapses to a single live header row (`>C_ Clio Coder v0.5.
|
|
1136
|
+
- **Welcome Launchpad & Session Header:** Prior to your first prompt, Clio renders a framed launchpad dashboard (`src/interactive/welcome-dashboard.ts`) with 11 detail rows (model route status, workspace path, permissions/autonomy, guidance, target inventory, and fleet recipes) plus a wrapping `Subscriptions` field once a connected account reports quota, accompanied by ASCII wordmark art at ≥76 columns and rotating hints at ≥160 columns. A bottom action row indicates the immediate step or blocker (`describe a task · Enter to send · / for commands`, or route blockers such as `/model` or `/settings targets`). On prompt submission, the launchpad collapses to a single live header row (`>C_ Clio Coder v0.5.1 · <target/model> · <workspace> · <branch>*`) tracking mid-session route or branch changes. `/new` restores the launchpad; `/resume`, `/tree`, `/fork`, and `/handoff` collapse it after transition. See [tui-design.md](../architecture/tui-design.md#51-welcome-launchpad--session-header).
|
|
1051
1137
|
- **Quiet, Focused Clio Composer:** Normal composition rails remain clean and uncluttered (`src/interactive/clio-editor.ts`), omitting duplicate model identity or newline hints already provided by the footer. Exceptional operational states elevate to the top rail: `CONFIRM` (`warning` token, or `CONFIRM · FULL-AUTO` in `editorDanger`) when an approval prompt owns input, `PREPARING` during turn dispatch, `COMPACTING` during context compaction, or `FULL-AUTO` (`editorDanger`). Native editor scroll indicators (`↑/↓` line counts) remain on line 0 when drafts scroll. When the draft is empty, line 1 shows context-aware dim placeholder text (`Ask Clio… / for commands`, `A parked call is waiting for your decision`, `Clio has your prompt and is preparing the turn`, or `Clio is compacting the session context`). During parked permission prompts, the bottom rail carries fitted decision keys (`confirmRailHint` via `src/interactive/permission-hint.ts`: `Enter` allow, or `Backspace` clear draft to allow if a draft is present; `Esc` deny; `s` stop turn; `v` inspect mutation; standing approval terms toggle via `?` on the permission card itself).
|
|
1052
|
-
- **Two-Line Compact Footer & Expanded Dashboard:** The compact footer (`src/interactive/footer/pages.ts`) renders an ambient two-line strip: Line 1 displays live activity phase (`accent`) and active worker counts (`agent`), model/target identity, thinking level, context meter bar, and token usage; Line
|
|
1138
|
+
- **Two-Line Compact Footer & Expanded Dashboard:** The compact footer (`src/interactive/footer/pages.ts`) renders an ambient two-line strip: Line 1 displays live activity phase (`accent`) and active worker counts (`agent`), model/target identity, thinking level, context meter bar, and token usage; Line 1 also shows the selected model’s weekly quota remaining when its account and model group are known; Line 2 preserves workspace cwd and Git branch/dirty state on the left, with rotating shortcuts, tips, or urgent notices on the right. Pressing `Alt+U` expands the dashboard into 1/4 of the viewport (minimum 8 rows), cycling through `Activity` (live worker cards and finished history), `Context` (meter bar/grid, category swatches, headroom), `Status` (Cost & Connections, Local Machine metrics, memory bank), and closed.
|
|
1053
1139
|
- **Grouped Slash Command Palette:** Typing `/` opens an autocomplete command palette grouped by operational category (`Run`, `Inspect`, `Configure`, `Sessions`) with compact argument hints. Every suggestion is the command's one canonical spelling.
|
|
1054
1140
|
- **Voice-First Transcript & Receipts:** User (`› `) and assistant (`✦ `) prose are formatted with a two-cell hanging indent, ensuring wrapped continuation lines remain visually tied to their voice prefix. Tool ledgers maintain full terminal width. Completed turn receipts honor Output style: Compact omits the separate receipt, Standard shows a small completion line with available duration, and Detailed includes available call counts, token usage and reasoning provenance.
|
|
1055
1141
|
- **Transactional Settings Center:** Open `/settings` or deep-link to one of `chat`, `fleet`, `targets`, `context`, `safety`, `interface`, or `integrations`. Value edits construct change plans offering `Apply this session`, `Apply and save globally`, or `Cancel`; narrow terminals use a drill-down layout below 72 columns.
|
|
@@ -687,7 +687,7 @@ Every new assistant ledger entry carries `responseModelIdObservation` in one of
|
|
|
687
687
|
|
|
688
688
|
</details>
|
|
689
689
|
|
|
690
|
-
The adapter retains `responseModel` as the differing response id because providers outside the stream tap still supply that fact. `clio-coder usage report` emits `attributedModelId`, `requestedModelIds`, and `responseModelIdObservationCounts`. Its text table and the `/
|
|
690
|
+
The adapter retains `responseModel` as the differing response id because providers outside the stream tap still supply that fact. `clio-coder usage report` emits `attributedModelId`, `requestedModelIds`, and `responseModelIdObservationCounts`. Its text table and the `/usage` overlay use the labels `attributed model`, `requested model ids`, and `response model id observation`; requested ids are printed as ids rather than as `same`.
|
|
691
691
|
|
|
692
692
|
The footer's last-turn line uses `response model id observation <state>`, with the id after `reported` or a historical `legacy difference-only` state. Dispatch receipt `upstreamResponses` entries carry `requestedModelId`, `responseModelIdObservation`, `differingResponseModelId`, and `providerResponseId`. The peer warning is said once per process per distinct fact (target, requested id, resolved instance, peer set), not once per turn.
|
|
693
693
|
|
|
@@ -1235,7 +1235,7 @@ integrations:
|
|
|
1235
1235
|
```
|
|
1236
1236
|
Then invoke it using `/delegate claude-code <task>`.
|
|
1237
1237
|
|
|
1238
|
-
`/delegate [--share] <agent-id> <task>` does not accept `--model` in v0.5.
|
|
1238
|
+
`/delegate [--share] <agent-id> <task>` does not accept `--model` in v0.5.1.
|
|
1239
1239
|
`/run --model <id>` selects a model for a Clio fleet worker; it does not configure
|
|
1240
1240
|
an external ACP session. External model selection depends on the adapter's own
|
|
1241
1241
|
supported configuration. Clio does not currently expose an ACP model selector.
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Context continuity and recovery
|
|
2
|
+
|
|
3
|
+
Clio can reduce a long native session while preserving the assistant's exact handoff note and the original task. Open `/context` to inspect the next request's input, output reservation, headroom, and pending handoff. The model can read the same accounting with `context(scope="budget")`.
|
|
4
|
+
|
|
5
|
+
## Choosing a reduction
|
|
6
|
+
|
|
7
|
+
| Action | Use it for |
|
|
8
|
+
| --- | --- |
|
|
9
|
+
| Automatic compaction | Routine pressure management under your configured threshold. |
|
|
10
|
+
| `/context compact [instructions]` | An operator-directed summary, optionally focused on specific information. |
|
|
11
|
+
| `self_compact({"note_to_self":"…"})` | An assistant-directed handoff followed by continuation of the same task. |
|
|
12
|
+
| `/context recover <handoffId> <reduce\|deliver>` | Explicit recovery of an interrupted handoff. |
|
|
13
|
+
|
|
14
|
+
`self_compact` is available to the native orchestrator. Dispatched workers do not receive its host callback, and external agents that own their own loop do not receive its schema through the native session tool surface. Skill restrictions and normal tool permission checks still apply.
|
|
15
|
+
|
|
16
|
+
The assistant must call `self_compact` alone. A batch containing it and another tool, or two self-compaction calls, is rejected before any valid sibling executes. The note should preserve the objective, decisions, useful evidence, relevant paths, unresolved questions, and next steps. It must be nonblank and no larger than 8,192 UTF-8 bytes. Clio preserves the accepted text exactly and labels it as assistant-authored recall, rather than presenting it as an operator instruction.
|
|
17
|
+
|
|
18
|
+
## What the receipt means
|
|
19
|
+
|
|
20
|
+
The tool's first receipt means that the note was prepared and flushed to the session ledger. Reduction happens after that receipt has been persisted. Clio records the reduction attempt before invoking the summarizer, checkpoints the outcome, and records delivery intent before allowing another foreground request.
|
|
21
|
+
|
|
22
|
+
A final, nonempty, successful assistant response acknowledges that delivery. Intermediate tool calls, empty responses, errors, cancellation, and a generic end-of-run event do not acknowledge it. Continuation does not append another operator turn or create a fresh durable-memory selection attempt.
|
|
23
|
+
|
|
24
|
+
Each handoff allows at most two reduction attempts, with at most two summary stream invocations per attempt. The automatic window is bounded to 15 minutes. A new operator recovery request may renew that window, but does not refund spent attempts or mint a replacement handoff identity. Summarizer calls, including failed calls with known usage, remain attributable to their originating session.
|
|
25
|
+
|
|
26
|
+
## Recovering an interrupted handoff
|
|
27
|
+
|
|
28
|
+
The `/context` overlay shows the pending handoff ID and its phase. Use the exact ID:
|
|
29
|
+
|
|
30
|
+
```text
|
|
31
|
+
/context recover <handoffId> reduce
|
|
32
|
+
/context recover <handoffId> deliver
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
`reduce` is available when the handoff has not committed and an attempt remains. `deliver` is available when a validated commit exists. A restarted process first records the interrupted state as paused; it does not automatically repeat an uncertain delivery. Recovery authority comes from the operator command and its durable control record, never from a tool argument or text found in a note.
|
|
36
|
+
|
|
37
|
+
If the continuation still cannot fit, use `/context compact` to reduce more history before trying delivery again. Missing or conflicting storage evidence can prevent recovery. Clio retains uncertainty instead of silently creating a new transaction. A missing commit can be reconstructed only from a validated summary carry, using its original reserved identity and an exact storage check.
|
|
38
|
+
|
|
39
|
+
Session forks inherit notes as recall only. They do not inherit permission to resume the parent's handoff. Ordinary summaries persist in the session ledger and replay after `/resume`; a separate handoff file remains useful when moving work to another session or another agent.
|
|
40
|
+
|
|
41
|
+
## Request budgets and memory
|
|
42
|
+
|
|
43
|
+
Submission and native continuation require estimated input plus the resolved output reservation to fit the effective window. Pending user-message framing and images count. A final check inspects the actual request after steering has been drained. Ordinary automatic-compaction preferences remain separate from this hard admission check: disabling automatic compaction cannot authorize an oversized request.
|
|
44
|
+
|
|
45
|
+
Successful durable reductions invalidate older private-memory content jobs and queued memory reminders. Their known usage still counts. Restoration retains the private bank, selects a bounded set of remembered facts and procedures, and suppresses stale private status when an authoritative summary or handoff is available. The full reminder wrapper must fit, and restoration is consumed only after installation in an admitted context. This does not make remembered claims independently verified.
|
|
46
|
+
|
|
47
|
+
Approved durable-memory selection is frozen for a prepared turn and its continuations. Changes in session, repository, runtime, model, or memory configuration invalidate that authority. A subsequent turn reads the current bounded store contents; a same-size rewrite cannot hide behind a file-size cache key. Default selection limits remain five records and 400 tokens. Experimental lexical ranking is not enabled by default.
|
|
48
|
+
|
|
49
|
+
Token counts remain estimates unless a provider has attested the relevant prefix. Flush and checkpoint success establish the filesystem durability available to the running process; they do not guarantee survival of every hardware or power failure, or exactly-once execution by a remote provider.
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
# Proactive task memory
|
|
2
2
|
|
|
3
|
+
|
|
4
|
+
After a durable context reduction, restoration uses a commit-scoped offer: stale content jobs and buffered reminders lose authority, known usage remains attributed, and restoration is consumed only after an admitted installation. See [Context continuity and recovery](context-continuity.md) for the lifecycle and its limits.
|
|
5
|
+
|
|
3
6
|
Clio's proactive task memory protects long-running work from behavioral state
|
|
4
7
|
decay: a requirement, environment fact, failed attempt, or diagnosis can still
|
|
5
8
|
exist in the transcript while no longer influencing the next action. The design
|
|
@@ -19,7 +22,7 @@ writes, model resolution, reminders, handoff offers, and handoff seeding.
|
|
|
19
22
|
| --- | --- |
|
|
20
23
|
| Inspect the bank and recent memory steps | `/memory` |
|
|
21
24
|
| Select a background model or change memory controls | `/settings` → **Context & Memory** |
|
|
22
|
-
| Review recorded cost | `/
|
|
25
|
+
| Review recorded cost | `/usage` or `clio-coder usage report` |
|
|
23
26
|
| Look up the default values and routing example | [Operator setup](#operator-setup) |
|
|
24
27
|
| Understand what survives a handoff | [Handoff continuity](#handoff-continuity) |
|
|
25
28
|
|
|
@@ -234,7 +237,7 @@ The LLM tier costs real tokens, real seconds of model time, and a request slot o
|
|
|
234
237
|
a server that is usually the same machine the operator's own turns run on.
|
|
235
238
|
|
|
236
239
|
Every step is therefore accounted for the way a `/btw` side question is: one cost
|
|
237
|
-
entry under the `background-memory` label, which `/
|
|
240
|
+
entry under the `background-memory` label, which `/usage` shows as its own
|
|
238
241
|
`memory steps` row, and one durable row in `<stateDir>/usage/out-of-turn.jsonl`
|
|
239
242
|
carrying the usage, the call's duration, and the backend's prefill facts.
|
|
240
243
|
`clio-coder usage report` folds those rows after the process exits, and `/memory`
|
|
@@ -582,7 +585,7 @@ Every exact-schema record has:
|
|
|
582
585
|
- count of cited entries, input/output/total memory-model tokens, and latency.
|
|
583
586
|
|
|
584
587
|
The same steps are also billed. See "Cost and the default decision" for the
|
|
585
|
-
`/
|
|
588
|
+
`/usage` row, the durable out-of-turn usage row, and the lifetime figures `/memory`
|
|
586
589
|
folds out of this file.
|
|
587
590
|
|
|
588
591
|
`dropped` is the one outcome that ran no step. It has two causes, separated by
|