akm-cli 0.9.31 → 0.10.26101002-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 +265 -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/eligibility.js +14 -1
- package/dist/commands/improve/extract-cli.js +1 -1
- package/dist/commands/improve/improve-cli.js +87 -102
- package/dist/commands/improve/improve-strategies.js +8 -12
- package/dist/commands/improve/improve.js +2 -2
- 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 +11 -31
- 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/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 +41 -11
- 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 +13049 -14013
- package/dist/scripts/akm-migrate.js +16316 -17276
- 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 +1 -1
- package/docs/agents/README.md +3 -3
- package/docs/agents/agent-install.md +1 -1
- package/docs/architecture/adapters.md +17 -31
- package/docs/architecture/architecture.md +4 -5
- package/docs/architecture/improvement.md +52 -21
- package/docs/architecture/internals/improve-workflow.md +15 -8
- package/docs/architecture/internals/indexing.md +1 -1
- package/docs/architecture/internals/search.md +1 -2
- package/docs/architecture/internals/storage-locations.md +5 -5
- package/docs/architecture/persisted-data-compat.md +13 -4
- package/docs/architecture/specs/0.9.0-decisions.md +6 -2
- package/docs/architecture/specs/improve-collapse-churn-detector-design.md +2 -2
- package/docs/architecture/specs/workflow-format-unification.md +1 -6
- package/docs/architecture/testing/manual-testing-checklist.md +20 -29
- package/docs/architecture/testing/task-workflow-manual-tests.md +106 -203
- package/docs/architecture/testing/testing-workflow.md +1 -1
- package/docs/architecture/workflow-engine.md +5 -56
- package/docs/guides/author-workflows.md +39 -69
- package/docs/guides/capture-knowledge.md +1 -1
- package/docs/guides/claude-code-vs-akm-workflows.md +1 -2
- package/docs/guides/discover-and-load.md +4 -4
- package/docs/guides/getting-started.md +1 -1
- package/docs/guides/improve-the-library.md +7 -7
- package/docs/guides/recipes/headless-install.md +2 -2
- package/docs/guides/run-workflows.md +1 -1
- package/docs/guides/use-with-any-agent.md +49 -4
- package/docs/integration/bundling-akm.md +7 -6
- package/docs/maintainers/curate-workmap.md +1 -2
- package/docs/maintainers/release-checklist.md +30 -1
- package/docs/posts/akm-command-tour.md +3 -3
- package/docs/product-surface.md +1 -1
- package/docs/reference/README.md +1 -0
- package/docs/reference/api.md +65 -0
- package/docs/reference/asset-types.md +3 -5
- package/docs/reference/bundle-types.md +2 -4
- package/docs/reference/cli.md +129 -171
- package/docs/reference/configuration.md +84 -19
- package/docs/reference/data-and-telemetry.md +1 -1
- package/docs/reference/env-and-secrets.md +2 -2
- package/docs/reference/supported-formats.md +3 -4
- package/docs/reference/tasks.md +12 -19
- package/docs/reference/website-sources.md +1 -1
- package/docs/reference/workflow-schema.md +89 -317
- package/docs/reference/workflows.md +20 -48
- package/package.json +12 -2
- 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,10 +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 the `--shape summary`
|
|
618
|
-
section above; it is a usage error (exit 2) everywhere except `akm show`.
|
|
606
|
+
| `agent` | `name`, `ref`, `type`, `path`, `editable`, conditional `editHint`, `description`, `action`, `score`, optional `estimatedTokens`/`keys` | no local access fields |
|
|
619
607
|
|
|
620
608
|
There is no registry `curated` boolean. Renderers surface an optional
|
|
621
609
|
`warnings: string[]` field on hits when a provider has non-fatal issues to
|
|
@@ -661,8 +649,7 @@ candidates (`search.curateRerank.topN`) by name, description and the start of
|
|
|
661
649
|
each asset's indexed content. Curate includes direct follow-up
|
|
662
650
|
commands such as `akm show <ref>` or `akm bundle add <ref>` so you can
|
|
663
651
|
immediately inspect or install what it found.
|
|
664
|
-
`--detail`
|
|
665
|
-
does not.
|
|
652
|
+
`--detail` (including `agent`) works on curate output.
|
|
666
653
|
Curate preserves the underlying search's `searchMode` and warnings.
|
|
667
654
|
Agent-shaped local items include `ref`, `path`, and `editable`, plus `editHint`
|
|
668
655
|
only for read-only items. Their `followUp` remains `akm show <ref>` rather than
|
|
@@ -731,20 +718,15 @@ filter. A mismatch (or absent scope) returns `NotFoundError` so the caller
|
|
|
731
718
|
cannot accidentally read out-of-scope content.
|
|
732
719
|
|
|
733
720
|
The default `show` JSON includes the asset body when applicable. Canonical
|
|
734
|
-
`ref` is always present,
|
|
735
|
-
|
|
736
|
-
always present too, at every `--detail` level, in the `human` (default) and
|
|
737
|
-
`agent` shapes — `--shape summary` omits both, since it is a compact
|
|
738
|
-
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`/
|
|
739
723
|
`editable` are gated behind `--detail full`. Use `--detail brief` for a
|
|
740
724
|
reduced metadata-first view without `content`/`template`/`prompt`;
|
|
741
725
|
`--detail full` adds verbose extras such as `schemaVersion` and, when
|
|
742
|
-
`editable` is `false`, `editHint`; `--
|
|
726
|
+
`editable` is `false`, `editHint`; `--detail agent` strips non-action metadata
|
|
743
727
|
(e.g. `origin`, `tags`) down to the action-relevant field set while still
|
|
744
|
-
including `ref`/`path`/`editable
|
|
745
|
-
|
|
746
|
-
`parameters`, `workflowTitle`, `action`, `run`, `origin`, and `keys`, plus the
|
|
747
|
-
optional fragment metadata described below.
|
|
728
|
+
including `ref`/`path`/`editable`, plus the optional fragment metadata
|
|
729
|
+
described below.
|
|
748
730
|
|
|
749
731
|
`links` lists the asset's declared links, grouped by kind: `outgoing` (the
|
|
750
732
|
assets its own `xrefs:`, `supersededBy:`, `contradictedBy:`,
|
|
@@ -816,7 +798,7 @@ akm workflow status 7c115132 # 8+ char run-id prefix also works
|
|
|
816
798
|
akm workflow resume <run-id>
|
|
817
799
|
akm workflow abandon <run-id>
|
|
818
800
|
akm workflow list --active
|
|
819
|
-
akm workflow list --children # also list child workflow runs
|
|
801
|
+
akm workflow list --children # also list child workflow runs (Experimental)
|
|
820
802
|
akm workflow list --all-scopes # include runs started from a different working directory
|
|
821
803
|
akm workflow plan workflows/ship-release # compile+freeze preview, zero writes
|
|
822
804
|
```
|
|
@@ -828,10 +810,10 @@ Subcommands:
|
|
|
828
810
|
|
|
829
811
|
| Subcommand | Description |
|
|
830
812
|
| --- | --- |
|
|
831
|
-
| `create <name>` | Validate and write a Markdown workflow under `workflows/`. `--path <dir>` places it in a subdirectory; `--from <file>` imports content; `--force`
|
|
832
|
-
| `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 |
|
|
833
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 |
|
|
834
|
-
| `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) |
|
|
835
817
|
| `resume <run-id>` | Flip a `blocked` or `failed` run back to `active`. Completed runs cannot be resumed |
|
|
836
818
|
| `abandon <run-id>` | Mark a run failed so it stops counting as active (`resume` can reopen it) |
|
|
837
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 |
|
|
@@ -847,8 +829,8 @@ workflow ref is never mistaken for one.
|
|
|
847
829
|
The public `workflow start`, `next`, and `complete` lifecycle was removed in
|
|
848
830
|
0.9, along with the experimental `brief`/`report` external-driver protocol.
|
|
849
831
|
Use `workflow run` for execution and `workflow status` for inspection. The
|
|
850
|
-
removed commands fail with an `UNKNOWN_COMMAND` envelope
|
|
851
|
-
|
|
832
|
+
removed commands fail with an `UNKNOWN_COMMAND` envelope; there are no
|
|
833
|
+
compatibility aliases.
|
|
852
834
|
|
|
853
835
|
There is also no `akm workflow template`, `validate`, or `watch`.
|
|
854
836
|
`workflow create --print` prints a starter, `akm lint --type workflows`
|
|
@@ -907,9 +889,8 @@ has nothing left to abort and nothing left to resume.
|
|
|
907
889
|
|
|
908
890
|
**What `--max-steps` counts.** The budget is spent by the **steps that
|
|
909
891
|
finish** — completed, failed, or gate-rejected with the loop budget spent — not
|
|
910
|
-
by entries in the `executed` report, which gains one per gate-loop iteration
|
|
911
|
-
|
|
912
|
-
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
|
|
913
894
|
step the invocation left unfinished — an abort, a verification-judge outage —
|
|
914
895
|
costs nothing either, because the next invocation still owes that work.
|
|
915
896
|
`--max-retries` subtracts the same way: a reopened run's remaining budget is
|
|
@@ -921,7 +902,7 @@ budget is left. `gate.max_loops` (1–100) is the per-step ceiling;
|
|
|
921
902
|
`budget.max_units` and `budget.max_tokens` are the whole-run ceilings, seeded
|
|
922
903
|
from the unit journal so they hold across resumes.
|
|
923
904
|
|
|
924
|
-
`run` is
|
|
905
|
+
`run` is Experimental and does not consult `experimental.workflowEngine`. Every
|
|
925
906
|
non-empty `### gate` requires `workflow.judgeEngine` to name a configured LLM
|
|
926
907
|
or agent engine before a new run can be frozen. Gate evaluation is fail-closed.
|
|
927
908
|
|
|
@@ -942,7 +923,7 @@ when the cwd is inside it, otherwise the cwd itself. In practice this means:
|
|
|
942
923
|
akm workflow create ship-release
|
|
943
924
|
akm workflow create ship-release --from ./ship-release.md
|
|
944
925
|
akm workflow create ship-release --from ./ship-release.md --force
|
|
945
|
-
akm workflow create ship-release --force
|
|
926
|
+
akm workflow create ship-release --force
|
|
946
927
|
akm workflow create ship --path release # writes workflows/release/ship.md
|
|
947
928
|
```
|
|
948
929
|
|
|
@@ -950,14 +931,9 @@ akm workflow create ship --path release # writes workflows/release/ship
|
|
|
950
931
|
| --- | --- |
|
|
951
932
|
| `--path <dir>` | Relative subdirectory under `workflows/` to place the workflow in. The filename comes from `<name>`. |
|
|
952
933
|
| `--from <file>` | Import and validate a Markdown workflow from an existing file |
|
|
953
|
-
| `--force` | Overwrite an existing workflow
|
|
954
|
-
| `--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 |
|
|
955
935
|
| `--print` | Print the Markdown template without creating anything |
|
|
956
936
|
|
|
957
|
-
`--force` requires either `--from <file>` (replace from a source file) or
|
|
958
|
-
`--reset` (explicitly acknowledge you are overwriting in place). Without one of
|
|
959
|
-
these, `--force` is rejected to prevent silent template overwrites.
|
|
960
|
-
|
|
961
937
|
`<name>` itself must be **flat** — `^[a-z0-9][a-z0-9._/-]*$` after combining
|
|
962
938
|
with `--path`, but the bare `--name` positional is rejected if it contains a
|
|
963
939
|
`/`. Hierarchical placement (`release/ship`) goes through `--path release
|
|
@@ -1012,11 +988,11 @@ Two output modes:
|
|
|
1012
988
|
- **`--format json`**: the full envelope — `ok`, `ref`, `title`,
|
|
1013
989
|
`sourceFormat`, `sourcePath`, `irVersion`, `planHash`, `published` (always
|
|
1014
990
|
`false`, so a consumer can never mistake this for a run envelope),
|
|
1015
|
-
`execution`, `budget?`, `params?`, `
|
|
991
|
+
`execution`, `budget?`, `params?`, `steps[]`, `notices[]`,
|
|
1016
992
|
`warnings[]`. Each step entry carries an `expansion` field
|
|
1017
993
|
naming how its target was reached: `{via: "direct"}`, `{via: "task",
|
|
1018
994
|
taskRef}`, or — for a step composing a child workflow —
|
|
1019
|
-
`{via: "child", childRef, childPlanHash,
|
|
995
|
+
`{via: "child", childRef, childPlanHash, steps[]}` with the
|
|
1020
996
|
child's own step list nested recursively in the same shape.
|
|
1021
997
|
|
|
1022
998
|
Text-mode example:
|
|
@@ -1027,13 +1003,11 @@ source: workflows/release.md
|
|
|
1027
1003
|
plan: irVersion 5, hash 4f2ba91c3d0e… (not published)
|
|
1028
1004
|
limits: maxConcurrency 4; budget max_units 50, max_tokens 100000
|
|
1029
1005
|
params: channel, version
|
|
1030
|
-
outputs: report <- steps.summarize.output
|
|
1031
1006
|
steps:
|
|
1032
1007
|
1. notify [command] direct
|
|
1033
1008
|
2. build [script] via tasks/plan-v4-task
|
|
1034
1009
|
3. dispatch [child-workflow] -> workflows/release-checklist (plan 91acbe20f5d1…)
|
|
1035
1010
|
with: channel="stable" (literal), files <- steps.build.output.files (reference)
|
|
1036
|
-
exports: report, changed_count
|
|
1037
1011
|
3.1 verify [command] direct
|
|
1038
1012
|
4. summarize [command] direct
|
|
1039
1013
|
read set:
|
|
@@ -1065,7 +1039,7 @@ Workflow markdown contract:
|
|
|
1065
1039
|
- Frontmatter carries the asset envelope and orchestration graph (`params`,
|
|
1066
1040
|
`steps`, `defaults`, and `budget`).
|
|
1067
1041
|
- Every `## <step-id>` heading must name a declared step exactly. Unit and map
|
|
1068
|
-
steps require a section
|
|
1042
|
+
steps require a section.
|
|
1069
1043
|
- An optional `### gate` inside a step section carries its gate rubric. Omitted
|
|
1070
1044
|
or empty rubric text skips validation.
|
|
1071
1045
|
|
|
@@ -1366,7 +1340,19 @@ stopping the CLI upgrade.
|
|
|
1366
1340
|
| --- | --- | --- |
|
|
1367
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` |
|
|
1368
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) |
|
|
1369
|
-
| 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.
|
|
1370
1356
|
|
|
1371
1357
|
Claude Code does not update third-party marketplaces on its own (the Claude
|
|
1372
1358
|
desktop app turns plugin updates off), and OpenCode never re-checks a cached
|
|
@@ -1374,7 +1360,7 @@ plugin, so neither moves without this step. Codex refreshes its git
|
|
|
1374
1360
|
marketplaces at every start.
|
|
1375
1361
|
|
|
1376
1362
|
The result gains a `plugins` array, one entry per harness:
|
|
1377
|
-
`{ "harness": "claude-code" | "codex" | "opencode", "outcome": ..., "from"?, "to"?, "message"? }`.
|
|
1363
|
+
`{ "harness": "claude-code" | "codex" | "opencode" | "opencode-v2", "outcome": ..., "from"?, "to"?, "message"? }`.
|
|
1378
1364
|
`outcome` is `updated`, `current`, `skipped`, `deferred` or `failed`; under
|
|
1379
1365
|
`--check` it can also be `pending` or `unknown`. `--check` does not fetch the
|
|
1380
1366
|
Claude Code or Codex marketplaces, so for them it reports `unknown` (whether a
|
|
@@ -1392,7 +1378,9 @@ target is the akm-cli that `akm-opencode@latest` depends on
|
|
|
1392
1378
|
The result then carries `lockstep: { plugin, pinnedVersion, newestVersion, heldBack }`,
|
|
1393
1379
|
`latestVersion` is the pinned version, the install names that exact version
|
|
1394
1380
|
rather than `@latest`, and the text output says the CLI is held back. The CLI
|
|
1395
|
-
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
|
|
1396
1384
|
in-process copy and are not part of this rule.
|
|
1397
1385
|
|
|
1398
1386
|
Lockstep fails closed. When the OpenCode plugin is cached but the pin cannot
|
|
@@ -1430,6 +1418,10 @@ carries `channel: "next"` (`"latest"` otherwise); no other field changes.
|
|
|
1430
1418
|
`@latest` does, or its `akm-cli` pin is unreadable, the CLI is held where it is and the OpenCode entry
|
|
1431
1419
|
is `failed`, exactly as in the stable lockstep above.
|
|
1432
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
|
+
|
|
1433
1425
|
Without that line the OpenCode entry is `skipped`, its message names the line
|
|
1434
1426
|
to add, and lockstep stays against the `@latest` pin, so the CLI does not go
|
|
1435
1427
|
past what OpenCode will run.
|
|
@@ -1713,8 +1705,8 @@ file path, a single HTTP/HTTPS URL, or `-` for stdin.
|
|
|
1713
1705
|
|
|
1714
1706
|
**Write target resolution:** the destination is the working bundle
|
|
1715
1707
|
(`defaultBundle`) unless `defaultWriteTarget` is set in config, which
|
|
1716
|
-
overrides it to a named source. An explicit `--
|
|
1717
|
-
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 →
|
|
1718
1710
|
`ConfigError`. See [Configuration](configuration.md#bundles-and-write-target) for
|
|
1719
1711
|
details.
|
|
1720
1712
|
|
|
@@ -1731,14 +1723,14 @@ akm import ./notes/oauth-quirks.md --xref knowledge/auth/vendor-x-token-api
|
|
|
1731
1723
|
akm import ./notes/modern-guide.md --supersedes knowledge/legacy-guide
|
|
1732
1724
|
|
|
1733
1725
|
# Route the write to a specific writable bundle:
|
|
1734
|
-
akm import ./docs/auth-flow.md --
|
|
1726
|
+
akm import ./docs/auth-flow.md --bundle team-bundle
|
|
1735
1727
|
```
|
|
1736
1728
|
|
|
1737
1729
|
| Flag | Description |
|
|
1738
1730
|
| --- | --- |
|
|
1739
1731
|
| `--name` | Optional knowledge name. Defaults to the source filename, URL path, or a slug from stdin content |
|
|
1740
1732
|
| `--force` | Overwrite an existing knowledge document with the same name |
|
|
1741
|
-
| `--
|
|
1733
|
+
| `--bundle <name>` | Override the write destination. Accepts a source name from your config; falls back to `defaultWriteTarget` then the working bundle. |
|
|
1742
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. |
|
|
1743
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). |
|
|
1744
1736
|
|
|
@@ -1920,15 +1912,16 @@ akm registry remove my-team --yes # Skip the confirmation prompt
|
|
|
1920
1912
|
Inspect or apply every pending migration in one plan. `akm migrate` is a thin
|
|
1921
1913
|
wrapper over the standalone `akm-migrate` executable (installed alongside
|
|
1922
1914
|
`akm`, and embedded in the release binary), which owns every historical shape
|
|
1923
|
-
akm
|
|
1915
|
+
akm 0.9.15 and later wrote so the CLI proper reads only current schemas. The steps,
|
|
1924
1916
|
in order:
|
|
1925
1917
|
|
|
1926
1918
|
1. config.json rewritten in its current shape (`configFile`): retired and
|
|
1927
|
-
unknown keys dropped,
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
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;
|
|
1932
1925
|
2. pending `state.db` migrations, historical-destructive ones included, with
|
|
1933
1926
|
a verified sibling safety copy (`stateMigrations`) — the only path besides
|
|
1934
1927
|
`akm upgrade` that admits released migration 018, which an ordinary
|
|
@@ -1983,7 +1976,6 @@ akm config set output.detail full # Set one key
|
|
|
1983
1976
|
akm config set output.detail full --silent # Set without the post-write config dump on stdout
|
|
1984
1977
|
akm config unset llm # Remove an optional key
|
|
1985
1978
|
akm config path # Print path to config file
|
|
1986
|
-
akm config path --all # Print all config-related paths
|
|
1987
1979
|
akm config diff other-host/config.json # Effective-config differences, secrets redacted
|
|
1988
1980
|
```
|
|
1989
1981
|
|
|
@@ -1995,7 +1987,7 @@ Subcommands:
|
|
|
1995
1987
|
| `list` | List current configuration |
|
|
1996
1988
|
| `set <key> <value>` | Set one config key; prints the resulting config with `ok: true` |
|
|
1997
1989
|
| `unset <key>` | Unset an optional key, or a whole `embedding`/engine section; prints the resulting config with `ok: true` |
|
|
1998
|
-
| `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. |
|
|
1999
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. |
|
|
2000
1992
|
|
|
2001
1993
|
`set` and `unset` accept `--silent` to suppress the post-write config dump
|
|
@@ -2047,14 +2039,13 @@ column borrow its model from a configured engine instead of a literal string.
|
|
|
2047
2039
|
|
|
2048
2040
|
### help
|
|
2049
2041
|
|
|
2050
|
-
Print the sectioned command overview, detailed help for any command,
|
|
2051
|
-
|
|
2042
|
+
Print the sectioned command overview, detailed help for any command, or a
|
|
2043
|
+
release's migration guidance.
|
|
2052
2044
|
|
|
2053
2045
|
```sh
|
|
2054
2046
|
akm help # Sectioned command overview (same as `akm --help`)
|
|
2055
2047
|
akm help bundle # Detailed options and subcommands for `bundle`
|
|
2056
2048
|
akm help env # Detailed options and subcommands for `env`
|
|
2057
|
-
akm help agents # Agent-facing usage instructions
|
|
2058
2049
|
akm help migrate 0.6.0 # Notes for a specific release
|
|
2059
2050
|
akm help migrate v0.6.0 # v-prefix accepted
|
|
2060
2051
|
akm help migrate v0.6.0-rc1 # Prereleases normalize to the stable note
|
|
@@ -2073,22 +2064,12 @@ unknown version prints the list of bundled notes so you can pick one that
|
|
|
2073
2064
|
exists. See [`CONTRIBUTING.md`](https://github.com/itlackey/akm/blob/main/.github/CONTRIBUTING.md#shipping-a-release--migration-notes)
|
|
2074
2065
|
for the per-release workflow.
|
|
2075
2066
|
|
|
2076
|
-
### help agents
|
|
2077
|
-
|
|
2078
|
-
Print agent-facing instructions for using `akm`. Add this output to your
|
|
2079
|
-
`AGENTS.md`, `CLAUDE.md`, or system prompt so your agent knows how to use
|
|
2080
|
-
the CLI. Prints the short guide by default; pass `--full` for the complete
|
|
2081
|
-
one.
|
|
2082
|
-
|
|
2083
|
-
```sh
|
|
2084
|
-
akm help agents
|
|
2085
|
-
```
|
|
2086
|
-
|
|
2087
2067
|
### hints
|
|
2088
2068
|
|
|
2089
|
-
Print the agent-facing CLI guide
|
|
2090
|
-
|
|
2091
|
-
|
|
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.)
|
|
2092
2073
|
|
|
2093
2074
|
```sh
|
|
2094
2075
|
akm hints
|
|
@@ -2145,9 +2126,9 @@ akm does not manage individual keys — edit the `.env` file directly (`$EDITOR
|
|
|
2145
2126
|
"$(akm env path <ref>)"`). `env remove <ref>` removes the whole file.
|
|
2146
2127
|
|
|
2147
2128
|
Env mutations (`create`, `remove`) pick their write destination the same way
|
|
2148
|
-
every other write command does: an explicit `--
|
|
2129
|
+
every other write command does: an explicit `--bundle <source>` wins, else
|
|
2149
2130
|
`defaultWriteTarget`, else the working bundle. The chosen source must be
|
|
2150
|
-
writable — a non-writable `--
|
|
2131
|
+
writable — a non-writable `--bundle`/`defaultWriteTarget` fails with a
|
|
2151
2132
|
`ConfigError` before anything is written — and on a git-backed writable target
|
|
2152
2133
|
the mutation lands in a single boundary commit (filesystem targets are
|
|
2153
2134
|
committed by `akm sync`; `env/` stays out of git when your bundle `.gitignore`
|
|
@@ -2211,7 +2192,7 @@ akm env create prod --from-file ./.env # seed from an existing .env (byte-for
|
|
|
2211
2192
|
printf 'A=1\nB=2\n' | akm env create prod --from-stdin
|
|
2212
2193
|
akm env create prod --path staging # creates env/staging/prod.env
|
|
2213
2194
|
akm env create prod --sensitive # hidden from `env list` and the search index
|
|
2214
|
-
akm env create prod --
|
|
2195
|
+
akm env create prod --bundle team # write to the `team` source
|
|
2215
2196
|
```
|
|
2216
2197
|
|
|
2217
2198
|
| Flag | Description |
|
|
@@ -2220,7 +2201,7 @@ akm env create prod --target team # write to the `team` source
|
|
|
2220
2201
|
| `--from-file <path>` | Seed the env file from an existing `.env` at this path |
|
|
2221
2202
|
| `--from-stdin` | Seed the env file from stdin |
|
|
2222
2203
|
| `--sensitive` | Exclude this env file from `env list` output and the search index |
|
|
2223
|
-
| `--
|
|
2204
|
+
| `--bundle <source>` | Override the write destination (falls back to `defaultWriteTarget` then the working bundle) |
|
|
2224
2205
|
|
|
2225
2206
|
Creates `env/prod.env` with mode 0600. Empty `create` is a no-op if the file
|
|
2226
2207
|
exists; `--from-file`/`--from-stdin` **refuse to clobber** an existing env (remove
|
|
@@ -2335,7 +2316,7 @@ of multi-line material. Writes are atomic (mode 0600) under an exclusive
|
|
|
2335
2316
|
`<secret>.lock`. Maximum size is 5 MB.
|
|
2336
2317
|
|
|
2337
2318
|
`secret set` selects its write destination like every other write command: an
|
|
2338
|
-
explicit `--
|
|
2319
|
+
explicit `--bundle <source>` wins, else `defaultWriteTarget`, else the working
|
|
2339
2320
|
bundle. The chosen source must be writable (a non-writable target fails with a
|
|
2340
2321
|
`ConfigError`), and on a git-backed writable target the mutation lands in a
|
|
2341
2322
|
single boundary commit. Reads (`list`, `run`) still span all configured sources.
|
|
@@ -2569,7 +2550,7 @@ tombstone under `.akm/memory-cleanup/archive/` and is not reported (#884). Also
|
|
|
2569
2550
|
`dangerous-env-key` findings for env files (the same key set `akm bundle add`
|
|
2570
2551
|
enforces — see [Dangerous env key audit](#dangerous-env-key-audit) — but
|
|
2571
2552
|
non-blocking here; `lint` only warns). `--type workflows` structurally parses
|
|
2572
|
-
and compiles
|
|
2553
|
+
and compiles Markdown workflows; errors surface as
|
|
2573
2554
|
`invalid-workflow-structure` findings (0.9.0: this is the only
|
|
2574
2555
|
structural-validation surface now that `akm workflow validate` is gone).
|
|
2575
2556
|
|
|
@@ -2617,7 +2598,7 @@ akm improve --skip-if-locked # for high-frequency scheduled runs: skip
|
|
|
2617
2598
|
akm improve --require-engines # for scheduled runs: abort (exit 78) instead of degrading if an engine/credential is unavailable
|
|
2618
2599
|
akm improve --no-sync # skip the end-of-run git commit entirely (default: on for git-backed bundles)
|
|
2619
2600
|
akm improve --sync --no-push # commit only, skip the push after it
|
|
2620
|
-
akm improve --
|
|
2601
|
+
akm improve --dry-run --strategy consolidate # preview consolidate's resolved engine/model routing; nothing is dispatched
|
|
2621
2602
|
akm improve lessons/my-lesson --show-prompt --format text # print the composed reflect prompt for one asset, unwrapped; no lock/index/engine call
|
|
2622
2603
|
akm improve report # LLM usage/routing report for the most recent real run
|
|
2623
2604
|
akm improve report --run <id> # ...for one specific improve_runs id
|
|
@@ -2627,15 +2608,12 @@ akm improve judge < revision.json # reflect's quality judge on one revision
|
|
|
2627
2608
|
|
|
2628
2609
|
| Flag | Description |
|
|
2629
2610
|
| --- | --- |
|
|
2630
|
-
| `--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. |
|
|
2631
|
-
| `--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. |
|
|
2632
2611
|
| `--task` | Optional extra guidance for this improvement pass |
|
|
2633
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. |
|
|
2634
|
-
| `--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. |
|
|
2635
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 |
|
|
2636
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` |
|
|
2637
2615
|
| `--timeout-ms <ms>` | Wall-clock budget for the run (default: `7200000` = 2 hours) |
|
|
2638
|
-
| `--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 |
|
|
2639
2617
|
| `--strategy <name>` | Override the active improve strategy (a built-in or entry under `improve.strategies`) |
|
|
2640
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. |
|
|
2641
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. |
|
|
@@ -2649,15 +2627,18 @@ ref-scoped improvement. It owns the memory-cleanup and lesson-distillation
|
|
|
2649
2627
|
flow. A qualified scope such as `team//skills/code-review` selects that bundle;
|
|
2650
2628
|
a different explicit `--bundle` is a usage error.
|
|
2651
2629
|
|
|
2630
|
+
A type scope that matches no asset in the stash (a misspelt type, say) prints a warning on stderr, with the
|
|
2631
|
+
nearest real type when one is close, and plans nothing; the exit code stays 0.
|
|
2632
|
+
|
|
2652
2633
|
A run improves one bundle, the one it writes to, and plans only that bundle's
|
|
2653
2634
|
assets: an asset that lives in another bundle is left alone even when that
|
|
2654
2635
|
bundle is writable, and a bare ref scope (`akm improve skills/x`) resolves
|
|
2655
2636
|
inside the write target only. To improve another bundle, name it
|
|
2656
2637
|
(`akm improve --bundle team`, or `akm improve team//skills/code-review`). A
|
|
2657
2638
|
scheduled `akm improve` therefore covers only its write target: schedule one
|
|
2658
|
-
`akm improve --bundle <name>` run per other bundle. `--dry-run`
|
|
2659
|
-
|
|
2660
|
-
`AKM_BUNDLE_DIR`, then `defaultBundle`), so
|
|
2639
|
+
`akm improve --bundle <name>` run per other bundle. `--dry-run`
|
|
2640
|
+
resolves the bundle the way a live run does (the working bundle starts from
|
|
2641
|
+
`AKM_BUNDLE_DIR`, then `defaultBundle`), so it previews the bundle a live run
|
|
2661
2642
|
improves.
|
|
2662
2643
|
|
|
2663
2644
|
Every stage records what it did with each asset in the improve ledger
|
|
@@ -2686,10 +2667,10 @@ covering doc that ranks lower than the 20th nearest goes unseen. With no stored
|
|
|
2686
2667
|
vector (semantic search off, or the memory not indexed yet) that check does
|
|
2687
2668
|
nothing and the exact slug and whole-body checks still apply.
|
|
2688
2669
|
|
|
2689
|
-
No built-in strategy turns the improve-stage extract process on
|
|
2690
|
-
`
|
|
2691
|
-
|
|
2692
|
-
|
|
2670
|
+
No built-in strategy turns the improve-stage extract process on. Set the
|
|
2671
|
+
selected strategy's process `enabled: true` to opt in. Proactive maintenance is
|
|
2672
|
+
on in `default`; set `processes.proactiveMaintenance.enabled: false` to turn it
|
|
2673
|
+
off. The stage toggle does not disable a direct
|
|
2693
2674
|
`akm proposal extract --type <harness>` or `akm proposal extract --auto`
|
|
2694
2675
|
invocation.
|
|
2695
2676
|
|
|
@@ -2718,18 +2699,16 @@ newer than distill's last attempt. It skips a memory flagged wrong and not
|
|
|
2718
2699
|
edited since (a negative feedback in that window judged the body it still has,
|
|
2719
2700
|
or, recorded without that body's hash, is newer than the file's last write),
|
|
2720
2701
|
and a memory whose only feedback in that window is positive with no reason or
|
|
2721
|
-
note, unless the ref is explicit.
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
(salience and outcome) and plan nothing, so improve does not rewrite on a
|
|
2727
|
-
proactive cadence; they pick only refs in the
|
|
2702
|
+
note, unless the ref is explicit. In a strategy that enables
|
|
2703
|
+
`proactiveMaintenance` (`default` does), a further lane plans refs with no such
|
|
2704
|
+
feedback that are due for a revisit: at most `maxPerRun` (default 15) per run,
|
|
2705
|
+
only refs not reflected or distilled for `dueDays` (default 30), so each comes up
|
|
2706
|
+
at most once a month. It picks only refs in the
|
|
2728
2707
|
[retrieval scope](https://github.com/itlackey/akm/blob/main/docs/architecture/improvement.md#retrieval-scope): returned by
|
|
2729
2708
|
`search`, `curate` or `show`, or named by feedback, in the last 90 days, or new
|
|
2730
2709
|
material no improve stage has processed. The planned refs are ranked by salience
|
|
2731
2710
|
and cut to the limit; an explicit ref scope bypasses every gate. Use
|
|
2732
|
-
`--require-feedback-signal` to turn
|
|
2711
|
+
`--require-feedback-signal` to turn that lane off for the run.
|
|
2733
2712
|
|
|
2734
2713
|
When the active strategy enables a process (or the triage judgment engine)
|
|
2735
2714
|
whose engine or credential cannot be resolved in this process's environment,
|
|
@@ -2744,7 +2723,7 @@ itself. `ok` and the exit code are unchanged either way, matching `extract`'s
|
|
|
2744
2723
|
`skippedProcesses` (or pass `--require-engines` to abort instead of
|
|
2745
2724
|
degrading). `reason` names which engine and which credential reference (an env
|
|
2746
2725
|
var, `apiKeyFile` path, or `secret://` reference — never its value) is
|
|
2747
|
-
missing. A `--dry-run
|
|
2726
|
+
missing. A `--dry-run` preview never dispatches, so it never aborts
|
|
2748
2727
|
on an unavailable credential either — even a strategy left with every process
|
|
2749
2728
|
disabled this way still returns its plan, with the affected processes in
|
|
2750
2729
|
`skippedProcesses`.
|
|
@@ -2795,11 +2774,11 @@ still carries that engine's `engine`/`model`/`engineKind` alongside
|
|
|
2795
2774
|
`unavailable`, rather than omitting them the way a never-configured process
|
|
2796
2775
|
does — so a preview can show what would have run. This table is
|
|
2797
2776
|
resolved before any dispatch on every invocation (dry or live), so
|
|
2798
|
-
`akm improve --dry-run --strategy <name>`
|
|
2777
|
+
`akm improve --dry-run --strategy <name>` previews an ad-hoc
|
|
2799
2778
|
strategy override without changing config first; `akm health`'s
|
|
2800
2779
|
`active-improve-strategy` check performs the equivalent resolution but only
|
|
2801
2780
|
for the configured default strategy (`defaults.improveStrategy`), and reports
|
|
2802
|
-
no model or per-process notices.
|
|
2781
|
+
no model or per-process notices. `--dry-run` does not probe
|
|
2803
2782
|
engine reachability over the network — pair with `akm health --probe` (or the
|
|
2804
2783
|
default probe-on behavior) to check whether a named engine actually answers.
|
|
2805
2784
|
|
|
@@ -2824,9 +2803,12 @@ destination than `memory`.
|
|
|
2824
2803
|
`akm improve report` (#944) answers "which engine did each model-calling process
|
|
2825
2804
|
use this run, how much did it cost, and which enabled processes made zero
|
|
2826
2805
|
calls (and why)" without hand-written SQLite against `state.db`. It is a
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2806
|
+
real subcommand (`report` is not an asset type, so it is not a scope of the
|
|
2807
|
+
improve run). It takes two flags of its own, `--run <id>` (the usage report for
|
|
2808
|
+
one specific `improve_runs` row instead of the most recent real run) and
|
|
2809
|
+
`--since <window>` (aggregate over every real, non-dry-run run started since a
|
|
2810
|
+
duration like `24h`/`7d` or an ISO timestamp); they are mutually exclusive, and on
|
|
2811
|
+
`akm improve` itself they are unknown flags (exit 2).
|
|
2830
2812
|
|
|
2831
2813
|
Every real (non-dry-run) `akm improve` invocation persists a `usageReport`
|
|
2832
2814
|
field on the result (`result_json` in `improve_runs`, and in the
|
|
@@ -2861,7 +2843,7 @@ support.
|
|
|
2861
2843
|
|
|
2862
2844
|
#### improve judge
|
|
2863
2845
|
|
|
2864
|
-
`akm improve judge` runs reflect's quality judge on one revision and prints its
|
|
2846
|
+
`akm improve judge` (a real subcommand; `--strategy` is its only flag) runs reflect's quality judge on one revision and prints its
|
|
2865
2847
|
verdict, for testing a judge engine on revisions whose right answer you know. It
|
|
2866
2848
|
reads `{"source": "...", "candidate": "...", "feedback": "...", "ref": "..."}` JSON
|
|
2867
2849
|
from stdin (`feedback` and `ref` are optional; `ref` names the revised asset,
|
|
@@ -2888,15 +2870,15 @@ single queue.
|
|
|
2888
2870
|
|
|
2889
2871
|
New qualified proposals record their destination source name and materialized
|
|
2890
2872
|
root. `proposal diff`, `accept`, and `revert` use that recorded target by
|
|
2891
|
-
default; an explicit `--
|
|
2873
|
+
default; an explicit `--bundle` must resolve to the same source and root or the
|
|
2892
2874
|
command fails with exit 2. An unbound proposal in a selected non-primary queue
|
|
2893
2875
|
uses that authenticated queue root. A short historical unbound proposal
|
|
2894
|
-
mutation requires either an explicit `--
|
|
2876
|
+
mutation requires either an explicit `--bundle` or a selected `--queue` that
|
|
2895
2877
|
authenticates its root; it never falls back to an ambient write target.
|
|
2896
2878
|
|
|
2897
2879
|
#### proposal extract
|
|
2898
2880
|
|
|
2899
|
-
**
|
|
2881
|
+
**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.
|
|
2900
2882
|
|
|
2901
2883
|
Extract durable insights from native coding-agent session files (claude-code,
|
|
2902
2884
|
codex, opencode) and queue them as proposals. This is the standalone
|
|
@@ -3054,7 +3036,7 @@ akm proposal accept <id>
|
|
|
3054
3036
|
akm proposal accept 7c115132 # 8-char UUID prefix
|
|
3055
3037
|
akm proposal accept skills/akm-dream # Asset ref
|
|
3056
3038
|
akm proposal accept <id> --queue team-bundle
|
|
3057
|
-
akm proposal accept <id> --
|
|
3039
|
+
akm proposal accept <id> --bundle team-bundle # Must match a recorded target
|
|
3058
3040
|
akm proposal accept --generator reflect -y # Bulk-accept by generator (requires -y)
|
|
3059
3041
|
akm proposal accept --generator reflect --max-diff-lines 50 -y # ...only if <= 50 lines
|
|
3060
3042
|
akm proposal accept --generator reflect --older-than 7 --dry-run # Preview a bulk accept
|
|
@@ -3063,7 +3045,7 @@ akm proposal accept --generator reflect --older-than 7 --dry-run # Preview a bu
|
|
|
3063
3045
|
| Flag | Description |
|
|
3064
3046
|
| --- | --- |
|
|
3065
3047
|
| `--queue <source>` | Select the proposal queue by configured writable source name |
|
|
3066
|
-
| `--
|
|
3048
|
+
| `--bundle <name>` | Write destination; must match the proposal's recorded target |
|
|
3067
3049
|
| `--generator <name>` | Bulk-accept all pending proposals from this generator (e.g. `reflect`, `distill`). Requires no positional id. |
|
|
3068
3050
|
| `--max-diff-lines` | When bulk-accepting, only accept proposals whose content is `<=` this many lines. Larger proposals are skipped. |
|
|
3069
3051
|
| `--older-than` | When bulk-accepting, only accept proposals created (or last reopened) more than this many days ago |
|
|
@@ -3203,13 +3185,13 @@ to `reverted` and appends a `proposal_reverted` event to the audit log.
|
|
|
3203
3185
|
akm proposal revert <id>
|
|
3204
3186
|
akm proposal revert skills/akm-dream # Asset ref
|
|
3205
3187
|
akm proposal revert <id> --queue team-bundle
|
|
3206
|
-
akm proposal revert <id> --
|
|
3188
|
+
akm proposal revert <id> --bundle team-bundle # Must match a recorded target
|
|
3207
3189
|
```
|
|
3208
3190
|
|
|
3209
3191
|
| Flag | Description |
|
|
3210
3192
|
| --- | --- |
|
|
3211
3193
|
| `--queue <source>` | Select the proposal queue by configured writable source name |
|
|
3212
|
-
| `--
|
|
3194
|
+
| `--bundle <name>` | Select the destination for an unbound proposal, or confirm a recorded destination; a conflict with a recorded target is rejected |
|
|
3213
3195
|
|
|
3214
3196
|
Accepts the full proposal UUID or the asset ref. UUID prefixes are **not**
|
|
3215
3197
|
supported for reverting (archived proposals require the full identifier). Errors
|
|
@@ -3226,13 +3208,13 @@ akm proposal diff <id>
|
|
|
3226
3208
|
akm proposal diff skills/akm-dream # Asset ref form
|
|
3227
3209
|
akm proposal diff 7c115132 # 8-char UUID prefix
|
|
3228
3210
|
akm proposal diff <id> --queue team-bundle
|
|
3229
|
-
akm proposal diff <id> --
|
|
3211
|
+
akm proposal diff <id> --bundle team-bundle # Must match a recorded target
|
|
3230
3212
|
```
|
|
3231
3213
|
|
|
3232
3214
|
| Flag | Description |
|
|
3233
3215
|
| --- | --- |
|
|
3234
3216
|
| `--queue <source>` | Select the proposal queue by configured writable source name |
|
|
3235
|
-
| `--
|
|
3217
|
+
| `--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 |
|
|
3236
3218
|
|
|
3237
3219
|
`proposal accept` runs full validation before promoting. `proposal reject`
|
|
3238
3220
|
requires `--reason`.
|
|
@@ -3279,8 +3261,15 @@ one at a time. One rule decides each proposal: a proposal whose quality judge
|
|
|
3279
3261
|
passed on its current content is accepted (unless its target changed since it
|
|
3280
3262
|
was minted — that one is auto-rejected as `stale-target`); an empty diff is
|
|
3281
3263
|
rejected; a proposal that reflect or distill deferred for review is left for a
|
|
3282
|
-
person;
|
|
3283
|
-
is
|
|
3264
|
+
person; a proposal from the proactive-maintenance lane (no feedback behind it)
|
|
3265
|
+
is left for a person too (reason `proactive-needs-review`), even when its judge
|
|
3266
|
+
passed it; everything else goes to the judgment tier when one is enabled, and
|
|
3267
|
+
is otherwise left for review. The judgment tier may accept only a consolidate
|
|
3268
|
+
promotion (a memory proposed as a new knowledge note); any other kind it would
|
|
3269
|
+
accept, such as a retirement, an exact fix or a reflect revision, is left for a
|
|
3270
|
+
person (reason `judgment-not-promotion`). Judged over every kind, the tier
|
|
3271
|
+
accepted unsafe retirements, applied exact fixes unreviewed and changed notes
|
|
3272
|
+
nobody had touched: 6 to 14 harmed items a night on two models (#1132). A reflect revision that changes the body, and
|
|
3284
3273
|
every distill lesson or knowledge promotion, is deferred for review even when
|
|
3285
3274
|
its judge passes it. Default mode stages decisions (queue mode); pass
|
|
3286
3275
|
`--promote` to actually accept.
|
|
@@ -3299,7 +3288,7 @@ akm proposal drain --strategy default --promote -y # Read the triage block from
|
|
|
3299
3288
|
| `--dry-run` | List what would be accepted/rejected/deferred, without writing |
|
|
3300
3289
|
| `--max-accepts` | Hard per-run accept ceiling; accepts beyond this are reported as `skippedByCap` |
|
|
3301
3290
|
| `--older-than` | Only consider proposals created (or last reopened) more than this many days ago |
|
|
3302
|
-
| `--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. |
|
|
3291
|
+
| `--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. |
|
|
3303
3292
|
| `-y`, `--yes` | Skip the confirmation prompt (required in non-interactive mode for promotion) |
|
|
3304
3293
|
|
|
3305
3294
|
### feedback (`--reason`)
|
|
@@ -3325,15 +3314,14 @@ shell commands. It manages on-disk task definitions under
|
|
|
3325
3314
|
(cron / launchd / schtasks). Task source v4 YAML (`version: 4`) is the only
|
|
3326
3315
|
executable source contract this release accepts; `akm task add` writes v4 —
|
|
3327
3316
|
see the canonical [Tasks reference](tasks.md). The
|
|
3328
|
-
group is `add | enable | disable | run | explain | validate |
|
|
3317
|
+
group is `add | enable | disable | run | explain | validate | sync | doctor | history | prune`
|
|
3329
3318
|
— there is no `show` or `remove`; use `akm show tasks/<id>` to inspect one
|
|
3330
3319
|
task. Use `task enable` / `task disable` for host-local activation; edit the
|
|
3331
3320
|
file only to change the authored schedule or remove the task.
|
|
3332
|
-
|
|
3333
|
-
spellings return the identical envelope.
|
|
3321
|
+
List tasks with `akm search --type task`.
|
|
3334
3322
|
|
|
3335
3323
|
```sh
|
|
3336
|
-
akm task
|
|
3324
|
+
akm search --type task # List tasks (cross-bundle)
|
|
3337
3325
|
akm show tasks/<id> # Inspect one task
|
|
3338
3326
|
akm task add <id> --schedule "@daily" \ # Register a new task and install it
|
|
3339
3327
|
--command "akm improve --strategy default"
|
|
@@ -3344,7 +3332,6 @@ akm task enable team//tasks/nightly # Add local activation and sync its bu
|
|
|
3344
3332
|
akm task disable team//tasks/nightly # Remove local activation and unschedule it
|
|
3345
3333
|
akm task run <id> # Execute now (what the scheduler calls)
|
|
3346
3334
|
akm task explain <ref> # Read-only: declared inputs, target, schedule — spawns nothing
|
|
3347
|
-
akm task validate <path> # Read-only: parse one task file by path, report sync's diagnostic
|
|
3348
3335
|
akm task history [<id>] [--id <id>] [--limit <n>] # Recent runs from state.db (positional id == --id)
|
|
3349
3336
|
akm task sync # Reconcile activated refs from all enabled configured bundles
|
|
3350
3337
|
akm task sync --dry-run # Preview the reconcile — zero scheduler writes
|
|
@@ -3360,13 +3347,6 @@ this host's scheduler activation), `--force` (overwrite an existing task with
|
|
|
3360
3347
|
the same id), and `--rebind` (also point the bundle's installed scheduler rows
|
|
3361
3348
|
at this akm invocation, as `akm task sync --rebind` does).
|
|
3362
3349
|
|
|
3363
|
-
`akm task list [<query>] [--limit <n>] [--from local|registry|all]` is a
|
|
3364
|
-
pure alias for `akm search --type task` with the query, `--limit`, and
|
|
3365
|
-
`--from` flags passed through — same envelope, same `results` alias, no
|
|
3366
|
-
second implementation. 0.9.0 removed `task list` as a redundant
|
|
3367
|
-
implementation of task listing (see the 0.9.0 CHANGELOG entry); this
|
|
3368
|
-
reintroduces only the spelling, not the logic.
|
|
3369
|
-
|
|
3370
3350
|
`akm task explain <ref> [input flags]` prints a task's declared `inputs:`,
|
|
3371
3351
|
the values that would actually be supplied (with provenance), the resolved
|
|
3372
3352
|
target, effective execution settings, and schedule bindings — **read-only**:
|
|
@@ -3374,28 +3354,6 @@ it never spawns anything, writes history, or touches the scheduler. A
|
|
|
3374
3354
|
secret-shaped value prints as `<redacted>`. See
|
|
3375
3355
|
[`akm task explain`](tasks.md#akm-task-explain).
|
|
3376
3356
|
|
|
3377
|
-
`akm task validate <path>` parses ONE task file by filesystem path — not a
|
|
3378
|
-
concept ref or id, and the file need not live in any configured bundle —
|
|
3379
|
-
and reports the same diagnostic `akm task sync` would produce for it,
|
|
3380
|
-
INCLUDING sync's own cron-dialect check and its per-schedule-entry
|
|
3381
|
-
input-contract check (so a file `sync` would reject can never be reported
|
|
3382
|
-
`valid` here): `{ok, path, sourceVersion, outcome, reason?,
|
|
3383
|
-
resolved?}` where `outcome` is `valid` (parses as task source v4 directly
|
|
3384
|
-
and passes both sync checks), `blocked` (task v2/v3 that must first be
|
|
3385
|
-
rewritten by `akm migrate apply`), `invalid` (the YAML doesn't parse, or the document fails schema
|
|
3386
|
-
validation, or it parsed but fails one of the two sync checks), or
|
|
3387
|
-
`not-a-task` (the YAML parses but never declares a `version:` field — not
|
|
3388
|
-
shaped like a task source). `resolved` is the compiled task shape
|
|
3389
|
-
`akm task sync` itself would build a scheduler binding from — id, the
|
|
3390
|
-
compiled schema version, resolved `uses`/`run` target, declared `inputs`
|
|
3391
|
-
contract, and `schedule` bindings — present only on `valid`.
|
|
3392
|
-
Unlike `akm task explain`, it never runs execution lowering: a command-kind
|
|
3393
|
-
task validates the same whether or not the local config has an engine
|
|
3394
|
-
configured. Exits 0 for `valid`, 1 for
|
|
3395
|
-
`blocked`/`invalid`/`not-a-task`, 2 for a missing or unreadable path.
|
|
3396
|
-
**Read-only**: it never touches the scheduler and never requires the file to
|
|
3397
|
-
be indexed or wired into a bundle.
|
|
3398
|
-
|
|
3399
3357
|
`akm task run` is what cron / launchd / schtasks invoke at the scheduled
|
|
3400
3358
|
time. Each run is recorded as a row in the durable `task_history` table
|
|
3401
3359
|
(`state.db`), surfaced by `akm task history` — **not** by `akm log`; there is
|