Open-source skills for designing and reviewing software with AI agents
Python agent-skillsai-agentsantigravityclaude-codeclaude-code-pluginclaude-skillscodexcodex-plugincoding-agentscontext-engineeringdeveloper-toolsgeminillmmulti-agentprompt-engineeringspec-driven-development
Fix bootstrap prompt truncation and Claude transcript lookup (#114)
n3wthd651fe86c12d
diff --git a/skills/egm_bootstrap/SKILL.md b/skills/egm_bootstrap/SKILL.mdindex a6f220c..6d49a92 100644--- a/skills/egm_bootstrap/SKILL.md+++ b/skills/egm_bootstrap/SKILL.md@@ -67,7 +67,7 @@ If your harness has no subagent tool, run the scout steps inline.subdirectories, you MUST immediately request user approval (using a structured question tool, if your harness has one, or plain chat) before proceeding with full-tree executionor unbounded subagent spawning.---------------------------------------------------------------------------------+---## Workflow@@ -83,7 +83,7 @@ If your harness has no subagent tool, run the scout steps inline.* None found: `<test-command>`2. Record as `VerificationCommand` to populate generated README contracts.---------------------------------------------------------------------------------+---### Step 1: Startup Branching Control@@ -93,7 +93,7 @@ If your harness has no subagent tool, run the scout steps inline.3. If `is_worker` is `false` or unset, proceed as the Root Orchestrator to**Step 2: Incremental Scoping & Safety Gate**.---------------------------------------------------------------------------------+---### Step 2: Incremental Scoping & Safety Gate (Root Orchestrator)@@ -151,7 +151,7 @@ If your harness has no subagent tool, run the scout steps inline.4. Calculate the total count of pruned directories and maximum depth. Proceedto **Step 3: Execution Strategy Selection**.---------------------------------------------------------------------------------+---### Step 3: Execution Strategy Selection (Root Orchestrator)@@ -197,7 +197,7 @@ If your harness has no subagent tool, run the scout steps inline.* Go idle and wait for all worker subagents to return their JSON subtreeindex payloads. Jump to **Step 5: Root Compilation & Termination**.---------------------------------------------------------------------------------+---### Step 4: Sub-Orchestrator Worker Flow@@ -315,12 +315,13 @@ If your harness has no subagent tool, run the scout steps inline.the `subtree_index` array containing the `path`, `summary`, `interface`,`invariants`, and `side_effects` for every processed directory.-4. If `is_worker` is `true`, return this JSON payload (matching the `Worker- Return Interface Schema`) to the Root Orchestrator and terminate. If+4. If `is_worker` is `true`, read the [Worker Return Interface Schema](references/worker-return.schema.json)+ relative to this skill directory, then return a matching JSON payload to+ the Root Orchestrator and terminate. If`is_worker` is `false` (sequential mode), proceed directly to **Step 5: RootCompilation & Termination**.---------------------------------------------------------------------------------+---### Step 5: Root Compilation & Termination (Root Orchestrator)@@ -393,7 +394,7 @@ If your harness has no subagent tool, run the scout steps inline.6. Terminate execution successfully.---------------------------------------------------------------------------------+---## Templates@@ -455,32 +456,3 @@ If your harness has no subagent tool, run the scout steps inline.## Subdirectories & Boundaries- [Subdirectory Name]: [Relative link to existing child contract file (e.g., `./subdir/README.md` or `./subdir/${target_filename}`) or `./subdir/SKILL.md`] - [Summary of child contract/role]```------------------------------------------------------------------------------------## Schemas--### Worker Return Interface Schema (JSON)--```json-{- "type": "object",- "properties": {- "subtree_index": {- "type": "array",- "items": {- "type": "object",- "properties": {- "path": { "type": "string" },- "summary": { "type": "string" },- "interface": { "type": "array", "items": { "type": "string" } },- "invariants": { "type": "array", "items": { "type": "string" } },- "side_effects": { "type": "array", "items": { "type": "string" } }- },- "required": ["path", "summary"]- }- }- },- "required": ["subtree_index"]-}-```diff --git a/skills/egm_bootstrap/references/worker-return.schema.json b/skills/egm_bootstrap/references/worker-return.schema.jsonnew file mode 100644index 0000000..7e89295--- /dev/null+++ b/skills/egm_bootstrap/references/worker-return.schema.json@@ -0,0 +1,20 @@+{+ "type": "object",+ "properties": {+ "subtree_index": {+ "type": "array",+ "items": {+ "type": "object",+ "properties": {+ "path": { "type": "string" },+ "summary": { "type": "string" },+ "interface": { "type": "array", "items": { "type": "string" } },+ "invariants": { "type": "array", "items": { "type": "string" } },+ "side_effects": { "type": "array", "items": { "type": "string" } }+ },+ "required": ["path", "summary"]+ }+ }+ },+ "required": ["subtree_index"]+}diff --git a/tests/integration/test_claude.py b/tests/integration/test_claude.pyindex 61965e9..9d7df4b 100644--- a/tests/integration/test_claude.py+++ b/tests/integration/test_claude.py@@ -18,6 +18,13 @@ pytestmark = pytest.mark.skipif()+def trace_directory(workspace: Path) -> Path:+ """Locates native transcripts under Claude's configured directory."""+ config = Path(os.environ.get("CLAUDE_CONFIG_DIR") or Path.home() / ".claude")+ project = "".join(c if c.isalnum() else "-" for c in str(workspace.resolve()))+ return config / "projects" / project++def test_native_reviewer_isolation(tmp_path: Path) -> None:root = Path(__file__).resolve().parents[2]plugin = tmp_path / "plugin"@@ -60,8 +67,7 @@ Do not read other plugins or logs, use MCP, or modify files.)assert result.returncode == 0, result.stderrassert not json.loads(result.stdout).get("is_error")- project = "".join(c if c.isalnum() else "-" for c in str(workspace.resolve()))- traces = Path.home() / ".claude/projects" / project+ traces = trace_directory(workspace)parent = [json.loads(line) for line in(traces / f"{session}.jsonl").read_text().split("\n") if line.strip()]calls, successful = {}, set()diff --git a/tests/unit/test_claude_traces.py b/tests/unit/test_claude_traces.pynew file mode 100644index 0000000..364cbee--- /dev/null+++ b/tests/unit/test_claude_traces.py@@ -0,0 +1,32 @@+# Copyright 2026 Google LLC.+# SPDX-License-Identifier: Apache-2.0++"""Offline regression coverage for Claude's native transcript directory."""++from pathlib import Path+import runpy++import pytest++ROOT = Path(__file__).resolve().parents[2]++[email protected]("config_mode", ["unset", "default", "custom"])+def test_trace_directory(+ tmp_path: Path, monkeypatch: pytest.MonkeyPatch, config_mode: str+) -> None:+ trace_directory = runpy.run_path(str(ROOT / "tests/integration/test_claude.py"))[+ "trace_directory"+ ]+ monkeypatch.setattr(Path, "home", classmethod(lambda cls: tmp_path / "home"))+ config = tmp_path / "home" / ".claude"+ if config_mode == "unset":+ monkeypatch.delenv("CLAUDE_CONFIG_DIR", raising=False)+ else:+ if config_mode == "custom":+ config = tmp_path / "custom config"+ monkeypatch.setenv("CLAUDE_CONFIG_DIR", str(config))++ assert trace_directory(Path("/work/egm probe.v1")) == (+ config / "projects" / "-work-egm-probe-v1"+ )diff --git a/tests/unit/test_skill_load_limits.py b/tests/unit/test_skill_load_limits.pynew file mode 100644index 0000000..790d187--- /dev/null+++ b/tests/unit/test_skill_load_limits.py@@ -0,0 +1,21 @@+# Copyright 2026 Google LLC.+# SPDX-License-Identifier: Apache-2.0++"""Keep complete skill instructions within Antigravity's body load limit."""++from pathlib import Path++import pytest++ROOT = Path(__file__).resolve().parents[2]++[email protected]("skill", sorted((ROOT / "skills").glob("*/SKILL.md")),+ ids=lambda skill: skill.parent.name)+def test_skill_body_fits_antigravity(skill: Path) -> None:+ body = skill.read_text(encoding="utf-8").split("---", 2)[2].strip()+ size = len(body.encode("utf-8"))+ assert size <= 24_000, (+ f"{skill.parent.name}: {size} bytes exceeds Antigravity's 24,000-byte "+ "skill body limit; move details into an explicitly read reference"+ )