clinkx 1.0.0 → 1.1.1
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/CHANGELOG.md +95 -0
- package/README.md +184 -112
- package/clinkx-workflows/dist/chairman-knobs.d.ts +24 -0
- package/clinkx-workflows/dist/chairman-knobs.js +27 -0
- package/clinkx-workflows/dist/chairman-knobs.js.map +1 -0
- package/clinkx-workflows/dist/clink-client.d.ts +10 -0
- package/clinkx-workflows/dist/clink-client.js +39 -1
- package/clinkx-workflows/dist/clink-client.js.map +1 -1
- package/clinkx-workflows/dist/config.d.ts +29 -1
- package/clinkx-workflows/dist/config.js +35 -2
- package/clinkx-workflows/dist/config.js.map +1 -1
- package/clinkx-workflows/dist/context-preflight.d.ts +5 -0
- package/clinkx-workflows/dist/context-preflight.js.map +1 -1
- package/clinkx-workflows/dist/council-execution-policy.d.ts +68 -0
- package/clinkx-workflows/dist/council-execution-policy.js +110 -0
- package/clinkx-workflows/dist/council-execution-policy.js.map +1 -0
- package/clinkx-workflows/dist/council-expander.d.ts +9 -8
- package/clinkx-workflows/dist/council-expander.js +18 -9
- package/clinkx-workflows/dist/council-expander.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/activity-contract.d.ts +5557 -4
- package/clinkx-workflows/dist/dashboard/activity-contract.js +55 -3
- package/clinkx-workflows/dist/dashboard/activity-contract.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/activity-reader.d.ts +9 -5
- package/clinkx-workflows/dist/dashboard/activity-reader.js +15 -2
- package/clinkx-workflows/dist/dashboard/activity-reader.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/api-routes.d.ts +4 -0
- package/clinkx-workflows/dist/dashboard/api-routes.js +133 -25
- package/clinkx-workflows/dist/dashboard/api-routes.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/context-builder-invocation-contract.d.ts +3865 -0
- package/clinkx-workflows/dist/dashboard/context-builder-invocation-contract.js +69 -0
- package/clinkx-workflows/dist/dashboard/context-builder-invocation-contract.js.map +1 -0
- package/clinkx-workflows/dist/dashboard/context-run-reader.d.ts +36 -2
- package/clinkx-workflows/dist/dashboard/context-run-reader.js +142 -19
- package/clinkx-workflows/dist/dashboard/context-run-reader.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/contracts.d.ts +20027 -480
- package/clinkx-workflows/dist/dashboard/contracts.js +133 -6
- package/clinkx-workflows/dist/dashboard/contracts.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/index.d.ts +4 -0
- package/clinkx-workflows/dist/dashboard/index.js +4 -0
- package/clinkx-workflows/dist/dashboard/index.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/invocation-contract.d.ts +786 -0
- package/clinkx-workflows/dist/dashboard/invocation-contract.js +201 -0
- package/clinkx-workflows/dist/dashboard/invocation-contract.js.map +1 -0
- package/clinkx-workflows/dist/dashboard/lazy-content.d.ts +14 -1
- package/clinkx-workflows/dist/dashboard/lazy-content.js +53 -2
- package/clinkx-workflows/dist/dashboard/lazy-content.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/native-transcript/contract.d.ts +90 -0
- package/clinkx-workflows/dist/dashboard/native-transcript/contract.js +31 -0
- package/clinkx-workflows/dist/dashboard/native-transcript/contract.js.map +1 -0
- package/clinkx-workflows/dist/dashboard/native-transcript/projection.d.ts +12 -0
- package/clinkx-workflows/dist/dashboard/native-transcript/projection.js +286 -0
- package/clinkx-workflows/dist/dashboard/native-transcript/projection.js.map +1 -0
- package/clinkx-workflows/dist/dashboard/progress-report-contract.d.ts +147 -4
- package/clinkx-workflows/dist/dashboard/progress-report-contract.js +11 -11
- package/clinkx-workflows/dist/dashboard/progress-report-contract.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/progress-report-reader.js +4 -56
- package/clinkx-workflows/dist/dashboard/progress-report-reader.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/progress-report-status-store.d.ts +2 -1
- package/clinkx-workflows/dist/dashboard/progress-report-status-store.js +6 -5
- package/clinkx-workflows/dist/dashboard/progress-report-status-store.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/prompt-builder-library-contract.d.ts +194 -0
- package/clinkx-workflows/dist/dashboard/prompt-builder-library-contract.js +89 -0
- package/clinkx-workflows/dist/dashboard/prompt-builder-library-contract.js.map +1 -0
- package/clinkx-workflows/dist/dashboard/prompt-builder-library-store.d.ts +26 -0
- package/clinkx-workflows/dist/dashboard/prompt-builder-library-store.js +102 -0
- package/clinkx-workflows/dist/dashboard/prompt-builder-library-store.js.map +1 -0
- package/clinkx-workflows/dist/dashboard/request-admission.js +4 -0
- package/clinkx-workflows/dist/dashboard/request-admission.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/scanner.d.ts +3 -0
- package/clinkx-workflows/dist/dashboard/scanner.js +52 -8
- package/clinkx-workflows/dist/dashboard/scanner.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/server-factory.d.ts +14 -1
- package/clinkx-workflows/dist/dashboard/server-factory.js +73 -21
- package/clinkx-workflows/dist/dashboard/server-factory.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/session-log-contract.d.ts +223 -56
- package/clinkx-workflows/dist/dashboard/session-log-contract.js +26 -0
- package/clinkx-workflows/dist/dashboard/session-log-contract.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/session-log-journal.js +10 -3
- package/clinkx-workflows/dist/dashboard/session-log-journal.js.map +1 -1
- package/clinkx-workflows/dist/dashboard/session-log-redaction.d.ts +9 -1
- package/clinkx-workflows/dist/dashboard/session-log-redaction.js +793 -59
- package/clinkx-workflows/dist/dashboard/session-log-redaction.js.map +1 -1
- package/clinkx-workflows/dist/dashboard-ui/assets/index-JPHQVtn9.js +106 -0
- package/clinkx-workflows/dist/dashboard-ui/assets/style-DOMHk-j6.css +1 -0
- package/clinkx-workflows/dist/dashboard-ui/index.html +2 -2
- package/clinkx-workflows/dist/delegate-finalizer-policy.d.ts +26 -0
- package/clinkx-workflows/dist/delegate-finalizer-policy.js +72 -0
- package/clinkx-workflows/dist/delegate-finalizer-policy.js.map +1 -0
- package/clinkx-workflows/dist/delegate-signature.d.ts +14 -0
- package/clinkx-workflows/dist/delegate-signature.js +14 -0
- package/clinkx-workflows/dist/delegate-signature.js.map +1 -0
- package/clinkx-workflows/dist/delegate-validate.d.ts +32 -2
- package/clinkx-workflows/dist/delegate-validate.js +51 -0
- package/clinkx-workflows/dist/delegate-validate.js.map +1 -1
- package/clinkx-workflows/dist/engine.d.ts +113 -3
- package/clinkx-workflows/dist/engine.js +476 -80
- package/clinkx-workflows/dist/engine.js.map +1 -1
- package/clinkx-workflows/dist/errors.d.ts +22 -2
- package/clinkx-workflows/dist/errors.js +30 -2
- package/clinkx-workflows/dist/errors.js.map +1 -1
- package/clinkx-workflows/dist/fidelity.d.ts +47 -1
- package/clinkx-workflows/dist/fidelity.js +54 -1
- package/clinkx-workflows/dist/fidelity.js.map +1 -1
- package/clinkx-workflows/dist/fingerprint.d.ts +24 -6
- package/clinkx-workflows/dist/fingerprint.js +32 -9
- package/clinkx-workflows/dist/fingerprint.js.map +1 -1
- package/clinkx-workflows/dist/index.js +53 -1
- package/clinkx-workflows/dist/index.js.map +1 -1
- package/clinkx-workflows/dist/logger.d.ts +1 -1
- package/clinkx-workflows/dist/logger.js +17 -3
- package/clinkx-workflows/dist/logger.js.map +1 -1
- package/clinkx-workflows/dist/monotonic-clock.d.ts +19 -0
- package/clinkx-workflows/dist/monotonic-clock.js +22 -0
- package/clinkx-workflows/dist/monotonic-clock.js.map +1 -0
- package/clinkx-workflows/dist/plan-review/contract.d.ts +52 -52
- package/clinkx-workflows/dist/plan-review/publication.d.ts +4 -4
- package/clinkx-workflows/dist/plan-review/run-state.d.ts +16 -16
- package/clinkx-workflows/dist/roster-contract.d.ts +889 -0
- package/clinkx-workflows/dist/roster-contract.js +180 -0
- package/clinkx-workflows/dist/roster-contract.js.map +1 -0
- package/clinkx-workflows/dist/rosters.d.ts +14 -0
- package/clinkx-workflows/dist/rosters.js +169 -0
- package/clinkx-workflows/dist/rosters.js.map +1 -0
- package/clinkx-workflows/dist/run-health.d.ts +7 -0
- package/clinkx-workflows/dist/run-health.js +25 -0
- package/clinkx-workflows/dist/run-health.js.map +1 -0
- package/clinkx-workflows/dist/schema.d.ts +64 -0
- package/clinkx-workflows/dist/schema.js +24 -0
- package/clinkx-workflows/dist/schema.js.map +1 -1
- package/clinkx-workflows/dist/server.js +2 -0
- package/clinkx-workflows/dist/server.js.map +1 -1
- package/clinkx-workflows/dist/shutdown.d.ts +15 -2
- package/clinkx-workflows/dist/shutdown.js +60 -16
- package/clinkx-workflows/dist/shutdown.js.map +1 -1
- package/clinkx-workflows/dist/state-schema.d.ts +23 -0
- package/clinkx-workflows/dist/state.d.ts +5 -0
- package/clinkx-workflows/dist/state.js +128 -21
- package/clinkx-workflows/dist/state.js.map +1 -1
- package/clinkx-workflows/dist/stdio-watchdog.d.ts +52 -0
- package/clinkx-workflows/dist/stdio-watchdog.js +212 -0
- package/clinkx-workflows/dist/stdio-watchdog.js.map +1 -0
- package/clinkx-workflows/dist/types.d.ts +6 -0
- package/clinkx-workflows/dist/validators/council.d.ts +50 -50
- package/clinkx-workflows/dist/validators/plan-review.d.ts +3 -3
- package/clinkx-workflows/dist/workflow-tools.d.ts +70 -0
- package/clinkx-workflows/dist/workflow-tools.js +760 -168
- package/clinkx-workflows/dist/workflow-tools.js.map +1 -1
- package/clinkx-workflows/templates/council/answer-chairman.txt +3 -0
- package/clinkx-workflows/templates/council/answer-cross-reviewer.txt +3 -0
- package/clinkx-workflows/templates/council/answer-specialist.txt +3 -0
- package/clinkx-workflows/templates/council/chairman.txt +3 -0
- package/clinkx-workflows/templates/council/code-review-chairman.txt +3 -0
- package/clinkx-workflows/templates/council/code-review-cross-reviewer.txt +3 -0
- package/clinkx-workflows/templates/council/code-review-reviewer.txt +3 -0
- package/clinkx-workflows/templates/council/debug-chairman.txt +3 -0
- package/clinkx-workflows/templates/council/debug-cross-reviewer.txt +3 -0
- package/clinkx-workflows/templates/council/debug-debugger.txt +3 -0
- package/clinkx-workflows/templates/council/discover-analyst.txt +3 -0
- package/clinkx-workflows/templates/council/discover-chairman.txt +3 -0
- package/clinkx-workflows/templates/council/discover-cross-reviewer.txt +3 -0
- package/clinkx-workflows/templates/council/member.txt +3 -0
- package/clinkx-workflows/templates/council/plan-review-chairman.txt +3 -0
- package/clinkx-workflows/templates/council/plan-review-cross-reviewer.txt +3 -0
- package/clinkx-workflows/templates/council/plan-review-reviewer.txt +3 -0
- package/clinkx-workflows/templates/council/reviewer.txt +3 -0
- package/clinkx-workflows/workflows/council-answer.yaml +3 -0
- package/clinkx-workflows/workflows/council-code-review.yaml +3 -0
- package/clinkx-workflows/workflows/council-debug.yaml +3 -0
- package/clinkx-workflows/workflows/council-default.yaml +7 -0
- package/clinkx-workflows/workflows/council-discover.yaml +3 -0
- package/clinkx-workflows/workflows/council-plan-review.yaml +3 -0
- package/conf/adapters/agy.json +9 -2
- package/conf/adapters/claude.json +7 -0
- package/conf/adapters/codex.json +7 -0
- package/conf/adapters/glm.json +19 -3
- package/conf/adapters/grok.json +9 -2
- package/conf/adapters/hapi/agy.json +9 -2
- package/conf/adapters/hapi/claude.json +7 -0
- package/conf/adapters/hapi/codex.json +7 -0
- package/conf/adapters/hapi/glm.json +20 -4
- package/conf/rosters/default-council.json +21 -0
- package/dist/activity-journal.d.ts +17 -3
- package/dist/activity-journal.js +404 -79
- package/dist/activity-journal.js.map +1 -1
- package/dist/codex/agent-tools.js +36 -0
- package/dist/codex/agent-tools.js.map +1 -1
- package/dist/codex/app-server-client.d.ts +3 -0
- package/dist/codex/app-server-client.js +11 -0
- package/dist/codex/app-server-client.js.map +1 -1
- package/dist/codex/app-server-registry.d.ts +18 -0
- package/dist/codex/app-server-registry.js +88 -2
- package/dist/codex/app-server-registry.js.map +1 -1
- package/dist/codex/client-types.d.ts +7 -1
- package/dist/codex/protocol.d.ts +4 -4
- package/dist/config.d.ts +220 -23
- package/dist/config.js +104 -1
- package/dist/config.js.map +1 -1
- package/dist/context-builder/bundle.d.ts +13 -0
- package/dist/context-builder/bundle.js +46 -0
- package/dist/context-builder/bundle.js.map +1 -1
- package/dist/context-builder/delegate-finalizer-effective.d.ts +33 -0
- package/dist/context-builder/delegate-finalizer-effective.js +82 -0
- package/dist/context-builder/delegate-finalizer-effective.js.map +1 -0
- package/dist/context-builder/delegate-packet.d.ts +18 -0
- package/dist/context-builder/delegate-packet.js +73 -9
- package/dist/context-builder/delegate-packet.js.map +1 -1
- package/dist/context-builder/delegate-reconstruction.d.ts +29 -0
- package/dist/context-builder/delegate-reconstruction.js +110 -41
- package/dist/context-builder/delegate-reconstruction.js.map +1 -1
- package/dist/context-builder/delegate-validation.d.ts +31 -0
- package/dist/context-builder/delegate-validation.js +87 -10
- package/dist/context-builder/delegate-validation.js.map +1 -1
- package/dist/context-builder/delegate.d.ts +9 -0
- package/dist/context-builder/delegate.js +210 -59
- package/dist/context-builder/delegate.js.map +1 -1
- package/dist/context-builder/diagnostics.d.ts +1 -1
- package/dist/context-builder/diagnostics.js.map +1 -1
- package/dist/context-builder/discovery-progress.d.ts +25 -0
- package/dist/context-builder/discovery-progress.js +64 -0
- package/dist/context-builder/discovery-progress.js.map +1 -0
- package/dist/context-builder/discovery-watchdog.d.ts +15 -0
- package/dist/context-builder/discovery-watchdog.js +39 -0
- package/dist/context-builder/discovery-watchdog.js.map +1 -0
- package/dist/context-builder/discovery.d.ts +7 -0
- package/dist/context-builder/discovery.js +119 -7
- package/dist/context-builder/discovery.js.map +1 -1
- package/dist/context-builder/external-gaps.d.ts +73 -0
- package/dist/context-builder/external-gaps.js +248 -0
- package/dist/context-builder/external-gaps.js.map +1 -0
- package/dist/context-builder/globs.d.ts +1 -0
- package/dist/context-builder/globs.js +15 -0
- package/dist/context-builder/globs.js.map +1 -1
- package/dist/context-builder/handler.d.ts +42 -1
- package/dist/context-builder/handler.js +690 -62
- package/dist/context-builder/handler.js.map +1 -1
- package/dist/context-builder/invocation-sidecar.d.ts +41 -0
- package/dist/context-builder/invocation-sidecar.js +189 -0
- package/dist/context-builder/invocation-sidecar.js.map +1 -0
- package/dist/context-builder/lifecycle-contract.d.ts +51 -51
- package/dist/context-builder/mutation-lock.d.ts +32 -0
- package/dist/context-builder/mutation-lock.js +321 -0
- package/dist/context-builder/mutation-lock.js.map +1 -0
- package/dist/context-builder/review-coverage.d.ts +32 -0
- package/dist/context-builder/review-coverage.js +130 -23
- package/dist/context-builder/review-coverage.js.map +1 -1
- package/dist/context-builder/schema.d.ts +76 -1
- package/dist/context-builder/schema.js +21 -1
- package/dist/context-builder/schema.js.map +1 -1
- package/dist/context-builder/secrets.d.ts +31 -0
- package/dist/context-builder/secrets.js +871 -84
- package/dist/context-builder/secrets.js.map +1 -1
- package/dist/context-builder/status.d.ts +1 -1
- package/dist/context-builder/status.js +1 -0
- package/dist/context-builder/status.js.map +1 -1
- package/dist/context-builder/storage.d.ts +29 -5
- package/dist/context-builder/storage.js +311 -236
- package/dist/context-builder/storage.js.map +1 -1
- package/dist/context-builder/versions.d.ts +19 -4
- package/dist/context-builder/versions.js +19 -4
- package/dist/context-builder/versions.js.map +1 -1
- package/dist/context-builder/workflow-runner.d.ts +6 -0
- package/dist/context-builder/workflow-runner.js +363 -173
- package/dist/context-builder/workflow-runner.js.map +1 -1
- package/dist/dashboard-adapter-catalog.js +7 -0
- package/dist/dashboard-adapter-catalog.js.map +1 -1
- package/dist/dashboard-cli.d.ts +2 -0
- package/dist/dashboard-cli.js +40 -2
- package/dist/dashboard-cli.js.map +1 -1
- package/dist/dashboard-companion/client.d.ts +1 -0
- package/dist/dashboard-companion/client.js +22 -3
- package/dist/dashboard-companion/client.js.map +1 -1
- package/dist/dashboard-companion/protocol.js +4 -1
- package/dist/dashboard-companion/protocol.js.map +1 -1
- package/dist/dashboard-gateway/index.d.ts +1 -0
- package/dist/dashboard-gateway/index.js +33 -2
- package/dist/dashboard-gateway/index.js.map +1 -1
- package/dist/handler.js +5 -1
- package/dist/handler.js.map +1 -1
- package/dist/index.d.ts +18 -1
- package/dist/index.js +145 -7
- package/dist/index.js.map +1 -1
- package/dist/logger.d.ts +1 -1
- package/dist/logger.js +18 -3
- package/dist/logger.js.map +1 -1
- package/dist/parsers/agy-stream-json.d.ts +14 -0
- package/dist/parsers/agy-stream-json.js +172 -0
- package/dist/parsers/agy-stream-json.js.map +1 -0
- package/dist/parsers/extract.js +5 -1
- package/dist/parsers/extract.js.map +1 -1
- package/dist/parsers/observed-invocation.d.ts +20 -0
- package/dist/parsers/observed-invocation.js +42 -0
- package/dist/parsers/observed-invocation.js.map +1 -0
- package/dist/pipeline.d.ts +13 -0
- package/dist/pipeline.js +60 -10
- package/dist/pipeline.js.map +1 -1
- package/dist/progress-report/lock.d.ts +74 -0
- package/dist/progress-report/lock.js +343 -0
- package/dist/progress-report/lock.js.map +1 -0
- package/dist/progress-report/schema.d.ts +808 -0
- package/dist/progress-report/schema.js +119 -0
- package/dist/progress-report/schema.js.map +1 -0
- package/dist/progress-report/store.d.ts +66 -0
- package/dist/progress-report/store.js +766 -0
- package/dist/progress-report/store.js.map +1 -0
- package/dist/progress-report/tools.d.ts +20 -0
- package/dist/progress-report/tools.js +141 -0
- package/dist/progress-report/tools.js.map +1 -0
- package/dist/prompt-mode.d.ts +1 -1
- package/dist/prompt-mode.js +7 -2
- package/dist/prompt-mode.js.map +1 -1
- package/dist/runner.d.ts +7 -0
- package/dist/runner.js +10 -3
- package/dist/runner.js.map +1 -1
- package/dist/safety.d.ts +50 -0
- package/dist/safety.js +182 -1
- package/dist/safety.js.map +1 -1
- package/dist/schema.d.ts +8 -0
- package/dist/schema.js +20 -0
- package/dist/schema.js.map +1 -1
- package/dist/server.d.ts +6 -1
- package/dist/server.js +94 -8
- package/dist/server.js.map +1 -1
- package/dist/session-log-stream.d.ts +1 -1
- package/dist/session-log-stream.js +280 -33
- package/dist/session-log-stream.js.map +1 -1
- package/dist/stdio-activity.d.ts +28 -0
- package/dist/stdio-activity.js +72 -0
- package/dist/stdio-activity.js.map +1 -0
- package/docs/configuration.md +426 -0
- package/docs/security.md +293 -0
- package/package.json +5 -5
- package/clinkx-workflows/dist/dashboard-ui/assets/index-DOkMXTfB.js +0 -25
- package/clinkx-workflows/dist/dashboard-ui/assets/style-ChJsn0KD.css +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,100 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.1.1 — 2026-10-05
|
|
4
|
+
|
|
5
|
+
### Changed
|
|
6
|
+
|
|
7
|
+
- The npm package now ships `docs/configuration.md` and `docs/security.md`, and the README is rewritten as a self-contained, install-facing page in Simplified Technical English. `package.json` `homepage` points at the npm package page and `bugs` is removed, because the source repository is private.
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- `context_builder` secret scanning (`allow_secrets:false`) on large bodies is 6-8x faster on Node 24: comment masking now returns the input string when nothing is masked, so memo lookups no longer compare a distinct but equal copy of the whole body. Output is unchanged.
|
|
12
|
+
- npm publish confirmation now waits up to about eight minutes for npm to expose the new version instead of failing after a few seconds; 1.1.0's automated publish succeeded but failed confirmation and needed a manual re-run to go green.
|
|
13
|
+
|
|
14
|
+
## 1.1.0 — 2026-10-03
|
|
15
|
+
|
|
16
|
+
### Upgrade notes
|
|
17
|
+
|
|
18
|
+
- Adapter files stay whole-file first-wins. An overlay in `~/.config/clinkx/adapters/` keeps its 1.0.0 argv and parser and does not get the shipped changes below, including `invocation_overrides` (required for per-call `model`/`effort`) and the agy stream-json parser. Re-copy from the packaged `conf/adapters/` or `conf/adapters/hapi/` to adopt them. (#26, #44)
|
|
19
|
+
- Shipped `agy` now sends the prompt on stdin without `--print` and passes `--output-format stream-json`, which needs an agy build that emits stream-json (1.1.8+). (#26, #44)
|
|
20
|
+
- Shipped `glm` and the `hapi/glm` template pin `--model glm-5.3[1m]`, Opus/Sonnet defaults `glm-5.3[1m]`, Haiku `glm-4.7`, and `CLAUDE_CODE_AUTO_COMPACT_WINDOW=1000000`. 1.0.0 used `glm-5`.
|
|
21
|
+
- A finalizer `model`, `effort`, or explicit `min_score` on an effectively disabled finalizer (`finalizer.enabled` omitted under a profile that defaults it off) is now rejected `-32602` by `run_workflow` and `context_builder` before any state or spawn. 1.0.0 accepted and ignored it. Set `finalizer.enabled:true` or drop the knob. (#52)
|
|
22
|
+
- The six `council-*` workflows default to `context_external_gap_policy: degrade`. When the finalizer reports evidence it could not obtain, the run proceeds with `context_quality:"degraded"`, health reason `context_external_gaps`, and a `## Known missing evidence` bundle block instead of failing. An explicit `cb_delegate` with `external_gap_policy:"fail"` keeps the failure. `plan-review-receipts` is unchanged. (#55)
|
|
23
|
+
- `review_deep` delegate `timeout_seconds` defaults to 300 (was 180). (#55)
|
|
24
|
+
- Context-builder default excludes add `.worktrees/**` and vendor trees (`Pods`, `.cxx`, `.gradle`, `DerivedData`). `exclude_globs:[]` / `cb_exclude_globs:[]` cannot remove them. (#45, #55)
|
|
25
|
+
- The workflow context cache (`wfctx-*`) goes cold once: the delegate prompt and discovery algorithm versions changed. (#55)
|
|
26
|
+
- Drain, finish, or abandon unfinished resumable workflow runs before upgrading. Child-config fingerprints now cover override declarations and the enabled curator/finalizer adapters, and shipped adapter JSON changed, so resume across the upgrade can be rejected. Runs that do resume replay their persisted snapshot and keep external-gap policy `fail`. (#26, #55)
|
|
27
|
+
- `progress_report_start`, `progress_report_update`, `progress_report_get`, and `progress_report_list` are always advertised. (#51)
|
|
28
|
+
- New flags, off by default. Only exact `true` enables `CLINKX_INVOCATION_AUDIT_V2_PERSISTENCE_ENABLED`, `CLINKX_OBSERVED_INVOCATION_PERSISTENCE_ENABLED`, and `CLINKX_SESSION_LOG_TOOL_ARGUMENTS_PERSISTENCE_ENABLED`; `CLINKX_SERVER_IDLE_TIMEOUT_SECONDS` defaults to `0`. Readers always accept the new formats, so enable writers only once every dashboard reading the same state runs 1.1.0. With the audit flag off, the dashboard shows model/effort as not recorded. (#24, #28, #40, #57)
|
|
29
|
+
- New runtime dependency: `@letta-ai/trajectory`, pinned to `0.4.3`. (#57)
|
|
30
|
+
|
|
31
|
+
### Added
|
|
32
|
+
|
|
33
|
+
- Per-call `model` and `effort` on `clink`, generic workflow calls, council `members[]`, `chairman_model` / `chairman_effort`, and the `context_builder` / `cb_delegate` curator and finalizer, when the resolved adapter declares `invocation_overrides`. Every shipped subprocess adapter declares both; Codex effort renders as `-c model_reasoning_effort=<value>`. Unsupported values fail `-32602` before spawn. `plan-review-receipts`, the Codex app-server tools, and Elaris are unchanged. (#26)
|
|
34
|
+
- Invocation evidence: a pre-dispatch audit (requested value, applied value, provenance) for workflow calls, direct `clink` activity, and context curator/finalizer calls, plus the model/effort a child reports (Claude `system/init`, app-server `thread/start`). The dashboard shows both in the call inspector and on run-detail stage rows. Persistence is behind the flags above. (#28, #40, #53)
|
|
35
|
+
- `run_workflow.roster`: named council presets carrying members, chairman, and the context delegate. Discovery is first-wins across `CLINKX_ROSTERS_PATH`, `${XDG_CONFIG_HOME:-~/.config}/clinkx/rosters/`, and built-in `conf/rosters/` (ships `default-council`). A roster cannot be combined with `members`, `chairman`, `chairman_model`, `chairman_effort`, or a non-empty `cb_delegate`. (#52)
|
|
36
|
+
- `list_workflows` adds `available_clis` (per-adapter model/effort support) and `available_rosters`. Council runs report `resolved_roster` on the async ack, the sync result, and `workflow_run_status`. (#52)
|
|
37
|
+
- `workflow_run_status` adds `context.delegate.finalizer` `{effective_enabled, execution_status, score?}` and, while preflight is still scanning, a top-level `context_progress` block. (#52)
|
|
38
|
+
- Progress-report tools `progress_report_start` / `_update` / `_get` / `_list`: patch-only writes, `expected_revision` compare-and-swap, `request_id` replay, server-owned ids and timestamps. Reports live under `<state dir>/progress-reports/` and show on the dashboard. (#51)
|
|
39
|
+
- Delegate `external_gap_policy: "fail" | "degrade"` (default `fail`) on `context_builder` and `cb_delegate`. Finalizer-reported `external_gaps` are classified; rejected gaps fail under either policy, accepted ones carry provenance. (#55)
|
|
40
|
+
- `CLINKX_SERVER_IDLE_TIMEOUT_SECONDS`: opt-in idle lifetime for both STDIO servers. Active tools, workflows, Codex turns, and response delivery hold it off. (#24)
|
|
41
|
+
- Dashboard: prompt builder at `/prompt-builder` for `run_workflow` and chief-of-staff prompts, validated against live adapter capabilities. Its library persists in a private `prompt-builder-library.json` sidecar. Copy is its only action.
|
|
42
|
+
- Dashboard: `CLINKX_WORKFLOWS_DASHBOARD_AUTH_MODE=none` for loopback-only testing. Host and origin checks stay enforced; remote and gateway modes reject it. (#47)
|
|
43
|
+
- Dashboard: session-log conversations tail in place. Tool rows can show bounded, redacted tool arguments when `CLINKX_SESSION_LOG_TOOL_ARGUMENTS_PERSISTENCE_ENABLED=true`, and Find searches them. (#57)
|
|
44
|
+
- Dashboard: `CLINKX_WORKFLOWS_PROGRESS_REPORT_OVERRIDE_DIR` moves the status-pin sidecar off a read-only state directory.
|
|
45
|
+
- Automatic npm publishing after main CI passes. A PR that bumps the root
|
|
46
|
+
version (stable, ahead of the base and npm `latest`, with `CHANGELOG.md` in the
|
|
47
|
+
same diff) releases on merge; PRs and main pushes that leave the version
|
|
48
|
+
unchanged never publish or read the registry and ship with the next bump. A
|
|
49
|
+
failed or incomplete publication is recovered only by a manual run on main,
|
|
50
|
+
which rebuilds from current main and publishes that source under the version
|
|
51
|
+
if it is still unpublished. One tarball is verified across the Node matrix
|
|
52
|
+
and published with OIDC, a single `npm publish` write, bounded registry
|
|
53
|
+
reconciliation, and no rebuild in the publisher. The publisher parses the tarball itself instead of using system
|
|
54
|
+
`tar`, accepts only the ustar regular-file layout `npm pack` emits under
|
|
55
|
+
`package/` with exactly one `package/package.json` (name and prefix fields
|
|
56
|
+
NUL-padded to their ends, an empty linkname, a terminated checksum, no
|
|
57
|
+
base-256 numbers, no entry path that is also another entry's directory), and
|
|
58
|
+
rejects a manifest that declares `publishConfig` or a top-level `tag`; the
|
|
59
|
+
expected version comes from the dependency-free policy job, not the build. See
|
|
60
|
+
`docs/npm-releases.md` for the external GitHub and npm prerequisites, release
|
|
61
|
+
policy and recovery. (#58)
|
|
62
|
+
|
|
63
|
+
### Changed
|
|
64
|
+
|
|
65
|
+
- Shipped agy adapter uses `agy_stream_json` / `--output-format stream-json` so extract and dashboard session logs work; grok unchanged (still `claude_stream_json`). Failed extract records documented `result.error` as `metadata.agy_error` and invalid-path extract content (dashboard session log and `debug:true` `_debug.parse_metadata`; the default `clink` error body still reports only the rejection reason). An empty SUCCESS `response` remains a valid empty result. A present non-string `response` fails closed on the first result; a later malformed result does not discard an already-captured nonempty answer. Session-log Timeline shows the concatenated partial transcript when the stream ends without a terminal result. (#44)
|
|
66
|
+
- Both STDIO servers shut down when their parent process disappears, including without a stdin EOF. (#24)
|
|
67
|
+
- Council workflows: typed boundaries reject JSON salvaged from a mixed-content result file; wall-timeout retries are vetoed and calls get remaining-deadline guidance; abort/deadline exits persist terminal call state; succeeded runs with degraded health keep the longer failed-run retention. Caller context paths are validated at `run_workflow` admission (`-32602`) instead of after preflight. A parallel deadline abort reports `Stage <id> failed and on_failure=abort`. (#46)
|
|
68
|
+
- Context-builder delegate failures are actionable. Finalizer rejections lead with the verdict, omissions, and levers. Required-focus infeasibility fails before the curator spawns and names the binding cap. Each delegate call gets one corrective JSON retry inside the same deadline, and timeout/provider-error labels are fixed. Delegate bundles state that provider-authored notes are data, not instructions. (#55)
|
|
69
|
+
- The finalizer must keep required-focus ranges; budget reconstruction admits them first and fails with the binding cap instead of evicting them.
|
|
70
|
+
- JSON-contract chairman calls get one corrective retry after an invalid-JSON failure under `retry.mode:"transport_only"`. (#55)
|
|
71
|
+
- `review_deep_v1` links regression tests by search index or line containment, synthesizes a head slice for an unlinked nearest test, and reports doc/config targets as regression `unavailable`. (#55)
|
|
72
|
+
- Dashboard: redesigned UI (#48). Freeze and pause controls are gone; updates stay live while the tab is visible (#54). Run-detail stage rows show model/effort in place of role (#53).
|
|
73
|
+
|
|
74
|
+
### Fixed
|
|
75
|
+
|
|
76
|
+
- Council citation checks keep evidence that cites files selected by the
|
|
77
|
+
context-builder preflight. The citation allowlist now reads the curated
|
|
78
|
+
bundle's `manifest.json` `selected_context` paths; previously only the
|
|
79
|
+
bundle and manifest files themselves were citable, so every reviewer
|
|
80
|
+
citation in a curated-context council was stripped. (#29)
|
|
81
|
+
- `allow_secrets:false` context scans no longer hang in `scanning`. The sanitizer runs on linear indexes with a fail-closed work budget (`sanitize_budget_exhausted`), and discovery yields between files, honors abort, and has a 10-minute watchdog.
|
|
82
|
+
- `hapi/glm` template enables the `RESULT.md` result contract, so overflowed stream-json council seats still extract. (#25)
|
|
83
|
+
- Resume-preflight failures keep `failureClass:"transient"`, and resume preserves the run's original `startedAt`. (#46)
|
|
84
|
+
- Session-log redaction covers credential headers of any scheme, cookies, URL userinfo, vendor tokens, JWTs, escaped embedded JSON, and credential flags; prose apostrophes no longer open a false shell quote. The producer backlog is bounded, and size loss is reported separately from redaction. (#57)
|
|
85
|
+
- Dashboard: stale detail or errors from an earlier request no longer overwrite a newer selection (#45). The gateway reclaims a companion slot held by a dead socket instead of returning 409.
|
|
86
|
+
|
|
87
|
+
### Docs
|
|
88
|
+
|
|
89
|
+
- Deslop/unslop delivery evaluation report, with a 2026-09-27 revision. The
|
|
90
|
+
skill it evaluated now lives in the agent-skills repository and is not
|
|
91
|
+
shipped in this package. (#29)
|
|
92
|
+
- `clinkx-workflows` README no longer claims side-effecting workflows are
|
|
93
|
+
rejected at load time; `validateNoSideEffects` is an empty placeholder. (#29)
|
|
94
|
+
- `docs/configuration.md` documents the GLM 1M pin, STDIO server lifetime,
|
|
95
|
+
and per-call override templates (#24, #26). README documents roster
|
|
96
|
+
presets (#52).
|
|
97
|
+
|
|
3
98
|
## 1.0.0 — 2026-08-17
|
|
4
99
|
|
|
5
100
|
First npm release of the work that landed after `0.3.0`. The previous registry `latest` is still `clinkx@0.3.0` (published 2026-06-15).
|
package/README.md
CHANGED
|
@@ -1,121 +1,114 @@
|
|
|
1
1
|
# ClinkX
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
ClinkX is an MCP server that connects your AI coding assistant to other command-line AI agents. It runs Codex, Claude Code, agy, GLM, or Grok as child processes and returns their output as MCP tool results. You can send one task to one agent. You can run a council of many agents on one question. You can also build a context bundle for a later task.
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
- `context_builder` writes a persisted context bundle from allowed local roots. Selection is deterministic by default. You can also run explicit curator and finalizer adapters, then the server validates and materializes locally.
|
|
7
|
-
- `list_workflows`, `resume_workflow`, and `run_workflow` run multi-stage workflows.
|
|
5
|
+
ClinkX uses MCP over STDIO. It works with any MCP client that can start a local command.
|
|
8
6
|
|
|
9
|
-
|
|
7
|
+
## Requirements
|
|
10
8
|
|
|
11
|
-
|
|
9
|
+
- Node.js 24.0.0 or later.
|
|
10
|
+
- At least one of these command-line tools on your `PATH`: `codex`, `claude`, `agy`, or `grok`. The `glm` adapter also uses the `claude` command.
|
|
11
|
+
- The `codex` command, if you run workflows. Workflows use Codex to select repository context before the first stage. See [Workflows](#workflows) for the opt-out switch.
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
## Installation
|
|
14
14
|
|
|
15
|
-
|
|
16
|
-
npm install
|
|
17
|
-
npm run build:all
|
|
18
|
-
node dist/index.js
|
|
19
|
-
```
|
|
15
|
+
Add ClinkX to the MCP server list of your client. The exact file and format depend on the client. This is the common JSON shape:
|
|
20
16
|
|
|
21
|
-
|
|
17
|
+
```json
|
|
18
|
+
{
|
|
19
|
+
"mcpServers": {
|
|
20
|
+
"clinkx": {
|
|
21
|
+
"command": "npx",
|
|
22
|
+
"args": ["-y", "clinkx@latest"],
|
|
23
|
+
"env": {
|
|
24
|
+
"CLINKX_ALLOWED_ROOTS": "/path/to/your/workspace",
|
|
25
|
+
"CLINKX_WORKFLOWS_WORKSPACE_ROOT": "/path/to/your/workspace"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
```
|
|
22
31
|
|
|
23
|
-
|
|
32
|
+
Set the two paths to the directory that tool calls can reference. Use absolute paths.
|
|
24
33
|
|
|
25
|
-
|
|
34
|
+
To install ClinkX globally, run this command. Then set `"command": "clinkx"` with no `args`:
|
|
26
35
|
|
|
27
36
|
```bash
|
|
28
|
-
|
|
37
|
+
npm install -g clinkx
|
|
29
38
|
```
|
|
30
39
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
Screens: Runs, Single Calls, Context Runs, Workflows, Adapters, Artifacts. They show retained workflow state, direct-call lifecycle, standalone/refine context-builder lifecycle, persisted pre-dispatch workflow input, final outputs and errors, validated JSON artifacts, and the launch-time workflow/adapter catalogs. Runs, Single Calls, and Context Runs have their own path routes. The persisted-call inspector is an overlay that still shows up as a nested route in history.
|
|
34
|
-
|
|
35
|
-
Workflow-call, activity, and context-run detail pages also have local session logs (observability only). Timeline and Conversation are chronological; order comes from the log sequence. Each lane is fenced to one immutable parent generation (run, activity, or context) plus the matching attempt, turn, or curator/finalizer execution. Pages are at most 500 events. A lane stops at 100,000 events. Events are normalized and pattern-redacted. They are not raw provider payloads, a session browser, or a live tail.
|
|
36
|
-
|
|
37
|
-
The dashboard has no SSE, filesystem watch, worker-health inference, cross-process cancellation, or run-creation form. Session logs cannot replay, approve, cancel, or otherwise control a run. Copied action objects are MCP tool handoffs, not JSON-RPC requests.
|
|
38
|
-
|
|
39
|
-
Point the dashboard at the same `CLINKX_WORKFLOWS_STATE_DIR` as the workflow process or you will see a different (often empty) run set. Successful sync and async runs are kept for one day by default so you can inspect them. `CLINKX_WORKFLOWS_RETAIN_SUCCEEDED_DAYS=0` or `CLINKX_WORKFLOWS_RETAIN_ASYNC_DAYS=0` means keep that class forever, which can fill the disk.
|
|
40
|
-
|
|
41
|
-
Workflow and activity session logs follow retention of that exact parent generation. Context session logs follow the parent context-run/manual lifecycle. There is no separate context-run pruner yet.
|
|
42
|
-
|
|
43
|
-
Persisted inputs, outputs, errors, and artifact bytes can be sensitive. Access is loopback-only and passkey-gated. That is a shared-account boundary, not isolation from other processes as the same OS user. Redaction strips high-confidence credentials and user-home paths before write. Prompts, outputs, tool summaries, and reasoning can still be sensitive after that. Per-run state admission defaults to 16 MiB (configurable 1–64 MiB via `CLINKX_WORKFLOWS_DASHBOARD_MAX_STATE_BYTES`). Raw result/call reads use smaller fixed caps.
|
|
44
|
-
|
|
45
|
-
For local Docker, `compose.dashboard-local.yml` runs the real UI + API over plain HTTP. Caddy publishes on `127.0.0.1` and `::1`. The browser uses `http://localhost:<port>`. Caddy shares the dashboard network namespace and proxies IPv4 to Node at `127.0.0.1:4180`. The same Node process also listens on `::1:4180`. See `docs/dashboard-local-compose.md`.
|
|
40
|
+
Restart your MCP client after you change its configuration. To control when upgrades happen, replace `clinkx@latest` with a fixed version.
|
|
46
41
|
|
|
47
|
-
|
|
42
|
+
## First call
|
|
48
43
|
|
|
49
|
-
|
|
44
|
+
Ask your assistant to use the `clink` tool. This is the smallest valid request:
|
|
50
45
|
|
|
51
|
-
```
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
46
|
+
```json
|
|
47
|
+
{
|
|
48
|
+
"cli_name": "codex",
|
|
49
|
+
"prompt": "Summarize the module boundaries in this project. Do not edit files.",
|
|
50
|
+
"absolute_file_paths": ["/path/to/your/workspace/src/server.ts"]
|
|
51
|
+
}
|
|
55
52
|
```
|
|
56
53
|
|
|
57
|
-
|
|
54
|
+
ClinkX starts the Codex CLI, sends the prompt and the file references, and returns the final answer. You can run many `clink` calls at the same time, up to the concurrency limit.
|
|
58
55
|
|
|
59
|
-
##
|
|
56
|
+
## Tools
|
|
60
57
|
|
|
61
|
-
|
|
58
|
+
| Tool | Function |
|
|
59
|
+
|---|---|
|
|
60
|
+
| `clink` | Runs one task on one configured CLI and returns the result. |
|
|
61
|
+
| `context_builder` | Selects a bounded set of files from permitted roots and writes a reusable context bundle to disk. |
|
|
62
|
+
| `refine_context_run` | Makes a new bundle from an earlier one. You can add, remove, promote, or demote files, or set their slices. |
|
|
63
|
+
| `list_workflows` | Lists the available workflows, CLIs, and roster presets. |
|
|
64
|
+
| `run_workflow` | Starts a multi-stage workflow. Runs in blocking mode by default, or in the background with `async: true`. |
|
|
65
|
+
| `workflow_run_status` | Reports the progress and result of a workflow run. |
|
|
66
|
+
| `resume_workflow` | Continues a workflow run that stopped before completion. |
|
|
67
|
+
| `cancel_workflow` | Cancels a workflow run. |
|
|
68
|
+
| `progress_report_start`, `progress_report_update`, `progress_report_get`, `progress_report_list` | Keep a live progress report that the dashboard shows. |
|
|
62
69
|
|
|
63
|
-
|
|
64
|
-
2. `${XDG_CONFIG_HOME:-~/.config}/clinkx/adapters/*.json`. First-wins on `name`.
|
|
65
|
-
3. Packaged `conf/adapters/*.json` next to the installed package (`import.meta.url`). Not `process.cwd()`.
|
|
70
|
+
Two more tool groups are off by default:
|
|
66
71
|
|
|
67
|
-
|
|
72
|
+
- `clink_agent_run` and `clink_agent_manage` control a stateful Codex app-server session with approvals. Set `CLINKX_APP_SERVER_ENABLED=true` to publish them.
|
|
73
|
+
- `clink_elaris_run` and `clink_elaris_manage` start remote Elaris agent sessions over HTTPS. Set `CLINKX_ELARIS_ENABLED=true` and the Elaris connection variables to publish them.
|
|
68
74
|
|
|
69
|
-
|
|
75
|
+
Each tool publishes its full input schema through MCP. MCP clients can show the schema with the tool description.
|
|
70
76
|
|
|
71
|
-
|
|
72
|
-
|---|---|
|
|
73
|
-
| `CLINKX_WORKFLOWS_DASHBOARD_CREDENTIAL_DIR` | Optional absolute, non-root credential directory. Host default: `${CLINKX_WORKFLOWS_STATE_DIR}/dashboard/webauthn`. Compose pins the writable `/data/dashboard-credentials` volume. |
|
|
74
|
-
| `DASHBOARD_DEPLOYMENT_SLUG` | Required Compose identity, `^[a-z][a-z0-9-]{0,31}$`. Local and cloud names keep distinct stack-kind prefixes. |
|
|
75
|
-
| `DASHBOARD_CREDENTIAL_BOOTSTRAP_MODE` | Required Compose state assertion. First start is `bootstrap`. Flip to `existing-enrolled` right after enrollment, before restart. |
|
|
77
|
+
## Supported CLIs
|
|
76
78
|
|
|
77
|
-
|
|
79
|
+
An adapter file tells ClinkX how to start one CLI, how to pass the prompt, and how to read the output. These adapters are included:
|
|
78
80
|
|
|
79
|
-
|
|
81
|
+
| `cli_name` | Command (short form) | Notes |
|
|
82
|
+
|---|---|---|
|
|
83
|
+
| `codex` | `codex exec --json` | Default curator and finalizer for workflow context. |
|
|
84
|
+
| `claude` | `claude -p --output-format stream-json` | |
|
|
85
|
+
| `agy` | `agy --output-format stream-json` | Use an agy build that emits stream-json (1.1.8 or later). |
|
|
86
|
+
| `glm` | `claude -p ... --model glm-5.3[1m]` | Runs GLM through the Claude Code CLI. |
|
|
87
|
+
| `grok` | `grok --output-format streaming-messages-json` | |
|
|
80
88
|
|
|
81
|
-
|
|
89
|
+
All included adapters accept the optional `model` and `effort` fields on each call:
|
|
82
90
|
|
|
83
|
-
|
|
91
|
+
```json
|
|
92
|
+
{ "cli_name": "codex", "prompt": "...", "model": "gpt-5.4", "effort": "low" }
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
If you omit a field, ClinkX uses the adapter setting or the CLI default. If the adapter does not declare the field or the value, ClinkX returns MCP error `-32602` and does not start the process.
|
|
84
96
|
|
|
85
|
-
|
|
97
|
+
The `conf/adapters/hapi/` directory in the package holds optional templates that start each CLI through a `hapi` gateway. These templates are not ready to use. You must set the gateway URL and credentials in your copy.
|
|
86
98
|
|
|
87
|
-
|
|
99
|
+
## Configuration
|
|
88
100
|
|
|
89
|
-
|
|
101
|
+
### Adapter files
|
|
90
102
|
|
|
91
|
-
|
|
92
|
-
{
|
|
93
|
-
"task": "Collect context for the server tool registration",
|
|
94
|
-
"roots": ["/path/to/workspace"],
|
|
95
|
-
"focus_paths": ["src/server.ts"],
|
|
96
|
-
"delegate": {
|
|
97
|
-
"enabled": true,
|
|
98
|
-
"curator": {
|
|
99
|
-
"cli_name": "<curator-cli>",
|
|
100
|
-
"role": "<curator-role>"
|
|
101
|
-
},
|
|
102
|
-
"finalizer": {
|
|
103
|
-
"cli_name": "<finalizer-cli>",
|
|
104
|
-
"role": "<finalizer-role>",
|
|
105
|
-
"min_score": 8.5
|
|
106
|
-
},
|
|
107
|
-
"failure_policy": "fallback",
|
|
108
|
-
"timeout_seconds": 120,
|
|
109
|
-
"max_response_chars": 20000
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
```
|
|
103
|
+
ClinkX reads adapter JSON files from these locations, in this order. ClinkX uses the first file with a given `name`.
|
|
113
104
|
|
|
114
|
-
|
|
105
|
+
1. `CLINKX_CONFIG_PATH`, a file or a directory. When you set it, ClinkX reads only this location and does not load the included adapters. The location must also contain a `codex` adapter with a `json` role, or you must set `CLINKX_WORKFLOWS_CONTEXT_PREFLIGHT_ENABLED=false`.
|
|
106
|
+
2. `${XDG_CONFIG_HOME:-~/.config}/clinkx/adapters/*.json`.
|
|
107
|
+
3. The `conf/adapters/` directory inside the installed package.
|
|
115
108
|
|
|
116
|
-
|
|
109
|
+
To change an included adapter, copy its file to `~/.config/clinkx/adapters/` and edit the copy. The copy replaces the included file completely. ClinkX does not merge the two files. After you upgrade ClinkX, compare your copy with the new included file. Copy the new file again if necessary.
|
|
117
110
|
|
|
118
|
-
|
|
111
|
+
To add a CLI that is not included, write a new file in the same directory. This example adapter returns the prompt unchanged:
|
|
119
112
|
|
|
120
113
|
```json
|
|
121
114
|
{
|
|
@@ -128,56 +121,135 @@ Put the JSON in `${XDG_CONFIG_HOME:-~/.config}/clinkx/adapters/`. Or set `CLINKX
|
|
|
128
121
|
}
|
|
129
122
|
```
|
|
130
123
|
|
|
131
|
-
|
|
124
|
+
### Environment variables
|
|
125
|
+
|
|
126
|
+
These are the variables that most installations set. Every variable has a default.
|
|
127
|
+
|
|
128
|
+
| Variable | Default | Function |
|
|
129
|
+
|---|---|---|
|
|
130
|
+
| `CLINKX_ALLOWED_ROOTS` | Current directory of the server process | Comma-separated list of directories that tool calls can reference. Set it so path checks do not depend on the directory in which the client starts ClinkX. |
|
|
131
|
+
| `CLINKX_WORKFLOWS_WORKSPACE_ROOT` | Current directory of the server process | Workspace for workflows. Set it to the same directory as the allowed root. |
|
|
132
|
+
| `CLINKX_WORKFLOWS_STATE_DIR` | `${XDG_STATE_HOME:-~/.local/state}/clinkx-workflows` | Directory for workflow runs, progress reports, and dashboard state. |
|
|
133
|
+
| `CLINKX_CONTEXT_BUILDER_RUNS_DIR` | `${XDG_STATE_HOME:-~/.local/state}/clinkx/context-builder/runs` | Directory for `context_builder` runs and bundles. |
|
|
134
|
+
| `CLINKX_CONFIG_PATH` | not set | Replaces the adapter search path. See [Adapter files](#adapter-files). |
|
|
135
|
+
| `CLINKX_ROSTERS_PATH` | not set | Replaces the roster-preset search path. See [Workflows](#workflows). |
|
|
136
|
+
| `CLINKX_MAX_CONCURRENT` | `5` | Maximum number of `clink` processes at one time. ClinkX returns an error when the limit is reached. It does not queue requests. |
|
|
137
|
+
| `CLINKX_TIMEOUT_SECONDS` | `600` | Default time limit for one child process. |
|
|
138
|
+
| `CLINKX_MAX_RESPONSE_CHARS` | `20000` | Maximum number of characters in one tool result. |
|
|
139
|
+
| `CLINKX_LOG_LEVEL` | `info` | Log level. Logs go to stderr. |
|
|
140
|
+
| `CLINKX_CONTEXT_ALLOW_SECRETS` | `true` | When `true`, `context_builder` copies secret material into bundles as written. See [Safety](#safety). |
|
|
141
|
+
| `CLINKX_WORKFLOWS_CONTEXT_PREFLIGHT_ENABLED` | `true` | Set to `false` to run workflows without the Codex context step. |
|
|
142
|
+
| `CLINKX_WORKFLOWS_RETAIN_SUCCEEDED_DAYS` | `1` | Days to keep completed blocking workflow runs on disk. `0` keeps them without limit. |
|
|
143
|
+
| `CLINKX_WORKFLOWS_RETAIN_ASYNC_DAYS` | `1` | Days to keep completed background workflow runs on disk. `0` keeps them without limit. |
|
|
144
|
+
| `CLINKX_SERVER_IDLE_TIMEOUT_SECONDS` | `0` | Seconds of inactivity after which the server exits. `0` disables the timer. Active tool calls, workflows, and Codex turns reset it. |
|
|
145
|
+
| `CLINKX_APP_SERVER_ENABLED` | `false` | Set to `true` to publish the Codex app-server tools. |
|
|
146
|
+
| `CLINKX_ELARIS_ENABLED` | `false` | Set to `true` to publish the Elaris tools. |
|
|
147
|
+
|
|
148
|
+
ClinkX writes only MCP JSON-RPC to stdout. All logs go to stderr. The server detects the exit of its parent process and stops.
|
|
149
|
+
|
|
150
|
+
## Workflows
|
|
151
|
+
|
|
152
|
+
A workflow runs many CLI calls in stages and returns one result. A council workflow asks each member for an independent answer. The members then review each other. A chairman writes the final answer. These workflows are included:
|
|
153
|
+
|
|
154
|
+
| Workflow | Purpose |
|
|
155
|
+
|---|---|
|
|
156
|
+
| `council-answer` | Answer one hard question. |
|
|
157
|
+
| `council-code-review` | Review a change set. |
|
|
158
|
+
| `council-debug` | Find the cause of a defect. |
|
|
159
|
+
| `council-discover` | Inspect a codebase or a design space. |
|
|
160
|
+
| `council-plan-review` | Review a plan document. |
|
|
161
|
+
| `council-default` | General-purpose council. |
|
|
162
|
+
| `plan-review-receipts` | Typed plan review that returns receipt candidates for an external approval process. |
|
|
132
163
|
|
|
133
|
-
The
|
|
164
|
+
Before the first stage, the workflow runs `context_builder` with Codex as curator and finalizer. This step selects the repository files that the members receive. The `codex` command must be on your `PATH`. To skip this step, set `CLINKX_WORKFLOWS_CONTEXT_PREFLIGHT_ENABLED=false`.
|
|
134
165
|
|
|
135
|
-
|
|
166
|
+
### Roster presets
|
|
167
|
+
|
|
168
|
+
A roster preset names the members, the chairman, and the context delegate of a council in one file. Pass the preset name as `roster` in place of `members`, `chairman`, and `cb_delegate`:
|
|
136
169
|
|
|
137
170
|
```json
|
|
138
171
|
{
|
|
139
|
-
"
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
"args": ["-y", "clinkx@latest"],
|
|
143
|
-
"env": {
|
|
144
|
-
"CLINKX_ALLOWED_ROOTS": "/path/to/your/workspace",
|
|
145
|
-
"CLINKX_WORKFLOWS_WORKSPACE_ROOT": "/path/to/your/workspace"
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
}
|
|
172
|
+
"workflow": "council-default",
|
|
173
|
+
"roster": "default-council",
|
|
174
|
+
"variables": { "user_request": "Compare the three approaches and pick one." }
|
|
149
175
|
}
|
|
150
176
|
```
|
|
151
177
|
|
|
152
|
-
|
|
178
|
+
The included `default-council` preset uses Codex, Claude, and GLM as members and Codex as chairman. ClinkX reads these locations in this order and uses the first file with a given name:
|
|
179
|
+
|
|
180
|
+
1. `CLINKX_ROSTERS_PATH`, a file or a directory. When you set it, ClinkX reads only this location.
|
|
181
|
+
2. `${XDG_CONFIG_HOME:-~/.config}/clinkx/rosters/*.json`.
|
|
182
|
+
3. The `conf/rosters/` directory inside the installed package.
|
|
183
|
+
|
|
184
|
+
To write your own preset, copy `conf/rosters/default-council.json` to `~/.config/clinkx/rosters/<name>.json` and edit the copy. The file name is the preset name. The preset name must match `^[a-z0-9][a-z0-9_-]{0,63}$`. A request that gives `roster` together with `members`, `chairman`, `chairman_model`, `chairman_effort`, or a non-empty `cb_delegate` returns error `-32602` and starts no run.
|
|
185
|
+
|
|
186
|
+
### Background runs
|
|
187
|
+
|
|
188
|
+
Pass `async: true` to `run_workflow` to get a `run_id` immediately. Call `workflow_run_status` with that `run_id` to see the stage progress. Pass `include_result: true` to get the final result. Use `cancel_workflow` to stop a run. Completed runs stay on disk for the retention period given above.
|
|
189
|
+
|
|
190
|
+
## Context bundles
|
|
191
|
+
|
|
192
|
+
Use `context_builder` when a later call needs a selected part of the repository. Then the first tool result does not contain that content. You must give at least one anchor: a `focus_paths` entry or a non-blank `search_terms` entry.
|
|
153
193
|
|
|
154
194
|
```json
|
|
155
195
|
{
|
|
156
|
-
"
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
"env": {
|
|
161
|
-
"CLINKX_ALLOWED_ROOTS": "/path/to/your/workspace",
|
|
162
|
-
"CLINKX_WORKFLOWS_WORKSPACE_ROOT": "/path/to/your/workspace"
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
}
|
|
196
|
+
"task": "Collect context for the server tool registration",
|
|
197
|
+
"roots": ["/path/to/your/workspace"],
|
|
198
|
+
"focus_paths": ["src/server.ts"],
|
|
199
|
+
"search_terms": ["ListToolsRequestSchema"]
|
|
166
200
|
}
|
|
167
201
|
```
|
|
168
202
|
|
|
203
|
+
The tool writes the bundle to the context-runs directory and returns a short JSON receipt. The receipt contains `recommended_clink.absolute_file_paths`. Pass that list as `absolute_file_paths` on the next `clink` call.
|
|
204
|
+
|
|
205
|
+
By default the selection is deterministic. You can also set `delegate.enabled: true` and name a curator and a finalizer CLI. The curator makes a selection and the finalizer scores it. ClinkX checks the selection and rebuilds the bundle from local files. It applies the budgets again and writes only content that it checked itself. Provider output is an input that ClinkX checks, not a result.
|
|
206
|
+
|
|
207
|
+
## Dashboard
|
|
208
|
+
|
|
209
|
+
The package includes a local, read-only web dashboard. It shows workflow runs, single calls, context runs, progress reports, the workflow catalog, the adapter catalog, and the saved artifacts. Start it with the second command that the package installs:
|
|
210
|
+
|
|
211
|
+
```bash
|
|
212
|
+
npx -p clinkx clinkx-workflows-dashboard --port 4180
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
The dashboard listens on `127.0.0.1` and `::1` and prints `http://localhost:<port>`. Passkey sign-in is the default. On the first start, the dashboard prints one enrollment code. Register a passkey with that code, then sign in. For local tests only, `CLINKX_WORKFLOWS_DASHBOARD_AUTH_MODE=none` disables sign-in.
|
|
216
|
+
|
|
217
|
+
Point the dashboard at the same `CLINKX_WORKFLOWS_STATE_DIR` as the ClinkX server. If the two directories differ, the dashboard shows a different run set, often an empty one. If you set `CLINKX_CONTEXT_BUILDER_RUNS_DIR` for the server, set the same value for the dashboard.
|
|
218
|
+
|
|
219
|
+
The dashboard does not start, cancel, or approve anything. The data that it shows can contain prompts, outputs, and file contents from your workspace. Access is local and needs a passkey, but any process that runs as the same OS user can read the state directory.
|
|
220
|
+
|
|
169
221
|
## Safety
|
|
170
222
|
|
|
171
|
-
ClinkX
|
|
223
|
+
ClinkX checks request paths and passes only a small set of environment variables to the child process. It does not sandbox the child process.
|
|
224
|
+
|
|
225
|
+
**WARNING: A child process has the same permissions as the user who started ClinkX.** The included adapters start each CLI with no sandbox and with approval prompts turned off or set to accept file edits. The child process can edit and delete files in your workspace and can run commands. Give each prompt clear limits. Do not run ClinkX as root or as an administrator.
|
|
226
|
+
|
|
227
|
+
**WARNING: `context_builder` copies secrets by default.** The default is `allow_secrets: true`. With this default, ClinkX copies API keys, private keys, tokens, and files such as `.env` and `id_rsa` into bundles. The CLIs that receive the bundle also receive the secrets. To make ClinkX omit or redact common secret forms, set one of these:
|
|
228
|
+
|
|
229
|
+
- `allow_secrets: false` on the `context_builder` call.
|
|
230
|
+
- `cb_allow_secrets: false` on the `run_workflow` call.
|
|
231
|
+
- `CLINKX_CONTEXT_ALLOW_SECRETS=false` in the server environment.
|
|
172
232
|
|
|
173
|
-
|
|
233
|
+
This filter is a best-effort check, not a security boundary.
|
|
174
234
|
|
|
175
|
-
|
|
235
|
+
`CLINKX_ALLOWED_ROOTS` limits the paths that tool calls can reference. It does not limit the child process. Set it in all installations so that the limit does not depend on the start directory of the client.
|
|
176
236
|
|
|
177
|
-
|
|
237
|
+
Only the `council-plan-review` and `plan-review-receipts` prompts tell the members not to edit files. This is an instruction to the model, not a mechanical control. The other workflows give no such instruction.
|
|
178
238
|
|
|
179
|
-
|
|
239
|
+
## Documentation
|
|
240
|
+
|
|
241
|
+
The installed package contains these files. After `npm install clinkx`, find them in `node_modules/clinkx/`.
|
|
242
|
+
|
|
243
|
+
| File | Content |
|
|
244
|
+
|---|---|
|
|
245
|
+
| `docs/configuration.md` | Reference for adapter files, invocation overrides, and environment variables. |
|
|
246
|
+
| `docs/security.md` | Trust boundaries, redaction scope, and the limits of each safety control. |
|
|
247
|
+
| `CHANGELOG.md` | Changes, upgrade notes, and new flags for each release. |
|
|
248
|
+
|
|
249
|
+
Read the upgrade notes before you upgrade a server that has unfinished workflow runs.
|
|
180
250
|
|
|
181
251
|
## License
|
|
182
252
|
|
|
183
|
-
Copyright (c) 2026 jim380. All rights reserved.
|
|
253
|
+
Copyright (c) 2026 jim380. All rights reserved.
|
|
254
|
+
|
|
255
|
+
ClinkX is free to use but not open source. You may install and run the published npm package for your own use. You may not copy, change, redistribute, or sell it. The `package.json` license field is `UNLICENSED`. See the `LICENSE` file in the package for the full text.
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared chairman invocation-knob resolution.
|
|
3
|
+
*
|
|
4
|
+
* Provider change (caller chairman is set AND differs from the static
|
|
5
|
+
* cli_name) drops inherited model/effort; only explicit chairman knobs apply.
|
|
6
|
+
* Same provider keeps unspecified static pins and overlays supplied knobs.
|
|
7
|
+
*/
|
|
8
|
+
export interface ChairmanCallPins {
|
|
9
|
+
readonly cli_name: string;
|
|
10
|
+
readonly model?: string | undefined;
|
|
11
|
+
readonly effort?: string | undefined;
|
|
12
|
+
}
|
|
13
|
+
export interface ResolveEffectiveChairmanCallInput {
|
|
14
|
+
readonly staticCall: ChairmanCallPins;
|
|
15
|
+
readonly chairmanCliName: string | undefined;
|
|
16
|
+
readonly chairmanModel: string | undefined;
|
|
17
|
+
readonly chairmanEffort: string | undefined;
|
|
18
|
+
}
|
|
19
|
+
export interface EffectiveChairmanCall {
|
|
20
|
+
readonly cli_name: string;
|
|
21
|
+
readonly model?: string;
|
|
22
|
+
readonly effort?: string;
|
|
23
|
+
}
|
|
24
|
+
export declare function resolveEffectiveChairmanCall(input: ResolveEffectiveChairmanCallInput): EffectiveChairmanCall;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared chairman invocation-knob resolution.
|
|
3
|
+
*
|
|
4
|
+
* Provider change (caller chairman is set AND differs from the static
|
|
5
|
+
* cli_name) drops inherited model/effort; only explicit chairman knobs apply.
|
|
6
|
+
* Same provider keeps unspecified static pins and overlays supplied knobs.
|
|
7
|
+
*/
|
|
8
|
+
export function resolveEffectiveChairmanCall(input) {
|
|
9
|
+
const { staticCall, chairmanCliName, chairmanModel, chairmanEffort } = input;
|
|
10
|
+
const providerChanged = chairmanCliName != null && chairmanCliName !== staticCall.cli_name;
|
|
11
|
+
const model = chairmanModel !== undefined
|
|
12
|
+
? chairmanModel
|
|
13
|
+
: providerChanged
|
|
14
|
+
? undefined
|
|
15
|
+
: staticCall.model;
|
|
16
|
+
const effort = chairmanEffort !== undefined
|
|
17
|
+
? chairmanEffort
|
|
18
|
+
: providerChanged
|
|
19
|
+
? undefined
|
|
20
|
+
: staticCall.effort;
|
|
21
|
+
return {
|
|
22
|
+
cli_name: chairmanCliName ?? staticCall.cli_name,
|
|
23
|
+
...(model !== undefined ? { model } : {}),
|
|
24
|
+
...(effort !== undefined ? { effort } : {}),
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=chairman-knobs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chairman-knobs.js","sourceRoot":"","sources":["../src/chairman-knobs.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAqBH,MAAM,UAAU,4BAA4B,CAC1C,KAAwC;IAExC,MAAM,EAAE,UAAU,EAAE,eAAe,EAAE,aAAa,EAAE,cAAc,EAAE,GAAG,KAAK,CAAC;IAC7E,MAAM,eAAe,GACnB,eAAe,IAAI,IAAI,IAAI,eAAe,KAAK,UAAU,CAAC,QAAQ,CAAC;IACrE,MAAM,KAAK,GAAG,aAAa,KAAK,SAAS;QACvC,CAAC,CAAC,aAAa;QACf,CAAC,CAAC,eAAe;YACf,CAAC,CAAC,SAAS;YACX,CAAC,CAAC,UAAU,CAAC,KAAK,CAAC;IACvB,MAAM,MAAM,GAAG,cAAc,KAAK,SAAS;QACzC,CAAC,CAAC,cAAc;QAChB,CAAC,CAAC,eAAe;YACf,CAAC,CAAC,SAAS;YACX,CAAC,CAAC,UAAU,CAAC,MAAM,CAAC;IAExB,OAAO;QACL,QAAQ,EAAE,eAAe,IAAI,UAAU,CAAC,QAAQ;QAChD,GAAG,CAAC,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QACzC,GAAG,CAAC,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KAC5C,CAAC;AACJ,CAAC"}
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
*/
|
|
15
15
|
import type { ClinkBackend, ToolCallResult } from "./backend.js";
|
|
16
16
|
import type { SessionLogOwnerV1 } from "./dashboard/session-log-contract.js";
|
|
17
|
+
import { type ObservedInvocationV1 } from "./dashboard/invocation-contract.js";
|
|
17
18
|
/** Parsed result from a clink call. */
|
|
18
19
|
export interface ClinkCallResult {
|
|
19
20
|
/** Primary output text (for storage/threading/hashing). */
|
|
@@ -50,3 +51,12 @@ export declare function callClink(session: ClinkBackend, input: Record<string, u
|
|
|
50
51
|
stageId: string;
|
|
51
52
|
callId: string;
|
|
52
53
|
}, timeoutMs?: number, sessionLogOwner?: SessionLogOwnerV1): Promise<ClinkCallResult>;
|
|
54
|
+
/**
|
|
55
|
+
* Extract a runtime-observed invocation record from a child `_debug` block.
|
|
56
|
+
*
|
|
57
|
+
* Best-effort telemetry: returns undefined when the block is absent, the
|
|
58
|
+
* `observed_invocation` key is missing, or the payload does not satisfy
|
|
59
|
+
* ObservedInvocationV1Schema. Never throws — malformed observed telemetry
|
|
60
|
+
* must not affect call success/failure handling.
|
|
61
|
+
*/
|
|
62
|
+
export declare function extractObservedInvocation(debug: Record<string, unknown> | null): ObservedInvocationV1 | undefined;
|