diff --git a/graphify/skill-aider.md b/graphify/skill-aider.md index 5154559d..6f37a5d8 100644 --- a/graphify/skill-aider.md +++ b/graphify/skill-aider.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-amp.md b/graphify/skill-amp.md index 7f58bb80..973a0157 100644 --- a/graphify/skill-amp.md +++ b/graphify/skill-amp.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-claw.md b/graphify/skill-claw.md index 4d59af1e..06d8195d 100644 --- a/graphify/skill-claw.md +++ b/graphify/skill-claw.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-codex.md b/graphify/skill-codex.md index e395cf73..9f8253ff 100644 --- a/graphify/skill-codex.md +++ b/graphify/skill-codex.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-copilot.md b/graphify/skill-copilot.md index 4d59af1e..06d8195d 100644 --- a/graphify/skill-copilot.md +++ b/graphify/skill-copilot.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-droid.md b/graphify/skill-droid.md index 1001fea3..e65d5a0c 100644 --- a/graphify/skill-droid.md +++ b/graphify/skill-droid.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-kilo.md b/graphify/skill-kilo.md index 15b47082..7922744e 100644 --- a/graphify/skill-kilo.md +++ b/graphify/skill-kilo.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-opencode.md b/graphify/skill-opencode.md index 064bbcd0..30b1bb83 100644 --- a/graphify/skill-opencode.md +++ b/graphify/skill-opencode.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-trae.md b/graphify/skill-trae.md index 9c8f927b..6ecca329 100644 --- a/graphify/skill-trae.md +++ b/graphify/skill-trae.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-vscode.md b/graphify/skill-vscode.md index dc33c0df..8b95828a 100644 --- a/graphify/skill-vscode.md +++ b/graphify/skill-vscode.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill-windows.md b/graphify/skill-windows.md index f64d0e83..7d590cd0 100644 --- a/graphify/skill-windows.md +++ b/graphify/skill-windows.md @@ -1,7 +1,6 @@ --- name: graphify-windows description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/graphify/skill.md b/graphify/skill.md index efde04e4..5d97b4c1 100644 --- a/graphify/skill.md +++ b/graphify/skill.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tests/test_skillgen.py b/tests/test_skillgen.py index 512b68f2..73e9884c 100644 --- a/tests/test_skillgen.py +++ b/tests/test_skillgen.py @@ -365,20 +365,13 @@ def test_all_progressive_hosts_check_and_audit_clean(): assert probs == [], f"[{key}] audit\n" + "\n".join(probs) -def test_kiro_and_pi_omit_the_trigger_line(): - """kiro and pi render no frontmatter trigger (trigger absent in v8).""" - for key in ("kiro", "pi"): +def test_no_host_has_trigger_in_frontmatter(): + """No split host emits a trigger: field — not part of Agent Skills spec (#1180).""" + for key in ("claude", "codex", "opencode", "kilo", "copilot", "claw", "droid", + "amp", "trae", "vscode", "kiro", "pi"): core, _ = _platform_artifacts(key) head = core.split("---", 2)[1] - assert "trigger:" not in head, f"[{key}] unexpectedly has a trigger line" - - -def test_triggered_hosts_keep_the_trigger_line(): - """The other split hosts keep trigger: /graphify in the frontmatter.""" - for key in ("opencode", "kilo", "copilot", "claw", "droid", "amp", "trae", "vscode"): - core, _ = _platform_artifacts(key) - head = core.split("---", 2)[1] - assert "trigger: /graphify" in head, f"[{key}] missing trigger line" + assert "trigger:" not in head, f"[{key}] unexpectedly has a trigger: line" def test_kilo_renders_its_rules_tail_section(): @@ -466,10 +459,15 @@ def test_monoliths_change_only_the_enum_description_and_chunk_cleanup(): platforms = gen.load_platforms() for key in ("aider", "devin"): rendered = gen.render(platforms[key])[0].content.splitlines() - original = gen._normalise(gen._git_show(platforms[key].roundtrip_ref)).splitlines() + # Strip trigger: lines from the reference — their removal (#1180) is a + # permitted diff alongside enum, description, and chunk-cleanup changes. + original = [ + l for l in gen._normalise(gen._git_show(platforms[key].roundtrip_ref)).splitlines() + if not gen._is_trigger_line(l) + ] assert len(rendered) == len(original), f"[{key}] line count changed" diff_idx = [i for i, (r, o) in enumerate(zip(rendered, original)) if r != o] - # Exactly four lines change: the prose enum guidance, the schema line, + # Four lines change: the prose enum guidance, the schema line, # the frontmatter description, and the chunk-cleanup rewrite. assert len(diff_idx) == 4, f"[{key}] expected 4 changed lines, got {len(diff_idx)}" enum_changes = 0 diff --git a/tools/skillgen/expected/graphify__skill-aider.md b/tools/skillgen/expected/graphify__skill-aider.md index 5154559d..6f37a5d8 100644 --- a/tools/skillgen/expected/graphify__skill-aider.md +++ b/tools/skillgen/expected/graphify__skill-aider.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-amp.md b/tools/skillgen/expected/graphify__skill-amp.md index 7f58bb80..973a0157 100644 --- a/tools/skillgen/expected/graphify__skill-amp.md +++ b/tools/skillgen/expected/graphify__skill-amp.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-claw.md b/tools/skillgen/expected/graphify__skill-claw.md index 4d59af1e..06d8195d 100644 --- a/tools/skillgen/expected/graphify__skill-claw.md +++ b/tools/skillgen/expected/graphify__skill-claw.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-codex.md b/tools/skillgen/expected/graphify__skill-codex.md index e395cf73..9f8253ff 100644 --- a/tools/skillgen/expected/graphify__skill-codex.md +++ b/tools/skillgen/expected/graphify__skill-codex.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-copilot.md b/tools/skillgen/expected/graphify__skill-copilot.md index 4d59af1e..06d8195d 100644 --- a/tools/skillgen/expected/graphify__skill-copilot.md +++ b/tools/skillgen/expected/graphify__skill-copilot.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-droid.md b/tools/skillgen/expected/graphify__skill-droid.md index 1001fea3..e65d5a0c 100644 --- a/tools/skillgen/expected/graphify__skill-droid.md +++ b/tools/skillgen/expected/graphify__skill-droid.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-kilo.md b/tools/skillgen/expected/graphify__skill-kilo.md index 15b47082..7922744e 100644 --- a/tools/skillgen/expected/graphify__skill-kilo.md +++ b/tools/skillgen/expected/graphify__skill-kilo.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-opencode.md b/tools/skillgen/expected/graphify__skill-opencode.md index 064bbcd0..30b1bb83 100644 --- a/tools/skillgen/expected/graphify__skill-opencode.md +++ b/tools/skillgen/expected/graphify__skill-opencode.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-trae.md b/tools/skillgen/expected/graphify__skill-trae.md index 9c8f927b..6ecca329 100644 --- a/tools/skillgen/expected/graphify__skill-trae.md +++ b/tools/skillgen/expected/graphify__skill-trae.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-vscode.md b/tools/skillgen/expected/graphify__skill-vscode.md index dc33c0df..8b95828a 100644 --- a/tools/skillgen/expected/graphify__skill-vscode.md +++ b/tools/skillgen/expected/graphify__skill-vscode.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill-windows.md b/tools/skillgen/expected/graphify__skill-windows.md index f64d0e83..7d590cd0 100644 --- a/tools/skillgen/expected/graphify__skill-windows.md +++ b/tools/skillgen/expected/graphify__skill-windows.md @@ -1,7 +1,6 @@ --- name: graphify-windows description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/expected/graphify__skill.md b/tools/skillgen/expected/graphify__skill.md index efde04e4..5d97b4c1 100644 --- a/tools/skillgen/expected/graphify__skill.md +++ b/tools/skillgen/expected/graphify__skill.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/fragments/core/aider.md b/tools/skillgen/fragments/core/aider.md index 5154559d..6f37a5d8 100644 --- a/tools/skillgen/fragments/core/aider.md +++ b/tools/skillgen/fragments/core/aider.md @@ -1,7 +1,6 @@ --- name: graphify description: "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger: /graphify --- # /graphify diff --git a/tools/skillgen/gen.py b/tools/skillgen/gen.py index c67334b2..245ae0d0 100644 --- a/tools/skillgen/gen.py +++ b/tools/skillgen/gen.py @@ -244,7 +244,7 @@ class Platform: refs_dst: str | None = None name: str = "graphify" description: str | None = None - trigger: str | None = "/graphify" + trigger: str | None = None # removed — not part of Agent Skills spec (#1180) dispatch: str | None = None query_variant: str = "cli-inline" extraction: str = "verbose" @@ -283,7 +283,7 @@ def load_platforms() -> dict[str, Platform]: refs_dst=cfg.get("refs_dst"), name=cfg.get("name", "graphify"), description=cfg.get("description"), - trigger=cfg.get("trigger", "/graphify"), + trigger=cfg.get("trigger"), dispatch=cfg.get("dispatch"), query_variant=cfg.get("query_variant", "cli-inline"), extraction=cfg.get("extraction", "verbose"), @@ -318,16 +318,14 @@ class RenderedArtifact: def _render_frontmatter(platform: Platform) -> str: - """Render the YAML frontmatter from the platform's name/description/trigger. + """Render the YAML frontmatter from the platform's name and description. - The trigger line is omitted when the platform has no trigger (kiro/pi). + Only emits fields from the Agent Skills spec (name, description). The description is preserved verbatim from platforms.toml — never invented. """ if platform.description is None: raise ValueError(f"split platform '{platform.key}' is missing a description") lines = ["---", f"name: {platform.name}", f'description: "{platform.description}"'] - if platform.trigger: - lines.append(f"trigger: {platform.trigger}") lines.append("---") return "\n".join(lines) @@ -718,6 +716,15 @@ def _is_chunk_cleanup_line(line: str) -> bool: return line.lstrip().startswith("rm -f") and "find " in line and "-name '.graphify_chunk_" in line +def _is_trigger_line(line: str) -> bool: + """Whether a line is the non-spec ``trigger:`` frontmatter field (#1180). + + The Agent Skills spec does not include ``trigger:`` — only name/description + and a few optional fields. Removing it is a permitted monolith diff. + """ + return line.strip().startswith("trigger:") + + def monolith_roundtrip(platform: Platform) -> list[str]: """Assert a monolith renders diff-clean vs its v8 blob modulo allowed changes. @@ -735,14 +742,17 @@ def monolith_roundtrip(platform: Platform) -> list[str]: original = _normalise(_git_show(platform.roundtrip_ref)) rendered_lines = rendered.splitlines() - original_lines = original.splitlines() + # Strip trigger lines from the original before comparing — they are non-spec + # and their removal (#1180) is a permitted diff. Filter here so the line-count + # check and the per-line zip both operate on the same reduced set. + original_lines = [l for l in original.splitlines() if not _is_trigger_line(l)] problems: list[str] = [] if len(rendered_lines) != len(original_lines): problems.append( f"[{platform.key}] line count differs: rendered {len(rendered_lines)} vs v8 {len(original_lines)} " - "(the only allowed changes are the enum line(s) and the description line, " - "which must not add or remove lines)" + "(the only allowed changes are the enum line(s), the description line, " + "the chunk-cleanup rewrite, and trigger: removal — none must add or remove other lines)" ) return problems @@ -750,7 +760,7 @@ def monolith_roundtrip(platform: Platform) -> list[str]: if r == o: continue # The permitted diffs are the enum unification, the unified description, - # and the shell-agnostic chunk-cleanup rewrite (#1172). + # the shell-agnostic chunk-cleanup rewrite (#1172), and trigger removal (#1180). if _is_enum_line(r) or _is_frontmatter_description_line(r) or _is_chunk_cleanup_line(r): continue problems.append( diff --git a/tools/skillgen/platforms.toml b/tools/skillgen/platforms.toml index bc1ccbd9..49f702dc 100644 --- a/tools/skillgen/platforms.toml +++ b/tools/skillgen/platforms.toml @@ -18,7 +18,6 @@ # refs_dst rendered references/ dir, relative to the repo root (split only). # name frontmatter name (default "graphify"; graphify-windows for windows). # description frontmatter description, PRESERVED VERBATIM per platform. Required. -# trigger frontmatter trigger (default "/graphify"; omit -> no trigger line). # dispatch Part-B dispatch fragment basename under fragments/dispatch/. # query_variant cli | cli-inline. Selects both the core query stub and the # query reference body. @@ -158,7 +157,6 @@ core = "core" skill_dst = "graphify/skill-kiro.md" refs_dst = "graphify/skills/kiro/references" description = "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger = "" dispatch = "agent-tool-disk" query_variant = "cli-inline" extraction = "compact" @@ -169,7 +167,6 @@ core = "core" skill_dst = "graphify/skill-pi.md" refs_dst = "graphify/skills/pi/references" description = "Use for any question about a codebase, its architecture, file relationships, or project content — especially when graphify-out/ exists, where the question should be treated as a graphify query first. Turns any input (code, docs, papers, images, videos) into a persistent knowledge graph with god nodes, community detection, and query/path/explain tools." -trigger = "" dispatch = "agent-tool-disk" query_variant = "cli-inline" extraction = "compact"