CCG is a command-line workflow engine that coordinates Claude, Codex, Gemini, and other models as specialized collaborators on coding tasks. It is used to analyze requests, choose a strategy, delegate work to model-specific roles, and combine their results. The catalogue entries provide the skills, commands, agents, and plugin that implement this workflow.
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.
git clone --depth 1 https://github.com/fengshao1227/ccg-workflowWrote 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.
[](https://agentmods.dev/commands/fengshao1227/ccg-workflow/context)<a href="https://agentmods.dev/commands/fengshao1227/ccg-workflow/context"><img src="https://agentmods.dev/badge/commands/fengshao1227/ccg-workflow/context/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/fengshao1227/ccg-workflow/context"><img src="https://agentmods.dev/badge/commands/fengshao1227/ccg-workflow/context.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00023 | $0.02482 |
| Opus 5.5 | $0.00009 | $0.00993 |
| Sonnet 5.5 | $0.00005 | $0.00496 |
| Haiku 4.5 | $0.00002 | $0.00248 |
Grade A, and why
context scanned grade A with 0 findings 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 1mo ago.
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.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
Copies of this mod
1 near-identical copy found in the catalogue:
- context — 100% identical, 0 lines differ
How it starts
The opening of the file, as written. The whole thing — 333 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Context - 项目上下文管理
管理 .context/ 目录结构,为 LLM 工具提供决策审计链。
使用方法
/context <subcommand> [options]
子命令
| 子命令 | 说明 |
|---|---|
init |
初始化 .context/ 目录结构 |
log <message> |
(可选)手动追加备注到 session.log,commit 时会合并 |
show |
查看当前分支的 session.log |
compress |
压缩 session.log → uncommit.md(手动预览用) |
history |
查看 history/commits.md |
squash <ids...> |
合并多条 history 记录(配合 git squash) |
核心用法:
init一次,之后只管开发。/ccg:commit提交时自动从 git diff 分析决策并归档到 history/。log仅在你想手动补充备注时使用。
执行工作流
子命令:init
[模式:初始化]
在当前项目根目录创建 .context/ 结构:
- 检测项目根目录(查找
.git/) - 若
.context/已存在,跳过已有文件,仅补全缺失 - 创建以下结构:
.context/
├── .gitignore
├── .gitattributes
├── prefs/
│ ├── coding-style.md
│ └── workflow.md
├── current/
│ └── branches/
│ └── .gitkeep
└── history/
├── commits.jsonl
├── commits.md
└── archives/
└── .gitkeep
- 创建
.context/.gitignore:
# Ephemeral workspace — never commit
current/
# Raw interaction logs — always local only
**/session.log
**/session.raw.log
**/*.session.log
**/*.raw.log
# Editor / temp
**/*.tmp
**/*.bak
**/*.swp
- 创建
.context/.gitattributes:
# JSONL append-only: 'union' merge reduces conflicts
history/commits.jsonl merge=union
history/archives/*.jsonl merge=union
- 创建
.context/prefs/coding-style.md(团队编码规范模板):
# Coding Style Guide
> 此文件定义团队编码规范,所有 LLM 工具在修改代码时必须遵守。
> 提交到 Git,团队共享。
## General
- Prefer small, reviewable changes; avoid unrelated refactors.
- Keep functions short (<50 lines); avoid deep nesting (≤3 levels).
- Name things explicitly; no single-letter variables except loop counters.
- Handle errors explicitly; never swallow errors silently.
## Language-Specific
<!-- 根据项目语言补充,例如:-->
<!-- ### TypeScript -->
<!-- - Use strict mode; prefer `interface` over `type` for object shapes. -->
## Git Commits
- Conventional Commits, imperative mood.
- Atomic commits: one logical change per commit.
## Testing
- Every feat/fix MUST include corresponding tests.
- Coverage must not decrease.
- Fix flow: write failing test FIRST, then fix code.
## Security
- Never log secrets (tokens/keys/cookies/JWT).
- Validate inputs at trust boundaries.
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.
- 1mo ago First seen · 333 lines · 23 tokens per session scan A 6f0773fbd632
context is a command published in the GitHub repository fengshao1227/ccg-workflow (5,945 stars, last pushed 4d ago), licensed MIT. It adds 23 tokens to every session and 2,482 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
brain-github-export
Export all accumulated brain knowledge as CONVENTIONS.md and open a GitHub Pull Request so your whole team can review what the AI team learned. Requires gh CLI to be installed and authenticated.
capture-memory
Capture learnings to MEMORY.md, output compact summary.
create-pr
Create a pull request (GitHub) or merge request (GitLab) from the current branch.
review-code
Read ALL memory bank code rules + best practices, check the files that changed, and APPLY fixes so they adhere. The active counterpart to /scan (which is read-only). Use after an AI session, before commit, to make changed files compliant.
reflect
Capture learnings from the current conversation through guided reflection.
analyze-git
Perform a comprehensive analysis of the git repository to identify branches and worktrees that can be cleaned up. This is a READ-ONLY analysis - no deletions will be performed.