@babylonjs-toolkit/agent 1.1.11 → 1.1.14
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/README.md +42 -18
- package/package.json +1 -1
- package/skills/bt-gauntlet/SKILL.md +173 -220
- package/skills/bt-gauntlet/references/blender-model-pipeline.md +194 -0
- package/skills/bt-gauntlet/references/critic-rubrics.md +179 -0
- package/skills/bt-gauntlet/references/loop-templates.md +131 -0
- package/skills/bt-gauntlet/references/spec-composition.md +87 -0
- package/skills/bt-gauntlet/references/target-images.md +121 -0
- package/skills/bt-gauntlet/references/unity-level-pipeline.md +285 -0
- package/skills/bt-gauntlet/references/workspace.md +133 -0
- package/skills/bt-plan/SKILL.md +173 -169
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
# Pipeline: `blender-model`
|
|
2
|
+
|
|
3
|
+
**Deliverable:** a high-fidelity model or asset authored/refined in headless Blender — geometry, UVs, PBR
|
|
4
|
+
maps, LODs, skinning, animation — delivered either as a `.glb` straight to BabylonJS, or as an FBX inside a
|
|
5
|
+
Unity project for a `unity-level` job to compose with.
|
|
6
|
+
|
|
7
|
+
> **Required reading before round 1.** Fetch and read the Agent Reference's
|
|
8
|
+
> [Blender Headless CLI Instructions](https://raw.githubusercontent.com/babylontoolkit/agent/main/references/unity-blender-cli.md)
|
|
9
|
+
> in full. Section numbers below refer to it. Builder subagents must be given it too.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## 1. Decide the destination first — it changes everything downstream
|
|
14
|
+
|
|
15
|
+
| The asset needs… | Route |
|
|
16
|
+
|---|---|
|
|
17
|
+
| Interactive components (Rigidbody, Animator, AudioSource, NavMeshAgent, LODGroup …) | **Blender fixes the model → Unity composes → Toolkit exports.** Blender **cannot** write `extras.metadata.components`; those come from Unity, and only under a Pro licence. |
|
|
18
|
+
| Geometry / materials / animation only — a prop, a clip, a static mesh | **Export `.glb` straight from Blender and skip Unity entirely.** |
|
|
19
|
+
|
|
20
|
+
Record the route in `pipeline.md`. It decides where the artifact lives, how it is verified, and whether the
|
|
21
|
+
`unity-level` pipeline's licence gate applies.
|
|
22
|
+
|
|
23
|
+
## 2. Prerequisite gate — before round 1, and again on every resume
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
blender --version
|
|
27
|
+
blender -b --factory-startup --python-exit-code 1 \
|
|
28
|
+
--python-expr "import bpy; print('bpy', bpy.app.version_string)"
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
| Must be true | Why |
|
|
32
|
+
|---|---|
|
|
33
|
+
| Blender resolves on PATH (or the `bpy` pip module is importable) | no builder can run |
|
|
34
|
+
| The canonical four flags are used on **every** invocation | see below |
|
|
35
|
+
| The importers/exporters you need exist **in this build** | operator names moved in 5.x — enumerate, never assume (§3) |
|
|
36
|
+
| For the Unity route: the `unity-level` prerequisite gate also passes | components and the export come from Unity |
|
|
37
|
+
|
|
38
|
+
**The canonical invocation — use all four flags every time:**
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
blender --background --factory-startup --python-exit-code 1 \
|
|
42
|
+
--python /path/to/script.py -- arg1 arg2
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
> ⚠️ **A Python exception does not fail the process.** Blender prints the traceback and exits `0`. Without
|
|
46
|
+
> `--python-exit-code 1` the loop will record a crashed round as a success and the critic will be handed
|
|
47
|
+
> stale evidence. This is the single most dangerous gotcha in this pipeline.
|
|
48
|
+
|
|
49
|
+
Introspect before relying on any operator (§7):
|
|
50
|
+
|
|
51
|
+
```python
|
|
52
|
+
print(sorted(n for n in dir(bpy.ops.export_scene) if not n.startswith('_')))
|
|
53
|
+
print(bpy.ops.export_scene.gltf.__doc__)
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### `pipeline.md` for this kind
|
|
57
|
+
|
|
58
|
+
```markdown
|
|
59
|
+
# Pipeline — blender-model
|
|
60
|
+
Route : glb-direct | via-unity
|
|
61
|
+
Blender : 5.1.2 (path: /Applications/Blender.app/Contents/MacOS/Blender)
|
|
62
|
+
Source asset : /abs/path/UnityProject/Assets/Models/character.fbx
|
|
63
|
+
Write mode : IN PLACE (GUID preserved) | NEW PATH (GUID reset — settings copied)
|
|
64
|
+
Backup : character.fbx.bak
|
|
65
|
+
Viewer page : http://localhost:8888/viewer.html?asset=character.glb
|
|
66
|
+
Viewer lighting: FIXED — hdri studio.hdr, exposure 1.0, no post (never change mid-run)
|
|
67
|
+
Tri budget : 45k · Texel density: 512 px/m
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
---
|
|
71
|
+
|
|
72
|
+
## 3. In place vs. new file — the rule that protects the whole project
|
|
73
|
+
|
|
74
|
+
| | **Edit in place** (overwrite the FBX) | **Create a new model** (new path) |
|
|
75
|
+
|---|---|---|
|
|
76
|
+
| Unity GUID | ✅ preserved | ❌ new GUID |
|
|
77
|
+
| Existing scene / prefab references | ✅ all survive and pick up the change | ➖ referenced by nothing |
|
|
78
|
+
| Importer settings — rig, avatar, clips, scale | ✅ preserved (`.meta` untouched) | ❌ **reset to defaults** |
|
|
79
|
+
| Use for | iterating on an asset already in scenes | variants, LODs, experiments |
|
|
80
|
+
|
|
81
|
+
**A gauntlet iterates on the same asset for many rounds. That makes in-place the default, and it makes this
|
|
82
|
+
a hard loop rule:**
|
|
83
|
+
|
|
84
|
+
- **Always back up first** — the write is destructive: `cp "$FBX" "$FBX.bak"`.
|
|
85
|
+
- **Never delete-then-recreate.** Removing the file removes its `.meta`, which destroys the GUID and breaks
|
|
86
|
+
every scene and prefab that referenced it. Overwrite the bytes; leave the `.meta` alone.
|
|
87
|
+
- When a round genuinely needs a new path (an LOD, a variant), **copy the importer settings across** — Unity
|
|
88
|
+
will not (§8.3) — and record it in the round journal.
|
|
89
|
+
|
|
90
|
+
After any write, refresh Unity and confirm the GUID survived:
|
|
91
|
+
|
|
92
|
+
```bash
|
|
93
|
+
unity command eval 'UnityEditor.AssetDatabase.Refresh(UnityEditor.ImportAssetOptions.ForceSynchronousImport); return "ok";' --project-path "$PROJ"
|
|
94
|
+
|
|
95
|
+
unity command eval 'string p="Assets/Models/character.fbx";
|
|
96
|
+
var i=(UnityEditor.ModelImporter)UnityEditor.AssetImporter.GetAtPath(p);
|
|
97
|
+
return UnityEditor.AssetDatabase.AssetPathToGUID(p) + " rig=" + i.animationType + " scale=" + i.globalScale;' \
|
|
98
|
+
--project-path "$PROJ"
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
---
|
|
102
|
+
|
|
103
|
+
## 4. Part taxonomy — the default decomposition
|
|
104
|
+
|
|
105
|
+
| Part | Owns |
|
|
106
|
+
|---|---|
|
|
107
|
+
| **P1 Silhouette & proportion** | primary forms, scale against reference, readability at thumbnail size |
|
|
108
|
+
| **P2 Secondary forms** | panel breaks, bevels, structural detail, booleans and remesh cleanup |
|
|
109
|
+
| **P3 UVs & texel density** | unwrap, seam placement, uniform px/m, no stretching, atlas packing |
|
|
110
|
+
| **P4 PBR materials** | albedo, roughness, metallic, normal, AO — generated or baked, never flat placeholders |
|
|
111
|
+
| **P5 Baked maps** | high-to-low normal and AO bakes, curvature, cavity |
|
|
112
|
+
| **P6 Detail pass** | wear, edge damage, grime in crevices, decals, micro-normal |
|
|
113
|
+
| **P7 Topology & LODs** | tri budget, decimate chain, normals recalculated, no n-gons where they matter |
|
|
114
|
+
| **P8 Rig & skinning** *(if animated)* | weights ≤ 4 influences/vertex, normalised to 1.0, bone names matching the Unity Avatar rig |
|
|
115
|
+
| **P9 Integration** | scale, orientation, pivot, naming, `add_leaf_bones=False` on FBX export, collision proxies |
|
|
116
|
+
|
|
117
|
+
**Textures are generated, not procedural.** Where an image-generation tool is configured (the toolkit's
|
|
118
|
+
`kie-image` MCP — `generate_image`), use it for albedo, normals, roughness masks and detail maps. Do not
|
|
119
|
+
substitute procedural noise or flat colours for missing maps; that is the fastest route to a plastic-looking
|
|
120
|
+
asset and the critic will name it every round.
|
|
121
|
+
|
|
122
|
+
---
|
|
123
|
+
|
|
124
|
+
## 5. Verify recipe — the round's step 4
|
|
125
|
+
|
|
126
|
+
### 5.1 The engine is the truth, not the Cycles render
|
|
127
|
+
|
|
128
|
+
**Primary evidence: the asset loaded in BabylonJS, in a browser, under the fixed viewer lighting rig.** A
|
|
129
|
+
Cycles/EEVEE render flatters a model in ways the real-time engine will not — it is a diagnostic, not the
|
|
130
|
+
verdict.
|
|
131
|
+
|
|
132
|
+
- **Via Unity route:** re-export the level and load it off the toolkit dev server
|
|
133
|
+
(`unity-exporter-cli.md` §12) — that is how you verify the round trip actually survived.
|
|
134
|
+
- **glb-direct route:** serve the `.glb` into a minimal BabylonJS viewer page and screenshot that.
|
|
135
|
+
|
|
136
|
+
```bash
|
|
137
|
+
curl -sS -o /dev/null -w "%{http_code}\n" "http://localhost:8888/scenes/level01.gltf"
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
### 5.2 Lock the viewer, not just the camera
|
|
141
|
+
|
|
142
|
+
Two variables must be frozen or every round changes more than the model:
|
|
143
|
+
|
|
144
|
+
1. **The camera set** — fixed orbit angles recorded in `cameras.md`: a hero 3/4, a front elevation, and at
|
|
145
|
+
least one detail crop. Same distance, same fov, same resolution, every round.
|
|
146
|
+
2. **The lighting rig** — one HDRI, one exposure, no post. Written into `pipeline.md` and never changed
|
|
147
|
+
mid-run. A model that "got better" under a different HDRI did not get better.
|
|
148
|
+
|
|
149
|
+
### 5.3 The Blender-vs-engine gap
|
|
150
|
+
|
|
151
|
+
Render the same locked angles from Blender as a **secondary** frame. When the Blender render looks right and
|
|
152
|
+
the engine frame looks wrong, the round's problem is the export or the material translation — not the
|
|
153
|
+
sculpt. Make the critic say which side the gap is on, exactly as the `unity-level` pipeline does for the
|
|
154
|
+
Unity-vs-export boundary.
|
|
155
|
+
|
|
156
|
+
### 5.4 Metrics
|
|
157
|
+
|
|
158
|
+
Collect into `evidence/round-NN-<part>-metrics.json`: triangle count, material and texture count, texture
|
|
159
|
+
memory, texel density, influence count per vertex (max), whether weights normalise to 1.0, load time, and
|
|
160
|
+
browser console errors.
|
|
161
|
+
|
|
162
|
+
---
|
|
163
|
+
|
|
164
|
+
## 6. Extra critic inputs and gates for this pipeline
|
|
165
|
+
|
|
166
|
+
Scored on the **model / asset rubric** in `critic-rubrics.md` (Silhouette & Proportion, Surface & Material,
|
|
167
|
+
Detail Density, Topology & Efficiency, Integration Readiness).
|
|
168
|
+
|
|
169
|
+
**Hard gates:**
|
|
170
|
+
|
|
171
|
+
| Gate | Fails when |
|
|
172
|
+
|---|---|
|
|
173
|
+
| **Tri / texture budget** | the loop card's budget is exceeded |
|
|
174
|
+
| **Engine-legal skinning** | any vertex has > 4 influences, or weights do not normalise to 1.0 |
|
|
175
|
+
| **Rig names** | bone names no longer match the Unity Avatar/Animator rig |
|
|
176
|
+
| **Transform hygiene** | scale, orientation or pivot is wrong at import — the most common silent defect on generated and converted assets |
|
|
177
|
+
| **GUID survival** | an in-place round changed the GUID, or importer settings were reset |
|
|
178
|
+
| **Console** | the `.glb` produces errors on load |
|
|
179
|
+
| **No placeholder maps** | a material ships with flat-colour or procedural-noise stand-ins for maps the target needs |
|
|
180
|
+
|
|
181
|
+
---
|
|
182
|
+
|
|
183
|
+
## 7. Known failure modes
|
|
184
|
+
|
|
185
|
+
| Symptom | Cause | Fix |
|
|
186
|
+
|---|---|---|
|
|
187
|
+
| A crashed round recorded as success | missing `--python-exit-code 1` | always pass all four canonical flags |
|
|
188
|
+
| `bpy.ops.import_scene.fbx` not found | operator names moved in 5.x (`bpy.ops.wm.fbx_import` is native now) | enumerate the operators in *this* build (§3) |
|
|
189
|
+
| Every scene reference to the model broke | wrote to a new path, or delete-then-recreate | edit in place; never remove the `.meta` |
|
|
190
|
+
| Importer settings silently reset | new file path | copy them across explicitly (§8.3) |
|
|
191
|
+
| Model imports at 1/100 scale or lying on its side | FBX unit mismatch, or a generated asset's arbitrary orientation | `transform_apply` after fixing scale/rotation; check on every generated asset |
|
|
192
|
+
| Model looks great in Blender, dead in the engine | material translation or missing maps | §5.3 — isolate the side before re-sculpting |
|
|
193
|
+
| Components missing from the exported asset | Blender cannot write them, or community licence | components come from Unity under Pro only (§8.5) |
|
|
194
|
+
| `blender -b in.fbx` does nothing | not a valid invocation | import inside the script instead (§5) |
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
# Critic Contract, Rubrics and the Stall Ladder
|
|
2
|
+
|
|
3
|
+
The critic is the only thing standing between a gauntlet and a builder that grades its own homework.
|
|
4
|
+
This document defines exactly what a critic receives, what it must return, and how the loop reacts.
|
|
5
|
+
`SKILL.md` § *The Round Protocol* step 5 is the entry point; everything below is the detail.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## 1. What a critic receives — and what it must never see
|
|
10
|
+
|
|
11
|
+
A critic is a **fresh-context subagent**. It gets a fixed input set:
|
|
12
|
+
|
|
13
|
+
| Input | Why |
|
|
14
|
+
|---|---|
|
|
15
|
+
| `loop-card.md` | the objective, the bar, the success condition |
|
|
16
|
+
| The part's entry from `progress.md` | what this round was trying to fix |
|
|
17
|
+
| `reference/` — the target image(s) for this part's camera | the bar, as pixels |
|
|
18
|
+
| `evidence/round-NN-<part>-<camera>.png` | our current result, from the **locked camera** |
|
|
19
|
+
| `evidence/round-NN-<part>-metrics.json` | FPS, draw calls, console errors, load time, export metadata |
|
|
20
|
+
| The **previous round's** screenshot and verdict for this part, when one exists | so scores are comparable and regressions are visible |
|
|
21
|
+
| `components.md` when it exists | component-authority enforcement |
|
|
22
|
+
| `cameras.md` | to confirm the evidence was shot from the locked transform |
|
|
23
|
+
| The pipeline's extra criteria (see the pipeline reference for the deliverable kind) | export boundary, GUID survival, etc. |
|
|
24
|
+
|
|
25
|
+
**It must never see:** the builder's rationale, its chain of decisions, its summary of what it did, its
|
|
26
|
+
own claim of success, or the round journal's narrative. The critic grades pixels, numbers and behaviour —
|
|
27
|
+
never effort or intent.
|
|
28
|
+
|
|
29
|
+
> If the host has no subagent tool, the critique step still runs, but under the same discipline: look only
|
|
30
|
+
> at the inputs above. Say `no subagent tool available` plainly in the round journal.
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## 2. What a critic must return
|
|
35
|
+
|
|
36
|
+
### 2.1 A scored rubric — the same axes every round
|
|
37
|
+
|
|
38
|
+
Fractional scores allowed. The axes depend on the deliverable kind; the pipeline reference names which
|
|
39
|
+
table applies.
|
|
40
|
+
|
|
41
|
+
**Scene / level / in-game visual rubric** (`web-game`, `unity-level`) — **10 points**:
|
|
42
|
+
|
|
43
|
+
| Axis | Points | What it covers |
|
|
44
|
+
|---|---|---|
|
|
45
|
+
| **Composition** | 0–2 | Camera, framing, layout. Position and scale of every major element vs. the target. Silhouette of the scene as a whole. |
|
|
46
|
+
| **Lighting & Atmosphere** | 0–3 | Colour palette, exposure, contrast, shadow shape and softness, bounce/GI, ambient, fog and depth cueing, reflections, glow. Is the scene too dark or too bright vs. the target? |
|
|
47
|
+
| **Materials & Surfacing** | 0–2 | Every surface: albedo, roughness, metallic, normal detail, translucency, wetness. Nothing blocky, plasticky or fake unless the target is too. |
|
|
48
|
+
| **Detail & Density** | 0–2 | Set dressing, clutter, wear, edge damage, decals, scatter, small-scale variation. Does the frame hold up under a fine-toothed comb? |
|
|
49
|
+
| **Motion & Life** | 0–1 | Animation, wind, particles, flicker, ambient movement. Score `n/a` and redistribute to Detail when the part is genuinely static. |
|
|
50
|
+
|
|
51
|
+
**Model / asset rubric** (`blender-model`) — **10 points**:
|
|
52
|
+
|
|
53
|
+
| Axis | Points | What it covers |
|
|
54
|
+
|---|---|---|
|
|
55
|
+
| **Silhouette & Proportion** | 0–2 | Read at thumbnail size; proportions against the target and against real-world reference. |
|
|
56
|
+
| **Surface & Material** | 0–3 | PBR maps, roughness variation, normal/AO detail, texel density, seams, no stretched UVs. |
|
|
57
|
+
| **Detail Density** | 0–2 | Panel lines, wear, bevels, small forms. Detail where the eye goes, not uniformly smeared. |
|
|
58
|
+
| **Topology & Efficiency** | 0–2 | Triangle budget, sensible edge flow, LOD chain, no n-gons where they matter, clean normals. |
|
|
59
|
+
| **Integration Readiness** | 0–1 | Scale, orientation, pivot, naming, ≤ 4 influences/vertex and weights normalised for skinned meshes. |
|
|
60
|
+
|
|
61
|
+
### 2.2 A full, prioritized gap list — not one gap
|
|
62
|
+
|
|
63
|
+
**This is the single most important change from earlier versions of this skill.** The critic returns
|
|
64
|
+
**every** gap it can find, ordered most-impactful first, each one actionable:
|
|
65
|
+
|
|
66
|
+
```
|
|
67
|
+
GAP 01 [Lighting] Key light is ~40° too high and far too neutral. Target has a low
|
|
68
|
+
warm sun (~12° elevation, ~3200K) throwing long shadows across the
|
|
69
|
+
courtyard from camera-left. Fix: rotate the directional light to
|
|
70
|
+
(12, -145, 0), set colour to #FFB870, intensity ~2.4, re-bake.
|
|
71
|
+
GAP 02 [Materials] Cobblestones read as flat plastic — no normal map bound and roughness
|
|
72
|
+
is uniform 0.5. Fix: bake or generate a normal + roughness pair,
|
|
73
|
+
roughness range 0.35–0.8 with dirt in the crevices.
|
|
74
|
+
GAP 03 [Detail] Target has standing water and wet edges along the gutters; ours is
|
|
75
|
+
bone dry. Fix: add a wetness mask ...
|
|
76
|
+
...
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
Rules the critic must follow:
|
|
80
|
+
|
|
81
|
+
- **Be nitpicky and precise.** A gigantic list is correct when the product is nowhere near the target.
|
|
82
|
+
- **Never write non-actionable feedback.** "This tree looks fake" is banned. Name *what* creates the
|
|
83
|
+
impression and *how* to fix it: "the trunk has no bark normal map and the canopy is a single opaque
|
|
84
|
+
card — swap to layered alpha-tested branch planes with a translucency map."
|
|
85
|
+
- **Say when something needs to be thrown away.** If the model, layout or lighting rig needs a full
|
|
86
|
+
redesign, say so. Do not sugarcoat and do not settle.
|
|
87
|
+
- **Stay inside the reachable set.** The loop card's `OUT OF REACH` list names things the pipeline
|
|
88
|
+
physically cannot deliver (§ target-image reachability in `SKILL.md`). Do not raise gaps against those.
|
|
89
|
+
|
|
90
|
+
The **top gap** — `GAP 01` — is what gets recorded in `progress.md` as the named gap for the round, and is
|
|
91
|
+
what the stall ladder watches. The rest of the list stays in the round journal and is the builder's queue.
|
|
92
|
+
|
|
93
|
+
### 2.3 Hard gates — pass/fail, never scored
|
|
94
|
+
|
|
95
|
+
Scores can be gamed; gates cannot. **A part PASSES only when the rubric score meets the loop card's
|
|
96
|
+
threshold AND every gate passes.**
|
|
97
|
+
|
|
98
|
+
| Gate | Fails when |
|
|
99
|
+
|---|---|
|
|
100
|
+
| **Perf** | the loop card's FPS / draw-call / load-time / memory budget is missed |
|
|
101
|
+
| **Console** | any error in the browser console (warnings are reported, not fatal, unless the card says otherwise) |
|
|
102
|
+
| **Component authority** | a protected `TOOLKIT.*` component was reimplemented, bypassed or deleted without the full replacement-evidence checklist in the round journal |
|
|
103
|
+
| **Camera lock** | the evidence was not captured from the transform recorded in `cameras.md` |
|
|
104
|
+
| **Pipeline gate** | whatever the deliverable kind's pipeline reference declares (export-boundary integrity, GUID survival, licence tier …) |
|
|
105
|
+
|
|
106
|
+
### 2.4 The verdict line
|
|
107
|
+
|
|
108
|
+
```
|
|
109
|
+
PART: P3 Level lighting & atmosphere
|
|
110
|
+
SCORE: 6.5 / 10 (Comp 1.5 · Light 1.5 · Mat 1.5 · Detail 1.5 · Motion 0.5)
|
|
111
|
+
PREVIOUS: 5.0 / 10 (round 09)
|
|
112
|
+
GATES: perf PASS · console PASS · authority PASS · camera PASS · export PASS
|
|
113
|
+
VERDICT: FAIL
|
|
114
|
+
TOP GAP: GAP 01 — key light elevation and colour temperature
|
|
115
|
+
REGRESSION: none
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## 3. Continuity between rounds
|
|
121
|
+
|
|
122
|
+
The critic is fresh-context, but it is **not** memoryless about the score. It always receives the previous
|
|
123
|
+
round's screenshot and verdict for that part, with this instruction:
|
|
124
|
+
|
|
125
|
+
> Maintain consistency with the prior judgment — the same axes, the same standards, so the two scores are
|
|
126
|
+
> comparable. Do not feel obliged to match or increase the score. **If the product regressed, score it
|
|
127
|
+
> worse and say what regressed.**
|
|
128
|
+
|
|
129
|
+
Without this, round-over-round scores are not on the same scale, and the no-improvement counter in
|
|
130
|
+
`progress.md` measures nothing.
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
134
|
+
## 4. The stall ladder
|
|
135
|
+
|
|
136
|
+
Repetition without a changed strategy is a boundary event, not persistence. Two tiers, both with concrete
|
|
137
|
+
triggers, both checked in the round protocol's gate check.
|
|
138
|
+
|
|
139
|
+
### Tier 1 — STALL APPROACHING
|
|
140
|
+
|
|
141
|
+
Fires when **either** is true for a part:
|
|
142
|
+
|
|
143
|
+
- the best score for that part has not improved by **≥ 1.0 point in 2 rounds**, or
|
|
144
|
+
- the critic has named the **same top gap twice in a row**.
|
|
145
|
+
|
|
146
|
+
Response — **incremental tweaks are forbidden for the next round on that part.** Step back and look for the
|
|
147
|
+
architectural cause: the assets are simply not good enough; the lighting rig is wrong in kind, not degree;
|
|
148
|
+
the camera is in the wrong place; the layout does not match the target's structure; the material system
|
|
149
|
+
cannot express what the target shows. Make **one dramatic change** and record it in the round journal as:
|
|
150
|
+
|
|
151
|
+
```
|
|
152
|
+
STRATEGY: <what is being thrown away and what replaces it>
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
### Tier 2 — STALLED
|
|
156
|
+
|
|
157
|
+
Fires when the Tier 1 architectural swing scored **the same or worse**.
|
|
158
|
+
|
|
159
|
+
Response — **stop. Do not spend another round guessing at a different dramatic change.** Park the job,
|
|
160
|
+
write the status, and escalate to the user with:
|
|
161
|
+
|
|
162
|
+
- the target image and the two most recent evidence screenshots side by side,
|
|
163
|
+
- the standing gap list,
|
|
164
|
+
- what the architectural swing changed and what it scored,
|
|
165
|
+
- a specific question: is the current state good enough, or is something fundamental wrong with the target?
|
|
166
|
+
|
|
167
|
+
Record both tiers in `progress.md` under `Budgets:` as `stall: none | approaching | stalled`.
|
|
168
|
+
|
|
169
|
+
---
|
|
170
|
+
|
|
171
|
+
## 5. The integration critic
|
|
172
|
+
|
|
173
|
+
Run once, when the success condition is met, before reporting DONE. Fresh context, sees the whole artifact
|
|
174
|
+
end to end rather than one part. Local quality can rise while the whole becomes inconsistent — this is the
|
|
175
|
+
pass that catches it.
|
|
176
|
+
|
|
177
|
+
It checks: consistency of lighting and material language across parts, seams and transitions, whether the
|
|
178
|
+
sum still answers the loop card's OBJECTIVE, and every hard gate measured on the complete artifact rather
|
|
179
|
+
than per part. It returns the same rubric + gap list shape. A FAIL here reopens the parts it names.
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
# Loop Card Templates
|
|
2
|
+
|
|
3
|
+
The interview fills the `<SLOTS>` — including `<NAME>` and `<DELIVERABLE KIND>` — and the filled copy
|
|
4
|
+
becomes `_gauntlet/<name>/loop-card.md`. Kept verbatim here so they are easy to modify. A job never mixes
|
|
5
|
+
templates.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Template A — Universal Gauntlet Loop (`--template:gauntlet`, default)
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
I want you to create <DELIVERABLE> that achieves <OBJECTIVE> at the quality
|
|
13
|
+
level of <CONCRETE REFERENCE OR MEASURABLE BENCHMARK>.
|
|
14
|
+
|
|
15
|
+
DELIVERABLE KIND: <web-game | unity-level | blender-model>
|
|
16
|
+
Follow the matching pipeline reference for how to build and how to verify.
|
|
17
|
+
|
|
18
|
+
Build it with BabylonJS and the Babylon Toolkit (NOT Three.js), following the
|
|
19
|
+
Babylon Toolkit Agent Reference conventions already loaded in this session.
|
|
20
|
+
|
|
21
|
+
This gauntlet job is named <NAME>; all of its loop state lives in
|
|
22
|
+
_gauntlet/<NAME>/ and never anywhere else.
|
|
23
|
+
|
|
24
|
+
THE BAR IS AN IMAGE. The target lives at _gauntlet/<NAME>/reference/ and is
|
|
25
|
+
LOCKED — one target per locked camera in _gauntlet/<NAME>/cameras.md. Every
|
|
26
|
+
round captures evidence from those exact camera transforms and no others, so
|
|
27
|
+
the comparison is like for like.
|
|
28
|
+
|
|
29
|
+
OUT OF REACH (do not raise gaps against these):
|
|
30
|
+
<the elements of the target the pipeline physically cannot deliver>
|
|
31
|
+
|
|
32
|
+
Choose the approach. Break the work into the smallest important parts that can
|
|
33
|
+
be improved and judged independently, and record that decomposition as the part
|
|
34
|
+
checklist in _gauntlet/<NAME>/progress.md. Fan out builder subagents only where
|
|
35
|
+
the work is genuinely independent; keep tightly coupled systems under one owner.
|
|
36
|
+
Give every important part a separate, harsh critic with fresh context.
|
|
37
|
+
|
|
38
|
+
If the supplied assets include GLTF/GLB files carrying Babylon Toolkit component
|
|
39
|
+
metadata (extras.metadata.components), write the component inventory to
|
|
40
|
+
_gauntlet/<NAME>/components.md in round 1 and honor it every round: TOOLKIT.*
|
|
41
|
+
components are first-class — compose and tune them through PROJECT.* scripts,
|
|
42
|
+
never reimplement, bypass, or delete them (see the Agent Reference's
|
|
43
|
+
"Babylon Toolkit Component Authority" section). Critics fail violations.
|
|
44
|
+
|
|
45
|
+
Each critic must inspect the REAL artifact — evidence captured into
|
|
46
|
+
_gauntlet/<NAME>/evidence/ — never the builder's summary, and compare it
|
|
47
|
+
directly with the target in _gauntlet/<NAME>/reference/. It scores the rubric,
|
|
48
|
+
returns the FULL prioritized gap list (not one gap), and applies every hard
|
|
49
|
+
gate. It receives the previous round's screenshot and verdict so scores stay
|
|
50
|
+
comparable and regressions are caught.
|
|
51
|
+
|
|
52
|
+
Apply the stall ladder. If the best score has not improved by a full point in
|
|
53
|
+
two rounds, or the same top gap is named twice in a row, incremental tweaks are
|
|
54
|
+
FORBIDDEN — make one dramatic architectural change and record it as a STRATEGY
|
|
55
|
+
line. If that swing scores the same or worse, stop and escalate to me.
|
|
56
|
+
|
|
57
|
+
After EVERY round, update _gauntlet/<NAME>/progress.md and append
|
|
58
|
+
_gauntlet/<NAME>/rounds/round-NN.md before starting the next round, so a
|
|
59
|
+
brand-new session can resume this loop with `/bt-gauntlet --resume <NAME>`
|
|
60
|
+
at any time.
|
|
61
|
+
|
|
62
|
+
Keep looping until the output meets <SUCCESS CONDITION>, improvements no longer
|
|
63
|
+
justify another round, or one of these boundaries fires: <TIME / COST / ATTEMPT /
|
|
64
|
+
PERMISSION / SAFETY BOUNDARIES>. Escalate blockers that require human judgment.
|
|
65
|
+
|
|
66
|
+
Finish with one fresh integration critic that checks the complete artifact for
|
|
67
|
+
consistency, correctness, and fit with the original objective.
|
|
68
|
+
|
|
69
|
+
Do not deploy, spend money, use credentials, contact people, or make
|
|
70
|
+
irreversible changes without explicit approval.
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
---
|
|
74
|
+
|
|
75
|
+
## Template B — Bounded AI Loop Card (`--template:bounded`)
|
|
76
|
+
|
|
77
|
+
Use when reliability and cost matter more than dramatic language. Same slots.
|
|
78
|
+
|
|
79
|
+
```
|
|
80
|
+
OBJECTIVE
|
|
81
|
+
<OBJECTIVE — the exact outcome that should become true for <DELIVERABLE>>
|
|
82
|
+
|
|
83
|
+
DELIVERABLE KIND
|
|
84
|
+
<web-game | unity-level | blender-model> — build and verify per the matching
|
|
85
|
+
pipeline reference.
|
|
86
|
+
|
|
87
|
+
ENGINE
|
|
88
|
+
BabylonJS + Babylon Toolkit (NOT Three.js), per the Babylon Toolkit Agent
|
|
89
|
+
Reference conventions already loaded in this session.
|
|
90
|
+
|
|
91
|
+
INPUTS AND STATE
|
|
92
|
+
This gauntlet job is named <NAME>; all of its loop state lives in
|
|
93
|
+
_gauntlet/<NAME>/ and never anywhere else.
|
|
94
|
+
Use: _gauntlet/<NAME>/loop-card.md, brief.md, cameras.md, pipeline.md,
|
|
95
|
+
progress.md, reference/, and the project sources. Record after every round in
|
|
96
|
+
progress.md and rounds/: what changed, evidence, score, the full gap list,
|
|
97
|
+
failed approach, next action, and remaining budget — so
|
|
98
|
+
`/bt-gauntlet --resume <NAME>` can continue from a brand-new session.
|
|
99
|
+
|
|
100
|
+
METRIC / VERIFIER
|
|
101
|
+
Success requires all of the following:
|
|
102
|
+
- Rubric score >= <PASS THRESHOLD>/10 from a fresh critic, scored on the axes in
|
|
103
|
+
references/critic-rubrics.md, against the LOCKED target in reference/ captured
|
|
104
|
+
from the LOCKED cameras in cameras.md
|
|
105
|
+
- <CONCRETE REFERENCE OR MEASURABLE BENCHMARK — objective test or benchmark>
|
|
106
|
+
- Every hard gate passes: perf budget, console clean, camera lock, component
|
|
107
|
+
authority, and the pipeline gate for this deliverable kind
|
|
108
|
+
- Final fresh integration review of the complete artifact
|
|
109
|
+
|
|
110
|
+
OUT OF REACH
|
|
111
|
+
<elements of the target the pipeline cannot deliver — never raise gaps on these>
|
|
112
|
+
|
|
113
|
+
PROCESS
|
|
114
|
+
1. Inspect the current state (progress.md + pipeline.md + the actual project).
|
|
115
|
+
2. Choose the highest-impact unmet criterion, from the standing gap list.
|
|
116
|
+
3. Make one coherent improvement.
|
|
117
|
+
4. Run the real verifier (build/bake/export, capture from the locked camera,
|
|
118
|
+
collect metrics).
|
|
119
|
+
5. If it fails, feed the FULL gap list into the next round. Apply the stall
|
|
120
|
+
ladder: two rounds without a full point of improvement, or the same top gap
|
|
121
|
+
twice, forbids incremental tweaks and forces one architectural change; if
|
|
122
|
+
that fails too, stop and escalate.
|
|
123
|
+
6. If it passes, run a fresh independent final review.
|
|
124
|
+
|
|
125
|
+
BOUNDARIES
|
|
126
|
+
Allowed actions: read, draft, edit, build, bake, test, render, screenshot.
|
|
127
|
+
Forbidden without approval: deploy, delete, purchase, publish, message, secrets.
|
|
128
|
+
Stop, park state, and report when: <SUCCESS CONDITION> passes; <TIME / COST /
|
|
129
|
+
ATTEMPT / PERMISSION / SAFETY BOUNDARIES> is reached; the same blocker repeats;
|
|
130
|
+
the stall ladder reaches STALLED; or uncertainty requires human judgment.
|
|
131
|
+
```
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# Composition with the Spec Workflow, and Cross-Host Notes
|
|
2
|
+
|
|
3
|
+
## Composition with bt-spec / bt-plan / bt-execute
|
|
4
|
+
|
|
5
|
+
**The gauntlet contains its own plan — never run bt-plan on gauntlet work.** The mapping to the sibling
|
|
6
|
+
skills:
|
|
7
|
+
|
|
8
|
+
| Spec workflow | Gauntlet equivalent |
|
|
9
|
+
| --- | --- |
|
|
10
|
+
| `_specs/<feature>_spec.md` (bt-spec) | `_gauntlet/<name>/loop-card.md` — objective, benchmark, rubric, success condition, boundaries |
|
|
11
|
+
| `_specs/<feature>_plan.md` (bt-plan) | the part checklist in `_gauntlet/<name>/progress.md` — the lead agent's round-1 decomposition |
|
|
12
|
+
| bt-execute `ALL` (checkbox resume) | the round protocol + `--resume <name>` |
|
|
13
|
+
|
|
14
|
+
The difference is when a box may flip. A **bt-plan task** is feed-forward: known work, visited once, `- [x]`
|
|
15
|
+
when its acceptance verifies. A **gauntlet part** is feedback: `- [x]` only when a fresh critic scores it at
|
|
16
|
+
or above the pass threshold with every gate green, however many rounds that takes.
|
|
17
|
+
|
|
18
|
+
**Rule of thumb:** acceptance criteria you can enumerate up front, each satisfiable in one pass →
|
|
19
|
+
**bt-spec → bt-plan → bt-execute**. "As good as *that*" against a reference, unknown iteration count →
|
|
20
|
+
**bt-gauntlet**.
|
|
21
|
+
|
|
22
|
+
**Typical sequence for a real game — use both:**
|
|
23
|
+
|
|
24
|
+
1. **Foundation via the spec workflow** — scaffold, player controller, physics, level loading, weapon
|
|
25
|
+
systems, HUD. Checklist-shaped work with crisp acceptance; cheaper and faster than critic rounds.
|
|
26
|
+
2. **Quality via a gauntlet job** — once the game exists, `/bt-gauntlet --name:aaa-polish <brief>` with the
|
|
27
|
+
reference media. The loop builds on whatever the plan produced.
|
|
28
|
+
|
|
29
|
+
For a `unity-level` deliverable the same split applies, one layer down: use the spec workflow to scaffold
|
|
30
|
+
the Unity project, install the three packages and get a first export working end to end (that work is
|
|
31
|
+
enumerable and verifiable in one pass), then hand the *fidelity* problem to a gauntlet job. The Unity
|
|
32
|
+
Exporter reference points at this skill for exactly that step.
|
|
33
|
+
|
|
34
|
+
### Inside the spec loop (bt-gauntlet named in a bt-spec brief)
|
|
35
|
+
|
|
36
|
+
When a bt-spec / bt-plan / bt-execute run encounters this skill named in its brief (e.g. `/bt-spec Build the
|
|
37
|
+
racing game, then polish it to Gran Turismo quality using bt-gauntlet`), the composition follows the same
|
|
38
|
+
idiom bt-prototype uses with bt-hero — **pre-resolve everything at spec time so nothing prompts mid-run**:
|
|
39
|
+
|
|
40
|
+
- **bt-spec:** the interview happens HERE, at spec time — the spec answers every loop-card slot (including
|
|
41
|
+
`<NAME>`, `<DELIVERABLE KIND>`, the reference media or target-generation prompt, the locked cameras, the
|
|
42
|
+
`OUT OF REACH` list and the boundaries) and writes the **pre-filled loop card** as a spec artifact
|
|
43
|
+
(e.g. `_specs/<feature>_gauntlet-card.md`).
|
|
44
|
+
- **bt-plan:** the gauntlet becomes one task (usually the last), whose Details invoke
|
|
45
|
+
`/bt-gauntlet --card:_specs/<feature>_gauntlet-card.md --rounds:N`. Its **Acceptance** is observable:
|
|
46
|
+
"gauntlet job `<name>` reports DONE — success condition met and the integration critic passed — as
|
|
47
|
+
evidenced by `_gauntlet/<name>/progress.md` and the final round journal."
|
|
48
|
+
- **bt-execute:** runs the task by invoking the gauntlet non-interactively. Because a gauntlet may outlast
|
|
49
|
+
one session, the task's checkbox stays `- [ ]` while the job is merely parked; each later
|
|
50
|
+
`bt-execute <plan> NEXT` run re-enters via `/bt-gauntlet --resume <name>` and the box flips only when the
|
|
51
|
+
job genuinely reports DONE (or a loop-card boundary fires and the user accepts the parked result — record
|
|
52
|
+
which). The gauntlet's own critic evidence IS the acceptance evidence; the bt-execute verifier reads
|
|
53
|
+
`progress.md` + the last round journal rather than re-judging the art.
|
|
54
|
+
|
|
55
|
+
bt-gauntlet never orchestrates bt-spec itself — composition is always initiated from the spec side.
|
|
56
|
+
|
|
57
|
+
---
|
|
58
|
+
|
|
59
|
+
## Cross-Host Notes
|
|
60
|
+
|
|
61
|
+
This skill runs the same everywhere because resumability depends on nothing but the `_gauntlet/` files and
|
|
62
|
+
re-invocation — no host loop feature is required.
|
|
63
|
+
|
|
64
|
+
- **Subagents:** tool names differ (Claude Code `Agent`/`Task`; other hosts their own equivalent). Check the
|
|
65
|
+
tools you actually have; never call one you don't. No subagent tool → inline with the fresh-context
|
|
66
|
+
discipline.
|
|
67
|
+
- **Browser evidence:** chrome-devtools MCP on Claude Code; other hosts use their browser/screenshot tool.
|
|
68
|
+
None available → parts are `unverified`, never passed.
|
|
69
|
+
- **Image generation:** the toolkit's `kie-image` MCP (`generate_image`) where configured; any host image
|
|
70
|
+
tool otherwise. None available and no user-supplied reference → stop and ask (see `target-images.md`).
|
|
71
|
+
- **Interview:** `AskUserQuestion` where the host has it; plain numbered questions otherwise.
|
|
72
|
+
- **Unity / Blender CLIs:** shell tools, so they work on any host with a shell. A host with no shell cannot
|
|
73
|
+
run the `unity-level` or `blender-model` pipelines — say so rather than degrading silently.
|
|
74
|
+
- **Skill loading:** where skills are loaded with a tool (the Babylon Toolkit App Builder platform),
|
|
75
|
+
`load_skill('bt-gauntlet')`; where skills are files on disk (Claude Code), this folder lives in
|
|
76
|
+
`~/.claude/skills/` or the project's `.claude/skills/`. **Copy the entire folder — SKILL.md alone is not
|
|
77
|
+
the skill**, the `references/` are loaded on demand.
|
|
78
|
+
|
|
79
|
+
### What an `unverified` part means
|
|
80
|
+
|
|
81
|
+
A part is `unverified` when the host cannot produce the evidence its rubric needs (no browser tool, no
|
|
82
|
+
graphics device for a Unity capture, no image tool for a target). An `unverified` part:
|
|
83
|
+
|
|
84
|
+
- can **never** be flipped to `- [x]` on the builder's word;
|
|
85
|
+
- does not block other parts — keep looping on parts that *can* be verified;
|
|
86
|
+
- is reported explicitly at every park, with what is missing, so the user can supply the tool and re-run;
|
|
87
|
+
- makes the job ineligible for DONE. A gauntlet with unverified parts parks as `PARTIAL`, never `DONE`.
|