Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add Obsidian-Owl/specwright --skill gate-semanticgit clone --depth 1 https://github.com/Obsidian-Owl/specwrightWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/obsidian-owl/specwright/gate-semantic)<a href="https://agentmods.dev/skills/obsidian-owl/specwright/gate-semantic"><img src="https://agentmods.dev/badge/skills/obsidian-owl/specwright/gate-semantic/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/obsidian-owl/specwright/gate-semantic"><img src="https://agentmods.dev/badge/skills/obsidian-owl/specwright/gate-semantic.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00042 | $0.00926 |
| Opus 5.5 | $0.00017 | $0.00370 |
| Sonnet 5.5 | $0.00008 | $0.00185 |
| Haiku 4.5 | $0.00004 | $0.00093 |
Grade A, and why
gate-semantic scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 97 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Gate: Semantic Analysis
Goal
Detect semantic bugs in changed code using symbolic pre-processing when available. For each candidate finding, localize it explicitly with premises, claims, and conclusion grounded in file:line evidence.
Inputs
config.jsongates.semantic— categories, tools, optionalrulesDir{repoStateRoot}/work/{selectedWork.id}/workflow.json— selected work unit- Changed files via
git diff --name-only $(git merge-base HEAD <baseBranch>)
Outputs
{workDir}/evidence/semantic-report.md- Gate status in the selected work's
workflow.json
Constraints
Scope (MEDIUM freedom): Changed code files only. Skip markdown/JSON/YAML/config. No changed code → PASS.
Tool tiers (LOW freedom):
Resolve from gates.semantic.tools config, fall back to PATH detection.
Missing tools narrow scope — never FAIL or ERROR. Validate sg identity:
sg --version 2>&1 | grep -iq 'ast-grep' (/usr/bin/sg from shadow-utils
is a false positive).
| Tier | Tool | Adds |
|---|---|---|
| 0 | rg | Text-pattern extraction + LLM |
| 1 | ast-grep (sg) |
Structural JSON, metavariable capture |
| 2 | OpenGrep | Cross-function taint (rules: config rulesDir or .opengrep/rules/) |
Extraction (HIGH freedom):
Extract structural facts using highest available tier's tool. Feed facts
(not raw files) to LLM. Tier 1: sg scan <file> --json --rule <rule> or
sg run --pattern '...' <file> --json (avoid --stdin). Tier 2:
opengrep scan --config <rules-dir> --json <file>.
Categories (LOW freedom):
| Category | Tier | Diagnostic question |
|---|---|---|
| error-path-cleanup | 0+ | Does any error path skip releasing an acquired resource? |
| unchecked-errors | 0+ | Is any error-producing call's return value discarded? |
| fail-open-handling (CWE-636) | 1+ | Does any catch block swallow, broaden, or ignore errors? |
| error-data-leakage (CWE-209) | 1+ | Does any error response expose internals to the caller? |
| resource-lifecycle | 2+ | Is any acquired resource not released on all exit paths? |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 97 lines · 42 tokens per session scan A f635d998e77f
gate-semantic is a skill published in the GitHub repository Obsidian-Owl/specwright (10 stars, last pushed 5mo ago), licensed MIT. It adds 42 tokens to every session and 926 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
ai-development-guide
Applies language-agnostic and backend technical decision criteria, anti-pattern detection, debugging, and quality gates. Use when reviewing general/backend implementation choices, code smells, failures, or implementation completeness.
shipyard-debugging
Investigates root cause systematically before any fix is proposed. Use when encountering any bug, test failure, unexpected behavior, or error message. Also use for tracebacks, exceptions, "not working" complaints, build failures, performance problems, or integration issues, and whenever the next step would be to…
logic-review
Find logic bugs in a single file or function via semi-formal execution tracing (Premises → Trace → Divergence → Trigger → Remedy). Trigger when a user shares code and suspects something is wrong without naming a concrete failure — phrases like "review this", "does this look right", "check this function", "audit this…
logic-fix-all
Autonomous repository-wide audit-and-fix pipeline: health → review → locate/explain → fix → diff-verify → iterate until clean. Starts with a mandatory consent prompt (token-intensive); after consent runs hands-free. Trigger when the user wants ALL logic issues found and fixed — "fix everything", "fix all logic…
logic-health
Sweep a directory, module, or full codebase for logic correctness and produce a scored health dashboard with systemic patterns. Trigger when the user requests a health view — "audit the whole codebase", "health check", "health overview", "logic health overview", "audit src/", "audit auth and payments modules", "where…
debug
Systematic bug investigation with a five-phase framework: reproduce, narrow, diagnose, fix, verify. Supports automated regression bisect via --regression flag. Produces a structured debug report with root cause analysis, regression test, and CQ/Q self-evaluations.