project-context — скилл для Claude Code: переносит контекст проекта в инструкции
Собирает то, что вы каждый раз объясняете заново, и превращает это в инструкции и файлы-справочники. Новые чаты стартуют с этим контекстом.
npx skills add egorfedorov/claude-context-optimizer --skill project-context -a claude-codeЧто делает project-context
Скилл смотрит на текущий разговор и вытаскивает из него то, что вы повторяете: кто вы и над чем работаете, аудитория, правила и ограничения, тон и формат, термины, справочные тексты. Если чего-то важного в переписке нет, задаёт один вопрос — не больше.
На выходе две вещи на вашем языке. Первая — инструкции в одном блоке кода, до 250 слов, короткими строками по группам «Context», «Always», «Never» и «Output»; остаётся только то, что меняет ответы. Вторая — список длинных материалов (стайлгайд, спецификация, глоссарий, прайс) по именам, их нужно загружать файлами, а не вставлять в инструкции.
Дальше скилл подсказывает, куда это положить. Для claude.ai и десктопного приложения — Project с custom instructions и файлами в knowledge; для Claude — CLAUDE.md, который грузится в каждую сессию, поэтому туда идут только строки, нужные почти всегда: команды сборки и тестов, конвенции, жёсткие правила. Длинные справочники держите в отдельных файлах, на которые CLAUDE.md ссылается. В конце скилл пишет одну строку о том, что это экономит.
Какие задачи решает
- перестать вставлять один и тот же брифинг в каждый новый чат
- собрать правила проекта в
CLAUDE.mdбез лишнего - разложить стайлгайд и глоссарий по файлам вместо инструкций
- зафиксировать тон и формат ответов один раз
- настроить Project с custom instructions и knowledge
Примеры запросов агенту
- Я устал каждый раз объяснять одно и то же — собери из нашего разговора инструкции для проекта
- Сделай
CLAUDE.mdдля этого репозитория: команды сборки, конвенции и жёсткие правила - Что из того, что я повторяю, стоит вынести в файлы-справочники?
Как установить project-context
1Через Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill project-context -a claude-code2Вручную: положить файлы
~/.claude/skills/project-context/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/project-context/
1Через Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill project-context -a codex2Вручную: положить файлы
.agents/skills/project-context/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill project-context -a cursor2Вручную: положить файлы
.cursor/skills/project-context/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install egorfedorov/claude-context-optimizer project-context2Вручную: положить файлы
.github/skills/project-context/SKILL.md1Через Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill project-context -a gemini-cli2Командой платформы
gemini skills install https://github.com/egorfedorov/claude-context-optimizer --path skills/project-contextВручную: положить файлы
.devin/skills/project-context/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add egorfedorov/claude-context-optimizer --skill project-context -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Вопросы о project-context
Как установить project-context в Claude Code?
Выполните npx skills add egorfedorov/claude-context-optimizer --skill project-context -a claude-code. Скилл окажется в ~/.claude/skills/project-context/SKILL.md.
Что делает project-context?
Собирает повторяющийся контекст из разговора и оформляет его в инструкции до 250 слов плюс список справочных файлов. Подсказывает, куда положить результат — в Project, custom instructions или CLAUDE.md.
Куда скилл советует класть длинные тексты в Claude Code?
В отдельные файлы, на которые ссылается CLAUDE.md. Сам CLAUDE.md грузится в каждую сессию, поэтому в нём оставляют только то, что нужно на большинстве задач.
Исходный текст
SKILL.md · MIT
--- name: project-context description: Turn background the user keeps re-explaining or re-pasting into reusable instructions, so new chats start with it for free. Use when the user repeats the same context, rules, style guide, persona or reference text across messages or chats, says they are tired of explaining the same thing, or asks how to set up a Claude Project, custom instructions or a CLAUDE.md. license: MIT --- # Project context Context pasted into every new chat is paid for again in every chat, and drifts each time it is retyped. Written once as instructions, it costs nothing to bring along and stays the same. ## Collect From this conversation, gather what the user keeps supplying: who they are and what they work on, the audience, rules and constraints, tone and format preferences, terms and names, recurring reference material. Ask one question at most, and only for something essential that isn't in the conversation. ## Write two things, in the user's language **1. Instructions**, in one code block, under 250 words: short imperative lines grouped as *Context*, *Always*, *Never* and *Output*. Keep only what changes the answers. No pleasantries, no restating what Claude does anyway. **2. Reference material**: the long texts (a style guide, a spec, a glossary, a price list) listed by name, to upload as files rather than paste into the instructions. ## Where it goes - **claude.ai or the desktop app**: create a Project, paste the instructions into its custom instructions, and add the reference files to its knowledge. Every chat started in that Project begins with both. For preferences that apply everywhere, use Settings → Profile instead. - **Cowork**: start each task with the instructions, and keep the reference files in the folder you give it. - **Claude Code**: a `CLAUDE.md` loads into every session, so keep there only the lines that matter on most tasks (build and test commands, conventions, hard rules). Long references belong in files that `CLAUDE.md` points to, read when needed. End with one line on what this saves: for example, "This replaces the ~1,200-token briefing you've been pasting into each new chat."
© egorfedorov · MIT · egorfedorov/claude-context-optimizer