akm-cli 0.9.30 → 0.10.26101001-alpha
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 +282 -0
- package/README.md +10 -10
- package/ROADMAP.md +112 -0
- package/STABILITY.md +79 -53
- package/dist/api-node.mjs +20 -0
- package/dist/api.d.ts +23 -0
- package/dist/api.js +45 -0
- package/dist/assets/hints/cli-hints-full.md +13 -27
- package/dist/assets/hints/cli-hints-short.md +1 -1
- package/dist/assets/improve-strategies/default.json +3 -3
- package/dist/assets/prompts/consolidate-pair.md +9 -7
- package/dist/cli/shared.js +31 -48
- package/dist/cli/unknown-flags.js +6 -43
- package/dist/cli.js +8 -34
- package/dist/commands/agent/contribute-cli.js +1 -1
- package/dist/commands/completions.js +1 -2
- package/dist/commands/config-cli.js +5 -28
- package/dist/commands/env/env-cli.js +5 -5
- package/dist/commands/env/secret-cli.js +2 -2
- package/dist/commands/health/checks.js +41 -16
- package/dist/commands/health/plugin-staleness.js +52 -22
- package/dist/commands/improve/autonomy-gate.js +5 -3
- package/dist/commands/improve/consolidate/pair-pass.js +7 -1
- package/dist/commands/improve/consolidate.js +6 -35
- package/dist/commands/improve/distill/lesson-update.js +91 -0
- package/dist/commands/improve/distill-guards.js +1 -43
- package/dist/commands/improve/distill.js +140 -20
- package/dist/commands/improve/extract-cli.js +1 -1
- package/dist/commands/improve/improve-cli.js +120 -114
- package/dist/commands/improve/improve-strategies.js +8 -12
- package/dist/commands/improve/loop-stages.js +0 -1
- package/dist/commands/improve/planner.js +0 -1
- package/dist/commands/improve/preparation.js +40 -99
- package/dist/commands/improve/proactive-maintenance.js +2 -2
- package/dist/commands/improve/reflect-noise.js +3 -55
- package/dist/commands/improve/reflect.js +3 -8
- package/dist/commands/improve/retrieval-scope.js +2 -2
- package/dist/commands/improve/salience.js +2 -9
- package/dist/commands/improve/stage.js +14 -9
- package/dist/commands/lint/index.js +5 -20
- package/dist/commands/observability-cli.js +3 -9
- package/dist/commands/proposal/drain.js +39 -6
- package/dist/commands/proposal/proposal-cli.js +10 -30
- package/dist/commands/proposal/repository.js +3 -3
- package/dist/commands/read/knowledge.js +3 -3
- package/dist/commands/read/remember-cli.js +0 -13
- package/dist/commands/read/search-cli.js +29 -97
- package/dist/commands/read/search.js +0 -11
- package/dist/commands/read/show.js +0 -19
- package/dist/commands/sources/plugin-upgrade.js +164 -101
- package/dist/commands/sources/sources-cli.js +1 -15
- package/dist/commands/sources/stash-cli.js +4 -12
- package/dist/commands/tasks/tasks-cli.js +4 -115
- package/dist/commands/workflow/plan.js +11 -33
- package/dist/commands/workflow-cli.js +2 -7
- package/dist/core/adapter/adapter-ids.js +1 -2
- package/dist/core/adapter/adapters/agent-skills-adapter.js +0 -4
- package/dist/core/adapter/adapters/akm-adapter.js +9 -48
- package/dist/core/adapter/adapters/akm-lint.js +10 -26
- package/dist/core/adapter/adapters/akm-metadata.js +2 -72
- package/dist/core/adapter/adapters/akm-task-adapter.js +0 -5
- package/dist/core/adapter/adapters/akm-workflow-adapter.js +9 -28
- package/dist/core/adapter/adapters/dotenv-adapter.js +1 -20
- package/dist/core/adapter/adapters/generic-files-adapter.js +0 -10
- package/dist/core/adapter/adapters/llm-wiki-adapter.js +0 -4
- package/dist/core/adapter/adapters/tool-dir-shared.js +0 -24
- package/dist/core/adapter/adapters/website-snapshot-adapter.js +4 -4
- package/dist/core/adapter/recognize-match.js +3 -4
- package/dist/core/common.js +18 -2
- package/dist/core/config/config-schema.js +12 -15
- package/dist/core/config/config-types.js +6 -15
- package/dist/core/config/config-walker.js +6 -23
- package/dist/core/config/config.js +17 -80
- package/dist/core/config/engine-semantics.js +7 -3
- package/dist/core/config/schema/engines.js +7 -7
- package/dist/core/config/schema/improve-processes.js +8 -61
- package/dist/core/config/schema/improve.js +2 -21
- package/dist/core/config/schema/index-config.js +6 -39
- package/dist/core/env-secret-ref.js +2 -45
- package/dist/core/errors.js +1 -2
- package/dist/core/extra-params.js +2 -86
- package/dist/core/file-lock.js +10 -1
- package/dist/core/improve-result.js +11 -1
- package/dist/core/mutation-target.js +2 -2
- package/dist/core/recognition-util.js +4 -5
- package/dist/core/warn.js +21 -4
- package/dist/core/write-source.js +3 -3
- package/dist/execution/target-ref.js +1 -2
- package/dist/indexer/search/db-search.js +4 -19
- package/dist/indexer/search/fts-query.js +0 -19
- package/dist/integrations/agent/engine-resolution.js +5 -2
- package/dist/integrations/agent/index.js +1 -1
- package/dist/integrations/agent/profiles.js +41 -98
- package/dist/integrations/agent/request-lowering.js +3 -3
- package/dist/integrations/harnesses/aider/index.js +5 -0
- package/dist/integrations/harnesses/amazonq/index.js +1 -0
- package/dist/integrations/harnesses/claude/config-import.js +2 -3
- package/dist/integrations/harnesses/claude/index.js +5 -0
- package/dist/integrations/harnesses/codex/index.js +1 -0
- package/dist/integrations/harnesses/copilot/index.js +1 -0
- package/dist/integrations/harnesses/gemini/index.js +1 -0
- package/dist/integrations/harnesses/index.js +18 -39
- package/dist/integrations/harnesses/opencode/agent-builder.js +60 -35
- package/dist/integrations/harnesses/opencode/config-import.js +121 -52
- package/dist/integrations/harnesses/opencode/index.js +22 -0
- package/dist/integrations/harnesses/opencode/plugin-layout.js +68 -0
- package/dist/integrations/harnesses/opencode/session-log-types.js +12 -0
- package/dist/integrations/harnesses/opencode/session-log-v1.js +72 -0
- package/dist/integrations/harnesses/opencode/session-log-v2.js +140 -0
- package/dist/integrations/harnesses/opencode/session-log.js +104 -115
- package/dist/integrations/harnesses/opencode/version.js +98 -0
- package/dist/integrations/harnesses/opencode-sdk/{harness.js → index.js} +5 -17
- package/dist/integrations/harnesses/opencode-sdk/sdk-runner.js +105 -206
- package/dist/integrations/harnesses/opencode-sdk/v1-adapter.js +199 -0
- package/dist/integrations/harnesses/opencode-sdk/v2-adapter.js +228 -0
- package/dist/integrations/harnesses/opencode-sdk/wire.js +66 -0
- package/dist/integrations/harnesses/openhands/index.js +1 -0
- package/dist/integrations/harnesses/pi/index.js +1 -0
- package/dist/integrations/harnesses/shared.js +2 -0
- package/dist/integrations/harnesses/types.js +2 -0
- package/dist/llm/client.js +74 -14
- package/dist/output/cli-hints.js +1 -1
- package/dist/output/context.js +10 -19
- package/dist/output/format-exempt.js +5 -8
- package/dist/output/shapes/helpers.js +1 -22
- package/dist/output/shapes/passthrough.js +0 -1
- package/dist/output/shapes.js +3 -31
- package/dist/output/stdout.js +5 -1
- package/dist/output/text/command-format.js +6 -1
- package/dist/output/text/workflow-format.js +4 -22
- package/dist/scripts/akm-migrate-node.js +15746 -16706
- package/dist/scripts/akm-migrate.js +16319 -17275
- package/dist/setup/detect.js +10 -4
- package/dist/setup/harness-config-import.js +5 -14
- package/dist/setup/setup.js +1 -1
- package/dist/setup/steps/tasks.js +12 -13
- package/dist/storage/repositories/task-history-repository.js +0 -5
- package/dist/storage/repositories/workflow-runs-repository.js +5 -15
- package/dist/tasks/embedded.js +2 -1
- package/dist/tasks/run/task-history.js +0 -2
- package/dist/tasks/schedule-gates.js +39 -0
- package/dist/tasks/scheduler-binding.js +0 -16
- package/dist/tasks/scheduler-sync.js +3 -97
- package/dist/tasks/source/bounded-document.js +1 -1
- package/dist/tasks/source/task-source-v4.js +2 -12
- package/dist/tasks/task-run-reserved-flags.js +2 -31
- package/dist/workflows/authoring/authoring.js +6 -6
- package/dist/workflows/compile.js +8 -65
- package/dist/workflows/exec/child-workflow.js +22 -3
- package/dist/workflows/exec/native-executor.js +12 -147
- package/dist/workflows/exec/run-workflow.js +31 -103
- package/dist/workflows/exec/step-work.js +9 -178
- package/dist/workflows/exec/unit-dispatch.js +0 -10
- package/dist/workflows/freeze/environment.js +3 -44
- package/dist/workflows/freeze/freeze.js +8 -41
- package/dist/workflows/freeze/targets/child-workflow.js +27 -63
- package/dist/workflows/freeze/targets/command.js +2 -16
- package/dist/workflows/freeze/targets/shell.js +0 -2
- package/dist/workflows/freeze/task-bindings.js +2 -28
- package/dist/workflows/ir/params.js +12 -2
- package/dist/workflows/parser.js +82 -232
- package/dist/workflows/plan.js +1 -1
- package/dist/workflows/renderer.js +10 -19
- package/dist/workflows/runtime/run-plan.js +11 -53
- package/dist/workflows/runtime/runs.js +4 -27
- package/dist/workflows/source-files.js +12 -16
- package/dist/workflows/source-semantics.js +1 -93
- package/docs/README.md +43 -42
- package/docs/agents/README.md +15 -0
- package/docs/agents/agent-install.md +14 -0
- package/docs/architecture/README.md +67 -0
- package/docs/architecture/adapters.md +258 -0
- package/docs/architecture/akm-architecture-decision-history.md +2055 -0
- package/docs/architecture/akm-core-principles.md +126 -0
- package/docs/architecture/architecture.md +578 -0
- package/docs/architecture/comparisons/claude-code-vs-akm-workflows-full.md +550 -0
- package/docs/architecture/decisions/0001-no-interpolation-attached-structured-context.md +72 -0
- package/docs/architecture/decisions/0002-unit-reuse-and-input-hash-scope.md +142 -0
- package/docs/architecture/decisions/0003-child-env-allowlist-and-provenance.md +189 -0
- package/docs/architecture/decisions/0004-task-input-contract-and-flag-coercion.md +97 -0
- package/docs/architecture/decisions/0005-task-result-vocabulary-and-legacy-read-mapping.md +108 -0
- package/docs/architecture/decisions/0006-task-source-version-routing.md +124 -0
- package/docs/architecture/decisions/0007-workflow-composition-bounds.md +83 -0
- package/docs/architecture/decisions/0008-task-binding-normalization.md +88 -0
- package/docs/architecture/decisions/0009-child-run-publication-column-parity.md +80 -0
- package/docs/architecture/decisions/0010-driver-protocol-cut.md +36 -0
- package/docs/architecture/decisions/0011-engine-run-loop-invariants.md +125 -0
- package/docs/architecture/decisions/README.md +62 -0
- package/docs/architecture/improvement.md +471 -0
- package/docs/architecture/internals/classification.md +154 -0
- package/docs/architecture/internals/fresh-host-rebuild-runbook.md +40 -0
- package/docs/architecture/internals/functional-contract-patterns.md +340 -0
- package/docs/architecture/internals/health-advisories.md +110 -0
- package/docs/architecture/internals/improve-workflow.md +720 -0
- package/docs/architecture/internals/indexing.md +498 -0
- package/docs/architecture/internals/registry-network-boundary.md +57 -0
- package/docs/architecture/internals/search.md +248 -0
- package/docs/architecture/internals/storage-locations.md +943 -0
- package/docs/architecture/persisted-data-compat.md +68 -0
- package/docs/architecture/reviews/env-secret-access.md +319 -0
- package/docs/architecture/runtime-boundary-design.md +153 -0
- package/docs/architecture/specs/0.9.0-close-out-plan.md +361 -0
- package/docs/architecture/specs/0.9.0-decisions.md +532 -0
- package/docs/architecture/specs/0.9.0-docs-code-drift-register.md +745 -0
- package/docs/architecture/specs/0.9.0-open-items-register.md +135 -0
- package/docs/architecture/specs/0.9.0-public-api-issue-backlog.md +740 -0
- package/docs/architecture/specs/0.9.0-release-surface-review.md +636 -0
- package/docs/architecture/specs/agent-command-engine-model-design.md +513 -0
- package/docs/architecture/specs/akm-0.9.0-bundle-adapter-spec.md +501 -0
- package/docs/architecture/specs/akm-0.9.0-ref-grammar-decision.md +291 -0
- package/docs/architecture/specs/akm-format-neutral-bundle-workspace-spec.md +2059 -0
- package/docs/architecture/specs/di-seams-plan.md +539 -0
- package/docs/architecture/specs/driver-protocol-keep-or-cut.md +275 -0
- package/docs/architecture/specs/fact-asset-type.md +142 -0
- package/docs/architecture/specs/improve-collapse-churn-detector-design.md +634 -0
- package/docs/architecture/specs/okf-support.md +148 -0
- package/docs/architecture/specs/ref.md +329 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/README.md +72 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/findings-consolidated.md +152 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/library-eval-alternatives.md +352 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/library-eval-bunqueue.md +300 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/library-eval-openworkflow.md +402 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/opus-review-1.md +758 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/opus-review-2.md +645 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/opus-review-3.md +602 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/panel-r1-adversarial.md +27 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/panel-r1-architecture.md +27 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/panel-r1-coverage.md +74 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/panel-r1-security.md +15 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/panel-r2-adversarial.md +132 -0
- package/docs/architecture/specs/reviews/task-workflow-unification/panel-r2-verification.md +147 -0
- package/docs/architecture/specs/stash-conventions-code-spec.md +275 -0
- package/docs/architecture/specs/stash-organization-conventions.md +377 -0
- package/docs/architecture/specs/task-workflow-format-unification.md +721 -0
- package/docs/architecture/specs/workflow-engine-buy-vs-build.md +231 -0
- package/docs/architecture/specs/workflow-format-unification.md +432 -0
- package/docs/architecture/testing/manual-testing-checklist.md +3411 -0
- package/docs/architecture/testing/okf-v0.2-conformance-runbook.md +924 -0
- package/docs/architecture/testing/task-workflow-manual-tests.md +1720 -0
- package/docs/architecture/testing/testing-workflow.md +446 -0
- package/docs/architecture/workflow-engine.md +223 -0
- package/docs/guides/README.md +33 -0
- package/docs/guides/author-bundles.md +310 -0
- package/docs/guides/author-workflows.md +490 -0
- package/docs/guides/bundles.md +321 -0
- package/docs/guides/capture-knowledge.md +136 -0
- package/docs/guides/claude-code-vs-akm-workflows.md +29 -0
- package/docs/guides/concepts.md +93 -0
- package/docs/guides/discover-and-load.md +158 -0
- package/docs/guides/getting-started.md +240 -0
- package/docs/guides/improve-the-library.md +246 -0
- package/docs/guides/knowledge-management.md +18 -0
- package/docs/guides/recipes/headless-install.md +97 -0
- package/docs/guides/recipes/website-source.md +28 -0
- package/docs/guides/run-workflows.md +279 -0
- package/docs/guides/scheduling.md +123 -0
- package/docs/guides/use-with-any-agent.md +174 -0
- package/docs/guides/wikis.md +81 -0
- package/docs/integration/bundling-akm.md +7 -6
- package/docs/maintainers/README.md +19 -0
- package/docs/maintainers/curate-workmap.md +335 -0
- package/docs/maintainers/eval.md +3 -0
- package/docs/maintainers/local-development.md +108 -0
- package/docs/maintainers/release-checklist.md +132 -0
- package/docs/migration/README.md +2 -2
- package/docs/migration/release-notes/0.0.13.md +1 -1
- package/docs/migration/release-notes/0.1.0.md +1 -1
- package/docs/migration/release-notes/0.2.0.md +1 -1
- package/docs/migration/release-notes/0.3.0.md +1 -1
- package/docs/migration/release-notes/0.5.0.md +1 -1
- package/docs/migration/release-notes/0.6.0.md +1 -1
- package/docs/migration/release-notes/0.7.0.md +1 -1
- package/docs/migration/release-notes/0.7.3.md +2 -2
- package/docs/migration/release-notes/0.7.4.md +1 -1
- package/docs/migration/release-notes/0.7.5.md +1 -1
- package/docs/migration/release-notes/0.8.0.md +1 -1
- package/docs/migration/release-notes/0.9.0.md +1 -1
- package/docs/migration/release-notes/0.9.14.md +1 -1
- package/docs/migration/release-notes/0.9.15.md +1 -1
- package/docs/migration/release-notes/0.9.16.md +1 -1
- package/docs/migration/release-notes/0.9.17.md +1 -1
- package/docs/migration/release-notes/0.9.19.md +1 -1
- package/docs/migration/release-notes/0.9.2.md +1 -1
- package/docs/migration/release-notes/README.md +27 -31
- package/docs/migration/v0.5-to-v0.6.md +759 -0
- package/docs/migration/v0.8-to-v0.9.md +1 -1
- package/docs/plans/0.9.2-agent-command-workflow-plan.md +423 -0
- package/docs/posts/README.md +30 -0
- package/docs/posts/akm-command-tour.md +495 -0
- package/docs/posts/akm-logo-sized.webp +0 -0
- package/docs/posts/belief-aware-memory-12.md +139 -0
- package/docs/posts/config-v2-lessons-16.md +191 -0
- package/docs/posts/improve-loop-autonomous-10.md +225 -0
- package/docs/posts/improve-pipeline-debugging-0803.md +179 -0
- package/docs/posts/intro-part-01.md +76 -0
- package/docs/posts/intro-part-02.md +221 -0
- package/docs/posts/intro-part-03.md +190 -0
- package/docs/posts/intro-part-04.md +221 -0
- package/docs/posts/llm-mode-reflect-13.md +166 -0
- package/docs/posts/openpalm-built-on-akm.md +86 -0
- package/docs/posts/progressive-disclosure-06.md +129 -0
- package/docs/posts/proposal-safety-net-15.md +112 -0
- package/docs/posts/release-0.5.0.md +247 -0
- package/docs/posts/release-0.6.0.md +117 -0
- package/docs/posts/release-0.7.0.md +159 -0
- package/docs/posts/release-0.8.0.md +332 -0
- package/docs/posts/scattered-skills-05.md +100 -0
- package/docs/posts/task-assets-persistent-workflows-11.md +222 -0
- package/docs/posts/team-skills-07.md +198 -0
- package/docs/posts/wiki-agent-knowledge-08.md +223 -0
- package/docs/posts/workflows-vaults-09.md +321 -0
- package/docs/product-surface.md +54 -0
- package/docs/reference/README.md +2 -2
- package/docs/reference/api.md +65 -0
- package/docs/reference/asset-types.md +166 -0
- package/docs/reference/bundle-types.md +2 -4
- package/docs/reference/cli.md +129 -175
- package/docs/reference/configuration.md +84 -19
- package/docs/reference/data-and-telemetry.md +1 -1
- package/docs/reference/env-and-secrets.md +126 -0
- package/docs/reference/memory.md +124 -0
- package/docs/reference/refs.md +156 -0
- package/docs/reference/registry.md +489 -0
- package/docs/reference/supported-formats.md +3 -4
- package/docs/reference/tasks.md +12 -19
- package/docs/reference/website-sources.md +141 -0
- package/docs/reference/workflow-schema.md +89 -317
- package/docs/reference/workflows.md +20 -48
- package/package.json +23 -16
- package/schemas/akm-config.json +2 -243
- package/schemas/akm-task.json +2 -3
- package/schemas/akm-workflow.json +47 -84
- package/dist/assets/improve-strategies/catchup.json +0 -41
- package/dist/assets/improve-strategies/proactive-maintenance.json +0 -24
- package/dist/assets/improve-strategies/quick.json +0 -17
- package/dist/assets/improve-strategies/reflect-distill.json +0 -29
- package/dist/assets/improve-strategies/thorough.json +0 -49
- package/dist/assets/tasks/improve/akm-improve-catchup.yml +0 -6
- package/dist/assets/tasks/improve/akm-improve-frequent.yml +0 -4
- package/dist/assets/tasks/improve/akm-improve-nightly.yml +0 -4
- package/dist/cli/retired-commands.js +0 -118
- package/dist/commands/tasks/validate.js +0 -176
- package/dist/core/config/legacy-source-shape-shim.js +0 -117
- package/dist/integrations/harnesses/ids.js +0 -28
- package/dist/tasks/source/task-source-v3-frozen.js +0 -424
- package/dist/tasks/source/task-to-v4.js +0 -863
- package/dist/workflows/exec/worktree.js +0 -372
- package/dist/workflows/freeze/child-output-references.js +0 -83
- package/dist/workflows/freeze/identity.js +0 -22
- package/dist/workflows/freeze/targets/script.js +0 -50
- package/dist/workflows/freeze/targets/task.js +0 -124
- package/dist/workflows/github-yaml.js +0 -506
- package/dist/workflows/runtime/run-outputs.js +0 -80
package/docs/reference/cli.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
The CLI is called `akm` (Agent Knowledge Manager). Commands default to structured
|
|
4
4
|
JSON at `--detail brief`. Use `--format json|jsonl|yaml|text|md|html`,
|
|
5
|
-
`--detail brief|normal|full
|
|
5
|
+
`--detail brief|normal|full|agent` when you want a
|
|
6
6
|
different presentation. Errors include `error` and `hint` fields.
|
|
7
7
|
|
|
8
8
|
This page is authoritative for the current CLI. For per-release behavior
|
|
@@ -19,14 +19,15 @@ These flags are accepted by all commands:
|
|
|
19
19
|
| --- | --- | --- | --- |
|
|
20
20
|
| `--format` | `json`, `jsonl`, `yaml`, `text`, `md`, `html` | `json` | Output format |
|
|
21
21
|
| `--output` | path | _(none)_ | Write rendered output to a file instead of stdout (all formats except `jsonl`) |
|
|
22
|
-
| `--detail` | `brief`, `normal`, `full` | `brief` | Output **verbosity** level |
|
|
23
|
-
| `--shape` | `human`, `agent`, `summary` | `human` | Output **projection** |
|
|
22
|
+
| `--detail` | `brief`, `normal`, `full`, `agent` | `brief` | Output **verbosity** level, or the `agent` projection |
|
|
24
23
|
| `--quiet` / `-q` | boolean | `false` | Suppress stderr warnings |
|
|
25
24
|
| `--verbose` | boolean | `false` | Enable verbose diagnostics gated behind `isVerbose()`. Parsed globally before any subcommand runs. The `AKM_VERBOSE` env var honours the same setting and wins when both are present (see `src/core/warn.ts`). |
|
|
26
25
|
|
|
27
|
-
`--detail` controls **how much** is returned
|
|
28
|
-
|
|
29
|
-
|
|
26
|
+
`--detail brief|normal|full` controls **how much** is returned. `--detail agent`
|
|
27
|
+
selects the token-lean action view on `search`, `curate` and `show`; every other
|
|
28
|
+
command ignores it. (`--shape`, which carried `agent` and `summary` before 0.10,
|
|
29
|
+
is gone: it is an unknown flag, exit 2. `--shape summary` had a projection only
|
|
30
|
+
on `show`; use `--detail brief` there.)
|
|
30
31
|
|
|
31
32
|
### `--format jsonl`
|
|
32
33
|
|
|
@@ -67,12 +68,12 @@ Scripted `setup` modes emit a normal format-aware result. Interactive `setup`
|
|
|
67
68
|
is a terminal UI and emits no result document. `agent` leaves inherited child
|
|
68
69
|
streams raw, then formats its final `agent-result` envelope normally.
|
|
69
70
|
|
|
70
|
-
### `--
|
|
71
|
+
### `--detail agent`
|
|
71
72
|
|
|
72
73
|
Strips output to only action-relevant fields:
|
|
73
74
|
|
|
74
75
|
- **search**: keeps `name`, canonical `ref`, absolute `path`, `editable`, `type`, `description`, `action`, `score`, and optional `estimatedTokens`/`keys`
|
|
75
|
-
- **show**: adds absolute `path`, `editable`, and the existing type-specific action/content fields on top of the canonical `ref` that every `show` shape returns (`ref` is not agent-exclusive
|
|
76
|
+
- **show**: adds absolute `path`, `editable`, and the existing type-specific action/content fields on top of the canonical `ref` that every `show` shape returns (`ref` is not agent-exclusive; every `show` response carries it)
|
|
76
77
|
- **curate**: local items keep canonical `ref`, absolute `path`, `editable`, and their follow-up fields
|
|
77
78
|
|
|
78
79
|
For local materialized assets, `editHint` is added only when `editable` is
|
|
@@ -93,20 +94,11 @@ them.
|
|
|
93
94
|
|
|
94
95
|
Every one of these commands also carries a `results` field — the identical
|
|
95
96
|
array, not a copy — alongside its semantic key, in every `--format`/`--detail`
|
|
96
|
-
combination
|
|
97
|
+
combination, including `--detail agent`. Code
|
|
97
98
|
written against a single command should keep using its semantic key for
|
|
98
99
|
clarity; code that needs to handle several list commands uniformly can read
|
|
99
100
|
`results` and never maintain a per-command lookup table.
|
|
100
101
|
|
|
101
|
-
### `--shape summary`
|
|
102
|
-
|
|
103
|
-
Valid **only on `akm show`**. Every other command rejects `--shape summary`
|
|
104
|
-
with an `INVALID_SHAPE_VALUE` usage error (exit 2) — an honest rejection rather
|
|
105
|
-
than a silent fallback. It returns a compact view suitable for capability
|
|
106
|
-
discovery:
|
|
107
|
-
|
|
108
|
-
- **show**: `type`, `name`, canonical `ref`, `description`, `tags`, `parameters`, `workflowTitle`, `action`, `run`, `origin`, `keys`, `links`
|
|
109
|
-
|
|
110
102
|
## Exit Codes and Error Envelope
|
|
111
103
|
|
|
112
104
|
Every command exits with one of the following codes:
|
|
@@ -550,7 +542,7 @@ ran, `keyword` when keyword-only search was intentional or semantic search was
|
|
|
550
542
|
not ready, and `fts-fallback` when a ready semantic backend failed during this
|
|
551
543
|
query. The last case also adds one sanitized, endpoint-naming entry to
|
|
552
544
|
`warnings`; it never repeats the provider/runtime error text. Both fields are
|
|
553
|
-
preserved by `--
|
|
545
|
+
preserved by `--detail agent` so machine consumers can lower their confidence
|
|
554
546
|
instead of treating keyword fallback as healthy semantic ranking.
|
|
555
547
|
|
|
556
548
|
Ranking fuses two candidate lists by reciprocal rank (k = 60, equal weights):
|
|
@@ -578,8 +570,7 @@ kept.
|
|
|
578
570
|
| `--belief` | `all`, `current`, `historical` | `all` | Memory belief filter. `current` keeps active memory beliefs; `historical` keeps contradicted/superseded/archived ones. |
|
|
579
571
|
| `--include-sessions` | flag | `false` | Include session assets, which are excluded from default results via `config.search.defaultExcludeTypes` |
|
|
580
572
|
| `--format` | `json`, `jsonl`, `yaml`, `text`, `md`, `html` | `json` | Output format |
|
|
581
|
-
| `--detail` | `brief`, `normal`, `full` | `brief` | Output verbosity level |
|
|
582
|
-
| `--shape` | `human`, `agent`, `summary` | `human` | Output projection. `--shape summary` is valid **only on `akm show`**; passing it here is an `INVALID_SHAPE_VALUE` usage error (exit 2), like on every other command. |
|
|
573
|
+
| `--detail` | `brief`, `normal`, `full`, `agent` | `brief` | Output verbosity level, or the `agent` projection |
|
|
583
574
|
|
|
584
575
|
`--filter` flags AND-join: every supplied key must match the entry's
|
|
585
576
|
`scope` for the entry to appear in the result set. Entries without any scope
|
|
@@ -603,7 +594,7 @@ availability:
|
|
|
603
594
|
it (`lexical rank 3`, `vector rank 12`); surfaced at `full`
|
|
604
595
|
|
|
605
596
|
The default brief shape is intentionally small. The exact field set per
|
|
606
|
-
detail level (and
|
|
597
|
+
detail level (and for `--detail agent`) is authoritative in
|
|
607
598
|
`src/output/shapes/helpers.ts` (`shapeSearchHit` / `shapeSearchHitForAgent`),
|
|
608
599
|
assembled into the shape registry by the `src/output/shapes.ts` barrel:
|
|
609
600
|
|
|
@@ -612,11 +603,7 @@ assembled into the shape registry by the `src/output/shapes.ts` barrel:
|
|
|
612
603
|
| `brief` (default) | `type`, `name`, `ref`, `action`, `estimatedTokens` | `name`, `installRef`, `score` |
|
|
613
604
|
| `normal` | `type`, `name`, `description`, `action`, `score`, `estimatedTokens`, optional `warnings`/`quality`/`keys` | `name`, `description`, `action`, `installRef`, `score`, optional `warnings` |
|
|
614
605
|
| `full` | full hit object (includes `ref`, `origin`, `tags`, `whyMatched`, optional `warnings`, optional `quality`, timings, bundle metadata) | full hit object |
|
|
615
|
-
|
|
|
616
|
-
|
|
617
|
-
`--shape summary` is **not valid on `search`** — see
|
|
618
|
-
[`--shape summary`](#--shape-summary) above; it is a usage error (exit 2)
|
|
619
|
-
everywhere except `akm show`.
|
|
606
|
+
| `agent` | `name`, `ref`, `type`, `path`, `editable`, conditional `editHint`, `description`, `action`, `score`, optional `estimatedTokens`/`keys` | no local access fields |
|
|
620
607
|
|
|
621
608
|
There is no registry `curated` boolean. Renderers surface an optional
|
|
622
609
|
`warnings: string[]` field on hits when a provider has non-fatal issues to
|
|
@@ -662,8 +649,7 @@ candidates (`search.curateRerank.topN`) by name, description and the start of
|
|
|
662
649
|
each asset's indexed content. Curate includes direct follow-up
|
|
663
650
|
commands such as `akm show <ref>` or `akm bundle add <ref>` so you can
|
|
664
651
|
immediately inspect or install what it found.
|
|
665
|
-
`--detail`
|
|
666
|
-
does not.
|
|
652
|
+
`--detail` (including `agent`) works on curate output.
|
|
667
653
|
Curate preserves the underlying search's `searchMode` and warnings.
|
|
668
654
|
Agent-shaped local items include `ref`, `path`, and `editable`, plus `editHint`
|
|
669
655
|
only for read-only items. Their `followUp` remains `akm show <ref>` rather than
|
|
@@ -720,8 +706,8 @@ akm show memories/retro --filter user=alice --filter agent=claude
|
|
|
720
706
|
human-authored orientation doc from a bundle's optional `.meta/` directory
|
|
721
707
|
(`<name>` defaults to `index`; `.meta/<name>.md` is tried before an
|
|
722
708
|
extensionless `.meta/<name>`). These files are never indexed, so they do not
|
|
723
|
-
appear in `akm search`. See [
|
|
724
|
-
|
|
709
|
+
appear in `akm search`. See [Concepts](../guides/concepts.md) for the full
|
|
710
|
+
convention.
|
|
725
711
|
|
|
726
712
|
`--filter` accepts the same `<key>=<value>` shape as `akm search --filter` — one
|
|
727
713
|
spelling for the scope-narrowing axis on both commands (`--scope` was removed
|
|
@@ -732,20 +718,15 @@ filter. A mismatch (or absent scope) returns `NotFoundError` so the caller
|
|
|
732
718
|
cannot accidentally read out-of-scope content.
|
|
733
719
|
|
|
734
720
|
The default `show` JSON includes the asset body when applicable. Canonical
|
|
735
|
-
`ref` is always present,
|
|
736
|
-
|
|
737
|
-
always present too, at every `--detail` level, in the `human` (default) and
|
|
738
|
-
`agent` shapes — `--shape summary` omits both, since it is a compact
|
|
739
|
-
capability-discovery view, not an edit-target view. None of `ref`/`path`/
|
|
721
|
+
`ref` is always present, at every `--detail` level, `agent` included. Absolute `path` and `editable` are
|
|
722
|
+
always present too. None of `ref`/`path`/
|
|
740
723
|
`editable` are gated behind `--detail full`. Use `--detail brief` for a
|
|
741
724
|
reduced metadata-first view without `content`/`template`/`prompt`;
|
|
742
725
|
`--detail full` adds verbose extras such as `schemaVersion` and, when
|
|
743
|
-
`editable` is `false`, `editHint`; `--
|
|
726
|
+
`editable` is `false`, `editHint`; `--detail agent` strips non-action metadata
|
|
744
727
|
(e.g. `origin`, `tags`) down to the action-relevant field set while still
|
|
745
|
-
including `ref`/`path`/`editable
|
|
746
|
-
|
|
747
|
-
`parameters`, `workflowTitle`, `action`, `run`, `origin`, and `keys`, plus the
|
|
748
|
-
optional fragment metadata described below.
|
|
728
|
+
including `ref`/`path`/`editable`, plus the optional fragment metadata
|
|
729
|
+
described below.
|
|
749
730
|
|
|
750
731
|
`links` lists the asset's declared links, grouped by kind: `outgoing` (the
|
|
751
732
|
assets its own `xrefs:`, `supersededBy:`, `contradictedBy:`,
|
|
@@ -817,7 +798,7 @@ akm workflow status 7c115132 # 8+ char run-id prefix also works
|
|
|
817
798
|
akm workflow resume <run-id>
|
|
818
799
|
akm workflow abandon <run-id>
|
|
819
800
|
akm workflow list --active
|
|
820
|
-
akm workflow list --children # also list child workflow runs
|
|
801
|
+
akm workflow list --children # also list child workflow runs (Experimental)
|
|
821
802
|
akm workflow list --all-scopes # include runs started from a different working directory
|
|
822
803
|
akm workflow plan workflows/ship-release # compile+freeze preview, zero writes
|
|
823
804
|
```
|
|
@@ -829,10 +810,10 @@ Subcommands:
|
|
|
829
810
|
|
|
830
811
|
| Subcommand | Description |
|
|
831
812
|
| --- | --- |
|
|
832
|
-
| `create <name>` | Validate and write a Markdown workflow under `workflows/`. `--path <dir>` places it in a subdirectory; `--from <file>` imports content; `--force`
|
|
833
|
-
| `run <run-id\|ref>` |
|
|
813
|
+
| `create <name>` | Validate and write a Markdown workflow under `workflows/`. `--path <dir>` places it in a subdirectory; `--from <file>` imports content; `--force` overwrites; `--print` prints the template that would be written instead of writing it |
|
|
814
|
+
| `run <run-id\|ref>` | Canonical start/resume/execute command. A ref starts a run or resumes the active run in the current scope (announced as `resumed: true`, see below); a run id continues that exact active run. `--new` starts a fresh run even when one is already active. Executes until completion, failure, verification rejection, interruption, or an explicit limit |
|
|
834
815
|
| `status <run-id\|ref>` | Show the full run state, including all step statuses. `--units` also lists per-unit rows from the run journal (diagnostics only). Renders a `children:` tree when the run composes child workflows. `--all-scopes` widens the ref-fallthrough lookup (only reached when the target does not resolve to a run id) to every scope instead of just the current one |
|
|
835
|
-
| `list` | List workflow runs (optionally filtered by `--ref`; `--active` shows only `status=active` runs, excluding `blocked`/`failed`/`completed`). Child workflow runs are excluded unless `--children` is passed. `--all-scopes` searches every scope instead of only the current one (#942) |
|
|
816
|
+
| `list` | List workflow runs (optionally filtered by `--ref`; `--active` shows only `status=active` runs, excluding `blocked`/`failed`/`completed`). Child workflow runs (the Experimental `unit: { workflow: … }` step) are excluded unless `--children` is passed. `--all-scopes` searches every scope instead of only the current one (#942) |
|
|
836
817
|
| `resume <run-id>` | Flip a `blocked` or `failed` run back to `active`. Completed runs cannot be resumed |
|
|
837
818
|
| `abandon <run-id>` | Mark a run failed so it stops counting as active (`resume` can reopen it) |
|
|
838
819
|
| `plan <ref>` | **Evolving.** Compile and freeze a workflow WITHOUT publishing a run: the canonical step graph, per-step frozen target kinds, task/child expansion, input bindings, source read set, and lowering notices — zero durable writes. Returns the full JSON envelope by default, like every other command; pass `--format text` for a human-readable summary |
|
|
@@ -848,8 +829,8 @@ workflow ref is never mistaken for one.
|
|
|
848
829
|
The public `workflow start`, `next`, and `complete` lifecycle was removed in
|
|
849
830
|
0.9, along with the experimental `brief`/`report` external-driver protocol.
|
|
850
831
|
Use `workflow run` for execution and `workflow status` for inspection. The
|
|
851
|
-
removed commands fail with an `UNKNOWN_COMMAND` envelope
|
|
852
|
-
|
|
832
|
+
removed commands fail with an `UNKNOWN_COMMAND` envelope; there are no
|
|
833
|
+
compatibility aliases.
|
|
853
834
|
|
|
854
835
|
There is also no `akm workflow template`, `validate`, or `watch`.
|
|
855
836
|
`workflow create --print` prints a starter, `akm lint --type workflows`
|
|
@@ -908,9 +889,8 @@ has nothing left to abort and nothing left to resume.
|
|
|
908
889
|
|
|
909
890
|
**What `--max-steps` counts.** The budget is spent by the **steps that
|
|
910
891
|
finish** — completed, failed, or gate-rejected with the loop budget spent — not
|
|
911
|
-
by entries in the `executed` report, which gains one per gate-loop iteration
|
|
912
|
-
|
|
913
|
-
one, a route-skipped step costs nothing (no work was dispatched for it), and a
|
|
892
|
+
by entries in the `executed` report, which gains one per gate-loop iteration.
|
|
893
|
+
So a step's whole bounded `gate.max_loops` loop costs one, and a
|
|
914
894
|
step the invocation left unfinished — an abort, a verification-judge outage —
|
|
915
895
|
costs nothing either, because the next invocation still owes that work.
|
|
916
896
|
`--max-retries` subtracts the same way: a reopened run's remaining budget is
|
|
@@ -922,7 +902,7 @@ budget is left. `gate.max_loops` (1–100) is the per-step ceiling;
|
|
|
922
902
|
`budget.max_units` and `budget.max_tokens` are the whole-run ceilings, seeded
|
|
923
903
|
from the unit journal so they hold across resumes.
|
|
924
904
|
|
|
925
|
-
`run` is
|
|
905
|
+
`run` is Experimental and does not consult `experimental.workflowEngine`. Every
|
|
926
906
|
non-empty `### gate` requires `workflow.judgeEngine` to name a configured LLM
|
|
927
907
|
or agent engine before a new run can be frozen. Gate evaluation is fail-closed.
|
|
928
908
|
|
|
@@ -943,7 +923,7 @@ when the cwd is inside it, otherwise the cwd itself. In practice this means:
|
|
|
943
923
|
akm workflow create ship-release
|
|
944
924
|
akm workflow create ship-release --from ./ship-release.md
|
|
945
925
|
akm workflow create ship-release --from ./ship-release.md --force
|
|
946
|
-
akm workflow create ship-release --force
|
|
926
|
+
akm workflow create ship-release --force
|
|
947
927
|
akm workflow create ship --path release # writes workflows/release/ship.md
|
|
948
928
|
```
|
|
949
929
|
|
|
@@ -951,14 +931,9 @@ akm workflow create ship --path release # writes workflows/release/ship
|
|
|
951
931
|
| --- | --- |
|
|
952
932
|
| `--path <dir>` | Relative subdirectory under `workflows/` to place the workflow in. The filename comes from `<name>`. |
|
|
953
933
|
| `--from <file>` | Import and validate a Markdown workflow from an existing file |
|
|
954
|
-
| `--force` | Overwrite an existing workflow
|
|
955
|
-
| `--reset` | Explicitly replace an existing workflow with a fresh template (use with `--force`) |
|
|
934
|
+
| `--force` | Overwrite an existing workflow: with `--from`, replace its content from that file; alone, replace it with a fresh template |
|
|
956
935
|
| `--print` | Print the Markdown template without creating anything |
|
|
957
936
|
|
|
958
|
-
`--force` requires either `--from <file>` (replace from a source file) or
|
|
959
|
-
`--reset` (explicitly acknowledge you are overwriting in place). Without one of
|
|
960
|
-
these, `--force` is rejected to prevent silent template overwrites.
|
|
961
|
-
|
|
962
937
|
`<name>` itself must be **flat** — `^[a-z0-9][a-z0-9._/-]*$` after combining
|
|
963
938
|
with `--path`, but the bare `--name` positional is rejected if it contains a
|
|
964
939
|
`/`. Hierarchical placement (`release/ship`) goes through `--path release
|
|
@@ -1013,11 +988,11 @@ Two output modes:
|
|
|
1013
988
|
- **`--format json`**: the full envelope — `ok`, `ref`, `title`,
|
|
1014
989
|
`sourceFormat`, `sourcePath`, `irVersion`, `planHash`, `published` (always
|
|
1015
990
|
`false`, so a consumer can never mistake this for a run envelope),
|
|
1016
|
-
`execution`, `budget?`, `params?`, `
|
|
991
|
+
`execution`, `budget?`, `params?`, `steps[]`, `notices[]`,
|
|
1017
992
|
`warnings[]`. Each step entry carries an `expansion` field
|
|
1018
993
|
naming how its target was reached: `{via: "direct"}`, `{via: "task",
|
|
1019
994
|
taskRef}`, or — for a step composing a child workflow —
|
|
1020
|
-
`{via: "child", childRef, childPlanHash,
|
|
995
|
+
`{via: "child", childRef, childPlanHash, steps[]}` with the
|
|
1021
996
|
child's own step list nested recursively in the same shape.
|
|
1022
997
|
|
|
1023
998
|
Text-mode example:
|
|
@@ -1028,13 +1003,11 @@ source: workflows/release.md
|
|
|
1028
1003
|
plan: irVersion 5, hash 4f2ba91c3d0e… (not published)
|
|
1029
1004
|
limits: maxConcurrency 4; budget max_units 50, max_tokens 100000
|
|
1030
1005
|
params: channel, version
|
|
1031
|
-
outputs: report <- steps.summarize.output
|
|
1032
1006
|
steps:
|
|
1033
1007
|
1. notify [command] direct
|
|
1034
1008
|
2. build [script] via tasks/plan-v4-task
|
|
1035
1009
|
3. dispatch [child-workflow] -> workflows/release-checklist (plan 91acbe20f5d1…)
|
|
1036
1010
|
with: channel="stable" (literal), files <- steps.build.output.files (reference)
|
|
1037
|
-
exports: report, changed_count
|
|
1038
1011
|
3.1 verify [command] direct
|
|
1039
1012
|
4. summarize [command] direct
|
|
1040
1013
|
read set:
|
|
@@ -1066,7 +1039,7 @@ Workflow markdown contract:
|
|
|
1066
1039
|
- Frontmatter carries the asset envelope and orchestration graph (`params`,
|
|
1067
1040
|
`steps`, `defaults`, and `budget`).
|
|
1068
1041
|
- Every `## <step-id>` heading must name a declared step exactly. Unit and map
|
|
1069
|
-
steps require a section
|
|
1042
|
+
steps require a section.
|
|
1070
1043
|
- An optional `### gate` inside a step section carries its gate rubric. Omitted
|
|
1071
1044
|
or empty rubric text skips validation.
|
|
1072
1045
|
|
|
@@ -1350,7 +1323,7 @@ akm upgrade --next # Install the newest prerelease (@next) instead of the
|
|
|
1350
1323
|
| `--check` | Report pending updates (CLI and per-harness plugins) without changing anything |
|
|
1351
1324
|
| `--force` | Force upgrade even if on latest version |
|
|
1352
1325
|
| `--skip-post-upgrade` | Skip the post-upgrade index rebuild |
|
|
1353
|
-
| `--next` | Follow the `next` prerelease channel: install the newest prerelease of akm (and of the OpenCode plugin, see
|
|
1326
|
+
| `--next` | Follow the `next` prerelease channel: install the newest prerelease of akm (and of the OpenCode plugin, see the Prereleases section below). Works with `--check`, `--force` and `-q` |
|
|
1354
1327
|
|
|
1355
1328
|
Offline, or to migrate without a release check, run `akm migrate apply`
|
|
1356
1329
|
directly: it is the same step.
|
|
@@ -1367,7 +1340,19 @@ stopping the CLI upgrade.
|
|
|
1367
1340
|
| --- | --- | --- |
|
|
1368
1341
|
| Claude Code | `claude` is on `PATH`, the `akm-plugins` marketplace is configured and `akm@akm-plugins` is installed | `claude plugin marketplace update akm-plugins`, then `claude plugin update akm@akm-plugins` |
|
|
1369
1342
|
| Codex | `codex` is on `PATH` and `akm@akm-plugins` is installed from the `akm-plugins` marketplace | `codex plugin marketplace upgrade akm-plugins` (this also refreshes the installed plugin cache) |
|
|
1370
|
-
| OpenCode | `akm-opencode` is cached at `$XDG_CACHE_HOME/opencode/packages/akm-opencode@latest` (default `~/.cache/opencode/...`) and `opencode` is on `PATH` | If npm's `akm-opencode@latest` differs from the cached version and no OpenCode process is running: the cache directory is moved to the trash (never deleted), then `opencode debug config` is run from a temporary directory to fetch the new version. While OpenCode runs the update is `deferred` to a later `akm upgrade`. |
|
|
1343
|
+
| OpenCode 1 | `akm-opencode` is cached at `$XDG_CACHE_HOME/opencode/packages/akm-opencode@latest` (default `~/.cache/opencode/...`) and `opencode` is on `PATH` | If npm's `akm-opencode@latest` differs from the cached version and no OpenCode process is running: the cache directory is moved to the trash (never deleted), then `opencode debug config` is run from a temporary directory to fetch the new version. While OpenCode runs the update is `deferred` to a later `akm upgrade`. |
|
|
1344
|
+
| OpenCode 2 | `akm-opencode-v2` is named under `"plugins"` in the global OpenCode config (`opencode.json` or `.jsonc`) and cached at `$XDG_CACHE_HOME/opencode/npm/akm-opencode-v2@latest/<build>/`, and the `opencode` on `PATH` is OpenCode 2 | Same rule as OpenCode 1, with `akm-opencode-v2`: the cache folder is moved to the trash, then `opencode plugin add akm-opencode-v2` is run from a temporary directory (for a spec the config already names it only re-installs the cache; it does not touch the config). Listed only on a host that has the plugin, so an OpenCode 1 host reports exactly what it did before. |
|
|
1345
|
+
|
|
1346
|
+
The two OpenCode plugins never touch each other: `akm-opencode` is only looked
|
|
1347
|
+
for in OpenCode 1's cache and `plugin` key, `akm-opencode-v2` only in OpenCode
|
|
1348
|
+
2's cache and `plugins` key. Before moving a cache, akm reads `opencode
|
|
1349
|
+
--version` and skips the plugin when the `opencode` on `PATH` is the other
|
|
1350
|
+
major, since only the matching major can re-create that cache; akm never
|
|
1351
|
+
installs or replaces `opencode`. A spec that appears only under the legacy
|
|
1352
|
+
`plugin` key for OpenCode 2 is skipped with a note (`opencode plugin add`
|
|
1353
|
+
would write a `plugins` entry). Which OpenCode major akm itself drives is
|
|
1354
|
+
[detected from the engine's binary](configuration.md#engines), independent of this
|
|
1355
|
+
step.
|
|
1371
1356
|
|
|
1372
1357
|
Claude Code does not update third-party marketplaces on its own (the Claude
|
|
1373
1358
|
desktop app turns plugin updates off), and OpenCode never re-checks a cached
|
|
@@ -1375,7 +1360,7 @@ plugin, so neither moves without this step. Codex refreshes its git
|
|
|
1375
1360
|
marketplaces at every start.
|
|
1376
1361
|
|
|
1377
1362
|
The result gains a `plugins` array, one entry per harness:
|
|
1378
|
-
`{ "harness": "claude-code" | "codex" | "opencode", "outcome": ..., "from"?, "to"?, "message"? }`.
|
|
1363
|
+
`{ "harness": "claude-code" | "codex" | "opencode" | "opencode-v2", "outcome": ..., "from"?, "to"?, "message"? }`.
|
|
1379
1364
|
`outcome` is `updated`, `current`, `skipped`, `deferred` or `failed`; under
|
|
1380
1365
|
`--check` it can also be `pending` or `unknown`. `--check` does not fetch the
|
|
1381
1366
|
Claude Code or Codex marketplaces, so for them it reports `unknown` (whether a
|
|
@@ -1393,7 +1378,9 @@ target is the akm-cli that `akm-opencode@latest` depends on
|
|
|
1393
1378
|
The result then carries `lockstep: { plugin, pinnedVersion, newestVersion, heldBack }`,
|
|
1394
1379
|
`latestVersion` is the pinned version, the install names that exact version
|
|
1395
1380
|
rather than `@latest`, and the text output says the CLI is held back. The CLI
|
|
1396
|
-
is never moved backwards to meet the pin.
|
|
1381
|
+
is never moved backwards to meet the pin. With both OpenCode plugins present
|
|
1382
|
+
(`akm-opencode` and `akm-opencode-v2`), the CLI is held to the older of their
|
|
1383
|
+
two pins, and `lockstep.plugin` names the one that sets it. Claude Code and Codex have no
|
|
1397
1384
|
in-process copy and are not part of this rule.
|
|
1398
1385
|
|
|
1399
1386
|
Lockstep fails closed. When the OpenCode plugin is cached but the pin cannot
|
|
@@ -1431,6 +1418,10 @@ carries `channel: "next"` (`"latest"` otherwise); no other field changes.
|
|
|
1431
1418
|
`@latest` does, or its `akm-cli` pin is unreadable, the CLI is held where it is and the OpenCode entry
|
|
1432
1419
|
is `failed`, exactly as in the stable lockstep above.
|
|
1433
1420
|
|
|
1421
|
+
OpenCode 2's `akm-opencode-v2` follows the same rule with its own spec:
|
|
1422
|
+
`{ "plugins": ["akm-opencode-v2@next"] }`, cached under
|
|
1423
|
+
`$XDG_CACHE_HOME/opencode/npm/akm-opencode-v2@next/`.
|
|
1424
|
+
|
|
1434
1425
|
Without that line the OpenCode entry is `skipped`, its message names the line
|
|
1435
1426
|
to add, and lockstep stays against the `@latest` pin, so the CLI does not go
|
|
1436
1427
|
past what OpenCode will run.
|
|
@@ -1714,8 +1705,8 @@ file path, a single HTTP/HTTPS URL, or `-` for stdin.
|
|
|
1714
1705
|
|
|
1715
1706
|
**Write target resolution:** the destination is the working bundle
|
|
1716
1707
|
(`defaultBundle`) unless `defaultWriteTarget` is set in config, which
|
|
1717
|
-
overrides it to a named source. An explicit `--
|
|
1718
|
-
both. The full order is `--
|
|
1708
|
+
overrides it to a named source. An explicit `--bundle <name>` flag overrides
|
|
1709
|
+
both. The full order is `--bundle` → `defaultWriteTarget` → working bundle →
|
|
1719
1710
|
`ConfigError`. See [Configuration](configuration.md#bundles-and-write-target) for
|
|
1720
1711
|
details.
|
|
1721
1712
|
|
|
@@ -1732,14 +1723,14 @@ akm import ./notes/oauth-quirks.md --xref knowledge/auth/vendor-x-token-api
|
|
|
1732
1723
|
akm import ./notes/modern-guide.md --supersedes knowledge/legacy-guide
|
|
1733
1724
|
|
|
1734
1725
|
# Route the write to a specific writable bundle:
|
|
1735
|
-
akm import ./docs/auth-flow.md --
|
|
1726
|
+
akm import ./docs/auth-flow.md --bundle team-bundle
|
|
1736
1727
|
```
|
|
1737
1728
|
|
|
1738
1729
|
| Flag | Description |
|
|
1739
1730
|
| --- | --- |
|
|
1740
1731
|
| `--name` | Optional knowledge name. Defaults to the source filename, URL path, or a slug from stdin content |
|
|
1741
1732
|
| `--force` | Overwrite an existing knowledge document with the same name |
|
|
1742
|
-
| `--
|
|
1733
|
+
| `--bundle <name>` | Override the write destination. Accepts a source name from your config; falls back to `defaultWriteTarget` then the working bundle. |
|
|
1743
1734
|
| `--xref <ref>` | Cross-reference ref merged into the document's `xrefs:` frontmatter list. Repeatable. A document without frontmatter gains a block; a document with valid frontmatter keeps every existing key and value and gets the refs dedupe-appended (never a nested second block). Each ref must resolve in the write target or a configured source; an unresolvable ref fails with exit 2 before anything is written. If the document's existing frontmatter is not a parseable YAML mapping, the import fails (exit 2) rather than rewriting the block lossily — fix the frontmatter or import without `--xref`, which preserves the file verbatim. |
|
|
1744
1735
|
| `--supersedes <ref>` | Ref of an existing asset this document corrects. Repeatable. Imports the correction with the old ref merged into its `xrefs:` AND demotes the old asset (`beliefState: superseded` + `supersededBy: [<new ref>]`, a metadata-only frontmatter edit), then reindexes it. Same validation (including the self-supersede rejection), skipped-demotion (`applied: false`), idempotence, and git-boundary-commit behaviour as on `remember` (see above). |
|
|
1745
1736
|
|
|
@@ -1921,15 +1912,16 @@ akm registry remove my-team --yes # Skip the confirmation prompt
|
|
|
1921
1912
|
Inspect or apply every pending migration in one plan. `akm migrate` is a thin
|
|
1922
1913
|
wrapper over the standalone `akm-migrate` executable (installed alongside
|
|
1923
1914
|
`akm`, and embedded in the release binary), which owns every historical shape
|
|
1924
|
-
akm
|
|
1915
|
+
akm 0.9.15 and later wrote so the CLI proper reads only current schemas. The steps,
|
|
1925
1916
|
in order:
|
|
1926
1917
|
|
|
1927
1918
|
1. config.json rewritten in its current shape (`configFile`): retired and
|
|
1928
|
-
unknown keys dropped,
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1919
|
+
unknown keys dropped, `configVersion` bumped — the same pipeline every
|
|
1920
|
+
load already runs in memory, so this only persists it, under a backup. A
|
|
1921
|
+
config older than 0.9.15 (the legacy `stashDir`/`sources[]`/`installed`
|
|
1922
|
+
layout, an `extraParams` key that shadows a first-class engine field) is
|
|
1923
|
+
not converted by 0.10 and blocks this step: run `akm migrate apply` under
|
|
1924
|
+
akm 0.9.x first;
|
|
1933
1925
|
2. pending `state.db` migrations, historical-destructive ones included, with
|
|
1934
1926
|
a verified sibling safety copy (`stateMigrations`) — the only path besides
|
|
1935
1927
|
`akm upgrade` that admits released migration 018, which an ordinary
|
|
@@ -1984,7 +1976,6 @@ akm config set output.detail full # Set one key
|
|
|
1984
1976
|
akm config set output.detail full --silent # Set without the post-write config dump on stdout
|
|
1985
1977
|
akm config unset llm # Remove an optional key
|
|
1986
1978
|
akm config path # Print path to config file
|
|
1987
|
-
akm config path --all # Print all config-related paths
|
|
1988
1979
|
akm config diff other-host/config.json # Effective-config differences, secrets redacted
|
|
1989
1980
|
```
|
|
1990
1981
|
|
|
@@ -1996,7 +1987,7 @@ Subcommands:
|
|
|
1996
1987
|
| `list` | List current configuration |
|
|
1997
1988
|
| `set <key> <value>` | Set one config key; prints the resulting config with `ok: true` |
|
|
1998
1989
|
| `unset <key>` | Unset an optional key, or a whole `embedding`/engine section; prints the resulting config with `ok: true` |
|
|
1999
|
-
| `path` |
|
|
1990
|
+
| `path` | Print the config file path (`akm info` reports the bundle, config, data, cache and state directories). Load-bearing: `config path` is the one subcommand the CLI still allows to run when the on-disk config itself fails to load, so you always have a way to locate a broken config. |
|
|
2000
1991
|
| `diff <path\|bundle//path>` | Compare this instance's effective config (its own `extends` already applied) against another config file or bundle-relative file (loaded through the same loader — its `extends` honoured too); prints sorted `{ path, local, other }` rows for every differing leaf, secrets redacted on both sides. |
|
|
2001
1992
|
|
|
2002
1993
|
`set` and `unset` accept `--silent` to suppress the post-write config dump
|
|
@@ -2048,14 +2039,13 @@ column borrow its model from a configured engine instead of a literal string.
|
|
|
2048
2039
|
|
|
2049
2040
|
### help
|
|
2050
2041
|
|
|
2051
|
-
Print the sectioned command overview, detailed help for any command,
|
|
2052
|
-
|
|
2042
|
+
Print the sectioned command overview, detailed help for any command, or a
|
|
2043
|
+
release's migration guidance.
|
|
2053
2044
|
|
|
2054
2045
|
```sh
|
|
2055
2046
|
akm help # Sectioned command overview (same as `akm --help`)
|
|
2056
2047
|
akm help bundle # Detailed options and subcommands for `bundle`
|
|
2057
2048
|
akm help env # Detailed options and subcommands for `env`
|
|
2058
|
-
akm help agents # Agent-facing usage instructions
|
|
2059
2049
|
akm help migrate 0.6.0 # Notes for a specific release
|
|
2060
2050
|
akm help migrate v0.6.0 # v-prefix accepted
|
|
2061
2051
|
akm help migrate v0.6.0-rc1 # Prereleases normalize to the stable note
|
|
@@ -2074,22 +2064,12 @@ unknown version prints the list of bundled notes so you can pick one that
|
|
|
2074
2064
|
exists. See [`CONTRIBUTING.md`](https://github.com/itlackey/akm/blob/main/.github/CONTRIBUTING.md#shipping-a-release--migration-notes)
|
|
2075
2065
|
for the per-release workflow.
|
|
2076
2066
|
|
|
2077
|
-
### help agents
|
|
2078
|
-
|
|
2079
|
-
Print agent-facing instructions for using `akm`. Add this output to your
|
|
2080
|
-
`AGENTS.md`, `CLAUDE.md`, or system prompt so your agent knows how to use
|
|
2081
|
-
the CLI. Prints the short guide by default; pass `--full` for the complete
|
|
2082
|
-
one.
|
|
2083
|
-
|
|
2084
|
-
```sh
|
|
2085
|
-
akm help agents
|
|
2086
|
-
```
|
|
2087
|
-
|
|
2088
2067
|
### hints
|
|
2089
2068
|
|
|
2090
|
-
Print the agent-facing CLI guide
|
|
2091
|
-
|
|
2092
|
-
|
|
2069
|
+
Print the agent-facing CLI guide. Add this output to your `AGENTS.md`,
|
|
2070
|
+
`CLAUDE.md`, or system prompt so your agent knows how to use the CLI. The
|
|
2071
|
+
complete guide is the default; use `--detail brief` for the compact version.
|
|
2072
|
+
(`akm help agents`, the short-first form, was removed in 0.10.)
|
|
2093
2073
|
|
|
2094
2074
|
```sh
|
|
2095
2075
|
akm hints
|
|
@@ -2146,9 +2126,9 @@ akm does not manage individual keys — edit the `.env` file directly (`$EDITOR
|
|
|
2146
2126
|
"$(akm env path <ref>)"`). `env remove <ref>` removes the whole file.
|
|
2147
2127
|
|
|
2148
2128
|
Env mutations (`create`, `remove`) pick their write destination the same way
|
|
2149
|
-
every other write command does: an explicit `--
|
|
2129
|
+
every other write command does: an explicit `--bundle <source>` wins, else
|
|
2150
2130
|
`defaultWriteTarget`, else the working bundle. The chosen source must be
|
|
2151
|
-
writable — a non-writable `--
|
|
2131
|
+
writable — a non-writable `--bundle`/`defaultWriteTarget` fails with a
|
|
2152
2132
|
`ConfigError` before anything is written — and on a git-backed writable target
|
|
2153
2133
|
the mutation lands in a single boundary commit (filesystem targets are
|
|
2154
2134
|
committed by `akm sync`; `env/` stays out of git when your bundle `.gitignore`
|
|
@@ -2212,7 +2192,7 @@ akm env create prod --from-file ./.env # seed from an existing .env (byte-for
|
|
|
2212
2192
|
printf 'A=1\nB=2\n' | akm env create prod --from-stdin
|
|
2213
2193
|
akm env create prod --path staging # creates env/staging/prod.env
|
|
2214
2194
|
akm env create prod --sensitive # hidden from `env list` and the search index
|
|
2215
|
-
akm env create prod --
|
|
2195
|
+
akm env create prod --bundle team # write to the `team` source
|
|
2216
2196
|
```
|
|
2217
2197
|
|
|
2218
2198
|
| Flag | Description |
|
|
@@ -2221,7 +2201,7 @@ akm env create prod --target team # write to the `team` source
|
|
|
2221
2201
|
| `--from-file <path>` | Seed the env file from an existing `.env` at this path |
|
|
2222
2202
|
| `--from-stdin` | Seed the env file from stdin |
|
|
2223
2203
|
| `--sensitive` | Exclude this env file from `env list` output and the search index |
|
|
2224
|
-
| `--
|
|
2204
|
+
| `--bundle <source>` | Override the write destination (falls back to `defaultWriteTarget` then the working bundle) |
|
|
2225
2205
|
|
|
2226
2206
|
Creates `env/prod.env` with mode 0600. Empty `create` is a no-op if the file
|
|
2227
2207
|
exists; `--from-file`/`--from-stdin` **refuse to clobber** an existing env (remove
|
|
@@ -2336,7 +2316,7 @@ of multi-line material. Writes are atomic (mode 0600) under an exclusive
|
|
|
2336
2316
|
`<secret>.lock`. Maximum size is 5 MB.
|
|
2337
2317
|
|
|
2338
2318
|
`secret set` selects its write destination like every other write command: an
|
|
2339
|
-
explicit `--
|
|
2319
|
+
explicit `--bundle <source>` wins, else `defaultWriteTarget`, else the working
|
|
2340
2320
|
bundle. The chosen source must be writable (a non-writable target fails with a
|
|
2341
2321
|
`ConfigError`), and on a git-backed writable target the mutation lands in a
|
|
2342
2322
|
single boundary commit. Reads (`list`, `run`) still span all configured sources.
|
|
@@ -2570,7 +2550,7 @@ tombstone under `.akm/memory-cleanup/archive/` and is not reported (#884). Also
|
|
|
2570
2550
|
`dangerous-env-key` findings for env files (the same key set `akm bundle add`
|
|
2571
2551
|
enforces — see [Dangerous env key audit](#dangerous-env-key-audit) — but
|
|
2572
2552
|
non-blocking here; `lint` only warns). `--type workflows` structurally parses
|
|
2573
|
-
and compiles
|
|
2553
|
+
and compiles Markdown workflows; errors surface as
|
|
2574
2554
|
`invalid-workflow-structure` findings (0.9.0: this is the only
|
|
2575
2555
|
structural-validation surface now that `akm workflow validate` is gone).
|
|
2576
2556
|
|
|
@@ -2618,7 +2598,7 @@ akm improve --skip-if-locked # for high-frequency scheduled runs: skip
|
|
|
2618
2598
|
akm improve --require-engines # for scheduled runs: abort (exit 78) instead of degrading if an engine/credential is unavailable
|
|
2619
2599
|
akm improve --no-sync # skip the end-of-run git commit entirely (default: on for git-backed bundles)
|
|
2620
2600
|
akm improve --sync --no-push # commit only, skip the push after it
|
|
2621
|
-
akm improve --
|
|
2601
|
+
akm improve --dry-run --strategy consolidate # preview consolidate's resolved engine/model routing; nothing is dispatched
|
|
2622
2602
|
akm improve lessons/my-lesson --show-prompt --format text # print the composed reflect prompt for one asset, unwrapped; no lock/index/engine call
|
|
2623
2603
|
akm improve report # LLM usage/routing report for the most recent real run
|
|
2624
2604
|
akm improve report --run <id> # ...for one specific improve_runs id
|
|
@@ -2628,15 +2608,12 @@ akm improve judge < revision.json # reflect's quality judge on one revision
|
|
|
2628
2608
|
|
|
2629
2609
|
| Flag | Description |
|
|
2630
2610
|
| --- | --- |
|
|
2631
|
-
| `--run <id>` | `report` scope only (#944): show the usage report for one specific `improve_runs` row instead of the most recent real run. Mutually exclusive with `--since`. Rejected with any other scope, or no scope. |
|
|
2632
|
-
| `--since <window>` | `report` scope only (#944): aggregate the usage report over every real (non-dry-run) run started since `<window>` (a duration like `24h`/`7d`, or an ISO timestamp) instead of one run. Mutually exclusive with `--run`. Rejected with any other scope, or no scope. |
|
|
2633
2611
|
| `--task` | Optional extra guidance for this improvement pass |
|
|
2634
2612
|
| `--dry-run` | Show the schema-v2 result on stdout without creating config, data, state, cache, bundle, log, or result artifacts. Dry-run results are never persisted, including on errors or signals. |
|
|
2635
|
-
| `--plan` | Alias for `--dry-run` (#947). Sets the exact same internal flag; no separate code path. Prefer this spelling when the goal is previewing `plan.processes` (resolved process -> engine -> model routing) rather than checking what would be written. |
|
|
2636
2613
|
| `--bundle` | Select the bundle the run improves and writes to (default: `defaultWriteTarget`, else the working bundle); only that bundle's assets are planned. When the ref scope is bundle-qualified, it must name the same bundle |
|
|
2637
2614
|
| `--limit <n>` | Cap the refs the run processes, highest salience first (refs routed to distill only come last). Overrides the strategy's `processes.reflect.limit` and `limit` |
|
|
2638
2615
|
| `--timeout-ms <ms>` | Wall-clock budget for the run (default: `7200000` = 2 hours) |
|
|
2639
|
-
| `--require-feedback-signal` | Turn the
|
|
2616
|
+
| `--require-feedback-signal` | Turn the proactive-maintenance lane off for the run, so only assets with recent feedback are planned |
|
|
2640
2617
|
| `--strategy <name>` | Override the active improve strategy (a built-in or entry under `improve.strategies`) |
|
|
2641
2618
|
| `--json-to-stdout` | Also emit the full persisted JSON result on stdout for a live run. Without this flag, stdout stays empty. Dry-runs always emit their result and are never persisted. |
|
|
2642
2619
|
| `--skip-if-locked` | If another improve run already holds the lock, skip gracefully (exit 0) instead of failing with "already running" (exit 75, `TransientError`, code `IMPROVE_LOCK_HELD` — field follow-up to #948: two legitimate `improve` invocations colliding on this lock is ordinary, retryable contention, not a broken config file). Use for high-frequency scheduled runs so they don't pile up failures while a longer run is in progress. |
|
|
@@ -2656,9 +2633,9 @@ bundle is writable, and a bare ref scope (`akm improve skills/x`) resolves
|
|
|
2656
2633
|
inside the write target only. To improve another bundle, name it
|
|
2657
2634
|
(`akm improve --bundle team`, or `akm improve team//skills/code-review`). A
|
|
2658
2635
|
scheduled `akm improve` therefore covers only its write target: schedule one
|
|
2659
|
-
`akm improve --bundle <name>` run per other bundle. `--dry-run`
|
|
2660
|
-
|
|
2661
|
-
`AKM_BUNDLE_DIR`, then `defaultBundle`), so
|
|
2636
|
+
`akm improve --bundle <name>` run per other bundle. `--dry-run`
|
|
2637
|
+
resolves the bundle the way a live run does (the working bundle starts from
|
|
2638
|
+
`AKM_BUNDLE_DIR`, then `defaultBundle`), so it previews the bundle a live run
|
|
2662
2639
|
improves.
|
|
2663
2640
|
|
|
2664
2641
|
Every stage records what it did with each asset in the improve ledger
|
|
@@ -2687,10 +2664,10 @@ covering doc that ranks lower than the 20th nearest goes unseen. With no stored
|
|
|
2687
2664
|
vector (semantic search off, or the memory not indexed yet) that check does
|
|
2688
2665
|
nothing and the exact slug and whole-body checks still apply.
|
|
2689
2666
|
|
|
2690
|
-
No built-in strategy turns the improve-stage extract process on
|
|
2691
|
-
`
|
|
2692
|
-
|
|
2693
|
-
|
|
2667
|
+
No built-in strategy turns the improve-stage extract process on. Set the
|
|
2668
|
+
selected strategy's process `enabled: true` to opt in. Proactive maintenance is
|
|
2669
|
+
on in `default`; set `processes.proactiveMaintenance.enabled: false` to turn it
|
|
2670
|
+
off. The stage toggle does not disable a direct
|
|
2694
2671
|
`akm proposal extract --type <harness>` or `akm proposal extract --auto`
|
|
2695
2672
|
invocation.
|
|
2696
2673
|
|
|
@@ -2719,18 +2696,16 @@ newer than distill's last attempt. It skips a memory flagged wrong and not
|
|
|
2719
2696
|
edited since (a negative feedback in that window judged the body it still has,
|
|
2720
2697
|
or, recorded without that body's hash, is newer than the file's last write),
|
|
2721
2698
|
and a memory whose only feedback in that window is positive with no reason or
|
|
2722
|
-
note, unless the ref is explicit.
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
(salience and outcome) and plan nothing, so improve does not rewrite on a
|
|
2728
|
-
proactive cadence; they pick only refs in the
|
|
2699
|
+
note, unless the ref is explicit. In a strategy that enables
|
|
2700
|
+
`proactiveMaintenance` (`default` does), a further lane plans refs with no such
|
|
2701
|
+
feedback that are due for a revisit: at most `maxPerRun` (default 15) per run,
|
|
2702
|
+
only refs not reflected or distilled for `dueDays` (default 30), so each comes up
|
|
2703
|
+
at most once a month. It picks only refs in the
|
|
2729
2704
|
[retrieval scope](https://github.com/itlackey/akm/blob/main/docs/architecture/improvement.md#retrieval-scope): returned by
|
|
2730
2705
|
`search`, `curate` or `show`, or named by feedback, in the last 90 days, or new
|
|
2731
2706
|
material no improve stage has processed. The planned refs are ranked by salience
|
|
2732
2707
|
and cut to the limit; an explicit ref scope bypasses every gate. Use
|
|
2733
|
-
`--require-feedback-signal` to turn
|
|
2708
|
+
`--require-feedback-signal` to turn that lane off for the run.
|
|
2734
2709
|
|
|
2735
2710
|
When the active strategy enables a process (or the triage judgment engine)
|
|
2736
2711
|
whose engine or credential cannot be resolved in this process's environment,
|
|
@@ -2745,7 +2720,7 @@ itself. `ok` and the exit code are unchanged either way, matching `extract`'s
|
|
|
2745
2720
|
`skippedProcesses` (or pass `--require-engines` to abort instead of
|
|
2746
2721
|
degrading). `reason` names which engine and which credential reference (an env
|
|
2747
2722
|
var, `apiKeyFile` path, or `secret://` reference — never its value) is
|
|
2748
|
-
missing. A `--dry-run
|
|
2723
|
+
missing. A `--dry-run` preview never dispatches, so it never aborts
|
|
2749
2724
|
on an unavailable credential either — even a strategy left with every process
|
|
2750
2725
|
disabled this way still returns its plan, with the affected processes in
|
|
2751
2726
|
`skippedProcesses`.
|
|
@@ -2796,11 +2771,11 @@ still carries that engine's `engine`/`model`/`engineKind` alongside
|
|
|
2796
2771
|
`unavailable`, rather than omitting them the way a never-configured process
|
|
2797
2772
|
does — so a preview can show what would have run. This table is
|
|
2798
2773
|
resolved before any dispatch on every invocation (dry or live), so
|
|
2799
|
-
`akm improve --dry-run --strategy <name>`
|
|
2774
|
+
`akm improve --dry-run --strategy <name>` previews an ad-hoc
|
|
2800
2775
|
strategy override without changing config first; `akm health`'s
|
|
2801
2776
|
`active-improve-strategy` check performs the equivalent resolution but only
|
|
2802
2777
|
for the configured default strategy (`defaults.improveStrategy`), and reports
|
|
2803
|
-
no model or per-process notices.
|
|
2778
|
+
no model or per-process notices. `--dry-run` does not probe
|
|
2804
2779
|
engine reachability over the network — pair with `akm health --probe` (or the
|
|
2805
2780
|
default probe-on behavior) to check whether a named engine actually answers.
|
|
2806
2781
|
|
|
@@ -2825,9 +2800,12 @@ destination than `memory`.
|
|
|
2825
2800
|
`akm improve report` (#944) answers "which engine did each model-calling process
|
|
2826
2801
|
use this run, how much did it cost, and which enabled processes made zero
|
|
2827
2802
|
calls (and why)" without hand-written SQLite against `state.db`. It is a
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2803
|
+
real subcommand (`report` is not an asset type, so it is not a scope of the
|
|
2804
|
+
improve run). It takes two flags of its own, `--run <id>` (the usage report for
|
|
2805
|
+
one specific `improve_runs` row instead of the most recent real run) and
|
|
2806
|
+
`--since <window>` (aggregate over every real, non-dry-run run started since a
|
|
2807
|
+
duration like `24h`/`7d` or an ISO timestamp); they are mutually exclusive, and on
|
|
2808
|
+
`akm improve` itself they are unknown flags (exit 2).
|
|
2831
2809
|
|
|
2832
2810
|
Every real (non-dry-run) `akm improve` invocation persists a `usageReport`
|
|
2833
2811
|
field on the result (`result_json` in `improve_runs`, and in the
|
|
@@ -2862,7 +2840,7 @@ support.
|
|
|
2862
2840
|
|
|
2863
2841
|
#### improve judge
|
|
2864
2842
|
|
|
2865
|
-
`akm improve judge` runs reflect's quality judge on one revision and prints its
|
|
2843
|
+
`akm improve judge` (a real subcommand; `--strategy` is its only flag) runs reflect's quality judge on one revision and prints its
|
|
2866
2844
|
verdict, for testing a judge engine on revisions whose right answer you know. It
|
|
2867
2845
|
reads `{"source": "...", "candidate": "...", "feedback": "...", "ref": "..."}` JSON
|
|
2868
2846
|
from stdin (`feedback` and `ref` are optional; `ref` names the revised asset,
|
|
@@ -2889,15 +2867,15 @@ single queue.
|
|
|
2889
2867
|
|
|
2890
2868
|
New qualified proposals record their destination source name and materialized
|
|
2891
2869
|
root. `proposal diff`, `accept`, and `revert` use that recorded target by
|
|
2892
|
-
default; an explicit `--
|
|
2870
|
+
default; an explicit `--bundle` must resolve to the same source and root or the
|
|
2893
2871
|
command fails with exit 2. An unbound proposal in a selected non-primary queue
|
|
2894
2872
|
uses that authenticated queue root. A short historical unbound proposal
|
|
2895
|
-
mutation requires either an explicit `--
|
|
2873
|
+
mutation requires either an explicit `--bundle` or a selected `--queue` that
|
|
2896
2874
|
authenticates its root; it never falls back to an ambient write target.
|
|
2897
2875
|
|
|
2898
2876
|
#### proposal extract
|
|
2899
2877
|
|
|
2900
|
-
**
|
|
2878
|
+
**Evolving** (see [STABILITY.md](../../STABILITY.md)): measured by the extract eval; 0.10 is still settling the improve defaults, so it is not yet Stable.
|
|
2901
2879
|
|
|
2902
2880
|
Extract durable insights from native coding-agent session files (claude-code,
|
|
2903
2881
|
codex, opencode) and queue them as proposals. This is the standalone
|
|
@@ -3055,7 +3033,7 @@ akm proposal accept <id>
|
|
|
3055
3033
|
akm proposal accept 7c115132 # 8-char UUID prefix
|
|
3056
3034
|
akm proposal accept skills/akm-dream # Asset ref
|
|
3057
3035
|
akm proposal accept <id> --queue team-bundle
|
|
3058
|
-
akm proposal accept <id> --
|
|
3036
|
+
akm proposal accept <id> --bundle team-bundle # Must match a recorded target
|
|
3059
3037
|
akm proposal accept --generator reflect -y # Bulk-accept by generator (requires -y)
|
|
3060
3038
|
akm proposal accept --generator reflect --max-diff-lines 50 -y # ...only if <= 50 lines
|
|
3061
3039
|
akm proposal accept --generator reflect --older-than 7 --dry-run # Preview a bulk accept
|
|
@@ -3064,7 +3042,7 @@ akm proposal accept --generator reflect --older-than 7 --dry-run # Preview a bu
|
|
|
3064
3042
|
| Flag | Description |
|
|
3065
3043
|
| --- | --- |
|
|
3066
3044
|
| `--queue <source>` | Select the proposal queue by configured writable source name |
|
|
3067
|
-
| `--
|
|
3045
|
+
| `--bundle <name>` | Write destination; must match the proposal's recorded target |
|
|
3068
3046
|
| `--generator <name>` | Bulk-accept all pending proposals from this generator (e.g. `reflect`, `distill`). Requires no positional id. |
|
|
3069
3047
|
| `--max-diff-lines` | When bulk-accepting, only accept proposals whose content is `<=` this many lines. Larger proposals are skipped. |
|
|
3070
3048
|
| `--older-than` | When bulk-accepting, only accept proposals created (or last reopened) more than this many days ago |
|
|
@@ -3204,13 +3182,13 @@ to `reverted` and appends a `proposal_reverted` event to the audit log.
|
|
|
3204
3182
|
akm proposal revert <id>
|
|
3205
3183
|
akm proposal revert skills/akm-dream # Asset ref
|
|
3206
3184
|
akm proposal revert <id> --queue team-bundle
|
|
3207
|
-
akm proposal revert <id> --
|
|
3185
|
+
akm proposal revert <id> --bundle team-bundle # Must match a recorded target
|
|
3208
3186
|
```
|
|
3209
3187
|
|
|
3210
3188
|
| Flag | Description |
|
|
3211
3189
|
| --- | --- |
|
|
3212
3190
|
| `--queue <source>` | Select the proposal queue by configured writable source name |
|
|
3213
|
-
| `--
|
|
3191
|
+
| `--bundle <name>` | Select the destination for an unbound proposal, or confirm a recorded destination; a conflict with a recorded target is rejected |
|
|
3214
3192
|
|
|
3215
3193
|
Accepts the full proposal UUID or the asset ref. UUID prefixes are **not**
|
|
3216
3194
|
supported for reverting (archived proposals require the full identifier). Errors
|
|
@@ -3227,13 +3205,13 @@ akm proposal diff <id>
|
|
|
3227
3205
|
akm proposal diff skills/akm-dream # Asset ref form
|
|
3228
3206
|
akm proposal diff 7c115132 # 8-char UUID prefix
|
|
3229
3207
|
akm proposal diff <id> --queue team-bundle
|
|
3230
|
-
akm proposal diff <id> --
|
|
3208
|
+
akm proposal diff <id> --bundle team-bundle # Must match a recorded target
|
|
3231
3209
|
```
|
|
3232
3210
|
|
|
3233
3211
|
| Flag | Description |
|
|
3234
3212
|
| --- | --- |
|
|
3235
3213
|
| `--queue <source>` | Select the proposal queue by configured writable source name |
|
|
3236
|
-
| `--
|
|
3214
|
+
| `--bundle <name>` | Select an unbound destination or confirm a recorded one for `proposal accept`, `diff`, or `revert`; a conflict with a recorded target is rejected |
|
|
3237
3215
|
|
|
3238
3216
|
`proposal accept` runs full validation before promoting. `proposal reject`
|
|
3239
3217
|
requires `--reason`.
|
|
@@ -3280,8 +3258,15 @@ one at a time. One rule decides each proposal: a proposal whose quality judge
|
|
|
3280
3258
|
passed on its current content is accepted (unless its target changed since it
|
|
3281
3259
|
was minted — that one is auto-rejected as `stale-target`); an empty diff is
|
|
3282
3260
|
rejected; a proposal that reflect or distill deferred for review is left for a
|
|
3283
|
-
person;
|
|
3284
|
-
is
|
|
3261
|
+
person; a proposal from the proactive-maintenance lane (no feedback behind it)
|
|
3262
|
+
is left for a person too (reason `proactive-needs-review`), even when its judge
|
|
3263
|
+
passed it; everything else goes to the judgment tier when one is enabled, and
|
|
3264
|
+
is otherwise left for review. The judgment tier may accept only a consolidate
|
|
3265
|
+
promotion (a memory proposed as a new knowledge note); any other kind it would
|
|
3266
|
+
accept, such as a retirement, an exact fix or a reflect revision, is left for a
|
|
3267
|
+
person (reason `judgment-not-promotion`). Judged over every kind, the tier
|
|
3268
|
+
accepted unsafe retirements, applied exact fixes unreviewed and changed notes
|
|
3269
|
+
nobody had touched: 6 to 14 harmed items a night on two models (#1132). A reflect revision that changes the body, and
|
|
3285
3270
|
every distill lesson or knowledge promotion, is deferred for review even when
|
|
3286
3271
|
its judge passes it. Default mode stages decisions (queue mode); pass
|
|
3287
3272
|
`--promote` to actually accept.
|
|
@@ -3300,7 +3285,7 @@ akm proposal drain --strategy default --promote -y # Read the triage block from
|
|
|
3300
3285
|
| `--dry-run` | List what would be accepted/rejected/deferred, without writing |
|
|
3301
3286
|
| `--max-accepts` | Hard per-run accept ceiling; accepts beyond this are reported as `skippedByCap` |
|
|
3302
3287
|
| `--older-than` | Only consider proposals created (or last reopened) more than this many days ago |
|
|
3303
|
-
| `--judgment` | Explicitly enable the judgment tier for this standalone drain, including when the selected strategy says `judgment.enabled: false`; execution overrides still come from that strategy. Without this flag, strategy judgment config does not enable standalone drain judgment. A missing runner remains a no-op with a logged `triage_deferred` summary. |
|
|
3288
|
+
| `--judgment` | Explicitly enable the judgment tier for this standalone drain, including when the selected strategy says `judgment.enabled: false`; it accepts only consolidate promotions (#1132); execution overrides still come from that strategy. Without this flag, strategy judgment config does not enable standalone drain judgment. A missing runner remains a no-op with a logged `triage_deferred` summary. |
|
|
3304
3289
|
| `-y`, `--yes` | Skip the confirmation prompt (required in non-interactive mode for promotion) |
|
|
3305
3290
|
|
|
3306
3291
|
### feedback (`--reason`)
|
|
@@ -3326,15 +3311,14 @@ shell commands. It manages on-disk task definitions under
|
|
|
3326
3311
|
(cron / launchd / schtasks). Task source v4 YAML (`version: 4`) is the only
|
|
3327
3312
|
executable source contract this release accepts; `akm task add` writes v4 —
|
|
3328
3313
|
see the canonical [Tasks reference](tasks.md). The
|
|
3329
|
-
group is `add | enable | disable | run | explain | validate |
|
|
3314
|
+
group is `add | enable | disable | run | explain | validate | sync | doctor | history | prune`
|
|
3330
3315
|
— there is no `show` or `remove`; use `akm show tasks/<id>` to inspect one
|
|
3331
3316
|
task. Use `task enable` / `task disable` for host-local activation; edit the
|
|
3332
3317
|
file only to change the authored schedule or remove the task.
|
|
3333
|
-
|
|
3334
|
-
spellings return the identical envelope.
|
|
3318
|
+
List tasks with `akm search --type task`.
|
|
3335
3319
|
|
|
3336
3320
|
```sh
|
|
3337
|
-
akm task
|
|
3321
|
+
akm search --type task # List tasks (cross-bundle)
|
|
3338
3322
|
akm show tasks/<id> # Inspect one task
|
|
3339
3323
|
akm task add <id> --schedule "@daily" \ # Register a new task and install it
|
|
3340
3324
|
--command "akm improve --strategy default"
|
|
@@ -3345,7 +3329,6 @@ akm task enable team//tasks/nightly # Add local activation and sync its bu
|
|
|
3345
3329
|
akm task disable team//tasks/nightly # Remove local activation and unschedule it
|
|
3346
3330
|
akm task run <id> # Execute now (what the scheduler calls)
|
|
3347
3331
|
akm task explain <ref> # Read-only: declared inputs, target, schedule — spawns nothing
|
|
3348
|
-
akm task validate <path> # Read-only: parse one task file by path, report sync's diagnostic
|
|
3349
3332
|
akm task history [<id>] [--id <id>] [--limit <n>] # Recent runs from state.db (positional id == --id)
|
|
3350
3333
|
akm task sync # Reconcile activated refs from all enabled configured bundles
|
|
3351
3334
|
akm task sync --dry-run # Preview the reconcile — zero scheduler writes
|
|
@@ -3361,13 +3344,6 @@ this host's scheduler activation), `--force` (overwrite an existing task with
|
|
|
3361
3344
|
the same id), and `--rebind` (also point the bundle's installed scheduler rows
|
|
3362
3345
|
at this akm invocation, as `akm task sync --rebind` does).
|
|
3363
3346
|
|
|
3364
|
-
`akm task list [<query>] [--limit <n>] [--from local|registry|all]` is a
|
|
3365
|
-
pure alias for `akm search --type task` with the query, `--limit`, and
|
|
3366
|
-
`--from` flags passed through — same envelope, same `results` alias, no
|
|
3367
|
-
second implementation. 0.9.0 removed `task list` as a redundant
|
|
3368
|
-
implementation of task listing (see the 0.9.0 CHANGELOG entry); this
|
|
3369
|
-
reintroduces only the spelling, not the logic.
|
|
3370
|
-
|
|
3371
3347
|
`akm task explain <ref> [input flags]` prints a task's declared `inputs:`,
|
|
3372
3348
|
the values that would actually be supplied (with provenance), the resolved
|
|
3373
3349
|
target, effective execution settings, and schedule bindings — **read-only**:
|
|
@@ -3375,28 +3351,6 @@ it never spawns anything, writes history, or touches the scheduler. A
|
|
|
3375
3351
|
secret-shaped value prints as `<redacted>`. See
|
|
3376
3352
|
[`akm task explain`](tasks.md#akm-task-explain).
|
|
3377
3353
|
|
|
3378
|
-
`akm task validate <path>` parses ONE task file by filesystem path — not a
|
|
3379
|
-
concept ref or id, and the file need not live in any configured bundle —
|
|
3380
|
-
and reports the same diagnostic `akm task sync` would produce for it,
|
|
3381
|
-
INCLUDING sync's own cron-dialect check and its per-schedule-entry
|
|
3382
|
-
input-contract check (so a file `sync` would reject can never be reported
|
|
3383
|
-
`valid` here): `{ok, path, sourceVersion, outcome, reason?,
|
|
3384
|
-
resolved?}` where `outcome` is `valid` (parses as task source v4 directly
|
|
3385
|
-
and passes both sync checks), `blocked` (task v2/v3 that must first be
|
|
3386
|
-
rewritten by `akm migrate apply`), `invalid` (the YAML doesn't parse, or the document fails schema
|
|
3387
|
-
validation, or it parsed but fails one of the two sync checks), or
|
|
3388
|
-
`not-a-task` (the YAML parses but never declares a `version:` field — not
|
|
3389
|
-
shaped like a task source). `resolved` is the compiled task shape
|
|
3390
|
-
`akm task sync` itself would build a scheduler binding from — id, the
|
|
3391
|
-
compiled schema version, resolved `uses`/`run` target, declared `inputs`
|
|
3392
|
-
contract, and `schedule` bindings — present only on `valid`.
|
|
3393
|
-
Unlike `akm task explain`, it never runs execution lowering: a command-kind
|
|
3394
|
-
task validates the same whether or not the local config has an engine
|
|
3395
|
-
configured. Exits 0 for `valid`, 1 for
|
|
3396
|
-
`blocked`/`invalid`/`not-a-task`, 2 for a missing or unreadable path.
|
|
3397
|
-
**Read-only**: it never touches the scheduler and never requires the file to
|
|
3398
|
-
be indexed or wired into a bundle.
|
|
3399
|
-
|
|
3400
3354
|
`akm task run` is what cron / launchd / schtasks invoke at the scheduled
|
|
3401
3355
|
time. Each run is recorded as a row in the durable `task_history` table
|
|
3402
3356
|
(`state.db`), surfaced by `akm task history` — **not** by `akm log`; there is
|