@dzhechkov/keysarium 1.5.21 → 1.5.25
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dzhechkov/keysarium",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.25",
|
|
4
4
|
"description": "AI Case Research Toolkit for Claude Code — full 7-phase pipeline with feature-adr, dream cycles, background workers, multi-platform support, reward learning, and Cloud.ru AI Factory mapping (--ai-factory flag)",
|
|
5
5
|
"main": "src/cli.js",
|
|
6
6
|
"bin": {
|
|
@@ -366,7 +366,7 @@ to Codex — always ASKING first, always with a Claude fallback (never blocks):
|
|
|
366
366
|
- **Model choice** → `args.codexModel` (`auto` default (Codex self-selects) · or an id your account exposes (e.g. `gpt-5.5`)).
|
|
367
367
|
|
|
368
368
|
*Scenario:* an L/XL run hits the session limit during coding → with `coder: 'codex-fallback'` feature-adr
|
|
369
|
-
logs *"Claude unavailable (limit?) — falling back to Codex auto"* and finishes on Codex, no restart.
|
|
369
|
+
logs *"Claude unavailable (limit?) — falling back to Codex auto"* and finishes on Codex, no restart. Codex writes out-of-band, so feature-adr confirms the edits LANDED (`git status`, ~30s poll) before QE — no false "Step 7 never ran" grade.
|
|
370
370
|
|
|
371
371
|
*Example:* `Workflow({ scriptPath: '.claude/workflows/feature-adr.js', args: { slug, description, tier:
|
|
372
372
|
'M', planner: 'codex', coder: 'codex-fallback', qeReviewer: 'codex-fallback', codexModel: 'auto' } }) // 'auto' = Codex picks top; or pin e.g. 'gpt-5.5'`.
|
|
@@ -375,6 +375,45 @@ Pre-flight, if Codex is `ready` (`codex-companion setup --json`), the orchestrat
|
|
|
375
375
|
before launching; plain `/feature-adr` offers the same at the planning checkpoint. Omit the Codex knobs
|
|
376
376
|
for today's all-Claude behavior. See `.claude/rules/feature-adr-ultracode.md`.
|
|
377
377
|
|
|
378
|
+
**Per-stage model routing — `args.models` (one dial, 11 stages).** `args.models` is an optional map that
|
|
379
|
+
routes each pipeline stage to an optimal model. Keys: `{router, requirements, research, adr, ideation,
|
|
380
|
+
ddd, architecture, plan, code, qe, fleet}`. Each value is a **spec**:
|
|
381
|
+
|
|
382
|
+
- **Claude** — `'fable' | 'opus' | 'sonnet' | 'haiku'` → adds `model` to that stage's `agent()` call
|
|
383
|
+
(any role `agentType` like `qe-code-reviewer` is PRESERVED).
|
|
384
|
+
- **Codex** — `'codex'` / `'codex:<id>'` / `'codex:<id>:<reasoning>'` (e.g. `'codex:gpt-5.6:xhigh'`;
|
|
385
|
+
`reasoning ∈ low|medium|high|xhigh`; ids incl. `gpt-5.5`, `gpt-5.6`) → routes the stage to the
|
|
386
|
+
`codex:codex-rescue` runtime with that `codexModel` + reasoning hint.
|
|
387
|
+
|
|
388
|
+
**Recommended DEFAULT TABLE** (applied only when you opt into routing — any one `args.models` key or any
|
|
389
|
+
Codex knob flips it on; otherwise every stage stays session-inherited, byte-identical to today):
|
|
390
|
+
|
|
391
|
+
| Stage | Default | | Stage | Default |
|
|
392
|
+
|---|---|---|---|---|
|
|
393
|
+
| router | `fable` | | architecture | `opus` |
|
|
394
|
+
| requirements | `sonnet` | | plan | `sonnet` |
|
|
395
|
+
| research | `sonnet` (folds into requirements) | | code | *the coder knob* (default Claude `opus`) |
|
|
396
|
+
| adr | `opus` | | qe | *CROSS-MODEL of the coder* (see below) |
|
|
397
|
+
| ideation | `sonnet` | | fleet | `sonnet` |
|
|
398
|
+
| ddd | `opus` (folds into architecture) | | | |
|
|
399
|
+
|
|
400
|
+
**Cross-model QE default (load-bearing).** When `args.models.qe` is UNSET, QE is auto-routed to the
|
|
401
|
+
**other model family than the coder** — a model that WRITES code must not also SELF-QE; independent
|
|
402
|
+
cross-model review catches what self-review misses. coder=Codex ⇒ QE=Claude (`opus`); coder=Claude ⇒
|
|
403
|
+
QE=Codex (`codex:<top>:high`), or a Claude reviewer if Codex is unavailable (**never blocks**).
|
|
404
|
+
|
|
405
|
+
**Precedence.** `args.models[stage]` is the general mechanism and WINS on conflict; the legacy
|
|
406
|
+
`planner`/`coder`/`qeReviewer`/`codexModel` knobs are shortcuts that fill a stage only when `args.models`
|
|
407
|
+
does not. `codexModel` sets the default id for a bare `'codex'` spec. Codex-fallback (Claude-first, then
|
|
408
|
+
Codex on limit-exhaustion) stays a knob-only behavior; a direct `models.code='codex'` means codex-first.
|
|
409
|
+
|
|
410
|
+
**gpt-5.6-ready** — a new Codex id is a DATA-ONLY addition to the `KNOWN_CODEX` allowlist (no control flow).
|
|
411
|
+
**Reporting** — the run result includes `modelsUsed` (the resolved per-stage model) so you see who did what.
|
|
412
|
+
|
|
413
|
+
*Example:* `Workflow({ scriptPath: '.claude/workflows/feature-adr.js', args: { slug, description, tier:
|
|
414
|
+
'L', models: { code: 'opus', qe: 'codex:gpt-5.6:high', architecture: 'opus', router: 'fable' } } })` —
|
|
415
|
+
Claude writes the code, Codex independently QEs it.
|
|
416
|
+
|
|
378
417
|
### Pattern memory loop (self-learning — runs in ALL modes)
|
|
379
418
|
|
|
380
419
|
**Self-learning is MANDATORY on EVERY `/feature-adr` run — including plain `/feature-adr` without any
|
|
@@ -408,6 +447,15 @@ non-blocking — an error or empty result never stalls the pipeline. This layer
|
|
|
408
447
|
**distinct from the Keysarium reward layer** installed by `--with-learning`: it uses agentic-qe MCP
|
|
409
448
|
memory + the dz store, is UNCONDITIONAL for the dz half (recall/teach/fa-record run in every mode) and Direct-mode-only for the aqe-MCP half, and never touches `.keysarium/memory/`.
|
|
410
449
|
|
|
450
|
+
**Canonical brain store — `args.brain` (never fragment the loop).** The dz durable loop only compounds if
|
|
451
|
+
Step-0 recall and Step-8 teach hit the SAME store. The workflow pins both to a canonical **brain** —
|
|
452
|
+
`args.brain`, default = the workspace root — via `cd <brain> && dz recall/teach … --project <brain>`, so a
|
|
453
|
+
Step-8 teach issued from a coder that `cd`'d into a target repo still lands in the brain, not that repo's
|
|
454
|
+
`.dz`. Omitting `args.brain` is behaviorally inert for a workspace-CWD run (`brain === repo`). **Share** a
|
|
455
|
+
brain: `dz recall --all --json > patterns.json` → `dz teach --from-json patterns.json --project <brain>`
|
|
456
|
+
(exact-text dedup, idempotent). **Recover** a fragmented store: `cd <stray-repo> && dz recall --all --json >
|
|
457
|
+
/tmp/stray.json` → `dz teach --from-json /tmp/stray.json --project <brain>` to merge it back into the brain.
|
|
458
|
+
|
|
411
459
|
**Live learning panel (`dz statusline`).** The pipeline **drives** the panel: at each pattern-memory-loop
|
|
412
460
|
step above it records its live state via `dz statusline --fa-record …`, so `dz statusline` can surface
|
|
413
461
|
per-run learning (which feature, which step, how many patterns recalled vs. newly stored). Each of the
|