agent-skills
AGENTS.md12 starsChanged 6 months agoMITView on GitHub
This file is the contract for any AI agent or human contributor working on this repo. (The skills in skills/ are the contract between agents and users of the skills — different audience.) Read at the repo root as AGENTS.md (cross-vendor agents.md convention) or as CLAUDE.md (symlink, for Claude Code's project-instruction lookup). One file, two entry points — editing either follows automatically. Deep reference for specific tasks lives under docs/maintainers/ and is loaded on demand — see Maintainer references at…
- Reads credentials
- Commits and pushes
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 31,774 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository6 other files it gives its agents.
- check-hmslSkill
- create-honeytokensSkill
- install-hooksSkill
- scan-machineSkill
- scan-secretsSkill
- triage-incidentsSkill
The file
We split this AGENTS.md into the rules it gives an agent
8 rules. About 2 are common, 4 are distinctive, and 2 are very specific to this project.
≈2
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 5
Read at the repo root as AGENTS.md (cross-vendor agents.md convention) or as CLAUDE.md (symlink, for Claude Code's project-instruction …
- Very specific: line 52
Every skill is invokable as a slash command — /gitguardian:<skill-name> (Claude Code) or the equivalent in Cursor.
- Distinctive: line 98
When in doubt, ask: *would this name still be right if we swapped the underlying tool?* If no, the tool name is in the wrong layer.
- Distinctive: line 131
Do not re-introduce a single shared doctrine duplicated across these skills to cover them — author per-skill doctrines instead.
- Common: line 133
When you add a remediation doctrine for another skill, author it for that skill's detection context rather than copying scan-secrets' …
- Common: line 158
Keep it to ~50–60 words. Drop redundant credential-type enumerations and troubleshooting-detail hooks that belong in the Troubleshooting …
- Very specific: line 166
Every SKILL.md carries a metadata block (a string→string map per the agent-skills spec):
- Distinctive: line 205
Keep skill output platform-neutral.
≈ “Common” is an estimate: at least 1 in 5 of the 40,246 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Agent Instructions
This file is the contract for any AI agent or human contributor working on this repo. (The skills in skills/ are the contract between agents and users of the skills — different audience.)
Read at the repo root as AGENTS.md (cross-vendor agents.md convention) or as CLAUDE.md (symlink, for Claude Code's project-instruction lookup). One file, two entry points — editing either follows automatically.
Deep reference for specific tasks lives under docs/maintainers/ and is loaded on demand — see Maintainer references at the bottom. Keep this file terse: it loads into every session.
Project Overview
This repo ships skill files that teach AI coding agents how to use ggshield, GitGuardian's open-source CLI. The agent invokes ggshield directly; the skill files supply the missing instructions on when, how, and what to do with the output.
Target agents: Claude Code directly via the plugin marketplace, Cursor via the .cursor-plugin/ manifest, Codex via the .codex-plugin/ manifest (and the repo-scoped .agents/plugins/marketplace.json), and ~50 other agents (Kiro CLI, Copilot, OpenCode, Cline, Windsurf, Gemini CLI, …) via the skills.sh CLI.
Repository Structure
.claude-plugin/ # Claude Code plugin metadata (marketplace.json + plugin.json)
.cursor-plugin/ # Cursor plugin metadata (same two files)
.codex-plugin/ # Codex plugin metadata (plugin.json only)
.agents/plugins/ # Codex repo-scoped marketplace (marketplace.json)
.codex-mcp.json # Codex MCP server config (Claude: .mcp.json, Cursor: mcp.json)
.github/workflows/ # CI: JSON + frontmatter validation, install-flow sanity, release automation
test/sanity.test.ts # install-flow sanity tests (vitest)
package.json # tooling-only (vitest); no runtime deps
release-please-*.{json} # Release Please config + released-version manifest
skills/<name>/ # one folder per skill (folder name = SKILL.md frontmatter `name:`)
SKILL.md # what the agent reads first
references/<topic>.md # long-form, loaded on demand; shared refs duplicated per skill
evals/ # evals.json + targets.json + files/ fixtures (scan-secrets, check-hmsl)
kiro/ # legacy Kiro power copy (Kiro now installs from the root); not kept in sync
docs/maintainers/ # task-gated reference for working ON this repo (see bottom of this file)
README.md # user-facing: what / install / what-you-can-do
LICENSE # MITThe six skills are scan-secrets, create-honeytokens, scan-machine, check-hmsl, install-hooks, triage-incidents. Shared references (ggshield-cli-setup.md, gitguardian-platform.md, and hook-selection.md for scanning/hook setup) are duplicated into every skill that links to them — see Skills are self-contained.
Skills index
| Skill | Description |
scan-secrets | Detect hardcoded secrets in files, git history, commits, Docker images, and PyPI packages. Use for explicit scans, audits, and suspected leaks. Routine protection for edits, commits, and pushes routes to install-hooks. |
create-honeytokens | Generate AWS decoy credentials (bare or wrapped in realistic code) and guide the user on where to plant them. Auto-triggers around .env.example, pre-publication open-source repos, internal wikis. |
scan-machine | Scan the entire developer machine for credentials across local git repositories, dotfiles, cloud CLI configs, shell history, AI agent caches, and abandoned project trees. Requires endpoint scanning to be enabled on the GitGuardian workspace (gated server-side; not available on Free). |
check-hmsl | Check whether a known credential has been seen leaking publicly via the HasMySecretLeaked (HMSL) hash-lookup service. Inverse of scan-secrets: that finds unknown secrets in code, this checks known secrets against the HMSL public GitHub corpus. Can run anonymously with lower quota, or authenticated for higher quota. |
install-hooks | Install recurring secret protection through Git pre-commit or pre-push hooks, or through supported AI hooks. Reuse protection that works, offer a missing installation one time, keep hook managers, and avoid duplicate agent scans. Pre-push checks outgoing commits. It does not prevent local commits. |
triage-incidents | Read, prioritize, and drive remediation on secret incidents already detected in the GitGuardian dashboard, via the GitGuardian Developer MCP server. Covers internal and Public Monitoring incidents, ranks them by validity/severity/blast radius/exposure, and closes the loop with confirmation-gated assign/tag/resolve writes. The one MCP-first skill in the bundle. |
Slash commands
Every skill is invokable as a slash command — /gitguardian:<skill-name> (Claude Code) or the equivalent in Cursor. We do not ship a separate commands/ directory; that's the legacy "flat .md as skill" pattern Anthropic now recommends against (see Critical structural rules in docs/maintainers/distribution.md).
| Slash invocation | Powered by |
/gitguardian:scan-secrets | skills/scan-secrets/SKILL.md |
/gitguardian:create-honeytokens | skills/create-honeytokens/SKILL.md |
/gitguardian:scan-machine | skills/scan-machine/SKILL.md |
/gitguardian:check-hmsl | skills/check-hmsl/SKILL.md |
/gitguardian:install-hooks | skills/install-hooks/SKILL.md |
/gitguardian:triage-incidents | skills/triage-incidents/SKILL.md |
The skill description (frontmatter) is what shows up in the slash-command autocomplete dropdown. Keep it action-verb-first ("Scan code for hardcoded secrets…", "Generate a GitGuardian honeytoken…") so it reads as a label, with the auto-trigger conditions following ("Auto-triggers when …") so model-driven invocation still works.
Commit attribution
AI-authored commits must include the model byline:
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>Replace with the actual model that authored the work. This is non-negotiable on this repo — the lineage matters for review and provenance.
Key conventions
These are repo-wide rules. Not preferences, conventions — break them and a reviewer will push back.
Naming layers (brand vs capability vs tool)
The repo's user-facing surface has three distinct layers, and the right name lives at the right layer:
| Layer | What it names | Tool-agnostic? | Examples |
| Brand / plugin | The thing users install | yes — it's a namespace, not a feature | gitguardian (plugin), GitGuardian (displayName), gitguardian-agent-skills (marketplace) |
| Capability / skill | What the agent learns to do | yes — verb-noun describing the action | scan-secrets, create-honeytokens, future triage-incidents |
| Tool / implementation | What actually does the work | no — real product name | ggshield CLI, ggmcp (Developer MCP server), GitGuardian public API |
Layer 3 is plumbing. It appears in each skill's ## Overview, ## Commands, and ## Troubleshooting sections — because users need to know which tool runs and how to install it — but never in a skill folder name, command name, or plugin namespace.
Concretely:
- Skill folder is
scan-secrets/, notggshield-scan-secrets/. If we add API-backed scanning later, the same skill teaches both paths. - Slash command is
/gitguardian:scan-secrets, not/ggshield:scan-secrets. The plugin namespace is the brand; the suffix after:is the skill name (which is the action); nothing in between says which tool runs it. - The plugin description is broad ("via ggshield, the Developer MCP server, and the GitGuardian API") so it doesn't lock us into one tool.
- The
ggshieldkeyword stays inplugin.jsonso users searching the marketplace for "ggshield" still find this plugin — discovery is a separate concern from naming.
When in doubt, ask: would this name still be right if we swapped the underlying tool? If no, the tool name is in the wrong layer.
Skill folder naming
Verb-noun, no product prefix. scan-secrets, create-honeytokens, check-hmsl, scan-machine. The plugin name is already gitguardian — prefixing every skill with gitguardian- or ggshield- is redundant. Matches the convention used across mature multi-skill plugin repos.
Long-form content goes under references/
Anything past ~150 lines, anything heavily detailed (alert response, planting strategy, full command variants with examples) lives in skills/<name>/references/<topic>.md. The SKILL.md stays terse and points at the reference. Lets the agent decide on demand what to load.
Skills are self-contained — references live inside each skill
Every reference file lives inside its owning skill at skills/<name>/references/<file>.md. There is no bundle-root references/ directory. SKILL.md files link to references as bare relative paths (references/<file>.md), which is the canonical pattern documented at https://code.claude.com/docs/en/skills#add-supporting-files and used by supabase/agent-skills and getsentry/sentry-for-ai — the two largest precedents.
This means truly-shared content (e.g., ggshield-cli-setup.md and gitguardian-platform.md) is duplicated into every skill that links to it. Yes, that means 4 copies. The DRY cost is real, and it's the price for two properties we need:
- Every skill works in isolation. A user who installs only
check-hmslvianpx skills add --skill check-hmslgets a complete skill folder with all its references resolved. Bundle-root references break this case. - Path resolution is platform-independent. Codex, Claude Code, Cursor, and skills.sh all interpret
references/<file>.mdas relative to the SKILL.md location. Bundle-root../../references/<file>.mdis non-standard and surfaced agent-side resolution bugs in practice (see commit history for the Codex-on-/references/failure).
Edit discipline. When you change a duplicated reference file in one skill, propagate the same change to every other skill that has a copy. A CI check that diffs the duplicated files would catch drift if/when this becomes a recurring problem. See docs/maintainers/contributing.md for the checksum check.
Skill-specific references (no duplication) — scan-secrets/references/workflows.md, create-honeytokens/references/planting-strategy.md — live alongside the shared ones in the same references/ folder; only the content differs in whether it has copies elsewhere.
The remediation doctrine
Remediation guidance is per-skill, not shared. Each skill that needs to tell the user what to do with a found credential gets its own remediation doctrine, tailored to that skill's detection context. There is no single cross-skill doctrine duplicated everywhere — that was tried and the fit was poor (an HMSL match is always public-facing; a honeytoken is never rotated; a machine-scan finding is always off-repo), so each skill's reality is different enough to warrant its own doctrine.
Current state:
scan-secrets/references/remediation-doctrine.md— the full doctrine: four triage axes, four deliverable modes, four lifecycle tracks (pre-leak, post-leak public, post-leak internal-private, off-repo), a credential-lifecycle section that states where type-specific mechanics come from instead of carrying vendor runbooks, the generic coordination framework, public-leak takedown, and per-mode validation.SKILL.mdroutes here directly when findings are present; the siblinginterpreting-results.mdis a separate reference for reading ggshield output (JSON shape, validity, severity), the HMSL handoff, andggignorefalse positives — it is not a remediation file. This doctrine is also the right basis for a future incident-management skill, which shares scan-secrets' full-lifecycle detection context.check-hmsl— keeps a short, self-contained remediation reminder inline (an HMSL match is always public-facing, so "it's burned, rotate it" is the whole story for now).scan-machineandcreate-honeytokens— retain their existing remediation prose for now; each will get its own tailored doctrine later.
Do not re-introduce a single shared doctrine duplicated across these skills to cover them — author per-skill doctrines instead.
When you add a remediation doctrine for another skill, author it for that skill's detection context rather than copying scan-secrets' wholesale.
SKILL.md section order
## Overview
## When to Use
## Onboarding (first use) ← setup BEFORE commands, since commands are useless without it
### Prerequisites
### Setup
## Commands (or skill-specific reference)
## Best Practices
## TroubleshootingOnboarding before Commands is deliberate: every command in the reference is useless until ggshield is installed and authenticated. A new user landing on the skill should hit the install path first.
Frontmatter description: is a trigger statement, not a feature list
Claude Code and Cursor auto-trigger skills by matching this field against the user's prompt and the current file context. Write it as:
Use when <concrete user condition>, when <file pattern>, when <error message>. Use when <explicit ask>.Keep it to ~50–60 words. Drop redundant credential-type enumerations and troubleshooting-detail hooks that belong in the Troubleshooting section.
No markdown or bracketed prefixes in description. No *emphasis*, **bold**, backticks, or [USER-RUN ONLY …] / [AGENT-EXECUTABLE] prefixes — they render as literal noise in catalog indices and machine-parsed dropdowns. Write plain prose.
Do not mention execution in the description unless the skill is the command-handoff exception. Agent-executable is the default, so stating it ("the agent runs X directly", "agent-executable") is noise — leave it out. Only a skill with command-handoff: "true" (below) states its execution contract in the description, and as a sentence ("User-run only — the agent prepares the commands, the user runs them…"), not a bracket. The machine-readable flag lives in metadata; the runtime enforcement lives in the body (the check-hmsl STOP block) — never collapse that human-readable contract out of a command-handoff skill's description.
metadata.command-handoff and metadata.version
Every SKILL.md carries a metadata block (a string→string map per the agent-skills spec):
metadata:
version: "0.1.4" # x-release-please-versioncommand-handoff— the exception flag, set to"true"only on a skill where the agent must not run the tool itself. Skills are agent-executable by default, so the default carries no flag. The exception exists when running the command would pull sensitive content into the agent's context — e.g.check-hmsl, where reading the credential file or echoing its contents into the thread defeats HMSL's local-hashing protocol. On those skills the agent's job is to build the command and hand it to the user to run, then interpret the sanitized output the user pastes back. Onlycheck-hmslcarries it today:metadata: command-handoff: "true" version: "0.1.4" # x-release-please-versionIt is a label for catalogs/validators/routers — it does not enforce anything; the body (STOP block) is the enforcement.
version— mirrors the plugin/package version; not an independent per-skill semver. The line carries an# x-release-please-versionannotation and is registered as agenericextra-file inrelease-please-config.json, so Release Please bumps it in lockstep with the manifests (seedocs/maintainers/releasing.md). Quote it so YAML reads it as a string; never hand-edit it out of step.
license: and compatibility: are required on every skill
Both are optional in the agent-skills spec; both are mandatory here. They sit between description: and metadata:, matching the spec's own field order.
license: MIT— same on every skill, mirroring the repo's rootLICENSE. A skill installed on its own vianpx skills add --skill <name>travels without that file, so the frontmatter is the only place its license is legible.compatibility:— the skill's real environment requirements, in one sentence, max 500 chars. This is the machine-readable version of the skill's own### Prerequisitessection, so the two must agree: when you raise a minimumggshieldversion or add a required scope in Prerequisites, updatecompatibilityin the same commit.
Write what this skill needs, not what the bundle needs — the field earns its place by differentiating. triage-incidents needs ggmcp and no CLI at all; scan-machine needs endpoint scanning enabled server-side; create-honeytokens needs a Manager seat and the honeytokens:write scope; check-hmsl is user-run and works unauthenticated. A generic "requires ggshield" on all six would be worse than nothing.
Mind YAML: an unquoted : inside the value breaks the frontmatter. Rephrase to avoid the colon rather than quoting the whole string. CI catches it — skills-ref validate runs on every skill in validate.yml — but catching it locally is faster.
Verify before claiming
Before listing GitGuardian product capabilities, check gitguardian.com or product docs — do not rely on training data. Before listing ggshield CLI capabilities, run ggshield --help and ggshield <subcommand> --help against the installed version. The product surface and the CLI surface are not the same; GitGuardian has dashboard features (Public Monitoring, NHI Governance) that aren't exposed through ggshield, and ggshield does not ship IaC or SCA scanning despite adjacent vendors doing both.
No git push without explicit consent
The maintainer reviews every push. Always commit, then ask before pushing. "Commit" does not imply "push"; previous consent for one push does not authorize the next. The same applies to deleting remote branches (e.g., during a rename), which is a destructive action — ask first.
No emojis in skill / command content
Keep skill output platform-neutral. Emojis vary in support across the ~50 target agents.
Maintainer references
Task-gated working knowledge lives under docs/maintainers/. Load the relevant file only when you're doing that task — none of it needs to be in always-on context.
| When you're… | Read |
| Adding a skill, a slash command, or editing a duplicated reference; planning router-pattern scaling | docs/maintainers/contributing.md |
Running the skill-creator eval loop, authoring evals.json, or building secret-bearing fixtures | docs/maintainers/evals.md |
| Cutting a release, bumping the version, or reasoning about SemVer policy | docs/maintainers/releasing.md |
| Touching manifests, validating the plugin, or publishing to Claude/Cursor/Codex marketplaces (includes the Critical structural rules and the manifest field reference) | docs/maintainers/distribution.md |
Resources
- ggshield CLI: https://github.com/GitGuardian/ggshield
- GitGuardian Developer MCP server: https://github.com/GitGuardian/ggmcp
- GitGuardian public docs: https://docs.gitguardian.com (append
.mdto any HTML page to get the Markdown version; AI-agent index at https://docs.gitguardian.com/llms.txt) - Claude Code plugin docs: https://code.claude.com/docs/en/plugins (full vendor docs index in
docs/maintainers/distribution.md) - Codex plugin docs: https://developers.openai.com/codex/plugins
- Cursor plugin template: https://github.com/cursor/plugin-template
- Cursor plugin submission: https://cursor.com/marketplace/publish
- skills.sh CLI (cross-agent installer): https://skills.sh
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

