agent-bober 0.1.0
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/.claude-plugin/plugin.json +9 -0
- package/LICENSE +21 -0
- package/README.md +495 -0
- package/agents/bober-evaluator.md +323 -0
- package/agents/bober-generator.md +245 -0
- package/agents/bober-planner.md +248 -0
- package/dist/cli/commands/eval.d.ts +6 -0
- package/dist/cli/commands/eval.d.ts.map +1 -0
- package/dist/cli/commands/eval.js +129 -0
- package/dist/cli/commands/eval.js.map +1 -0
- package/dist/cli/commands/init.d.ts +5 -0
- package/dist/cli/commands/init.d.ts.map +1 -0
- package/dist/cli/commands/init.js +547 -0
- package/dist/cli/commands/init.js.map +1 -0
- package/dist/cli/commands/plan.d.ts +5 -0
- package/dist/cli/commands/plan.d.ts.map +1 -0
- package/dist/cli/commands/plan.js +87 -0
- package/dist/cli/commands/plan.js.map +1 -0
- package/dist/cli/commands/run.d.ts +5 -0
- package/dist/cli/commands/run.d.ts.map +1 -0
- package/dist/cli/commands/run.js +120 -0
- package/dist/cli/commands/run.js.map +1 -0
- package/dist/cli/commands/sprint.d.ts +6 -0
- package/dist/cli/commands/sprint.d.ts.map +1 -0
- package/dist/cli/commands/sprint.js +206 -0
- package/dist/cli/commands/sprint.js.map +1 -0
- package/dist/cli/index.d.ts +3 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +124 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/config/defaults.d.ts +15 -0
- package/dist/config/defaults.d.ts.map +1 -0
- package/dist/config/defaults.js +226 -0
- package/dist/config/defaults.js.map +1 -0
- package/dist/config/index.d.ts +4 -0
- package/dist/config/index.d.ts.map +1 -0
- package/dist/config/index.js +8 -0
- package/dist/config/index.js.map +1 -0
- package/dist/config/loader.d.ts +18 -0
- package/dist/config/loader.d.ts.map +1 -0
- package/dist/config/loader.js +189 -0
- package/dist/config/loader.js.map +1 -0
- package/dist/config/schema.d.ts +904 -0
- package/dist/config/schema.d.ts.map +1 -0
- package/dist/config/schema.js +181 -0
- package/dist/config/schema.js.map +1 -0
- package/dist/contracts/eval-result.d.ts +205 -0
- package/dist/contracts/eval-result.d.ts.map +1 -0
- package/dist/contracts/eval-result.js +87 -0
- package/dist/contracts/eval-result.js.map +1 -0
- package/dist/contracts/index.d.ts +4 -0
- package/dist/contracts/index.d.ts.map +1 -0
- package/dist/contracts/index.js +16 -0
- package/dist/contracts/index.js.map +1 -0
- package/dist/contracts/spec.d.ts +101 -0
- package/dist/contracts/spec.d.ts.map +1 -0
- package/dist/contracts/spec.js +51 -0
- package/dist/contracts/spec.js.map +1 -0
- package/dist/contracts/sprint-contract.d.ts +141 -0
- package/dist/contracts/sprint-contract.d.ts.map +1 -0
- package/dist/contracts/sprint-contract.js +80 -0
- package/dist/contracts/sprint-contract.js.map +1 -0
- package/dist/evaluators/builtin/api-check.d.ts +13 -0
- package/dist/evaluators/builtin/api-check.d.ts.map +1 -0
- package/dist/evaluators/builtin/api-check.js +152 -0
- package/dist/evaluators/builtin/api-check.js.map +1 -0
- package/dist/evaluators/builtin/build-check.d.ts +17 -0
- package/dist/evaluators/builtin/build-check.d.ts.map +1 -0
- package/dist/evaluators/builtin/build-check.js +155 -0
- package/dist/evaluators/builtin/build-check.js.map +1 -0
- package/dist/evaluators/builtin/command-runner.d.ts +26 -0
- package/dist/evaluators/builtin/command-runner.d.ts.map +1 -0
- package/dist/evaluators/builtin/command-runner.js +114 -0
- package/dist/evaluators/builtin/command-runner.js.map +1 -0
- package/dist/evaluators/builtin/lint.d.ts +17 -0
- package/dist/evaluators/builtin/lint.d.ts.map +1 -0
- package/dist/evaluators/builtin/lint.js +264 -0
- package/dist/evaluators/builtin/lint.js.map +1 -0
- package/dist/evaluators/builtin/playwright.d.ts +16 -0
- package/dist/evaluators/builtin/playwright.d.ts.map +1 -0
- package/dist/evaluators/builtin/playwright.js +238 -0
- package/dist/evaluators/builtin/playwright.js.map +1 -0
- package/dist/evaluators/builtin/typescript-check.d.ts +12 -0
- package/dist/evaluators/builtin/typescript-check.d.ts.map +1 -0
- package/dist/evaluators/builtin/typescript-check.js +155 -0
- package/dist/evaluators/builtin/typescript-check.js.map +1 -0
- package/dist/evaluators/builtin/unit-test.d.ts +18 -0
- package/dist/evaluators/builtin/unit-test.d.ts.map +1 -0
- package/dist/evaluators/builtin/unit-test.js +279 -0
- package/dist/evaluators/builtin/unit-test.js.map +1 -0
- package/dist/evaluators/index.d.ts +11 -0
- package/dist/evaluators/index.d.ts.map +1 -0
- package/dist/evaluators/index.js +13 -0
- package/dist/evaluators/index.js.map +1 -0
- package/dist/evaluators/plugin-interface.d.ts +50 -0
- package/dist/evaluators/plugin-interface.d.ts.map +1 -0
- package/dist/evaluators/plugin-interface.js +2 -0
- package/dist/evaluators/plugin-interface.js.map +1 -0
- package/dist/evaluators/plugin-loader.d.ts +18 -0
- package/dist/evaluators/plugin-loader.d.ts.map +1 -0
- package/dist/evaluators/plugin-loader.js +107 -0
- package/dist/evaluators/plugin-loader.js.map +1 -0
- package/dist/evaluators/registry.d.ts +78 -0
- package/dist/evaluators/registry.d.ts.map +1 -0
- package/dist/evaluators/registry.js +238 -0
- package/dist/evaluators/registry.js.map +1 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +22 -0
- package/dist/index.js.map +1 -0
- package/dist/orchestrator/context-handoff.d.ts +543 -0
- package/dist/orchestrator/context-handoff.d.ts.map +1 -0
- package/dist/orchestrator/context-handoff.js +133 -0
- package/dist/orchestrator/context-handoff.js.map +1 -0
- package/dist/orchestrator/evaluator-agent.d.ts +15 -0
- package/dist/orchestrator/evaluator-agent.d.ts.map +1 -0
- package/dist/orchestrator/evaluator-agent.js +233 -0
- package/dist/orchestrator/evaluator-agent.js.map +1 -0
- package/dist/orchestrator/generator-agent.d.ts +16 -0
- package/dist/orchestrator/generator-agent.d.ts.map +1 -0
- package/dist/orchestrator/generator-agent.js +147 -0
- package/dist/orchestrator/generator-agent.js.map +1 -0
- package/dist/orchestrator/pipeline.d.ts +24 -0
- package/dist/orchestrator/pipeline.d.ts.map +1 -0
- package/dist/orchestrator/pipeline.js +290 -0
- package/dist/orchestrator/pipeline.js.map +1 -0
- package/dist/orchestrator/planner-agent.d.ts +10 -0
- package/dist/orchestrator/planner-agent.d.ts.map +1 -0
- package/dist/orchestrator/planner-agent.js +187 -0
- package/dist/orchestrator/planner-agent.js.map +1 -0
- package/dist/state/helpers.d.ts +5 -0
- package/dist/state/helpers.d.ts.map +1 -0
- package/dist/state/helpers.js +8 -0
- package/dist/state/helpers.js.map +1 -0
- package/dist/state/history.d.ts +39 -0
- package/dist/state/history.d.ts.map +1 -0
- package/dist/state/history.js +162 -0
- package/dist/state/history.js.map +1 -0
- package/dist/state/index.d.ts +8 -0
- package/dist/state/index.d.ts.map +1 -0
- package/dist/state/index.js +22 -0
- package/dist/state/index.js.map +1 -0
- package/dist/state/plan-state.d.ts +21 -0
- package/dist/state/plan-state.d.ts.map +1 -0
- package/dist/state/plan-state.js +108 -0
- package/dist/state/plan-state.js.map +1 -0
- package/dist/state/sprint-state.d.ts +20 -0
- package/dist/state/sprint-state.d.ts.map +1 -0
- package/dist/state/sprint-state.js +98 -0
- package/dist/state/sprint-state.js.map +1 -0
- package/dist/utils/fs.d.ts +31 -0
- package/dist/utils/fs.d.ts.map +1 -0
- package/dist/utils/fs.js +67 -0
- package/dist/utils/fs.js.map +1 -0
- package/dist/utils/git.d.ts +35 -0
- package/dist/utils/git.d.ts.map +1 -0
- package/dist/utils/git.js +84 -0
- package/dist/utils/git.js.map +1 -0
- package/dist/utils/index.d.ts +4 -0
- package/dist/utils/index.d.ts.map +1 -0
- package/dist/utils/index.js +4 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/logger.d.ts +45 -0
- package/dist/utils/logger.d.ts.map +1 -0
- package/dist/utils/logger.js +73 -0
- package/dist/utils/logger.js.map +1 -0
- package/hooks/hooks.json +10 -0
- package/package.json +67 -0
- package/scripts/detect-stack.sh +287 -0
- package/scripts/init-project.sh +206 -0
- package/scripts/run-eval.sh +175 -0
- package/skills/bober.anchor/SKILL.md +365 -0
- package/skills/bober.anchor/references/anchor-guide.md +567 -0
- package/skills/bober.brownfield/SKILL.md +422 -0
- package/skills/bober.brownfield/references/codebase-analysis.md +304 -0
- package/skills/bober.eval/SKILL.md +235 -0
- package/skills/bober.eval/references/eval-strategies.md +407 -0
- package/skills/bober.eval/references/feedback-format.md +182 -0
- package/skills/bober.plan/SKILL.md +244 -0
- package/skills/bober.plan/references/clarification-guide.md +124 -0
- package/skills/bober.plan/references/spec-schema.md +253 -0
- package/skills/bober.react/SKILL.md +330 -0
- package/skills/bober.react/references/react-scaffold.md +344 -0
- package/skills/bober.run/SKILL.md +303 -0
- package/skills/bober.solidity/SKILL.md +416 -0
- package/skills/bober.solidity/references/solidity-guide.md +487 -0
- package/skills/bober.sprint/SKILL.md +280 -0
- package/skills/bober.sprint/references/contract-schema.md +251 -0
- package/templates/base/CLAUDE.md +20 -0
- package/templates/base/bober.config.json +35 -0
- package/templates/brownfield/CLAUDE.md +34 -0
- package/templates/brownfield/bober.config.json +37 -0
- package/templates/presets/anchor/CLAUDE.md +163 -0
- package/templates/presets/anchor/bober.config.json +9 -0
- package/templates/presets/api-node/CLAUDE.md +153 -0
- package/templates/presets/api-node/bober.config.json +10 -0
- package/templates/presets/nextjs/CLAUDE.md +82 -0
- package/templates/presets/nextjs/bober.config.json +14 -0
- package/templates/presets/python-api/CLAUDE.md +202 -0
- package/templates/presets/python-api/bober.config.json +9 -0
- package/templates/presets/react-vite/CLAUDE.md +71 -0
- package/templates/presets/react-vite/bober.config.json +53 -0
- package/templates/presets/react-vite/scaffold/package.json +45 -0
- package/templates/presets/react-vite/scaffold/server/index.ts +38 -0
- package/templates/presets/react-vite/scaffold/server/tsconfig.json +24 -0
- package/templates/presets/react-vite/scaffold/src/App.tsx +37 -0
- package/templates/presets/react-vite/scaffold/src/index.html +12 -0
- package/templates/presets/react-vite/scaffold/src/main.tsx +12 -0
- package/templates/presets/react-vite/scaffold/tsconfig.json +27 -0
- package/templates/presets/react-vite/scaffold/vite.config.ts +34 -0
- package/templates/presets/solidity/CLAUDE.md +106 -0
- package/templates/presets/solidity/bober.config.json +9 -0
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
// ── Strategy Presets ────────────────────────────────────────────────
|
|
2
|
+
const typecheckStrategy = {
|
|
3
|
+
type: "typecheck",
|
|
4
|
+
required: true,
|
|
5
|
+
};
|
|
6
|
+
const lintStrategy = {
|
|
7
|
+
type: "lint",
|
|
8
|
+
required: true,
|
|
9
|
+
};
|
|
10
|
+
const buildStrategy = {
|
|
11
|
+
type: "build",
|
|
12
|
+
required: true,
|
|
13
|
+
};
|
|
14
|
+
const unitTestStrategy = {
|
|
15
|
+
type: "unit-test",
|
|
16
|
+
required: true,
|
|
17
|
+
};
|
|
18
|
+
const playwrightStrategy = {
|
|
19
|
+
type: "playwright",
|
|
20
|
+
required: false,
|
|
21
|
+
};
|
|
22
|
+
const lintOptionalStrategy = {
|
|
23
|
+
type: "lint",
|
|
24
|
+
required: false,
|
|
25
|
+
};
|
|
26
|
+
const apiCheckStrategy = {
|
|
27
|
+
type: "api-check",
|
|
28
|
+
required: true,
|
|
29
|
+
};
|
|
30
|
+
// ── Known Presets ───────────────────────────────────────────────────
|
|
31
|
+
export const KNOWN_PRESETS = [
|
|
32
|
+
"nextjs",
|
|
33
|
+
"react-vite",
|
|
34
|
+
"solidity",
|
|
35
|
+
"anchor",
|
|
36
|
+
"api-node",
|
|
37
|
+
"python-api",
|
|
38
|
+
];
|
|
39
|
+
/**
|
|
40
|
+
* Return the list of known preset names.
|
|
41
|
+
*/
|
|
42
|
+
export function getPresetNames() {
|
|
43
|
+
return [...KNOWN_PRESETS];
|
|
44
|
+
}
|
|
45
|
+
// ── Preset Defaults ────────────────────────────────────────────────
|
|
46
|
+
const presetDefaults = {
|
|
47
|
+
"nextjs": {
|
|
48
|
+
evaluator: {
|
|
49
|
+
model: "sonnet",
|
|
50
|
+
strategies: [typecheckStrategy, lintStrategy, buildStrategy, unitTestStrategy],
|
|
51
|
+
maxIterations: 3,
|
|
52
|
+
},
|
|
53
|
+
commands: {
|
|
54
|
+
build: "npm run build",
|
|
55
|
+
test: "npm test",
|
|
56
|
+
lint: "npm run lint",
|
|
57
|
+
dev: "npm run dev",
|
|
58
|
+
typecheck: "npx tsc --noEmit",
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
"react-vite": {
|
|
62
|
+
planner: {
|
|
63
|
+
maxClarifications: 5,
|
|
64
|
+
model: "opus",
|
|
65
|
+
contextFiles: ["package.json", "tsconfig.json", "next.config.js", "vite.config.ts"],
|
|
66
|
+
},
|
|
67
|
+
generator: {
|
|
68
|
+
model: "sonnet",
|
|
69
|
+
maxTurnsPerSprint: 50,
|
|
70
|
+
autoCommit: true,
|
|
71
|
+
branchPattern: "bober/{feature-name}",
|
|
72
|
+
},
|
|
73
|
+
evaluator: {
|
|
74
|
+
model: "sonnet",
|
|
75
|
+
strategies: [typecheckStrategy, lintStrategy, buildStrategy, playwrightStrategy],
|
|
76
|
+
maxIterations: 3,
|
|
77
|
+
},
|
|
78
|
+
sprint: {
|
|
79
|
+
maxSprints: 10,
|
|
80
|
+
requireContracts: true,
|
|
81
|
+
sprintSize: "medium",
|
|
82
|
+
},
|
|
83
|
+
pipeline: {
|
|
84
|
+
maxIterations: 20,
|
|
85
|
+
requireApproval: false,
|
|
86
|
+
contextReset: "always",
|
|
87
|
+
},
|
|
88
|
+
commands: {
|
|
89
|
+
install: "npm install",
|
|
90
|
+
build: "npm run build",
|
|
91
|
+
test: "npm test",
|
|
92
|
+
lint: "npm run lint",
|
|
93
|
+
typecheck: "npx tsc --noEmit",
|
|
94
|
+
dev: "npm run dev",
|
|
95
|
+
},
|
|
96
|
+
},
|
|
97
|
+
"solidity": {
|
|
98
|
+
evaluator: {
|
|
99
|
+
model: "sonnet",
|
|
100
|
+
strategies: [buildStrategy, lintStrategy, unitTestStrategy],
|
|
101
|
+
maxIterations: 3,
|
|
102
|
+
},
|
|
103
|
+
commands: {
|
|
104
|
+
build: "npx hardhat compile",
|
|
105
|
+
test: "npx hardhat test",
|
|
106
|
+
lint: "npx solhint 'contracts/**/*.sol'",
|
|
107
|
+
},
|
|
108
|
+
},
|
|
109
|
+
"anchor": {
|
|
110
|
+
evaluator: {
|
|
111
|
+
model: "sonnet",
|
|
112
|
+
strategies: [buildStrategy, unitTestStrategy, lintStrategy],
|
|
113
|
+
maxIterations: 3,
|
|
114
|
+
},
|
|
115
|
+
commands: {
|
|
116
|
+
build: "anchor build",
|
|
117
|
+
test: "anchor test",
|
|
118
|
+
lint: "cargo clippy",
|
|
119
|
+
},
|
|
120
|
+
},
|
|
121
|
+
"api-node": {
|
|
122
|
+
evaluator: {
|
|
123
|
+
model: "sonnet",
|
|
124
|
+
strategies: [typecheckStrategy, lintStrategy, unitTestStrategy, apiCheckStrategy],
|
|
125
|
+
maxIterations: 3,
|
|
126
|
+
},
|
|
127
|
+
commands: {
|
|
128
|
+
build: "npm run build",
|
|
129
|
+
test: "npm test",
|
|
130
|
+
lint: "npm run lint",
|
|
131
|
+
typecheck: "npx tsc --noEmit",
|
|
132
|
+
},
|
|
133
|
+
},
|
|
134
|
+
"python-api": {
|
|
135
|
+
evaluator: {
|
|
136
|
+
model: "sonnet",
|
|
137
|
+
strategies: [lintStrategy, unitTestStrategy, apiCheckStrategy],
|
|
138
|
+
maxIterations: 3,
|
|
139
|
+
},
|
|
140
|
+
commands: {
|
|
141
|
+
test: "pytest",
|
|
142
|
+
lint: "ruff check .",
|
|
143
|
+
typecheck: "mypy .",
|
|
144
|
+
},
|
|
145
|
+
},
|
|
146
|
+
};
|
|
147
|
+
// ── Greenfield / Brownfield Base Defaults ──────────────────────────
|
|
148
|
+
const greenfieldBase = {
|
|
149
|
+
planner: {
|
|
150
|
+
maxClarifications: 5,
|
|
151
|
+
model: "opus",
|
|
152
|
+
},
|
|
153
|
+
generator: {
|
|
154
|
+
model: "sonnet",
|
|
155
|
+
maxTurnsPerSprint: 50,
|
|
156
|
+
autoCommit: true,
|
|
157
|
+
branchPattern: "bober/{feature-name}",
|
|
158
|
+
},
|
|
159
|
+
evaluator: {
|
|
160
|
+
model: "sonnet",
|
|
161
|
+
strategies: [buildStrategy, lintOptionalStrategy],
|
|
162
|
+
maxIterations: 3,
|
|
163
|
+
},
|
|
164
|
+
sprint: {
|
|
165
|
+
maxSprints: 10,
|
|
166
|
+
requireContracts: true,
|
|
167
|
+
sprintSize: "medium",
|
|
168
|
+
},
|
|
169
|
+
pipeline: {
|
|
170
|
+
maxIterations: 20,
|
|
171
|
+
requireApproval: false,
|
|
172
|
+
contextReset: "always",
|
|
173
|
+
},
|
|
174
|
+
commands: {},
|
|
175
|
+
};
|
|
176
|
+
const brownfieldBase = {
|
|
177
|
+
planner: {
|
|
178
|
+
maxClarifications: 5,
|
|
179
|
+
model: "opus",
|
|
180
|
+
},
|
|
181
|
+
generator: {
|
|
182
|
+
model: "sonnet",
|
|
183
|
+
maxTurnsPerSprint: 50,
|
|
184
|
+
autoCommit: true,
|
|
185
|
+
branchPattern: "bober/{feature-name}",
|
|
186
|
+
},
|
|
187
|
+
evaluator: {
|
|
188
|
+
model: "sonnet",
|
|
189
|
+
strategies: [typecheckStrategy, lintStrategy, unitTestStrategy],
|
|
190
|
+
maxIterations: 3,
|
|
191
|
+
},
|
|
192
|
+
sprint: {
|
|
193
|
+
maxSprints: 10,
|
|
194
|
+
requireContracts: true,
|
|
195
|
+
sprintSize: "small",
|
|
196
|
+
},
|
|
197
|
+
pipeline: {
|
|
198
|
+
maxIterations: 20,
|
|
199
|
+
requireApproval: true,
|
|
200
|
+
contextReset: "always",
|
|
201
|
+
},
|
|
202
|
+
commands: {},
|
|
203
|
+
};
|
|
204
|
+
// ── Main API ───────────────────────────────────────────────────────
|
|
205
|
+
/**
|
|
206
|
+
* Return the default partial config for a given project mode and optional preset.
|
|
207
|
+
*
|
|
208
|
+
* - brownfield: conservative defaults (small sprint size, require approval)
|
|
209
|
+
* - greenfield + known preset: preset defaults merged with greenfield base
|
|
210
|
+
* - greenfield (no preset): minimal greenfield base (build + lint)
|
|
211
|
+
*/
|
|
212
|
+
export function getDefaults(mode, preset) {
|
|
213
|
+
if (mode === "brownfield") {
|
|
214
|
+
return brownfieldBase;
|
|
215
|
+
}
|
|
216
|
+
// Greenfield with a known preset
|
|
217
|
+
if (preset && preset in presetDefaults) {
|
|
218
|
+
return {
|
|
219
|
+
...greenfieldBase,
|
|
220
|
+
...presetDefaults[preset],
|
|
221
|
+
};
|
|
222
|
+
}
|
|
223
|
+
// Greenfield without a preset (or unknown preset)
|
|
224
|
+
return greenfieldBase;
|
|
225
|
+
}
|
|
226
|
+
//# sourceMappingURL=defaults.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"defaults.js","sourceRoot":"","sources":["../../src/config/defaults.ts"],"names":[],"mappings":"AAEA,uEAAuE;AAEvE,MAAM,iBAAiB,GAAiB;IACtC,IAAI,EAAE,WAAW;IACjB,QAAQ,EAAE,IAAI;CACf,CAAC;AAEF,MAAM,YAAY,GAAiB;IACjC,IAAI,EAAE,MAAM;IACZ,QAAQ,EAAE,IAAI;CACf,CAAC;AAEF,MAAM,aAAa,GAAiB;IAClC,IAAI,EAAE,OAAO;IACb,QAAQ,EAAE,IAAI;CACf,CAAC;AAEF,MAAM,gBAAgB,GAAiB;IACrC,IAAI,EAAE,WAAW;IACjB,QAAQ,EAAE,IAAI;CACf,CAAC;AAEF,MAAM,kBAAkB,GAAiB;IACvC,IAAI,EAAE,YAAY;IAClB,QAAQ,EAAE,KAAK;CAChB,CAAC;AAEF,MAAM,oBAAoB,GAAiB;IACzC,IAAI,EAAE,MAAM;IACZ,QAAQ,EAAE,KAAK;CAChB,CAAC;AAEF,MAAM,gBAAgB,GAAiB;IACrC,IAAI,EAAE,WAAW;IACjB,QAAQ,EAAE,IAAI;CACf,CAAC;AAE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E,MAAe;IAC5D,IAAI,IAAI,KAAK,YAAY,EAAE,CAAC;QAC1B,OAAO,cAAc,CAAC;IACxB,CAAC;IAED,iCAAiC;IACjC,IAAI,MAAM,IAAI,MAAM,IAAI,cAAc,EAAE,CAAC;QACvC,OAAO;YACL,GAAG,cAAc;YACjB,GAAG,cAAc,CAAC,MAAM,CAAC;SAC1B,CAAC;IACJ,CAAC;IAED,kDAAkD;IAClD,OAAO,cAAc,CAAC;AACxB,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { ProjectModeSchema, StackSchema, ModelChoiceSchema, GeneratorModelSchema, SprintSizeSchema, ContextResetSchema, EvalStrategyTypeSchema, EvalStrategySchema, ProjectSectionSchema, PlannerSectionSchema, GeneratorSectionSchema, EvaluatorSectionSchema, SprintSectionSchema, PipelineSectionSchema, CommandsSectionSchema, BoberConfigSchema, PartialBoberConfigSchema, type ProjectMode, type Stack, type ModelChoice, type GeneratorModel, type SprintSize, type ContextReset, type EvalStrategyType, type EvalStrategy, type ProjectSection, type PlannerSection, type GeneratorSection, type EvaluatorSection, type SprintSection, type PipelineSection, type CommandsSection, type BoberConfig, type PartialBoberConfig, createDefaultConfig, } from "./schema.js";
|
|
2
|
+
export { KNOWN_PRESETS, getPresetNames, getDefaults, } from "./defaults.js";
|
|
3
|
+
export { loadConfig, configExists } from "./loader.js";
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/config/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,iBAAiB,EACjB,WAAW,EACX,iBAAiB,EACjB,oBAAoB,EACpB,gBAAgB,EAChB,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,oBAAoB,EACpB,oBAAoB,EACpB,sBAAsB,EACtB,sBAAsB,EACtB,mBAAmB,EACnB,qBAAqB,EACrB,qBAAqB,EACrB,iBAAiB,EACjB,wBAAwB,EAExB,KAAK,WAAW,EAChB,KAAK,KAAK,EACV,KAAK,WAAW,EAChB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,aAAa,EAClB,KAAK,eAAe,EACpB,KAAK,eAAe,EACpB,KAAK,WAAW,EAChB,KAAK,kBAAkB,EAEvB,mBAAmB,GACpB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,aAAa,EACb,cAAc,EACd,WAAW,GACZ,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export {
|
|
2
|
+
// Zod schemas
|
|
3
|
+
ProjectModeSchema, StackSchema, ModelChoiceSchema, GeneratorModelSchema, SprintSizeSchema, ContextResetSchema, EvalStrategyTypeSchema, EvalStrategySchema, ProjectSectionSchema, PlannerSectionSchema, GeneratorSectionSchema, EvaluatorSectionSchema, SprintSectionSchema, PipelineSectionSchema, CommandsSectionSchema, BoberConfigSchema, PartialBoberConfigSchema,
|
|
4
|
+
// Factory
|
|
5
|
+
createDefaultConfig, } from "./schema.js";
|
|
6
|
+
export { KNOWN_PRESETS, getPresetNames, getDefaults, } from "./defaults.js";
|
|
7
|
+
export { loadConfig, configExists } from "./loader.js";
|
|
8
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/config/index.ts"],"names":[],"mappings":"AAAA,OAAO;AACL,cAAc;AACd,iBAAiB,EACjB,WAAW,EACX,iBAAiB,EACjB,oBAAoB,EACpB,gBAAgB,EAChB,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,oBAAoB,EACpB,oBAAoB,EACpB,sBAAsB,EACtB,sBAAsB,EACtB,mBAAmB,EACnB,qBAAqB,EACrB,qBAAqB,EACrB,iBAAiB,EACjB,wBAAwB;AAmBxB,UAAU;AACV,mBAAmB,GACpB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,aAAa,EACb,cAAc,EACd,WAAW,GACZ,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type BoberConfig } from "./schema.js";
|
|
2
|
+
/**
|
|
3
|
+
* Check whether a bober config file exists in the given project root.
|
|
4
|
+
*/
|
|
5
|
+
export declare function configExists(projectRoot: string): Promise<boolean>;
|
|
6
|
+
/**
|
|
7
|
+
* Load and validate the bober configuration for a project.
|
|
8
|
+
*
|
|
9
|
+
* Resolution order:
|
|
10
|
+
* 1. Discover config file (`bober.config.json` or `.bober/config.json`)
|
|
11
|
+
* 2. Parse & validate the partial config (project section required)
|
|
12
|
+
* 3. Merge with project-type defaults
|
|
13
|
+
* 4. Validate the final merged config against the full schema
|
|
14
|
+
*
|
|
15
|
+
* Throws if no config file is found or validation fails.
|
|
16
|
+
*/
|
|
17
|
+
export declare function loadConfig(projectRoot: string): Promise<BoberConfig>;
|
|
18
|
+
//# sourceMappingURL=loader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../src/config/loader.ts"],"names":[],"mappings":"AAIA,OAAO,EAGL,KAAK,WAAW,EACjB,MAAM,aAAa,CAAC;AA8ErB;;GAEG;AACH,wBAAsB,YAAY,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAGxE;AAqCD;;;;;;;;;;GAUG;AACH,wBAAsB,UAAU,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,CA+F1E"}
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
import { readFile, access } from "node:fs/promises";
|
|
2
|
+
import { join } from "node:path";
|
|
3
|
+
import { constants } from "node:fs";
|
|
4
|
+
import { BoberConfigSchema, PartialBoberConfigSchema, } from "./schema.js";
|
|
5
|
+
import { getDefaults } from "./defaults.js";
|
|
6
|
+
/**
|
|
7
|
+
* Migrate a v1 config (with `project.type`) to the v2 format (with `project.mode` / `project.preset`).
|
|
8
|
+
* Returns the input unchanged if it is not a v1 config.
|
|
9
|
+
*/
|
|
10
|
+
function migrateV1Config(raw) {
|
|
11
|
+
if (typeof raw !== "object" ||
|
|
12
|
+
raw === null ||
|
|
13
|
+
!("project" in raw)) {
|
|
14
|
+
return raw;
|
|
15
|
+
}
|
|
16
|
+
const obj = raw;
|
|
17
|
+
const project = obj.project;
|
|
18
|
+
if (!project || typeof project !== "object" || !("type" in project)) {
|
|
19
|
+
return raw;
|
|
20
|
+
}
|
|
21
|
+
const oldType = project.type;
|
|
22
|
+
// Already migrated or not a v1 type
|
|
23
|
+
if (typeof oldType !== "string") {
|
|
24
|
+
return raw;
|
|
25
|
+
}
|
|
26
|
+
const migrated = { ...obj, project: { ...project } };
|
|
27
|
+
const migratedProject = migrated.project;
|
|
28
|
+
delete migratedProject.type;
|
|
29
|
+
switch (oldType) {
|
|
30
|
+
case "react-fullstack":
|
|
31
|
+
migratedProject.mode = "greenfield";
|
|
32
|
+
migratedProject.preset = "react-vite";
|
|
33
|
+
break;
|
|
34
|
+
case "brownfield":
|
|
35
|
+
migratedProject.mode = "brownfield";
|
|
36
|
+
break;
|
|
37
|
+
case "generic":
|
|
38
|
+
migratedProject.mode = "greenfield";
|
|
39
|
+
break;
|
|
40
|
+
default:
|
|
41
|
+
// Unknown old type — treat as greenfield
|
|
42
|
+
migratedProject.mode = "greenfield";
|
|
43
|
+
break;
|
|
44
|
+
}
|
|
45
|
+
return migrated;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Config file candidate paths, searched in order.
|
|
49
|
+
*/
|
|
50
|
+
const CONFIG_CANDIDATES = [
|
|
51
|
+
"bober.config.json",
|
|
52
|
+
".bober/config.json",
|
|
53
|
+
];
|
|
54
|
+
/**
|
|
55
|
+
* Find the first existing config file path, or null.
|
|
56
|
+
*/
|
|
57
|
+
async function findConfigPath(projectRoot) {
|
|
58
|
+
for (const candidate of CONFIG_CANDIDATES) {
|
|
59
|
+
const fullPath = join(projectRoot, candidate);
|
|
60
|
+
try {
|
|
61
|
+
await access(fullPath, constants.R_OK);
|
|
62
|
+
return fullPath;
|
|
63
|
+
}
|
|
64
|
+
catch {
|
|
65
|
+
// not found, try next
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
return null;
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Check whether a bober config file exists in the given project root.
|
|
72
|
+
*/
|
|
73
|
+
export async function configExists(projectRoot) {
|
|
74
|
+
const found = await findConfigPath(projectRoot);
|
|
75
|
+
return found !== null;
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Deep merge two objects, preferring values from `override`.
|
|
79
|
+
* Arrays are replaced, not merged.
|
|
80
|
+
*/
|
|
81
|
+
function deepMerge(base, override) {
|
|
82
|
+
const result = { ...base };
|
|
83
|
+
for (const key of Object.keys(override)) {
|
|
84
|
+
const overrideVal = override[key];
|
|
85
|
+
const baseVal = result[key];
|
|
86
|
+
if (overrideVal !== undefined &&
|
|
87
|
+
overrideVal !== null &&
|
|
88
|
+
typeof overrideVal === "object" &&
|
|
89
|
+
!Array.isArray(overrideVal) &&
|
|
90
|
+
typeof baseVal === "object" &&
|
|
91
|
+
baseVal !== null &&
|
|
92
|
+
!Array.isArray(baseVal)) {
|
|
93
|
+
result[key] = deepMerge(baseVal, overrideVal);
|
|
94
|
+
}
|
|
95
|
+
else if (overrideVal !== undefined) {
|
|
96
|
+
result[key] = overrideVal;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
return result;
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Load and validate the bober configuration for a project.
|
|
103
|
+
*
|
|
104
|
+
* Resolution order:
|
|
105
|
+
* 1. Discover config file (`bober.config.json` or `.bober/config.json`)
|
|
106
|
+
* 2. Parse & validate the partial config (project section required)
|
|
107
|
+
* 3. Merge with project-type defaults
|
|
108
|
+
* 4. Validate the final merged config against the full schema
|
|
109
|
+
*
|
|
110
|
+
* Throws if no config file is found or validation fails.
|
|
111
|
+
*/
|
|
112
|
+
export async function loadConfig(projectRoot) {
|
|
113
|
+
const configPath = await findConfigPath(projectRoot);
|
|
114
|
+
if (!configPath) {
|
|
115
|
+
throw new Error(`No bober config found. Looked for ${CONFIG_CANDIDATES.map((c) => join(projectRoot, c)).join(", ")}`);
|
|
116
|
+
}
|
|
117
|
+
let rawContent;
|
|
118
|
+
try {
|
|
119
|
+
rawContent = await readFile(configPath, "utf-8");
|
|
120
|
+
}
|
|
121
|
+
catch (err) {
|
|
122
|
+
throw new Error(`Failed to read config file at ${configPath}: ${err instanceof Error ? err.message : String(err)}`, { cause: err });
|
|
123
|
+
}
|
|
124
|
+
let parsed;
|
|
125
|
+
try {
|
|
126
|
+
parsed = JSON.parse(rawContent);
|
|
127
|
+
}
|
|
128
|
+
catch (err) {
|
|
129
|
+
throw new Error(`Invalid JSON in config file ${configPath}: ${err instanceof Error ? err.message : String(err)}`, { cause: err });
|
|
130
|
+
}
|
|
131
|
+
// Apply v1 migration before validation
|
|
132
|
+
const migrated = migrateV1Config(parsed);
|
|
133
|
+
// Validate partial config (project.mode is required, everything else optional)
|
|
134
|
+
const partialResult = PartialBoberConfigSchema.safeParse(migrated);
|
|
135
|
+
if (!partialResult.success) {
|
|
136
|
+
const issues = partialResult.error.issues
|
|
137
|
+
.map((i) => ` - ${i.path.join(".")}: ${i.message}`)
|
|
138
|
+
.join("\n");
|
|
139
|
+
throw new Error(`Invalid bober config at ${configPath}:\n${issues}`);
|
|
140
|
+
}
|
|
141
|
+
const partial = partialResult.data;
|
|
142
|
+
const defaults = getDefaults(partial.project.mode, partial.project.preset);
|
|
143
|
+
// Build a complete config by deep-merging defaults with user overrides
|
|
144
|
+
const merged = deepMerge({
|
|
145
|
+
project: {
|
|
146
|
+
name: partial.project.name ?? "unnamed",
|
|
147
|
+
mode: partial.project.mode,
|
|
148
|
+
preset: partial.project.preset,
|
|
149
|
+
stack: partial.project.stack,
|
|
150
|
+
description: partial.project.description,
|
|
151
|
+
},
|
|
152
|
+
planner: defaults.planner ?? {
|
|
153
|
+
maxClarifications: 5,
|
|
154
|
+
model: "opus",
|
|
155
|
+
},
|
|
156
|
+
generator: defaults.generator ?? {
|
|
157
|
+
model: "sonnet",
|
|
158
|
+
maxTurnsPerSprint: 50,
|
|
159
|
+
autoCommit: true,
|
|
160
|
+
branchPattern: "bober/{feature-name}",
|
|
161
|
+
},
|
|
162
|
+
evaluator: defaults.evaluator ?? {
|
|
163
|
+
model: "sonnet",
|
|
164
|
+
strategies: [],
|
|
165
|
+
maxIterations: 3,
|
|
166
|
+
},
|
|
167
|
+
sprint: defaults.sprint ?? {
|
|
168
|
+
maxSprints: 10,
|
|
169
|
+
requireContracts: true,
|
|
170
|
+
sprintSize: "medium",
|
|
171
|
+
},
|
|
172
|
+
pipeline: defaults.pipeline ?? {
|
|
173
|
+
maxIterations: 20,
|
|
174
|
+
requireApproval: false,
|
|
175
|
+
contextReset: "always",
|
|
176
|
+
},
|
|
177
|
+
commands: defaults.commands ?? {},
|
|
178
|
+
}, partial);
|
|
179
|
+
// Final full validation
|
|
180
|
+
const fullResult = BoberConfigSchema.safeParse(merged);
|
|
181
|
+
if (!fullResult.success) {
|
|
182
|
+
const issues = fullResult.error.issues
|
|
183
|
+
.map((i) => ` - ${i.path.join(".")}: ${i.message}`)
|
|
184
|
+
.join("\n");
|
|
185
|
+
throw new Error(`Config validation failed after merging defaults:\n${issues}`);
|
|
186
|
+
}
|
|
187
|
+
return fullResult.data;
|
|
188
|
+
}
|
|
189
|
+
//# sourceMappingURL=loader.js.map
|
|
@@ -0,0 +1 @@
|
|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