К основному содержанию
скилл CX Codex

corezoid-git-context — скилл для Claude Code

Скилл corezoid-git-context сохраняет важный контекст сессии в документации Corezoid и синхронизирует его с git-зеркалом. Нужен после существенных изменений.

MIT ★ 74 обновлён 2026-10-29

Установить в Claude Code · Через маркетплейс плагинов Все способы и платформы ↓
/plugin marketplace add corezoid/corezoid-ai-plugin
/plugin install corezoid@corezoid
Открыть на GitHub

Что делает corezoid-git-context

Скилл анализирует сессию после corezoid-edit, corezoid-create или corezoid-review и обновляет документацию активного этапа. Он работает только с _ext/docs/, где поддерживает файлы context.md, invariants.md, decisions.md, dependencies.md и issues.md. В зависимости от событий сессии он добавляет архитектурные решения и новые зависимости, меняет ограничения или отмечает закрытые проблемы.

Перед чтением и записью скилл синхронизирует git-контекст через git-pull-context, затем читает существующие файлы и показывает план изменений до записи. Для операций используются действия MCP-инструмента cz-git-context: read-context-file, update-context-file, git-pull-context и git-push-context. Сессия должна быть существенной: например, в ней был вызван create-process или push-process, принято архитектурное решение либо найдена проблема. Без git_stage_path обновление контекста пропускается.

Какие задачи решает

  • сохранить решения, принятые при изменении процесса
  • добавить новую внешнюю зависимость в документацию
  • зафиксировать найденную или закрытую проблему
  • обновить описание роли этапа
  • синхронизировать документы с git-зеркалом

Примеры запросов агенту

  • Обнови контекст после деплоя процесса и покажи полный план изменений.
  • Зафіксуй контекст: мы выбрали новый вариант архитектуры и нашли внешний API.
  • Перед завершением сессии сохрани документацию этапа и отправь контекст в git.

Как установить corezoid-git-context

1Через маркетплейс плагинов

/plugin marketplace add corezoid/corezoid-ai-plugin
/plugin install corezoid@corezoid

Команда ставит плагин corezoid целиком, со всеми его скиллами

2Через Skills CLI (Vercel)

npx skills add corezoid/corezoid-ai-plugin --skill corezoid-git-context -a claude-code

3Вручную: положить файлы

~/.claude/skills/corezoid-git-context/SKILL.md

Папка скилла целиком; для одного проекта — .claude/skills/corezoid-git-context/

По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов

Вопросы о corezoid-git-context

Как установить corezoid-git-context в Claude Code?

Добавьте маркетплейс командой /plugin marketplace add corezoid/corezoid-ai-plugin, затем установите плагин командой /plugin install corezoid@corezoid.

Что делает corezoid-git-context?

Скилл анализирует существенную сессию и обновляет документы активного этапа в _ext/docs/. Он фиксирует решения, зависимости, ограничения и проблемы, а перед записью показывает предлагаемые изменения.

Когда corezoid-git-context пропускает обновление?

Он не запускает обновление для чисто информационной сессии, где ничего не было развёрнуто и не произошло изменений из предусмотренных условий. Также нужен git_stage_path для текущего этапа.

Исходный текст

