semantic-contracts-installer

semantic-contracts-installer is a skill for Claude Code, Codex from LLM-Coding/Semantic-Anchors. It costs 132 tokens per session (1,404 once invoked), scanned A, original, Apache-2.0.

An installer that adds project-specific vocabulary, writing patterns, and rules to the instruction files used by coding agents. A semantic contract is a written agreement about which concepts and templates an agent should follow.

In plain words
What is it for?
Use it to set up project- or user-level onboarding for Claude Code, Codex, Gemini CLI, Cursor, GitHub Copilot, and similar agents, or to install only semantic anchors.
Why use it?
It gives different coding agents the same project context instead of making each agent guess the team's terminology and document formats.

Skill for Claude CodeCodex

Written for Claude Code and Codex: SessionStart hook event, but also agents/openai.yaml present. Also seen: mentions CLAUDE.md; mentions Claude Code; mentions AGENTS.md.

Part of the semantic-anchors plugin — 6 skills shipped together

Install

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.

agentmods
npx agentmods add skills/llm-coding/semantic-anchors/semantic-contracts-installer
Any agent
npx skills add LLM-Coding/Semantic-Anchors --skill semantic-contracts-installer
Clone the repo
git clone --depth 1 https://github.com/LLM-Coding/Semantic-Anchors

Made for: Claude Code, Codex.

Or install semantic-anchors, the plugin that ships this one along with the rest of its 6 skills.

Wrote 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.

agentmods badge for semantic-contracts-installer

README.md
[![agentmods](https://agentmods.dev/badge/skills/llm-coding/semantic-anchors/semantic-contracts-installer.svg)](https://agentmods.dev/skills/llm-coding/semantic-anchors/semantic-contracts-installer)
Your own site
<a href="https://agentmods.dev/skills/llm-coding/semantic-anchors/semantic-contracts-installer"><img src="https://agentmods.dev/badge/skills/llm-coding/semantic-anchors/semantic-contracts-installer.svg" alt="Measured on agentmods" height="20"></a>
Per session 132 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,404 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00132 $0.01404
Opus 5 $0.00066 $0.00702
Sonnet 5 $0.00026 $0.00281
Haiku 4.5 $0.00013 $0.00140

Measured 6d ago against content hash f1b130a63973, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

semantic-contracts-installer scanned grade A with 1 finding 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 6d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/claude-session-start.sh, scripts/install.sh, scripts/refresh-contracts.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

- **Runtime:** python3 (used by `install.sh` for settings/JSON manipulation and path resolution); `curl` for `refresh-contracts.sh`.
plugins/semantic-anchors/skills/semantic-contracts-installer/SKILL.md · 75 lines

How it starts

The opening of the file, as written. The whole thing — 75 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Semantic Contracts Installer

Install a small, stable set of Semantic Contracts so coding agents start each session with the project's shared vocabulary and rules — not just terms the model already knows, but the compositions and rendered templates it cannot guess.

Why contracts first

A semantic anchor (BLUF, MECE, arc42) already works in any chat — the model knows it; installing a list of anchors adds little. A semantic contract is different: it pins which anchors apply in this project and carries a project-local template (e.g. the "Specification" contract = Cockburn use cases + Gherkin + EARS + activity diagrams, with the full template text). That template is information the model cannot reconstruct on its own. Installing contracts is therefore the primary mode; installing a bare anchor block is the --anchors-only fallback.

This is the Anchor / Contract / Skill taxonomy (ADR-007) in practice: the installer's job is to put the always-on contracts into the agent's instruction file.

Workflow (contracts mode — default)

  1. Decide scope and portability. Prefer project-local onboarding for "works across as many agents as possible"; use user-level memory only for agents that support it natively. Read references/agent-support.md before writing files.

  2. Present the contract catalog. Read data/contracts.json (a bundled snapshot of the published catalog) and show the user the available contracts by title + description. Keep the installed set small — usually 2 to 6 contracts that match the project's actual practice.

  3. Render the selected contracts into a block. For each chosen contract, emit its template (or templateDe when the project works in German) under a clear heading, followed by its resolved anchors[] as a one-line supporting-vocabulary list. Start from assets/templates/contracts-block.md. Do not add the markers — the installer adds them.

  4. Run the installer instead of editing by hand.

    • scripts/install.sh --source /path/to/contracts-block.md --target-dir <repo> --scope project for repository onboarding.
    • scripts/install.sh --source /path/to/contracts-block.md --scope home for personal onboarding.
    • It injects into the first suitable existing markdown file, else creates a minimal AGENTS.md, and writes an idempotent marker block (<!-- semantic-anchors:start/end -->) so updates replace the previous installation — including any block left by the former semantic-anchor-onboarding skill.

Read the full file on GitHub · 75 lines

Changes

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.

  1. 6d ago First seen · 75 lines · 132 tokens per session scan A f1b130a63973

Subscribe to this mod's changes

semantic-contracts-installer is a skill published in the GitHub repository LLM-Coding/Semantic-Anchors (465 stars, last pushed 5d ago), licensed Apache-2.0. It adds 132 tokens to every session and 1,404 once invoked, about $0.0007 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

media-ingest

Ingest video, audio, PDF, book, screenshot, and GitHub repo content into the brain. Multi-format handling with entity extraction and backlink propagation. Covers video-ingest, youtube-ingest, and book-ingest subtypes.

garrytan/gbrain · 52 tokens

mem0-oss-to-platform

Plan and then execute a migration of a project from the mem0 open-source / self-hosted SDK (the local Memory class) to the mem0 Platform / hosted / managed SDK (the MemoryClient class). Use this whenever a developer wants to move, switch, or migrate their mem0 usage off OSS/self-hosted to the hosted API — e.g.…

mem0ai/mem0 · 273 tokens

Cortex

Operate Cortex, the LifeOS memory system — the typed Knowledge Archive (People, Companies, Ideas, Research with typed related: links) plus recall of prior work sessions, ISAs, and conversations. Search, add, harvest, develop, ingest, distill, graph-navigate, recall. USE WHEN cortex, knowledge, knowledge base, search…

danielmiessler/LifeOS · 196 tokens

memory

Use when the user asks to remember, recall, forget, update, search, or inspect durable OpenSquilla memory, including profile facts in USER.md and long-term notes in MEMORY.md or memory//.md.

opensquilla/opensquilla · 44 tokens

ha-data-stores

Map of Hope Agent's local data stores and safe read-only query workflow. Use when the user asks where Hope Agent stores data, wants to inspect sessions/messages/memory/logs/background jobs/knowledge indexes/settings, asks the model to query local app data, or debugging requires checking persisted state. Trigger…

shiwenwen/hope-agent · 115 tokens

establishing-project-context

Use when the user asks to establish shared project language, or project work exposes a conflicting, renamed, or deprecated domain term that needs active semantic modeling. Routine small tasks stay on the fast path.

GanyuanRan/Aegis · 45 tokens