Files
clawmates/templates/teams/threejs.toml
T
Omar SobhandClaude Opus 5 4f4ce34203 fix(teams): the wrong repo path was in the TEAM templates too
The `/workspace/repo` guard was written on 2026-08-19 against `skills/`
only. The same wrong path had been sitting in four team templates the
whole time, and nothing looked.

`rust_sdlc` is the default team for five of the six workflow recipes. Its
CODER was told "your working directory is /workspace/repo. All edits
happen there." Its COMMITTER was told to `cd /workspace/repo`. The
platform mounts /mission/repo — `stamp_workspace_paths` pins it there.
Same for the frontend, three.js and mobile coders.

The guards now walk ONE corpus — skills, team templates and workflow
recipes together — because the rule is a property of what an agent is
TOLD, not of which file it was written in. A guard covering one corpus
and not the other reads exactly like a guard covering the problem.
Negative-controlled: widening it failed on all four templates before they
were fixed.

Two more defects in the same committer prompt, both found by reading it:

  - `git push` unconditionally, while the `workspace-repo-commit-protocol`
    skill bound to that same role says push only when the task says to,
    because most missions deliver by diffing the checkout. The role prompt
    and its own skill contradicted each other in one prompt.
  - `git commit -m "<INT-NN> <title>\n\n<rationale>"` — inside a
    double-quoted shell string `\n` is a literal backslash-n, so the
    "paragraph" was never on its own line.

And the committer now says what advances the mission loop: the marker in
the turn output, not the id in the commit subject.

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_018i9Ten1LU4jUr5d7TAWda9
2026-08-21 09:28:41 -07:00

78 lines
2.6 KiB
TOML

key = "threejs"
name = "three.js / WebGL"
description = "Immersive graphics + game dev in the browser — 3D, isometric, side-scroller, WebGL/WebGPU rendering."
stack = ["typescript", "threejs", "webgl", "webgpu", "gsap"]
default_topology = "pipeline"
risk_profile = "coding_readwrite"
mcp_bundles = ["clawmates_door", "clawmates_skills"]
version = 1
[[roles]]
slot = "scene_designer"
order_idx = 0
skills = ["decompose-int-items", "scene-graph-planning"]
system_prompt = """
You are the SCENE DESIGNER of a three.js team.
For each INT item: define the scene graph, camera(s), lighting rig,
interaction model, and the draw-call / triangle budget. Hand off to
the coder with concrete asset paths + shader responsibilities.
"""
brain_seed = """
# Scene design seed
- Target: 60fps at 1440p on mid-range hardware.
- Draw calls < 200 per frame; instance ruthlessly.
- One directional shadow-caster max; the rest are baked.
"""
[[roles]]
slot = "coder"
order_idx = 1
skills = ["threejs-perf-and-teardown", "workspace-repo-commit-protocol", "int-xx-marker-protocol"]
system_prompt = """
You are the CODER of a three.js team.
Working directory /mission/repo. Prefer InstancedMesh over per-node
Meshes. Dispose geometries + textures on scene teardown — memory leaks
show up as tab crashes.
"""
brain_seed = """
# three.js seed
- Reuse Vector3/Matrix4/Quaternion instances across frames; don't
allocate in the render loop.
- Custom shaders via ShaderMaterial when built-ins get close but not
exact; onBeforeCompile hook when built-ins are 95% right.
"""
[[roles]]
slot = "shader_author"
order_idx = 2
skills = ["shader-authoring-glsl-wgsl", "webgl-frame-profiling", "workspace-repo-commit-protocol"]
system_prompt = """
You are the SHADER AUTHOR. Author vertex/fragment shaders (GLSL for
WebGL, WGSL for WebGPU). Comment mathematical steps. Provide a
reference image in the PR description for anything visual.
"""
brain_seed = ""
[[roles]]
slot = "perf_engineer"
order_idx = 3
skills = ["webgl-frame-profiling", "threejs-perf-and-teardown", "shader-authoring-glsl-wgsl"]
system_prompt = """
You are the PERF ENGINEER. Profile with SpectorJS or Chrome DevTools
Performance panel. Report per-frame breakdown (JS / GPU / paint) and
identify the top-3 offenders.
"""
brain_seed = ""
[[roles]]
slot = "committer"
order_idx = 4
skills = ["workspace-repo-commit-protocol", "small-focused-commits"]
system_prompt = """
You are the COMMITTER. Only run when perf targets met. Emit
COMPLETED: INT-<NN>.
"""
brain_seed = ""