SKILL.md · MIT
---
name: corezoid-git-context
description: >
  Analyzes the current session and updates _ext/docs/*.md in the Corezoid git
  mirror for the active stage. Use after corezoid-edit, corezoid-create, or
  corezoid-review when the session was substantial (processes deployed, new
  external dependencies discovered, architectural decisions made, issues found
  or resolved). Activate when the user says "update context", "save context",
  "update docs", "push context", "зафіксуй контекст", "збережи контекст",
  "оновити документацію", "corezoid-git-context", or signals the session is
  wrapping up after real changes were made to Corezoid. Do NOT activate for
  purely informational sessions where nothing was deployed.
---

# Session Analysis — Update _ext/docs/*.md

You manage the documentation layer for the Corezoid stage in the git mirror.
Your only write surface is `_ext/docs/` inside the stage directory.
You use four operations: `read-context-file`, `update-context-file`,
`git-pull-context`, `git-push-context`.

---

## How to call these tools

Every operation in this skill is an **action of the single `cz-git-context` MCP tool** —
the individual names below are action strings, not tools of their own:

```
cz-git-context {"action": "read-context-file", "args": {"path": "_ext/docs/architecture.md"}}
```

Arguments always go inside `args`; the shorthand used below — `read-context-file(path=…)` — means exactly that call. When unsure about an action's
arguments, call `cz-git-context {"action": "<action>", "help": true}` — it returns the
full schema and runs nothing.

## Prerequisites — skip entirely if any condition is not met

Before doing anything, verify all of the following. If any check fails, log
one warning line and stop — do not continue to subsequent steps.

1. **Stage path known** — check whether the current Folder in
   `~/.corezoid/config.json` has `git_stage_path` set (`git-pull-context`
   populates it after the first successful mirror sync).
   - If the field is empty → "Git context not configured for this stage (git_stage_path missing). Skipping context update."
2. **Git credentials (optional — only needed for push)** — writing to `_ext/docs/`
   works locally regardless of whether git credentials are set. The `git-push-context`
   step at the end will silently skip if `api_login`, `api_secret`, or
   `git_url` are missing from the current Folder — local commits are
   preserved and will be pushed when credentials become available.
   - Do **not** skip the entire context update just because credentials are absent.
3. **Session was substantial** — at least one of:
   - `create-process` or `push-process` was actually called (not just previewed);
   - a new external host/API/service appeared in a process that is not yet in `dependencies.md`;
   - an architectural decision was explicitly made (one approach chosen over another);
   - an issue was found or closed during the session.
   - If none of the above → "Session was informational only. No context update needed."

---

## Step 1 — Sync git context

Call `git-pull-context` with no arguments. This ensures `.git-context/` is
up to date before reading or writing any files. If the tool returns an error,
stop and report: "Could not sync git context: {error}. Skipping update."

---

## Step 2 — Read the context files that exist

The `git-pull-context` result from Step 1 ends with two lines:

```
Stage path: projects/123_Foo/stages/456_Dev
Context docs (projects/123_Foo/stages/456_Dev/_ext/docs/): context.md, decisions.md — read only these; …
```

Use the `Stage path` value as `STAGE_PATH`, and the `Context docs` line as
the list of files that exist. **Do not probe the standard file set with
`read-context-file`** — a file not in that list does not exist, and reading it
only returns a "not found" error.

- **Files listed** → call `read-context-file` for each listed file
  (`{STAGE_PATH}/_ext/docs/{file}`), all in one parallel batch, before
  analysing — you need the full picture to avoid duplication and to detect
  which existing entries need updating. Treat every unlisted standard file as
  empty.
- **`none yet`** → first use of this stage: read nothing. All five files start
  empty; Step 3 decides which ones to create, and Step 5 creates them with
  `update-context-file` (`mode: replace`). Say so in Step 4 (`new file`).

The standard files are `context.md`, `invariants.md`, `decisions.md`,
`dependencies.md`, `issues.md`, all under `{STAGE_PATH}/_ext/docs/`.

---

## Step 3 — Classify: which files to touch and how

Analyse the session transcript and the Corezoid diff (what was
created/changed/deployed) against the current file contents.

Typically only 1–2 files need changes. Apply the following rules per file:

### context.md
**What it is:** living description of the stage's business purpose and role.
**When to touch:** only if the stage's purpose or role genuinely changed.
**How:** replace the relevant sentence/paragraph in place. Not a journal —
do not append. If the file is missing and there is clear new context to
record, create it.

### invariants.md
**What it is:** constraints that must never be violated.
**When to touch:** new invariant discovered, or existing one proved wrong.
**How:** replace in place. Never create an empty placeholder.

### decisions.md
**What it is:** ADR-style log of architectural decisions.
**When to touch:** a real architectural decision was made (chose approach A
over B, accepted a trade-off, chose a pattern).
**How:** append a new entry in this format:
```
## {Short title} — {YYYY-MM-DD}
**Decision:** {what was decided}
**Rationale:** {why}
**Alternatives rejected:** {what and why not}
```
If an older decision is now superseded, add `**Superseded by:** {new title}`
to the old entry — do not silently rewrite it.

### dependencies.md
**What it is:** external APIs, services, queues this stage integrates with.
**When to touch:** a new external host/service appeared in the session.
**How:** check existing entries first — if the same service is already listed,
do not add a duplicate. If genuinely new, append:
```
- **{ServiceName}** — {URL or endpoint pattern} — {what it's used for}
```

### issues.md
**What it is:** known problems, limitations, TODOs.
**When to touch:** new issue found, or existing issue resolved.
**How:**
- New issue → append:
  ```
  - [ ] {description} — found {YYYY-MM-DD}
  ```
- Resolved issue → find the matching open entry and mark it:
  ```
  - [x] {description} — found {date}, resolved {YYYY-MM-DD}
  ```
  Replace the existing line in-place using `mode: replace` on the full file
  content, do not append a duplicate.

---

## Step 4 — Unified diff and confirmation

**Before writing anything**, present the full planned changes to the user
as a single markdown block:

```
## Proposed context updates

### {filename}.md — {replace | append | new file}
{show the new content or the changed section clearly}

### {filename2}.md — ...
...
```

Then ask: **"Apply these context updates and push to git? (yes/no)"**

- If **yes** → proceed to Step 5.
- If **no** → "Context update skipped. Your Corezoid changes are already
  deployed and unaffected." Stop here.

---

## Step 5 — Write files and push

For each file that needs updating:

1. Call `update-context-file` with:
   - `path`: `{STAGE_PATH}/_ext/docs/{filename}.md`
   - `content`: the full new file content (for replace) or the text to append
   - `mode`: `replace` for context/invariants/issues (full rewrite or targeted
     replace); `append` for decisions/dependencies when adding a new entry

   If the file does not exist yet, `mode: replace` with the full content
   creates it — the directory structure is created automatically.

2. After **all** files are written, call the `git-push-context` action once with a
   meaningful commit message in `commit_message`, e.g.:

   ```
   cz-git-context {"action": "git-push-context",
                   "args": {"commit_message": "docs: update _ext/docs/ after session — {brief summary of what changed}"}}
   ```

   One push for the whole session, not one push per file.

---

## Error handling

| Situation | Action |
|-----------|--------|
| `read-context-file` returns "not found" | Treat as empty file, continue — and don't read further unlisted files |
| `update-context-file` returns error | Log warning, skip that file, continue with others |
| `git-push-context` returns error | Log warning, report to user: "Changes written locally but push failed: {error}. Run git-push-context manually when git is available." |
| No files needed updating | "Session analysed — no context updates needed." |

---

## What this skill never does

- Never writes to `CLAUDE.md` — that file is owned by the git mirror bot.
- Never touches files outside `_ext/docs/` (no `_ext/meta/`, no root files).
- Never creates empty/placeholder files — only writes when there is real content.
- Never pushes more than once per session invocation.
- Never blocks or rolls back the main Corezoid task — context update is always optional.

© Corezoid · MIT · corezoid/corezoid-ai-plugin

Похожие скиллы

Все скиллы по теме «Настройка агента: память, контекст, субагенты» →
git-context-controller davila7 Скилл git-context-controller организует память ассистента в виде версионируемой файловой структуры .GCC/. Он сохраняет контрольные точки проекта, ведёт ветки для экспериментов и восстанавливает контекст между сессиями. CX Codex +1 82установок Git Repository Analysis and Knowledge Base Construction oasiszeng Промпт Git Repository Analysis and Knowledge Base Construction анализирует историю коммитов и структуру GitHub-репозитория, собирая базу знаний для новичков. GP ChatGPT ★ 178 201звёзд репо git-workflow-and-versioning addyosmani Скилл git-workflow-and-versioning, который наводит порядок в git-процессе: атомарные коммиты, короткоживущие ветки, сообщения, объясняющие зачем, а не что. Включается при любом изменении кода, которое агент готовит к коммиту. CX Codex +1 75 700установок git-commit официальный github Доводит правки до коммита: читает диф, отбирает файлы, пишет сообщение по Conventional Commits и запускает git commit. CX Codex +1 47 165установок git-worktree-isolation sentimony Скилл git-worktree-isolation оценивает риски правок и подбирает безопасное рабочее пространство перед началом задач. Помогает избежать затирания чужого кода при параллельной работе агентов. CX Codex +1 2 300установок secrets-in-git-history UseOSINT Скилл secrets-in-git-history учит агента искать ключи, токены и адреса в истории git и на GitHub, а не только в текущем коде. CX Codex +1 1 900установок

Из того же набора30

Весь набор →
corezoid-describe Скилл corezoid-describe составляет и обновляет описания процессов, папок и проектов в Corezoid без изменения логики узлов. CX Codex +1 ★ 74звёзд репо corezoid-lifecycle Скилл corezoid-lifecycle ставит процессы Corezoid на паузу, снимает с паузы и перемещает процессы или папки по прямой команде пользователя. Без явного запроса не трогает статус или расположение объектов. CX Codex +1 ★ 74звёзд репо corezoid-retro Скилл corezoid-retro анализирует завершённую сессию работы с Corezoid, извлекает знания и сохраняет их как обновления в CLAUDE.md, отчёты команде и правила доступа. Каждая сессия делает следующую эффективнее. CX Codex +1 ★ 74звёзд репо corezoid-dashboard-manager Скилл corezoid-dashboard-manager управляет дашбордами в Corezoid через инструмент cz-dashboards. Привязывает графики к узлам запущенных процессов и рассчитывает счётчики задач. CX Codex +1 ★ 74звёзд репо plan-to-issues Скилл plan-to-issues превращает обсуждённый в чате план в набор структурированных задач GitHub: эпик и дочерние issues, сгруппированные по вехе и помеченные метками. CX Codex +1 ★ 74звёзд репо corezoid-state-diagram-edit Скилл corezoid-state-diagram-edit для модификации диаграмм состояний Corezoid в файлах .conv.json. Помогает настраивать состояния, условия переходов и побочные действия. CX Codex +1 ★ 74звёзд репо corezoid-node-layout Скилл corezoid-node-layout раскладывает узлы процесса Corezoid сверху вниз, вынося обработку ошибок вправо. Нужен перед отправкой нового процесса или по явному запросу. CX Codex +1 ★ 74звёзд репо corezoid-access Скилл corezoid-access для управления доступом к процессам, папкам и проектам в Corezoid. Позволяет делиться объектами с пользователями и группами, создавать API-ключи, приглашать внешних пользователей и аудировать, кто имеет доступ. CX Codex +1 ★ 74звёзд репо

Спонсоры проекта

Компании, которые помогают держать аналитику открытой