X9 context files generator
Skill xonika9/agent-skills/skills/x9-context-files-generator
Use when creating, auditing, or updating repository-level AGENTS.md, CLAUDE.md, or README.md — «создай AGENTS.md», «обнови README», «настрой контекст репозитория», "generate repository context files". Do not use for global personal instructions, skills, or ordinary documentation unrelated to onboarding agents or humans.From its SKILL.md
npx -y skills add xonika9/agent-skills --skill x9-context-files-generatorAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
6.2 KB, as published. Nobody here has run it
Repository context files
Create concise, evidence-backed onboarding files for two audiences: agents (AGENTS.md/CLAUDE.md) and humans (README.md). Existing files are user-owned inputs, not blank templates.
For every Create, Audit, or Update that touches agent-facing instructional prose in AGENTS.md or an explicitly exceptional CLAUDE.md, load and apply x9-agent-instructions before writing or judging that prose. It is a subordinate instruction-quality rubric, not the primary context-file workflow, and owns language, prescription, duplication, artifact references, and what earns a line. This skill remains the owner of repository evidence, audience selection, canonical files, merge and preservation behavior, AGENTS.md/CLAUDE.md normalization, and README.md.
Do not apply the subordinate rubric to README.md or to a CLAUDE.md that contains only the canonical @AGENTS.md import. Fold its findings into this workflow's single report and approval gate rather than producing a second handoff. If x9-agent-instructions is unavailable, continue the remaining repository and structural checks, record the instruction rubric as degraded, and do not claim a complete or clean agent-file result. README-only work records it as not applicable.
Select the action
- Create or update: an explicit request to create, update, fix, or rewrite a context file authorizes the requested in-scope edits; do not ask for the same permission again.
- Audit: an explicit audit/check request is read-only. Report findings and proposed changes, then ask once whether to apply them.
- Bare skill invocation: inspect the current repository read-only by default. If changes would help, show the proposal and ask once before editing.
Infer the action from the whole request, not only trigger words. When an authorized edit reveals an additional normalization outside the requested change, ask once before applying that extra change.
Workflow
- Read current repository instructions and README completely enough to preserve non-inferable rules. Inspect actual commands, manifests, CI, and representative code before writing.
- Classify content by audience:
- Agent file: commands, dangerous gotchas, local constraints, non-inferable conventions, and verification contracts.
- README: purpose, setup, normal usage, and links to deeper material.
- Keep one canonical owner for each fact. A short audience-specific summary is allowed when it changes behavior; link to the owner instead of copying full detail.
- Make root
AGENTS.mdthe single canonical local instruction file and rootCLAUDE.mdexactly@AGENTS.mdplus a final newline, unless the repository or user declares an exception. Put every new local rule inAGENTS.md. Before normalizing an existingCLAUDE.md, merge its unique rules intoAGENTS.md; never discard them silently or preserve a duplicate copy by default. Apply this normalization immediately when it was explicitly requested or already required by repository policy; otherwise propose it and ask once before editing. - Treat an existing
AGENTS.md,CLAUDE.md, orREADME.mdas merge-only unless the user explicitly requests replacement. Show a diff for substantive rewrites. - For agent files, remove content that is cheap to reconstruct only when its absence would not change the reader's next decision or action; use the detailed test in references/agents-md.md. Include architecture only when the rationale or boundary cannot be recovered cheaply from code and materially affects decisions. Avoid generated file trees and generic overviews.
- Use English for machine-facing instructions by default; follow repository/user language when human maintenance or domain literals make that clearer.
- Run commands you present only when they are safe, local, and within the requested repository scope. Read-only inspection and ordinary local validation are allowed by default. Destructive, external, costly, deployment, migration, production-data, account-mutating, or credential-changing commands require explicit user authority; otherwise preserve the command and label it unverified with the reason.
Read references/agents-md.md when editing agent files, references/readme.md for README work, and references/research-basis.md when judging how much inferred architecture belongs in context.
Boundaries
- Global
~/.claude/CLAUDE.mdand~/.codex/AGENTS.mdbelong tox9-agent-instructions. - Skill folders belong to
x9-skill-creator. - Do not put personal absolute paths such as
/Users/<name>/...or/home/<name>/...in committed files. Prefer repository-relative paths or neutral placeholders; keep a machine-bound path only when the repository genuinely depends on that machine and the user explicitly wants it documented. - Do not overwrite existing instructions by position from a stale read; re-read immediately before applying a patch.
Done
- Existing non-inferable rules are preserved or intentionally changed with user authority.
- When canonical-file normalization was authorized and no exception applies,
CLAUDE.mdcontains only@AGENTS.mdand all local instructions are owned byAGENTS.md. - Commands and paths trace to the current repository.
- Agent and human files contain only behavior-changing audience-specific material.
- The instruction rubric is reported as
applied,not applicable, ordegraded; a complete or clean agent-file result requiresapplied. - A fresh-context reader can start the project without inventing a command.
The onboarding declaration is the machine-readable onboarding contract.
What ships with it: 3 files
5.2 KB alongside SKILL.md
references/
- agents-md.md3.3 KB
- readme.md998 B
- research-basis.md884 B
Gives 0 of the 12 instructions most memory context skills give
Counted across 754 of the 1,056 authors here whose files we hold, read 2026-09-06
- Preserve existing content structurein 15 of 754, across 9 files
- Front-load the leading wordin 14 of 754, across 10 files
- Update existing entries instead of duplicatingin 14 of 754, across 7 files
- Keep CLAUDE.md under one hundred linesin 14 of 754, across 12 files
- Read CLAUDE.md at the project rootin 14 of 754
- Keep each meaning in a single source of truthin 12 of 754, across 8 files
- Redact sensitive information before committingin 11 of 754, across 4 files
- Scan for all CLAUDE.md filesin 11 of 754, across 7 files
- Use frontmatter for metadata on filesin 10 of 754, across 3 files
- Repeat user interactions 10 timesin 10 of 754, across 4 files
- Write the CLAUDE.md file into the target folderin 10 of 754, across 8 files
- Use memlab to process snapshotsin 9 of 754, across 3 files
Said here and by no other author read
- Load and apply x9-agent-instructions when touching agent-facing prose.
- Read current repository instructions and README completely.
- Inspect actual commands, manifests, CI, and representative code.
- Classify content by audience.
- Keep one canonical owner for each fact.
- Make root AGENTS.md the single canonical local instruction file.
Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once.