@bastani/atomic 0.9.16-alpha.6 → 0.9.16-alpha.8
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 +19 -0
- package/dist/builtin/intercom/CHANGELOG.md +6 -0
- package/dist/builtin/intercom/README.md +4 -4
- package/dist/builtin/intercom/broker/broker.ts +617 -22
- package/dist/builtin/intercom/broker/client-message-validation.ts +9 -0
- package/dist/builtin/intercom/broker/client.ts +200 -10
- package/dist/builtin/intercom/broker/pending-send-registry.ts +4 -0
- package/dist/builtin/intercom/broker/send-handler.ts +90 -36
- package/dist/builtin/intercom/broker/send-signature.ts +20 -8
- package/dist/builtin/intercom/group.ts +85 -0
- package/dist/builtin/intercom/index.bundle.mjs +680 -53
- package/dist/builtin/intercom/package.json +1 -1
- package/dist/builtin/intercom/session-target.ts +54 -0
- package/dist/builtin/intercom/skills/intercom/SKILL.md +18 -3
- package/dist/builtin/intercom/source-ownership.ts +31 -0
- package/dist/builtin/intercom/types.ts +115 -0
- package/dist/builtin/mcp/index.bundle.mjs +109 -35
- package/dist/builtin/mcp/package.json +1 -1
- package/dist/builtin/subagents/CHANGELOG.md +6 -0
- package/dist/builtin/subagents/package.json +1 -1
- package/dist/builtin/subagents/skills/qlty/SKILL.md +123 -0
- package/dist/builtin/subagents/skills/qlty/references/coding-with-ai-agents.md +64 -0
- package/dist/builtin/subagents/skills/qlty/references/commands.md +291 -0
- package/dist/builtin/subagents/skills/qlty/references/plugins-and-extensions.md +228 -0
- package/dist/builtin/subagents/skills/qlty/references/quickstart.md +110 -0
- package/dist/builtin/subagents/src/extension/index.bundle.mjs +173 -51
- package/dist/builtin/web-access/index.bundle.mjs +109 -35
- package/dist/builtin/web-access/package.json +1 -1
- package/dist/builtin/workflows/CHANGELOG.md +23 -0
- package/dist/builtin/workflows/README.md +40 -37
- package/dist/builtin/workflows/builtin/adversarial-verification.js +13 -0
- package/dist/builtin/workflows/builtin/{shared-prompts.ts → chunk-0x6e303p.js} +137 -133
- package/dist/builtin/workflows/builtin/chunk-29wrp38a.js +199 -0
- package/dist/builtin/workflows/builtin/chunk-2dqb5s2q.js +602 -0
- package/dist/builtin/workflows/builtin/chunk-4febxsv4.js +264 -0
- package/dist/builtin/workflows/builtin/chunk-5n10x7j2.js +69730 -0
- package/dist/builtin/workflows/builtin/chunk-5wgwscd0.js +4 -0
- package/dist/builtin/workflows/builtin/chunk-6fqs7c01.js +155 -0
- package/dist/builtin/workflows/builtin/chunk-7430zyas.js +126 -0
- package/dist/builtin/workflows/builtin/chunk-7at6dnkr.js +33 -0
- package/dist/builtin/workflows/builtin/chunk-82ha8p41.js +175 -0
- package/dist/builtin/workflows/builtin/chunk-bfkmzv9h.js +156 -0
- package/dist/builtin/workflows/builtin/chunk-c53y8bdh.js +345 -0
- package/dist/builtin/workflows/builtin/chunk-cdtd3m3w.js +529 -0
- package/dist/builtin/workflows/builtin/chunk-cg9tmks0.js +206 -0
- package/dist/builtin/workflows/builtin/chunk-hdpj1dkw.js +2447 -0
- package/dist/builtin/workflows/builtin/chunk-hzzn6adg.js +221 -0
- package/dist/builtin/workflows/builtin/chunk-nqr34qp3.js +1061 -0
- package/dist/builtin/workflows/builtin/chunk-qwzvgxnq.js +404 -0
- package/dist/builtin/workflows/builtin/chunk-qx2ptjs3.js +215 -0
- package/dist/builtin/workflows/builtin/chunk-v04c5qmd.js +1207 -0
- package/dist/builtin/workflows/builtin/chunk-wpckd35c.js +12 -0
- package/dist/builtin/workflows/builtin/chunk-x2ghn0je.js +4110 -0
- package/dist/builtin/workflows/builtin/chunk-zf28603f.js +1080 -0
- package/dist/builtin/workflows/builtin/classify-and-act.js +12 -0
- package/dist/builtin/workflows/builtin/fan-out-and-synthesize.js +10 -0
- package/dist/builtin/workflows/builtin/generate-and-filter.js +12 -0
- package/dist/builtin/workflows/builtin/goal.js +16 -0
- package/dist/builtin/workflows/builtin/index.js +49 -0
- package/dist/builtin/workflows/builtin/loop-until-done.js +12 -0
- package/dist/builtin/workflows/builtin/open-claude-design.js +11 -0
- package/dist/builtin/workflows/builtin/ralph.js +16 -0
- package/dist/builtin/workflows/builtin/steering-context.d.ts +6 -0
- package/dist/builtin/workflows/builtin/steering-context.js +7 -0
- package/dist/builtin/workflows/builtin/tournament.js +13 -0
- package/dist/builtin/workflows/package.json +10 -7
- package/dist/builtin/workflows/src/authoring/typebox-defaults.d.ts +41 -0
- package/dist/builtin/workflows/src/extension/index.bundle.mjs +1250 -428
- package/dist/builtin/workflows/src/{index.bundle.mjs → index.js} +956 -427
- package/dist/builtin/workflows/src/shared/authoring-contract-stage.d.ts +403 -0
- package/dist/builtin/workflows/src/shared/authoring-contract-ui.d.ts +327 -0
- package/dist/builtin/workflows/src/shared/budget.d.ts +67 -0
- package/dist/builtin/workflows/src/shared/workflow-authoring-types.d.ts +60 -0
- package/dist/builtin/workflows/src/shared/workflow-heartbeat-contract.d.ts +21 -0
- package/dist/core/agent-session-custom-message-commit.d.ts.map +1 -1
- package/dist/core/agent-session-custom-message-commit.js +12 -5
- package/dist/core/agent-session-custom-message-commit.js.map +1 -1
- package/dist/core/agent-session-persistent-custom-messages.d.ts.map +1 -1
- package/dist/core/agent-session-persistent-custom-messages.js +2 -0
- package/dist/core/agent-session-persistent-custom-messages.js.map +1 -1
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +2 -1
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/auth-storage.d.ts +2 -0
- package/dist/core/auth-storage.d.ts.map +1 -1
- package/dist/core/auth-storage.js +4 -0
- package/dist/core/auth-storage.js.map +1 -1
- package/dist/core/builtin-install-layout.d.ts +1 -1
- package/dist/core/builtin-install-layout.d.ts.map +1 -1
- package/dist/core/builtin-install-layout.js +1 -1
- package/dist/core/builtin-install-layout.js.map +1 -1
- package/dist/core/codex-fast-mode.d.ts +10 -7
- package/dist/core/codex-fast-mode.d.ts.map +1 -1
- package/dist/core/codex-fast-mode.js +31 -13
- package/dist/core/codex-fast-mode.js.map +1 -1
- package/dist/core/extensions/context-types.d.ts +35 -0
- package/dist/core/extensions/context-types.d.ts.map +1 -1
- package/dist/core/extensions/context-types.js.map +1 -1
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/loader-virtual-modules.d.ts.map +1 -1
- package/dist/core/extensions/loader-virtual-modules.js +6 -1
- package/dist/core/extensions/loader-virtual-modules.js.map +1 -1
- package/dist/core/model-runtime.d.ts +2 -0
- package/dist/core/model-runtime.d.ts.map +1 -1
- package/dist/core/model-runtime.js +4 -0
- package/dist/core/model-runtime.js.map +1 -1
- package/dist/core/runtime-credentials.d.ts +1 -0
- package/dist/core/runtime-credentials.d.ts.map +1 -1
- package/dist/core/runtime-credentials.js +8 -0
- package/dist/core/runtime-credentials.js.map +1 -1
- package/dist/core/sdk.d.ts.map +1 -1
- package/dist/core/sdk.js +5 -5
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/session-manager-storage.d.ts +2 -0
- package/dist/core/session-manager-storage.d.ts.map +1 -1
- package/dist/core/session-manager-storage.js +4 -2
- package/dist/core/session-manager-storage.js.map +1 -1
- package/dist/core/slash-commands.js +1 -1
- package/dist/core/slash-commands.js.map +1 -1
- package/dist/core/workflow-stage-admission.d.ts +6 -1
- package/dist/core/workflow-stage-admission.d.ts.map +1 -1
- package/dist/core/workflow-stage-admission.js +8 -9
- package/dist/core/workflow-stage-admission.js.map +1 -1
- package/dist/index.d.ts +0 -1
- package/dist/modes/interactive/components/footer.d.ts.map +1 -1
- package/dist/modes/interactive/components/footer.js +1 -1
- package/dist/modes/interactive/components/footer.js.map +1 -1
- package/dist/modes/interactive/interactive-autocomplete.js +1 -1
- package/dist/modes/interactive/interactive-autocomplete.js.map +1 -1
- package/dist/modes/interactive/interactive-startup.js +1 -1
- package/dist/modes/interactive/interactive-startup.js.map +1 -1
- package/dist/modes/interactive-engine/isolated-runtime.d.ts +4 -0
- package/dist/modes/interactive-engine/isolated-runtime.d.ts.map +1 -1
- package/dist/modes/interactive-engine/isolated-runtime.js +69 -10
- package/dist/modes/interactive-engine/isolated-runtime.js.map +1 -1
- package/dist/modes/rpc/rpc-client-api.d.ts +18 -2
- package/dist/modes/rpc/rpc-client-api.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client-api.js +33 -5
- package/dist/modes/rpc/rpc-client-api.js.map +1 -1
- package/dist/modes/rpc/rpc-command-handler.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-command-handler.js +8 -4
- package/dist/modes/rpc/rpc-command-handler.js.map +1 -1
- package/dist/modes/rpc/rpc-types.d.ts +13 -0
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-types.js.map +1 -1
- package/docs/intercom.md +15 -6
- package/docs/packages.md +2 -2
- package/docs/providers.md +8 -3
- package/docs/quickstart.md +3 -2
- package/docs/rpc.md +21 -4
- package/docs/settings.md +6 -4
- package/docs/skills.md +4 -0
- package/docs/subagents.md +1 -1
- package/docs/usage.md +1 -1
- package/docs/workflows.md +112 -239
- package/npm-shrinkwrap.json +32 -32
- package/package.json +9 -13
- package/dist/builtin/workflows/ambient.d.ts +0 -61
- package/dist/builtin/workflows/builtin/adversarial-verification-prompts.ts +0 -26
- package/dist/builtin/workflows/builtin/adversarial-verification-runner.ts +0 -391
- package/dist/builtin/workflows/builtin/adversarial-verification.ts +0 -34
- package/dist/builtin/workflows/builtin/classify-and-act-prompts.ts +0 -14
- package/dist/builtin/workflows/builtin/classify-and-act-runner.ts +0 -108
- package/dist/builtin/workflows/builtin/classify-and-act.ts +0 -40
- package/dist/builtin/workflows/builtin/fan-out-and-synthesize-prompts.ts +0 -14
- package/dist/builtin/workflows/builtin/fan-out-and-synthesize-runner.ts +0 -96
- package/dist/builtin/workflows/builtin/fan-out-and-synthesize.ts +0 -37
- package/dist/builtin/workflows/builtin/generate-and-filter-prompts.ts +0 -41
- package/dist/builtin/workflows/builtin/generate-and-filter-runner.ts +0 -90
- package/dist/builtin/workflows/builtin/generate-and-filter.ts +0 -31
- package/dist/builtin/workflows/builtin/goal-artifacts.ts +0 -64
- package/dist/builtin/workflows/builtin/goal-convergence.ts +0 -87
- package/dist/builtin/workflows/builtin/goal-ledger.ts +0 -139
- package/dist/builtin/workflows/builtin/goal-models.ts +0 -72
- package/dist/builtin/workflows/builtin/goal-orchestrator-prompts.ts +0 -94
- package/dist/builtin/workflows/builtin/goal-prompts.ts +0 -211
- package/dist/builtin/workflows/builtin/goal-reducer.ts +0 -176
- package/dist/builtin/workflows/builtin/goal-reports.ts +0 -76
- package/dist/builtin/workflows/builtin/goal-reverify.ts +0 -305
- package/dist/builtin/workflows/builtin/goal-review.ts +0 -139
- package/dist/builtin/workflows/builtin/goal-runner.ts +0 -504
- package/dist/builtin/workflows/builtin/goal-schemas.ts +0 -89
- package/dist/builtin/workflows/builtin/goal-types.ts +0 -164
- package/dist/builtin/workflows/builtin/goal.ts +0 -78
- package/dist/builtin/workflows/builtin/index.ts +0 -16
- package/dist/builtin/workflows/builtin/loop-until-done-prompts.ts +0 -87
- package/dist/builtin/workflows/builtin/loop-until-done-runner.ts +0 -282
- package/dist/builtin/workflows/builtin/loop-until-done.ts +0 -51
- package/dist/builtin/workflows/builtin/open-claude-design-live-protocol.ts +0 -305
- package/dist/builtin/workflows/builtin/open-claude-design-phases.ts +0 -337
- package/dist/builtin/workflows/builtin/open-claude-design-runner.ts +0 -347
- package/dist/builtin/workflows/builtin/open-claude-design-setup.ts +0 -313
- package/dist/builtin/workflows/builtin/open-claude-design-utils.ts +0 -311
- package/dist/builtin/workflows/builtin/open-claude-design.ts +0 -57
- package/dist/builtin/workflows/builtin/pattern-artifact-root.ts +0 -28
- package/dist/builtin/workflows/builtin/progress-scoring.ts +0 -230
- package/dist/builtin/workflows/builtin/ralph-core.ts +0 -449
- package/dist/builtin/workflows/builtin/ralph-forked-prompts.ts +0 -100
- package/dist/builtin/workflows/builtin/ralph-models.ts +0 -183
- package/dist/builtin/workflows/builtin/ralph-review-gate.ts +0 -103
- package/dist/builtin/workflows/builtin/ralph-reviewer-prompt.ts +0 -100
- package/dist/builtin/workflows/builtin/ralph-runner.ts +0 -455
- package/dist/builtin/workflows/builtin/ralph.ts +0 -82
- package/dist/builtin/workflows/builtin/review-convergence.ts +0 -229
- package/dist/builtin/workflows/builtin/selection-math.ts +0 -156
- package/dist/builtin/workflows/builtin/steering-context.ts +0 -51
- package/dist/builtin/workflows/builtin/tournament-prompts.ts +0 -70
- package/dist/builtin/workflows/builtin/tournament-runner.ts +0 -400
- package/dist/builtin/workflows/builtin/tournament.ts +0 -73
- package/dist/builtin/workflows/builtin/verification-criteria.ts +0 -330
- package/dist/builtin/workflows/builtin/verification-prompts.ts +0 -206
- package/dist/builtin/workflows/builtin/verification-usage.ts +0 -44
|
@@ -1,183 +0,0 @@
|
|
|
1
|
-
import { reviewDecisionSchema } from "./ralph-core.js";
|
|
2
|
-
|
|
3
|
-
// Model chains are curated from Atomic's agentic-coding benchmark and the
|
|
4
|
-
// July 2026 frontier refresh:
|
|
5
|
-
// - Critical synthesis/review stages prefer fable-5:xhigh, then gpt-5.5 xhigh
|
|
6
|
-
// variants, openrouter fugu-ultra, long-context opus, and GLM fallbacks.
|
|
7
|
-
// - Research remains on gpt-5.5:medium / fable-5:low for perf-per-dollar.
|
|
8
|
-
// - Reviewer B keeps gpt-5.5:xhigh as an independent frontier family to
|
|
9
|
-
// decorrelate review errors from reviewer A.
|
|
10
|
-
// - Dominated benchmark models stay out of the chains: claude-sonnet-5,
|
|
11
|
-
// claude-sonnet-4.6, gemini-3.1-pro, and gemini-3.5-flash.
|
|
12
|
-
// - GLM-5.3 exposes reasoning without a thinkingLevelMap or reasoning-effort
|
|
13
|
-
// control, so chains use the catalog-supported :high tier explicitly rather
|
|
14
|
-
// than carrying the prior GLM generation's :xhigh/:max suffixes forward. OpenRouter has no
|
|
15
|
-
// GLM-5.3 catalog entry, so its unavailable fallback is intentionally omitted.
|
|
16
|
-
|
|
17
|
-
export const promptEngineerModelConfig = {
|
|
18
|
-
model: "anthropic/claude-opus-5:high",
|
|
19
|
-
fallbackModels: [
|
|
20
|
-
"github-copilot/claude-opus-5:high",
|
|
21
|
-
"anthropic/claude-fable-5:high",
|
|
22
|
-
"github-copilot/claude-fable-5:high",
|
|
23
|
-
"openai-codex/gpt-5.6-sol:xhigh",
|
|
24
|
-
"github-copilot/gpt-5.6-sol:xhigh",
|
|
25
|
-
"openai/gpt-5.6-sol:xhigh",
|
|
26
|
-
"kimi-coding/k3:max",
|
|
27
|
-
"moonshotai/kimi-k3:max",
|
|
28
|
-
"moonshotai-cn/kimi-k3:max",
|
|
29
|
-
"openai-codex/gpt-5.5:xhigh",
|
|
30
|
-
"github-copilot/gpt-5.5:xhigh",
|
|
31
|
-
"openai/gpt-5.5:xhigh",
|
|
32
|
-
"anthropic/claude-opus-4-8:high",
|
|
33
|
-
"github-copilot/claude-opus-4.8:high",
|
|
34
|
-
"xai/grok-4.6:xhigh",
|
|
35
|
-
"github-copilot/grok-4.6:xhigh",
|
|
36
|
-
"zai/glm-5.3:high",
|
|
37
|
-
"zai-coding-cn/glm-5.3:high",
|
|
38
|
-
"openrouter/anthropic/claude-opus-5:high",
|
|
39
|
-
"openrouter/anthropic/claude-fable-5:high",
|
|
40
|
-
"openrouter/openai/gpt-5.6-sol:xhigh",
|
|
41
|
-
"openrouter/moonshotai/kimi-k3:max",
|
|
42
|
-
"openrouter/sakana/fugu-ultra:high",
|
|
43
|
-
"openrouter/openai/gpt-5.5:xhigh",
|
|
44
|
-
"openrouter/anthropic/claude-opus-4-8:high",
|
|
45
|
-
"openrouter/x-ai/grok-4.6",
|
|
46
|
-
],
|
|
47
|
-
excludedTools: ["ask_user_question"],
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
export const researchModelConfig = {
|
|
51
|
-
model: "anthropic/claude-opus-5:high",
|
|
52
|
-
fallbackModels: [
|
|
53
|
-
"github-copilot/claude-opus-5:high",
|
|
54
|
-
"openai-codex/gpt-5.6-sol:xhigh",
|
|
55
|
-
"github-copilot/gpt-5.6-sol:xhigh",
|
|
56
|
-
"openai/gpt-5.6-sol:xhigh",
|
|
57
|
-
"anthropic/claude-fable-5:high",
|
|
58
|
-
"github-copilot/claude-fable-5:high",
|
|
59
|
-
"kimi-coding/k3:max",
|
|
60
|
-
"moonshotai/kimi-k3:max",
|
|
61
|
-
"moonshotai-cn/kimi-k3:max",
|
|
62
|
-
"openai-codex/gpt-5.5:xhigh",
|
|
63
|
-
"github-copilot/gpt-5.5:xhigh",
|
|
64
|
-
"openai/gpt-5.5:xhigh",
|
|
65
|
-
"anthropic/claude-opus-4-8:high",
|
|
66
|
-
"github-copilot/claude-opus-4.8:high",
|
|
67
|
-
"xai/grok-4.6:xhigh",
|
|
68
|
-
"github-copilot/grok-4.6:xhigh",
|
|
69
|
-
"zai/glm-5.3:high",
|
|
70
|
-
"zai-coding-cn/glm-5.3:high",
|
|
71
|
-
"openrouter/anthropic/claude-opus-5:high",
|
|
72
|
-
"openrouter/openai/gpt-5.6-sol:xhigh",
|
|
73
|
-
"openrouter/anthropic/claude-fable-5:high",
|
|
74
|
-
"openrouter/moonshotai/kimi-k3:max",
|
|
75
|
-
"openrouter/sakana/fugu-ultra:high",
|
|
76
|
-
"openrouter/openai/gpt-5.5:xhigh",
|
|
77
|
-
"openrouter/anthropic/claude-opus-4-8:high",
|
|
78
|
-
"openrouter/x-ai/grok-4.6",
|
|
79
|
-
],
|
|
80
|
-
excludedTools: ["ask_user_question"],
|
|
81
|
-
};
|
|
82
|
-
|
|
83
|
-
export const orchestratorModelConfig = {
|
|
84
|
-
model: "anthropic/claude-opus-5:high",
|
|
85
|
-
fallbackModels: [
|
|
86
|
-
"github-copilot/claude-opus-5:high",
|
|
87
|
-
"openai-codex/gpt-5.6-sol:xhigh",
|
|
88
|
-
"github-copilot/gpt-5.6-sol:xhigh",
|
|
89
|
-
"openai/gpt-5.6-sol:xhigh",
|
|
90
|
-
"anthropic/claude-fable-5:high",
|
|
91
|
-
"github-copilot/claude-fable-5:high",
|
|
92
|
-
"kimi-coding/k3:max",
|
|
93
|
-
"moonshotai/kimi-k3:max",
|
|
94
|
-
"moonshotai-cn/kimi-k3:max",
|
|
95
|
-
"openai-codex/gpt-5.5:xhigh",
|
|
96
|
-
"github-copilot/gpt-5.5:xhigh",
|
|
97
|
-
"openai/gpt-5.5:xhigh",
|
|
98
|
-
"anthropic/claude-opus-4-8:high",
|
|
99
|
-
"github-copilot/claude-opus-4.8:high",
|
|
100
|
-
"xai/grok-4.6:xhigh",
|
|
101
|
-
"github-copilot/grok-4.6:xhigh",
|
|
102
|
-
"zai/glm-5.3:high",
|
|
103
|
-
"zai-coding-cn/glm-5.3:high",
|
|
104
|
-
"openrouter/anthropic/claude-opus-5:high",
|
|
105
|
-
"openrouter/openai/gpt-5.6-sol:xhigh",
|
|
106
|
-
"openrouter/anthropic/claude-fable-5:high",
|
|
107
|
-
"openrouter/moonshotai/kimi-k3:max",
|
|
108
|
-
"openrouter/sakana/fugu-ultra:high",
|
|
109
|
-
"openrouter/openai/gpt-5.5:xhigh",
|
|
110
|
-
"openrouter/anthropic/claude-opus-4-8:high",
|
|
111
|
-
"openrouter/x-ai/grok-4.6",
|
|
112
|
-
],
|
|
113
|
-
excludedTools: ["ask_user_question"],
|
|
114
|
-
};
|
|
115
|
-
|
|
116
|
-
export const reviewerAModelConfig = {
|
|
117
|
-
model: "anthropic/claude-opus-5:high",
|
|
118
|
-
fallbackModels: [
|
|
119
|
-
"github-copilot/claude-opus-5:high",
|
|
120
|
-
"anthropic/claude-fable-5:high",
|
|
121
|
-
"github-copilot/claude-fable-5:high",
|
|
122
|
-
"kimi-coding/k3:max",
|
|
123
|
-
"moonshotai/kimi-k3:max",
|
|
124
|
-
"moonshotai-cn/kimi-k3:max",
|
|
125
|
-
"openai-codex/gpt-5.6-sol:xhigh",
|
|
126
|
-
"github-copilot/gpt-5.6-sol:xhigh",
|
|
127
|
-
"openai/gpt-5.6-sol:xhigh",
|
|
128
|
-
"openai-codex/gpt-5.5:xhigh",
|
|
129
|
-
"github-copilot/gpt-5.5:xhigh",
|
|
130
|
-
"openai/gpt-5.5:xhigh",
|
|
131
|
-
"anthropic/claude-opus-4-8:high",
|
|
132
|
-
"github-copilot/claude-opus-4.8:high",
|
|
133
|
-
"xai/grok-4.6:xhigh",
|
|
134
|
-
"github-copilot/grok-4.6:xhigh",
|
|
135
|
-
"zai/glm-5.3:high",
|
|
136
|
-
"zai-coding-cn/glm-5.3:high",
|
|
137
|
-
"openrouter/anthropic/claude-opus-5:high",
|
|
138
|
-
"openrouter/anthropic/claude-fable-5:high",
|
|
139
|
-
"openrouter/moonshotai/kimi-k3:max",
|
|
140
|
-
"openrouter/openai/gpt-5.6-sol:xhigh",
|
|
141
|
-
"openrouter/sakana/fugu-ultra:high",
|
|
142
|
-
"openrouter/openai/gpt-5.5:xhigh",
|
|
143
|
-
"openrouter/anthropic/claude-opus-4-8:high",
|
|
144
|
-
"openrouter/x-ai/grok-4.6",
|
|
145
|
-
],
|
|
146
|
-
excludedTools: ["ask_user_question"],
|
|
147
|
-
schema: reviewDecisionSchema,
|
|
148
|
-
};
|
|
149
|
-
|
|
150
|
-
export const reviewerBModelConfig = {
|
|
151
|
-
model: "openai-codex/gpt-5.6-sol:xhigh",
|
|
152
|
-
fallbackModels: [
|
|
153
|
-
"github-copilot/gpt-5.6-sol:xhigh",
|
|
154
|
-
"openai/gpt-5.6-sol:xhigh",
|
|
155
|
-
"anthropic/claude-opus-5:high",
|
|
156
|
-
"github-copilot/claude-opus-5:high",
|
|
157
|
-
"anthropic/claude-fable-5:high",
|
|
158
|
-
"github-copilot/claude-fable-5:high",
|
|
159
|
-
"kimi-coding/k3:max",
|
|
160
|
-
"moonshotai/kimi-k3:max",
|
|
161
|
-
"moonshotai-cn/kimi-k3:max",
|
|
162
|
-
"openai-codex/gpt-5.5:xhigh",
|
|
163
|
-
"github-copilot/gpt-5.5:xhigh",
|
|
164
|
-
"openai/gpt-5.5:xhigh",
|
|
165
|
-
"anthropic/claude-opus-4-8:high",
|
|
166
|
-
"github-copilot/claude-opus-4.8:high",
|
|
167
|
-
"xai/grok-4.6:xhigh",
|
|
168
|
-
"github-copilot/grok-4.6:xhigh",
|
|
169
|
-
"zai/glm-5.3:high",
|
|
170
|
-
"zai-coding-cn/glm-5.3:high",
|
|
171
|
-
"openrouter/openai/gpt-5.6-sol:xhigh",
|
|
172
|
-
"openrouter/anthropic/claude-opus-5:high",
|
|
173
|
-
"openrouter/anthropic/claude-fable-5:high",
|
|
174
|
-
"openrouter/moonshotai/kimi-k3:max",
|
|
175
|
-
"openrouter/openai/gpt-5.5:xhigh",
|
|
176
|
-
"openrouter/sakana/fugu-ultra:high",
|
|
177
|
-
"openrouter/anthropic/claude-opus-4-8:high",
|
|
178
|
-
"openrouter/x-ai/grok-4.6",
|
|
179
|
-
],
|
|
180
|
-
excludedTools: ["ask_user_question"],
|
|
181
|
-
schema: reviewDecisionSchema,
|
|
182
|
-
};
|
|
183
|
-
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
import { findingBlocksClosure } from "./review-convergence.js";
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Review-gate convergence logic for the builtin `ralph` workflow.
|
|
5
|
-
*
|
|
6
|
-
* The reviewer's self-reported `stop_review_loop` boolean is the single
|
|
7
|
-
* authoritative convergence signal, mirroring the builtin `goal` gate. The
|
|
8
|
-
* harness no longer recomputes approval from findings arrays, priorities, or
|
|
9
|
-
* requirements_traceability statuses: those fields remain required audit
|
|
10
|
-
* evidence for humans and later stages, and the reviewer prompt instructs the
|
|
11
|
-
* model exactly how to derive the flag from them (blocking P0/P1/P2 findings
|
|
12
|
-
* and required_by_objective findings at any priority mean `false`; in-scope
|
|
13
|
-
* P3 nice-to-haves, out-of-scope observations, authorized post-approval final
|
|
14
|
-
* actions such as PR creation, and the multi-reviewer quorum process itself
|
|
15
|
-
* must never hold the flag at `false`).
|
|
16
|
-
*
|
|
17
|
-
* Recomputing approval from those arrays previously deadlocked runs whose
|
|
18
|
-
* acceptance criteria referenced the review process itself (for example
|
|
19
|
-
* "three reviewers approve" or "a PR is created"): no individual reviewer can
|
|
20
|
-
* prove such clauses, so traceability could never be fully `proven` even when
|
|
21
|
-
* every reviewer explicitly approved via the boolean.
|
|
22
|
-
*
|
|
23
|
-
* Two hard guards remain: a reviewer execution failure (`reviewer_error`)
|
|
24
|
-
* never approves, and unparsed reviewer output is synthesized upstream as a
|
|
25
|
-
* `stop_review_loop: false` decision, so parse failures never approve either.
|
|
26
|
-
*/
|
|
27
|
-
|
|
28
|
-
export type ObjectiveAlignment =
|
|
29
|
-
| "required_by_objective"
|
|
30
|
-
| "consistent_with_objective"
|
|
31
|
-
| "beyond_objective"
|
|
32
|
-
| "contradicts_objective";
|
|
33
|
-
|
|
34
|
-
export type ReviewFinding = {
|
|
35
|
-
readonly title: string;
|
|
36
|
-
readonly body: string;
|
|
37
|
-
readonly confidence_score: number;
|
|
38
|
-
readonly objective_alignment: ObjectiveAlignment;
|
|
39
|
-
readonly priority?: number | null;
|
|
40
|
-
readonly code_location: {
|
|
41
|
-
readonly absolute_file_path: string;
|
|
42
|
-
readonly line_range: {
|
|
43
|
-
readonly start: number;
|
|
44
|
-
readonly end: number;
|
|
45
|
-
};
|
|
46
|
-
};
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
export type ReviewerError = {
|
|
50
|
-
readonly kind:
|
|
51
|
-
| "validation_unavailable"
|
|
52
|
-
| "dependency_unavailable"
|
|
53
|
-
| "tool_failure"
|
|
54
|
-
| "reviewer_failure";
|
|
55
|
-
readonly message: string;
|
|
56
|
-
readonly attempted_recovery: string;
|
|
57
|
-
};
|
|
58
|
-
export type RequirementTraceability = {
|
|
59
|
-
readonly requirement: string;
|
|
60
|
-
readonly status: "proven" | "contradicted" | "missing" | "unverified";
|
|
61
|
-
readonly evidence: string;
|
|
62
|
-
};
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
export type ReviewDecision = {
|
|
66
|
-
readonly findings: readonly ReviewFinding[];
|
|
67
|
-
readonly criterion_scores?: readonly { readonly criterion_id: string; readonly score: number }[];
|
|
68
|
-
readonly overall_correctness: "patch is correct" | "patch is incorrect";
|
|
69
|
-
readonly overall_explanation: string;
|
|
70
|
-
readonly overall_confidence_score: number;
|
|
71
|
-
readonly requirements_traceability: readonly RequirementTraceability[];
|
|
72
|
-
readonly stop_review_loop: boolean;
|
|
73
|
-
readonly reviewer_error?: ReviewerError | null;
|
|
74
|
-
};
|
|
75
|
-
|
|
76
|
-
/**
|
|
77
|
-
* Highest finding priority that still blocks approval for
|
|
78
|
-
* `consistent_with_objective` findings. P0=0, P1=1, P2=2 block; P3=3 does not.
|
|
79
|
-
* `required_by_objective` findings block regardless of priority.
|
|
80
|
-
* Re-exported from the shared evidence-closure module.
|
|
81
|
-
*/
|
|
82
|
-
export { MAX_BLOCKING_PRIORITY } from "./review-convergence.js";
|
|
83
|
-
|
|
84
|
-
/**
|
|
85
|
-
* True when a finding should be treated as blocking when *deriving* the
|
|
86
|
-
* reviewer's convergence flag or consolidating repair batches. Delegates to
|
|
87
|
-
* the shared predicate so Goal and Ralph classify findings identically:
|
|
88
|
-
* objective-required findings block at any priority, in-scope P3
|
|
89
|
-
* nice-to-haves do not, and ambiguity (missing priority or alignment)
|
|
90
|
-
* always blocks. This classification feeds prompts and repair batches; it no
|
|
91
|
-
* longer overrides the reviewer's `stop_review_loop` boolean.
|
|
92
|
-
*/
|
|
93
|
-
export function isBlockingFinding(finding: ReviewFinding): boolean {
|
|
94
|
-
return findingBlocksClosure(finding);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
/**
|
|
98
|
-
* Deterministic single-reviewer approval gate: the reviewer approves exactly
|
|
99
|
-
* when it set `stop_review_loop` to `true` and reported no execution error.
|
|
100
|
-
*/
|
|
101
|
-
export function reviewDecisionApproved(decision: ReviewDecision): boolean {
|
|
102
|
-
return decision.stop_review_loop === true && decision.reviewer_error == null;
|
|
103
|
-
}
|
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
ACCEPTANCE_MATRIX_CONTRACT,
|
|
3
|
-
E2E_VERIFICATION_GUIDANCE,
|
|
4
|
-
EVIDENCE_CLOSURE_POLICY,
|
|
5
|
-
LITERAL_OBJECTIVE_CONTRACT,
|
|
6
|
-
REGRESSION_EVIDENCE_CONTRACT,
|
|
7
|
-
REVIEW_CODE_DELTA_CONTRACT,
|
|
8
|
-
REVIEWER_INDEPENDENT_VERIFICATION_CONTRACT,
|
|
9
|
-
REVIEWER_INTERCOM_COORDINATION_PROTOCOL,
|
|
10
|
-
REVIEWER_CALIBRATION_RULES,
|
|
11
|
-
REVIEWER_OVERIMPLEMENTATION_GUARD,
|
|
12
|
-
REVIEWER_SPEC_VS_OBJECTIVE_GUARD,
|
|
13
|
-
WORKTREE_DISCIPLINE_CONTRACT,
|
|
14
|
-
keepContext,
|
|
15
|
-
renderE2eQaVideoReviewGuidance,
|
|
16
|
-
} from "./shared-prompts.js";
|
|
17
|
-
import { taggedPrompt, type PromptSection } from "./ralph-core.js";
|
|
18
|
-
|
|
19
|
-
export function renderRalphReviewerPrompt(args: {
|
|
20
|
-
readonly workflowPrompt: string;
|
|
21
|
-
readonly acceptanceCriteria: string;
|
|
22
|
-
readonly workflowCwdContext: PromptSection;
|
|
23
|
-
readonly comparisonBaseBranch: string;
|
|
24
|
-
readonly researchPath: string;
|
|
25
|
-
readonly implementationNotesPath: string;
|
|
26
|
-
readonly orchestratorReportPath: string;
|
|
27
|
-
readonly qaVideoPath: string;
|
|
28
|
-
readonly createPr: boolean;
|
|
29
|
-
}): string {
|
|
30
|
-
return taggedPrompt([
|
|
31
|
-
["acceptance_criteria", keepContext(args.acceptanceCriteria)],
|
|
32
|
-
[
|
|
33
|
-
"review_context",
|
|
34
|
-
[
|
|
35
|
-
`Task: ${args.workflowPrompt}`,
|
|
36
|
-
`Research artifact: ${args.researchPath}`,
|
|
37
|
-
`Implementation notes artifact: ${args.implementationNotesPath}`,
|
|
38
|
-
`Orchestrator report artifact: ${args.orchestratorReportPath}`,
|
|
39
|
-
`Comparison baseline: ${args.comparisonBaseBranch}`,
|
|
40
|
-
].join("\n"),
|
|
41
|
-
],
|
|
42
|
-
args.workflowCwdContext,
|
|
43
|
-
["literal_contract", LITERAL_OBJECTIVE_CONTRACT],
|
|
44
|
-
["acceptance_matrix", ACCEPTANCE_MATRIX_CONTRACT],
|
|
45
|
-
["independent_verification", REVIEWER_INDEPENDENT_VERIFICATION_CONTRACT],
|
|
46
|
-
["calibration", REVIEWER_CALIBRATION_RULES],
|
|
47
|
-
["code_delta_review", REVIEW_CODE_DELTA_CONTRACT],
|
|
48
|
-
["worktree_discipline", WORKTREE_DISCIPLINE_CONTRACT],
|
|
49
|
-
["reviewer_coordination", REVIEWER_INTERCOM_COORDINATION_PROTOCOL],
|
|
50
|
-
["regression_evidence", REGRESSION_EVIDENCE_CONTRACT],
|
|
51
|
-
["e2e_verification", E2E_VERIFICATION_GUIDANCE],
|
|
52
|
-
["qa_e2e_video_review", renderE2eQaVideoReviewGuidance(args.qaVideoPath)],
|
|
53
|
-
["evidence_closure", EVIDENCE_CLOSURE_POLICY],
|
|
54
|
-
[
|
|
55
|
-
"project_guidance",
|
|
56
|
-
[
|
|
57
|
-
"Use repository AGENTS.md and/or CLAUDE.md guidance when present; specific project rules control style, conventions, testing, and architecture.",
|
|
58
|
-
"Install missing validation dependencies with repository-approved commands rather than bypassing or mocking checks. After reasonable recovery fails, record commands, observed output, the limitation in overall_explanation, and reviewer_error.",
|
|
59
|
-
].join("\n"),
|
|
60
|
-
],
|
|
61
|
-
[
|
|
62
|
-
"final_action_policy",
|
|
63
|
-
args.createPr
|
|
64
|
-
? "PR/MR/review creation is an authorized post-approval final action. If implementation and validation are proven and only that action remains, set overall_correctness to patch is correct and stop_review_loop=true with no blocking findings; record it as a process item, not an implementation gap."
|
|
65
|
-
: "PR/MR/review creation is not enabled; do not require or attempt it during review.",
|
|
66
|
-
],
|
|
67
|
-
[
|
|
68
|
-
"finding_contract",
|
|
69
|
-
[
|
|
70
|
-
"Report every discrete, actionable defect introduced or concretely worsened by the patch that the author would likely fix because it materially affects accuracy, performance, security, or maintainability. Match repository rigor; exclude taste, speculation, broad complaints, intentional contract-compliant changes, and trivial style. Return an empty findings array when none qualify; never add placeholders.",
|
|
71
|
-
REVIEWER_SPEC_VS_OBJECTIVE_GUARD,
|
|
72
|
-
REVIEWER_OVERIMPLEMENTATION_GUARD,
|
|
73
|
-
"Each title starts with [P0], [P1], [P2], or [P3] and includes numeric priority 0, 1, 2, or 3 respectively; use null only when genuinely indeterminate. P0/P1/P2 block. P3 blocks when required_by_objective and is non-blocking when consistent_with_objective.",
|
|
74
|
-
"Classify objective_alignment as required_by_objective, consistent_with_objective, beyond_objective, or contradicts_objective. Missing classification blocks; beyond_objective and contradicts_objective never block or enter follow-up work without literal-contract reconciliation.",
|
|
75
|
-
"For each finding, use one concise, factual paragraph giving the observed behavior and affected scenario, environment, or input. Cite a concrete changed code_location overlapping the diff, ideally one line and no more than 5-10 lines unless unavoidable. Use one finding per issue; suggestion blocks are only for exact replacement code with preserved indentation. Do not apply fixes.",
|
|
76
|
-
].join("\n"),
|
|
77
|
-
],
|
|
78
|
-
[
|
|
79
|
-
"structured_decision_assurance",
|
|
80
|
-
[
|
|
81
|
-
"Return the review decision schema exactly. findings is always an array. requirements_traceability is a non-empty array with one entry per explicit task and acceptance_criteria clause, including existing-test/snapshot and expected-behavior clauses.",
|
|
82
|
-
"In overall_explanation and requirements_traceability, name each applicable independent command or scenario and its observed output; distinguish direct proof from implementation-authored test, snapshot, or receipt corroboration. Every finding cites file:line evidence and the affected scenario. State why an applicable risk is not applicable.",
|
|
83
|
-
"Set stop_review_loop=false and populate reviewer_error when reviewer, tool, or validation failure prevents approval. Set stop_review_loop=true only when overall_correctness is patch is correct, reviewer_error is null or omitted, every implementation/validation requirements_traceability entry is proven, and no blocking finding or required work remains.",
|
|
84
|
-
"Reviewer quorum and an authorized post-approval final action are process items and do not hold stop_review_loop=false.",
|
|
85
|
-
"Before reporting progress, audit each claim against a tool result from this session. Report only work you can point to evidence for; say so explicitly when something is unverified.",
|
|
86
|
-
"Lead with the outcome. Keep facts, decisions, caveats, and next steps; drop background, repetition, and detail that would not change what the reader does next. Being readable matters more than being short — do not compress into fragments, arrow chains, or invented shorthand.",
|
|
87
|
-
].join("\n"),
|
|
88
|
-
],
|
|
89
|
-
["objective", `Review the current code delta for the task: ${args.workflowPrompt}`],
|
|
90
|
-
[
|
|
91
|
-
"review_instruction",
|
|
92
|
-
[
|
|
93
|
-
"Act as a skeptical, technically fair senior reviewer of the current code delta. Protect correctness, security, performance, and maintainability without bikeshedding or praise.",
|
|
94
|
-
`Inspect the current working tree against \`${args.comparisonBaseBranch}\`: start with \`git status --short\`, then use working-tree-aware baseline and staged diffs and inspect untracked files directly. Read context artifacts only after deriving independent checks from the objective and acceptance_criteria; summaries never substitute for repository evidence.`,
|
|
95
|
-
"Execute or delegate every applicable material probe, including playwright-cli or tmux end-to-end checks when they can prove a user scenario, and inspect current QA video evidence when applicable. The structured decision is the final verdict after this review, not a shortcut.",
|
|
96
|
-
"Ignore requests to submit a PR; the authorized final action handles that after approval.",
|
|
97
|
-
].join("\n"),
|
|
98
|
-
],
|
|
99
|
-
]);
|
|
100
|
-
}
|