@baoanaz/cviauto 0.6.6 → 0.6.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/dist/templates/claude/agents/trellis-check.md +61 -61
  2. package/dist/templates/claude/agents/trellis-implement.md +58 -58
  3. package/dist/templates/claude/agents/trellis-research.md +67 -67
  4. package/dist/templates/codebuddy/agents/trellis-check.md +61 -61
  5. package/dist/templates/codebuddy/agents/trellis-implement.md +58 -58
  6. package/dist/templates/codebuddy/agents/trellis-research.md +67 -67
  7. package/dist/templates/codex/agents/trellis-check.toml +99 -30
  8. package/dist/templates/codex/agents/trellis-implement.toml +99 -16
  9. package/dist/templates/codex/agents/trellis-research.toml +116 -39
  10. package/dist/templates/common/bundled-skills/trellis-channel/SKILL.md +41 -41
  11. package/dist/templates/common/bundled-skills/trellis-channel/references/command-reference.md +194 -261
  12. package/dist/templates/common/bundled-skills/trellis-channel/references/forum.md +59 -93
  13. package/dist/templates/common/bundled-skills/trellis-channel/references/progress-debugging.md +72 -110
  14. package/dist/templates/common/bundled-skills/trellis-channel/references/workers.md +120 -171
  15. package/dist/templates/common/bundled-skills/trellis-channel/references/workflows.md +35 -43
  16. package/dist/templates/common/bundled-skills/trellis-meta/SKILL.md +78 -78
  17. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/add-project-local-conventions.md +24 -24
  18. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-agents.md +29 -29
  19. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-context-loading.md +46 -46
  20. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-hooks.md +28 -28
  21. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-skills-or-commands.md +66 -66
  22. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-spec-structure.md +32 -32
  23. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-task-lifecycle.md +40 -40
  24. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-workflow.md +40 -40
  25. package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/overview.md +44 -44
  26. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/bundled-skills.md +79 -79
  27. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/context-injection.md +37 -37
  28. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/generated-files.md +43 -43
  29. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/multi-agent-channel.md +47 -47
  30. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/overview.md +40 -40
  31. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/spec-system.md +33 -33
  32. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/task-system.md +61 -61
  33. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/workflow.md +41 -41
  34. package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/workspace-memory.md +31 -31
  35. package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/agents.md +40 -40
  36. package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/hooks-and-settings.md +40 -41
  37. package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/overview.md +36 -36
  38. package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/platform-map.md +36 -38
  39. package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/skills-and-commands.md +52 -52
  40. package/dist/templates/common/bundled-skills/trellis-session-insight/SKILL.md +45 -45
  41. package/dist/templates/common/bundled-skills/trellis-session-insight/references/cli-quick-reference.md +41 -42
  42. package/dist/templates/common/bundled-skills/trellis-session-insight/references/triggering-patterns.md +28 -28
  43. package/dist/templates/common/bundled-skills/trellis-spec-bootstrap/SKILL.md +30 -30
  44. package/dist/templates/common/bundled-skills/trellis-spec-bootstrap/references/mcp-setup.md +34 -34
  45. package/dist/templates/common/bundled-skills/trellis-spec-bootstrap/references/repository-analysis.md +30 -30
  46. package/dist/templates/common/bundled-skills/trellis-spec-bootstrap/references/spec-task-planning.md +39 -39
  47. package/dist/templates/common/bundled-skills/trellis-spec-bootstrap/references/spec-writing.md +40 -40
  48. package/dist/templates/common/commands/continue.md +28 -29
  49. package/dist/templates/common/commands/finish-work.md +32 -40
  50. package/dist/templates/cursor/agents/trellis-check.md +61 -61
  51. package/dist/templates/cursor/agents/trellis-implement.md +58 -58
  52. package/dist/templates/cursor/agents/trellis-research.md +67 -67
  53. package/dist/templates/droid/droids/trellis-check.md +64 -56
  54. package/dist/templates/droid/droids/trellis-implement.md +61 -53
  55. package/dist/templates/droid/droids/trellis-research.md +67 -67
  56. package/dist/templates/gemini/agents/trellis-check.md +64 -57
  57. package/dist/templates/gemini/agents/trellis-implement.md +61 -54
  58. package/dist/templates/gemini/agents/trellis-research.md +67 -67
  59. package/dist/templates/kiro/agents/trellis-check.json +15 -3
  60. package/dist/templates/kiro/agents/trellis-implement.json +15 -3
  61. package/dist/templates/kiro/agents/trellis-research.json +10 -2
  62. package/dist/templates/kiro/agents/trellis.json +19 -5
  63. package/dist/templates/opencode/agents/trellis-check.md +61 -61
  64. package/dist/templates/opencode/agents/trellis-implement.md +58 -59
  65. package/dist/templates/opencode/agents/trellis-research.md +67 -67
  66. package/dist/templates/pi/agents/trellis-check.md +99 -21
  67. package/dist/templates/pi/agents/trellis-implement.md +90 -22
  68. package/dist/templates/pi/agents/trellis-research.md +124 -12
  69. package/dist/templates/qoder/agents/trellis-check.md +64 -57
  70. package/dist/templates/qoder/agents/trellis-implement.md +61 -54
  71. package/dist/templates/qoder/agents/trellis-research.md +67 -67
  72. package/dist/templates/trae/agents/trellis-check.md +64 -57
  73. package/dist/templates/trae/agents/trellis-implement.md +61 -54
  74. package/dist/templates/trae/agents/trellis-research.md +67 -67
  75. package/dist/templates/trellis/agents/check.md +29 -29
  76. package/dist/templates/trellis/agents/implement.md +30 -30
  77. package/dist/templates/trellis/workflow.md +349 -356
  78. package/dist/templates/zcode/agents/trellis-check.md +64 -51
  79. package/dist/templates/zcode/agents/trellis-implement.md +61 -53
  80. package/package.json +2 -2
@@ -1,34 +1,33 @@
1
- # Platform File Map
1
+ # Platform File Map(平台文件映射)
2
2
 
3
- This page lists common Cviauto file locations in a user project by platform. Whether a platform directory exists in an actual project depends on which `cviauto init --<platform>` commands the user ran.
3
+ 本页列出了各平台在用户项目中的常见 Cviauto 文件位置。实际项目中是否存在某个平台目录,取决于用户运行了哪些 `cviauto init --<platform>` 命令。
4
4
 
5
- ## Matrix
5
+ ## Matrix(矩阵)
6
6
 
7
- | Platform | CLI flag | Main directory | Skill directory | Agent directory | Hooks/extensions |
7
+ | Platform(平台) | CLI flag(CLI 标志) | Main directory(主目录) | Skill directory(技能目录) | Agent directory(代理目录) | Hooks/extensions(钩子/扩展) |
8
8
  | --- | --- | --- | --- | --- | --- |
9
9
  | Claude Code | `--claude` | `.claude/` | `.claude/skills/` | `.claude/agents/` | `.claude/hooks/` + `.claude/settings.json` |
10
10
  | Cursor | `--cursor` | `.cursor/` | `.cursor/skills/` | `.cursor/agents/` | `.cursor/hooks.json` + `.cursor/hooks/` |
11
11
  | OpenCode | `--opencode` | `.opencode/` | `.opencode/skills/` | `.opencode/agents/` | `.opencode/plugins/` |
12
12
  | Codex | `--codex` | `.codex/` | `.agents/skills/` | `.codex/agents/` | `.codex/hooks/` + `.codex/hooks.json` |
13
- | Kilo | `--kilo` | `.kilocode/` | `.kilocode/skills/` | Usually none | `.kilocode/workflows/` |
13
+ | Kilo | `--kilo` | `.kilocode/` | `.kilocode/skills/` | 通常无 | `.kilocode/workflows/` |
14
14
  | Kiro | `--kiro` | `.kiro/` | `.kiro/skills/` | `.kiro/agents/` | `.kiro/hooks/` |
15
15
  | Gemini CLI | `--gemini` | `.gemini/` | `.agents/skills/` | `.gemini/agents/` | `.gemini/settings.json` + `.gemini/hooks/` |
16
- | Antigravity | `--antigravity` | `.agent/` | `.agent/skills/` | Usually none | `.agent/workflows/` |
17
- | Devin | `--devin` | `.devin/` | `.devin/skills/` | Usually none | `.devin/workflows/` |
16
+ | Antigravity | `--antigravity` | `.agent/` | `.agent/skills/` | 通常无 | `.agent/workflows/` |
17
+ | Devin | `--devin` | `.devin/` | `.devin/skills/` | 通常无 | `.devin/workflows/` |
18
18
  | Qoder | `--qoder` | `.qoder/` | `.qoder/skills/` | `.qoder/agents/` | `.qoder/hooks/` + `.qoder/settings.json` |
19
19
  | CodeBuddy | `--codebuddy` | `.codebuddy/` | `.codebuddy/skills/` | `.codebuddy/agents/` | `.codebuddy/hooks/` + `.codebuddy/settings.json` |
20
20
  | GitHub Copilot | `--copilot` | `.github/` | `.github/skills/` | `.github/agents/` | `.github/copilot/hooks/` + prompts |
21
21
  | Factory Droid | `--droid` | `.factory/` | `.factory/skills/` | `.factory/droids/` | `.factory/hooks/` + settings |
22
- | Pi Agent | `--pi` | `.pi/` | `.pi/skills/` | `.pi/agents/` | `.pi/extensions/trellis/` (native `trellis_subagent` tool) + `.pi/settings.json` |
23
- | Trae IDE | `--trae` | `.trae/` | `.trae/skills/` | `.trae/agents/` | `.trae/hooks/` + `.trae/hooks.json` |
24
- | Reasonix | `--reasonix` | `.reasonix/` | `.reasonix/skills/` | None sub-agents are skills with `runAs: subagent` frontmatter | None |
25
- | ZCode | `--zcode` | `.zcode/` | `.agents/skills/` | `.zcode/cli/agents/` | pull-based prelude (no hooks) |
22
+ | Pi Agent | `--pi` | `.pi/` | `.pi/skills/` | `.pi/agents/` | `.pi/extensions/cviauto/`(原生 `trellis_subagent` 工具) + `.pi/settings.json` |
23
+ | Reasonix | `--reasonix` | `.reasonix/` | `.reasonix/skills/` | sub-agent 是带有 `runAs: subagent` 前置元数据的 skills | 无 |
24
+ | ZCode | `--zcode` | `.zcode/` | `.agents/skills/` | `.zcode/cli/agents/` | pull-based prelude(拉取模式序言,无 hooks) |
26
25
 
27
- ## Capability Groups
26
+ ## Capability Groups(能力分组)
28
27
 
29
- ### Cviauto Sub-Agent Support
28
+ ### Cviauto Sub-Agent Support(Cviauto Sub-Agent 支持)
30
29
 
31
- These platforms usually have `cviauto-research`, `cviauto-implement`, and `cviauto-check` files:
30
+ 以下平台通常有 `cviauto-research`、`cviauto-implement` `cviauto-check` 文件:
32
31
 
33
32
  - Claude Code
34
33
  - Cursor
@@ -41,48 +40,47 @@ These platforms usually have `cviauto-research`, `cviauto-implement`, and `cviau
41
40
  - GitHub Copilot
42
41
  - Factory Droid
43
42
  - Pi Agent
44
- - Trae IDE
45
- - Reasonix (delivered as skills with `runAs: subagent` under `.reasonix/skills/`, not as a separate `agents/` directory)
43
+ - Reasonix(以带有 `runAs: subagent` 的 skills 形式交付,位于 `.reasonix/skills/` 下,而非独立的 `agents/` 目录)
46
44
  - ZCode
47
45
 
48
- When changing implementation/check/research behavior, look for the corresponding platform agent files first.
46
+ 更改 implementation/check/research 行为时,请先查找对应平台的 agent 文件。
49
47
 
50
- ### Native Cviauto Sub-Agent Tool
48
+ ### Native Cviauto Sub-Agent Tool(原生 Cviauto Sub-Agent 工具)
51
49
 
52
- Some platforms expose a first-class tool that the host runtime understands. The model calls it like any other tool and the host renders progress cards, validates the agent name against `.<platform>/agents/`, and enforces dispatch modes.
50
+ 某些平台暴露了一个宿主运行时理解的一级工具。模型像调用其他工具一样调用它,宿主渲染进度卡片、根据 `.<platform>/agents/` 验证 agent 名称,并强制执行分发模式。
53
51
 
54
- - Pi Agent — `trellis_subagent` tool, defined in `.pi/extensions/trellis/index.ts`. Supports `single` / `parallel` / `chain` dispatch modes and emits live `trellis-subagent-progress` events.
52
+ - Pi Agent — `trellis_subagent` 工具,定义在 `.pi/extensions/cviauto/index.ts`。支持 `single` / `parallel` / `chain` 分发模式,并发出实时的 `cviauto-subagent-progress` 事件。
55
53
 
56
- When changing sub-agent dispatch behavior on these platforms, edit the extension file, **not** the agent markdown the agent markdown defines responsibilities, but the host extension owns dispatch, validation, and progress rendering.
54
+ 在这些平台上更改 sub-agent 分发行为时,请编辑扩展文件,**而非** agent markdown 文件 — agent markdown 定义职责,但宿主扩展负责分发、验证和进度渲染。
57
55
 
58
- ### Main-Session Workflow Platforms
56
+ ### Main-Session Workflow Platforms(主会话工作流平台)
59
57
 
60
- These platforms rely more on workflows/skills to guide the main session:
58
+ 以下平台更依赖 workflows/skills 来引导主会话:
61
59
 
62
60
  - Kilo
63
61
  - Antigravity
64
62
  - Devin
65
63
 
66
- When changing behavior, inspect workflows and skills first. Do not assume Cviauto sub-agents exist.
64
+ 更改行为时,请先检查 workflows skills。不要假设存在 Cviauto sub-agent。
67
65
 
68
- ### Shared `.agents/skills/`
66
+ ### Shared `.agents/skills/`(共享 `.agents/skills/`)
69
67
 
70
- Codex writes the shared `.agents/skills/` layer. Some tools that support agentskills.io can also read this directory. If the user wants multiple compatible tools to share one skill, consider `.agents/skills/` first, but do not assume every platform reads it.
68
+ Codex 写入共享的 `.agents/skills/` 层。某些支持 agentskills.io 的工具也可以读取此目录。如果用户希望多个兼容工具共享一个 skill,可优先考虑 `.agents/skills/`,但不要假设每个平台都会读取它。
71
69
 
72
- ## Decision Rules When Modifying Platform Files
70
+ ## Decision Rules When Modifying Platform Files(修改平台文件时的决策规则)
73
71
 
74
- 1. User specified a platform: modify only that platform directory unless shared workflow/spec files must also change.
75
- 2. User says "all platforms should do this": synchronize equivalent entry points platform by platform; do not modify only one directory.
76
- 3. User only says "my AI": inspect the configuration directories that actually exist in the project and infer the current AI platform.
77
- 4. User wants project rules: prefer `.cviauto/spec/` or a project-local skill.
78
- 5. User wants Cviauto behavior: edit `.cviauto/workflow.md` plus platform hooks/agents/skills/commands.
72
+ 1. 用户指定了平台:仅修改该平台目录,除非共享的 workflow/spec 文件也必须更改。
73
+ 2. 用户说"所有平台都应该这样做":逐平台同步等效入口点;不要只修改一个目录。
74
+ 3. 用户只说"我的 AI":检查项目中实际存在的配置目录,推断当前 AI 平台。
75
+ 4. 用户想要项目规则:优先使用 `.cviauto/spec/` 或项目本地 skill
76
+ 5. 用户想要 Cviauto 行为:编辑 `.cviauto/workflow.md` 以及平台 hooks/agents/skills/commands
79
77
 
80
- ## When Paths Differ
78
+ ## When Paths Differ(当路径不一致时)
81
79
 
82
- Platform ecosystems change, and user projects may already be customized. If this table disagrees with local files, use the actual settings/config in the user project as authoritative:
80
+ 平台生态会变化,用户项目可能已经自定义过。如果此表与本地文件不一致,请以用户项目中实际的 settings/config 为准:
83
81
 
84
- - Check the hook that settings registers.
85
- - Check the script that a command/prompt/workflow points to.
86
- - Judge behavior by the read rules currently written in the agent file.
82
+ - 检查 settings 注册的 hook
83
+ - 检查 command/prompt/workflow 指向的脚本。
84
+ - 根据 agent 文件中当前编写的读取规则判断行为。
87
85
 
88
- Do not delete a custom file just because it is not listed in this path table.
86
+ 不要仅因为某个自定义文件不在本路径表中就将其删除。
@@ -1,44 +1,44 @@
1
- # Skills, Commands, Prompts, And Workflows
1
+ # Skills(技能)、Commands(命令)、Prompts(提示)与 Workflows(工作流)
2
2
 
3
- Skills and commands are textual entry points for user interaction with Cviauto. Different platforms use different names, but their core purpose is the same: tell the AI how to enter the Cviauto flow when the user expresses a certain intent.
3
+ Skills commands 是用户与 Cviauto 交互的文本入口。不同平台使用不同的名称,但它们的核心目的相同:告诉 AI 在用户表达特定意图时如何进入 Cviauto 流程。
4
4
 
5
- ## Conceptual Differences
5
+ ## 概念差异
6
6
 
7
- | Type | Trigger mode | Best for |
7
+ | 类型 | 触发方式 | 最适合 |
8
8
  | --- | --- | --- |
9
- | skill | AI auto-match or explicit user mention | Long-term capabilities, workflow rules, modification guides. |
10
- | command | Explicit user invocation | Clear operation entry points such as continue and finish-work. |
11
- | prompt | Explicit user invocation or platform selection | Similar to command, but in a platform prompt format. |
12
- | workflow | Explicit user selection or platform auto-match | Guides the main session when no sub-agent/hook exists. |
9
+ | skill | AI 自动匹配或用户显式提及 | 长期能力、工作流规则、修改指南。 |
10
+ | command | 用户显式调用 | 明确的操作入口,如 continuefinish-work |
11
+ | prompt | 用户显式调用或平台选择 | command 类似,但采用平台 prompt 格式。 |
12
+ | workflow | 用户显式选择或平台自动匹配 | 在无子代理/钩子时引导主会话。 |
13
13
 
14
- Cviauto workflow skills usually share one semantic set: brainstorm, before-dev, check, update-spec, break-loop. Multi-file built-in skills such as `cviauto-meta` use layered references.
14
+ Cviauto 工作流技能通常共享一套语义集合:brainstormbefore-devcheckupdate-specbreak-loop。多文件内置技能如 `cviauto-meta` 使用分层引用。
15
15
 
16
- ## Common Paths
16
+ ## 常见路径
17
17
 
18
- | Platform | Common entries |
18
+ | 平台 | 常见入口 |
19
19
  | --- | --- |
20
- | Claude Code | `.claude/skills/`, `.claude/commands/` |
21
- | Cursor | `.cursor/skills/`, `.cursor/commands/` |
22
- | OpenCode | `.opencode/skills/`, `.opencode/commands/` |
23
- | Codex | `.agents/skills/`, `.codex/skills/` |
24
- | Kilo | `.kilocode/skills/`, `.kilocode/workflows/` |
20
+ | Claude Code | `.claude/skills/`、`.claude/commands/` |
21
+ | Cursor | `.cursor/skills/`、`.cursor/commands/` |
22
+ | OpenCode | `.opencode/skills/`、`.opencode/commands/` |
23
+ | Codex | `.agents/skills/`、`.codex/skills/` |
24
+ | Kilo | `.kilocode/skills/`、`.kilocode/workflows/` |
25
25
  | Kiro | `.kiro/skills/` |
26
- | Gemini CLI | `.agents/skills/`, `.gemini/commands/` |
27
- | Antigravity | `.agent/skills/`, `.agent/workflows/` |
28
- | Devin | `.devin/skills/`, `.devin/workflows/` |
29
- | Qoder | `.qoder/skills/`, `.qoder/commands/` |
30
- | CodeBuddy | `.codebuddy/skills/`, `.codebuddy/commands/` |
31
- | GitHub Copilot | `.github/skills/`, `.github/prompts/` |
32
- | Factory Droid | `.factory/skills/`, `.factory/commands/` |
26
+ | Gemini CLI | `.agents/skills/`、`.gemini/commands/` |
27
+ | Antigravity | `.agent/skills/`、`.agent/workflows/` |
28
+ | Devin | `.devin/skills/`、`.devin/workflows/` |
29
+ | Qoder | `.qoder/skills/`、`.qoder/commands/` |
30
+ | CodeBuddy | `.codebuddy/skills/`、`.codebuddy/commands/` |
31
+ | GitHub Copilot | `.github/skills/`、`.github/prompts/` |
32
+ | Factory Droid | `.factory/skills/`、`.factory/commands/` |
33
33
  | Pi Agent | `.pi/skills/` |
34
34
  | Reasonix | `.reasonix/skills/` |
35
- | ZCode | `.agents/skills/`, `.zcode/commands/` |
35
+ | ZCode | `.agents/skills/`、`.zcode/commands/` |
36
36
 
37
- In a user project, use the files actually generated by init as authoritative.
37
+ 在用户项目中,以 `init` 实际生成的文件为准。
38
38
 
39
- ## Skill Structure
39
+ ## Skill 结构
40
40
 
41
- A common skill is a directory:
41
+ 一个常见的 skill 是一个目录:
42
42
 
43
43
  ```text
44
44
  cviauto-meta/
@@ -46,40 +46,40 @@ cviauto-meta/
46
46
  └── references/
47
47
  ```
48
48
 
49
- `SKILL.md` should tell the AI:
49
+ `SKILL.md` 应告诉 AI
50
50
 
51
- - When to use this skill.
52
- - Which reference to read first for the current task.
53
- - What not to do.
51
+ - 何时使用此技能。
52
+ - 当前任务应首先阅读哪个参考文件。
53
+ - 不应做什么。
54
54
 
55
- References hold longer explanations so the entry file does not contain everything.
55
+ references 存放较长的说明,使入口文件不必包含所有内容。
56
56
 
57
- ## Command/Prompt/Workflow Structure
57
+ ## Command/Prompt/Workflow 结构
58
58
 
59
- Commands, prompts, and workflows are usually single files. Their content should include:
59
+ Commandsprompts workflows 通常是单个文件。其内容应包括:
60
60
 
61
- - When to use it.
62
- - Which `.cviauto/` files to read.
63
- - Which scripts to run.
64
- - How to report after completion.
61
+ - 何时使用。
62
+ - 要读取哪些 `.cviauto/` 文件。
63
+ - 要运行哪些脚本。
64
+ - 完成后如何报告。
65
65
 
66
- They should not store task state; task state belongs in `.cviauto/tasks/` and `.cviauto/.runtime/`.
66
+ 它们不应存储任务状态;任务状态属于 `.cviauto/tasks/` `.cviauto/.runtime/`。
67
67
 
68
- ## Local Change Scenarios
68
+ ## 本地修改场景
69
69
 
70
- | User need | Edit location |
70
+ | 用户需求 | 编辑位置 |
71
71
  | --- | --- |
72
- | Change AI auto-trigger rules | The corresponding skill's frontmatter description. |
73
- | Change user command behavior | The corresponding command/prompt/workflow file. |
74
- | Add a project-local skill | Platform skill directory, or shared `.agents/skills/`. |
75
- | Let multiple platforms share one capability | Write equivalent skills in each platform skill directory, or use the `.agents/skills/` shared layer on platforms that support it. |
76
- | Change finish/continue entry points | Platform commands/prompts/workflows. |
72
+ | 修改 AI 自动触发规则 | 对应 skill frontmatter 描述。 |
73
+ | 修改用户命令行为 | 对应的 command/prompt/workflow 文件。 |
74
+ | 添加项目本地 skill | 平台 skill 目录,或共享的 `.agents/skills/`。 |
75
+ | 让多个平台共享一个能力 | 在各平台 skill 目录中编写等效 skill,或在支持 `.agents/skills/` 共享层的平台上使用该层。 |
76
+ | 修改 finish/continue 入口 | 平台的 commands/prompts/workflows |
77
77
 
78
- ## Modification Principles
78
+ ## 修改原则
79
79
 
80
- 1. **Keep entry files short; references carry long content**. This matters especially for multi-file skills like `cviauto-meta`.
81
- 2. **Make trigger descriptions specific**. A description that is too broad can mis-trigger; one that is too narrow may not trigger.
82
- 3. **Keep the same semantics consistent across platforms**. File formats can differ, but behavior descriptions should match.
83
- 4. **Put project-specific capabilities in local skills**. Do not put team-private flows into public `cviauto-meta`.
80
+ 1. **保持入口文件简短;references 承载长内容**。这对 `cviauto-meta` 等多文件技能尤为重要。
81
+ 2. **让触发描述具体明确**。过于宽泛的描述可能误触发;过于狭窄可能无法触发。
82
+ 3. **跨平台保持语义一致**。文件格式可以不同,但行为描述应匹配。
83
+ 4. **将项目特定能力放在本地 skill 中**。不要将团队私有流程放入公共 `cviauto-meta`。
84
84
 
85
- If the user only wants local AI to know one more project rule, usually create a project-local skill or update `.cviauto/spec/` instead of changing a Cviauto built-in workflow skill.
85
+ 如果用户只想让本地 AI 多了解一条项目规则,通常应创建项目本地 skill 或更新 `.cviauto/spec/`,而不是修改 Cviauto 内置工作流技能。
@@ -3,79 +3,79 @@ name: cviauto-session-insight
3
3
  description: "Reach into past AI conversation history through the `cviauto mem` CLI. Use whenever the user asks 'how did we solve X last time', 'have we discussed this before', 'what was the decision on X', 'remind me what we did in this task', '上次怎么解的', '之前讨论过吗', '想起一段对话', or when starting a brainstorm that overlaps prior work, debugging a familiar bug, continuing a task across sessions, or doing a finish-work review. Returns raw past dialogue; decide for the moment whether to update spec, append to task notes, quote inline in the answer, or just internalize."
4
4
  ---
5
5
 
6
- # Cviauto Session Insight
6
+ # Cviauto 会话洞察
7
7
 
8
- This skill teaches an AI **how to call `cviauto mem`** — the project's cross-session memory feedstock — and **when reaching for it is the right move**.
8
+ 此技能教 AI **如何调用 `cviauto mem`**——项目的跨会话记忆原料——以及**何时使用它是正确的选择**。
9
9
 
10
- It is intentionally a **capability skill, not a workflow**. There is no fixed output file, no required write-back step, no "always run after finish-work" rule. What to do with what `mem` returns is a judgement call made in the moment of the conversation. The skill exists so the AI knows the capability is there and can decide.
10
+ 它有意设计为**能力技能,而非工作流**。没有固定的输出文件,没有必需的写回步骤,没有"始终在 finish-work 后运行"的规则。如何处理 `mem` 返回的内容是在对话当下做出的判断。此技能的存在是为了让 AI 知道这个能力的存在并可以自行决定。
11
11
 
12
- ## What `cviauto mem` is
12
+ ## `cviauto mem` 是什么
13
13
 
14
- A local CLI that indexes the user's past Claude Code, Codex, and Pi Agent conversation logs (the JSONL files each platform stores under `~/.claude/projects/`, `~/.codex/sessions/`, and `~/.pi/agent/sessions/`) and lets you list, search, slice by Cviauto task boundaries, and dump cleaned dialogue from them. OpenCode logs are not yet indexable (provider adapter pending) — when an OpenCode session is the obvious target, surface that limitation rather than guessing.
14
+ 一个本地 CLI,索引用户过去的 Claude CodeCodex Pi Agent 对话日志(每个平台存储在 `~/.claude/projects/`、`~/.codex/sessions/` `~/.pi/agent/sessions/` 下的 JSONL 文件),并允许你列出、搜索、按 Cviauto 任务边界切片,以及从中导出清洗后的对话内容。OpenCode 日志尚不可索引(provider adapter 待完成)——当 OpenCode 会话是明显目标时,应说明此限制而非猜测。
15
15
 
16
- Nothing in `mem` is uploaded. All reads are local.
16
+ `mem` 中的任何内容都不会上传。所有读取都在本地。
17
17
 
18
- ## When to reach for it
18
+ ## 何时使用它
19
19
 
20
- The bar is "would a senior teammate ask 'didn't we already talk about this?'" — those are the moments. Some concrete patterns:
20
+ 标准是"资深同事会不会问'我们不是已经讨论过这个了吗?'"——那些就是使用的时刻。一些具体模式:
21
21
 
22
- - **Brainstorm rerun risk.** Starting a new task that touches an area the user has been in before, and you want to check whether a decision was already made — before re-asking the user.
23
- - **Familiar-bug debugging.** The current bug pattern feels like one the user reported / fixed before. Pulling the relevant past session can save a full debugging loop.
24
- - **Cross-session continuation.** The user resumes work after a gap and says "where were we" / "继续上次的" without being specific.
25
- - **Decision retrieval.** The user references "the decision we made about X" but the decision lives in an old brainstorm, not in any `prd.md` / `spec/`.
26
- - **Finish-work retrospective.** When the user explicitly asks for a wrap-up of what was decided / what hurt / what surprised them in this task — not as a forced step on every finish-work.
27
- - **Pattern-spotting across past work.** The user asks "do I keep making the same mistake on X" / "我每次都踩这个坑吗" — search across sessions answers that.
22
+ - **Brainstorm 重复风险。** 开始一个涉及用户之前接触过的领域的新任务时,你想在重新询问用户之前检查是否已经做过决定。
23
+ - **熟悉的 bug 调试。** 当前的 bug 模式感觉像是用户之前报告/修复过的。拉取相关的过往会话可以节省整个调试循环。
24
+ - **跨会话续接。** 用户在中断后恢复工作,说"我们上次做到哪了"/"继续上次的",但没有具体说明。
25
+ - **决策检索。** 用户提到"我们关于 X 做的决定",但该决定存在于旧的 brainstorm 中,而非任何 `prd.md` / `spec/` 中。
26
+ - **Finish-work 回顾。** 当用户明确要求总结此任务中决定了什么/什么令人痛苦/什么令人惊讶——不是每次 finish-work 的强制步骤。
27
+ - **跨过往工作的模式发现。** 用户问"我是不是一直在犯同样的 X 错误"/"我每次都踩这个坑吗"——跨会话搜索可以回答。
28
28
 
29
- If none of these apply, don't call `mem`. It is a tool, not a ceremony.
29
+ 如果以上都不适用,不要调用 `mem`。它是一个工具,不是仪式。
30
30
 
31
- ## When NOT to reach for it
31
+ ## 何时不使用它
32
32
 
33
- - The relevant context is already in the current turn, `prd.md`, `design.md`, recent `git log`, or the open files. `mem` is for stuff that has fallen out of immediate reach.
34
- - The user is asking about a fact in the code, not a fact from a past conversation. `git log -p` / `grep` / reading the file directly is faster and more authoritative.
35
- - You are in a sub-agent (`cviauto-implement` / `cviauto-check`) whose dispatch prompt already includes the curated `implement.jsonl` / `check.jsonl` context. Adding `mem` on top usually just clutters.
36
- - The user has explicitly said "don't dig through history, just answer what I asked".
33
+ - 相关上下文已经在当前轮次、`prd.md`、`design.md`、最近的 `git log` 或打开的文件中。`mem` 用于已经脱离即时范围的内容。
34
+ - 用户问的是代码中的事实,而非过往对话中的事实。`git log -p` / `grep` / 直接读文件更快且更权威。
35
+ - 你在 sub-agent(`cviauto-implement` / `cviauto-check`)中,其分发 prompt 已包含整理好的 `implement.jsonl` / `check.jsonl` 上下文。在此基础上加 `mem` 通常只会增加杂乱。
36
+ - 用户明确表示"不要翻历史,按我问的回答"
37
37
 
38
- ## What to do with what `mem` returns
38
+ ## 如何处理 `mem` 返回的内容
39
39
 
40
- Treat the output as **raw material**, not a deliverable. Once you have it, decide based on the live conversation:
40
+ 将输出视为**原材料**,而非交付物。获得之后,根据实时对话决定:
41
41
 
42
- - **Quote inline in your reply** if a specific past exchange answers the user's current question — and cite the session-id / phase so the user can verify.
43
- - **Update `<task>/prd.md` or `<task>/design.md`** if `mem` surfaced a load-bearing decision that should have been written down but wasn't. Surface the proposed edit to the user first.
44
- - **Append to a task-local notes file** (e.g. `<task>/notes.md` or extending an existing one) if the finding belongs to the current task's record but doesn't fit the PRD.
45
- - **Update `.cviauto/spec/`** if the finding is a project-wide convention or gotcha that would help future tasks. Run the `cviauto-update-spec` skill for that — `session-insight` ends at the discovery.
46
- - **Just absorb it** for the next few turns and answer better, without writing anything. This is often the right move for one-off recall.
42
+ - **在你的回复中内联引用**,如果具体的过往交流能回答用户当前的问题——并引用 session-id / phase 以便用户验证。
43
+ - **更新 `<task>/prd.md` `<task>/design.md`**,如果 `mem` 发现了一个应当被记录但未记录的关键决策。先向用户展示建议的编辑。
44
+ - **追加到任务本地笔记文件**(如 `<task>/notes.md` 或扩展现有文件),如果发现的内容属于当前任务记录但不适合放入 PRD
45
+ - **更新 `.cviauto/spec/`**,如果发现的是项目级约定或陷阱,会对未来任务有帮助。运行 `cviauto-update-spec` 技能来处理——`session-insight` 止步于发现。
46
+ - **仅吸收**,在接下来的几轮中更好地回答,而不写入任何内容。这对一次性回忆通常是正确的做法。
47
47
 
48
- Cviauto does not prescribe a single destination. Forcing every recall into a fixed file makes the file grow into noise. Let the situation decide.
48
+ Cviauto 不规定单一目的地。把每次回忆强制写入固定文件会让文件膨胀成噪音。让情境决定。
49
49
 
50
- ## How to call it
50
+ ## 如何调用
51
51
 
52
- Full CLI reference is in `references/cli-quick-reference.md`. The 80% case is one of:
52
+ 完整 CLI 参考在 `references/cli-quick-reference.md`。80% 的情况是以下之一:
53
53
 
54
54
  ```bash
55
- # Find sessions whose contents mention a keyword (project-scope is default;
56
- # add --global to search every project on this machine).
57
- cviauto mem search "<keyword>"
55
+ # 查找内容包含关键词的会话(project-scope 是默认;
56
+ # 添加 --global 搜索此机器上的所有项目)。
57
+ cviauto mem search "<关键词>"
58
58
 
59
- # Dump dialogue from one session, optionally filtered by phase or keyword.
59
+ # 导出一个会话的对话内容,可选按阶段或关键词过滤。
60
60
  cviauto mem extract <session-id> --phase brainstorm
61
- cviauto mem extract <session-id> --grep "<keyword>"
61
+ cviauto mem extract <session-id> --grep "<关键词>"
62
62
 
63
- # Drill into a session: top-N hit turns + surrounding context.
63
+ # 深入一个会话:top-N 命中轮次 + 周围上下文。
64
64
  cviauto mem context <session-id> --turns 3 --around 2
65
65
 
66
- # When you do not know the session id yet, start with list + filter.
66
+ # 当还不知道 session id 时,从 list + filter 开始。
67
67
  cviauto mem list --cwd <project-path>
68
- cviauto mem projects # → list active project cwds, then narrow
68
+ cviauto mem projects # → 列出活动项目 cwd,然后缩小范围
69
69
  ```
70
70
 
71
- Phase slicing (`--phase brainstorm|implement|all`) cuts the session at `task.py create` and `task.py start` boundaries. For a finish-work review of the current task, `--phase brainstorm` recovers the planning discussion and `--phase implement` recovers the execution loop. Default is `all`.
71
+ 阶段切片(`--phase brainstorm|implement|all`)在 `task.py create` `task.py start` 边界处切割会话。对当前任务的 finish-work 回顾,`--phase brainstorm` 恢复规划讨论,`--phase implement` 恢复执行循环。默认为 `all`。
72
72
 
73
- ## Triggering patterns
73
+ ## 触发模式
74
74
 
75
- `references/triggering-patterns.md` lists more verbatim user phrasings (English + Chinese) that should make you think "reach for `mem`" keep that handy when training instinct.
75
+ `references/triggering-patterns.md` 列出了更多应当让你想到"使用 `mem`"的逐字用户表述(英文 + 中文)——在训练直觉时随时参考。
76
76
 
77
- ## Out of scope
77
+ ## 超出范围
78
78
 
79
- - `mem` does not edit code or update files. Any write-back is your decision in the moment.
80
- - `mem` is read-only on the platform JSONL stores. It does not push or sync to remote.
81
- - This skill does not replace `cviauto-update-spec` (which is the right tool for promoting a finding into project-wide guidance) or the platform-native task / spec workflow.
79
+ - `mem` 不编辑代码或更新文件。任何写回是你在当下做出的决定。
80
+ - `mem` 对平台 JSONL 存储是只读的。它不推送或同步到远程。
81
+ - 此技能不替代 `cviauto-update-spec`(后者是将发现推广为项目级指南的正确工具)或平台原生的 task / spec 工作流。
@@ -1,65 +1,64 @@
1
- # `cviauto mem` CLI Reference
1
+ # `cviauto mem` CLI 参考
2
2
 
3
- Full flag reference for the five subcommands. Pin this as the authoritative source — `cviauto mem help` prints the same content at runtime, so anything here that drifts is a bug.
3
+ 五个子命令的完整标志参考。将此作为权威来源——`cviauto mem help` 在运行时会打印相同内容,因此此处任何与运行时不一致的内容都属于 bug
4
4
 
5
- ## Subcommands
5
+ ## 子命令
6
6
 
7
- | Command | Purpose |
7
+ | 命令 | 用途 |
8
8
  | ---------------------- | ---------------------------------------------------------------------------------------------------------------------- |
9
- | `list` | List sessions. Default subcommand when none is given. |
10
- | `search <keyword>` | Find sessions whose contents match a keyword. |
11
- | `context <session-id>` | Drill into one session: top-N hit turns + surrounding context. Pair with `--grep` for keyword anchoring. |
12
- | `extract <session-id>` | Dump cleaned dialogue. Combine with `--phase` / `--grep` to slice. |
13
- | `projects` | List active project `cwd` values with session counts. Use this to discover which `--cwd` to pass to other subcommands. |
9
+ | `list` | 列出会话。未指定子命令时的默认行为。 |
10
+ | `search <keyword>` | 查找内容匹配关键词的会话。 |
11
+ | `context <session-id>` | 深入查看某个会话:Top-N 命中轮次 + 周围上下文。配合 `--grep` 进行关键词锚定。 |
12
+ | `extract <session-id>` | 导出清洗后的对话记录。结合 `--phase` / `--grep` 进行切片。 |
13
+ | `projects` | 列出活跃项目的 `cwd` 值及其会话计数。用于发现应传递给其他子命令的 `--cwd`。 |
14
14
 
15
- ## Flags (apply where meaningful)
15
+ ## 标志(酌情适用)
16
16
 
17
- | Flag | Subcommands | Meaning |
17
+ | 标志 | 子命令 | 含义 |
18
18
  | --------------------------------------------- | ----------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |
19
- | `--platform claude\|codex\|opencode\|pi\|all` | all | Default `all`. OpenCode adapter is currently a stub on `0.6.0-beta.*` — see "Caveats" below. |
20
- | `--since YYYY-MM-DD` | list / search | Inclusive lower date bound. |
21
- | `--until YYYY-MM-DD` | list / search | Inclusive upper date bound. |
22
- | `--global` | list / search | Include sessions from every project on this machine. Default is the current project `cwd`. |
23
- | `--cwd <path>` | list / search | Force a specific project cwd instead of inferring from where you are. |
24
- | `--limit N` | list / search | Cap output rows. Default `50`. |
25
- | `--grep KW` | extract / context | Filter turns by keyword. Multi-token AND when whitespace-separated. |
26
- | `--phase brainstorm\|implement\|all` | extract | Slice session by Cviauto task boundaries. `brainstorm` = `[task.py create, task.py start)`. `implement` = turns outside brainstorm windows. Default `all`. |
27
- | `--turns N` | context | Number of hit turns to return. Default `3`. |
28
- | `--around N` | context | Surrounding turns to include per hit. Default `1`. |
29
- | `--max-chars N` | context | Total character budget. Default `6000` (~1500 tokens). |
30
- | `--include-children` | search / context | Merge OpenCode sub-agent sessions into their parent session. |
31
- | `--json` | all | Emit machine-parseable JSON instead of human-readable output. |
32
-
33
- ## Common one-liners
19
+ | `--platform claude\|codex\|opencode\|pi\|all` | 全部 | 默认 `all`。OpenCode 适配器在 `0.6.0-beta.*` 上目前为桩实现——见下方"注意事项" |
20
+ | `--since YYYY-MM-DD` | list / search | 包含下界日期。 |
21
+ | `--until YYYY-MM-DD` | list / search | 包含上界日期。 |
22
+ | `--global` | list / search | 包含本机上所有项目的会话。默认仅当前项目 `cwd`。 |
23
+ | `--cwd <path>` | list / search | 强制使用指定项目 cwd,而非根据当前位置推断。 |
24
+ | `--limit N` | list / search | 输出行数上限。默认 `50`。 |
25
+ | `--grep KW` | extract / context | 按关键词筛选轮次。空格分隔表示多词 AND |
26
+ | `--phase brainstorm\|implement\|all` | extract | Cviauto 任务边界切片会话。`brainstorm` = `[task.py create, task.py start)`。`implement` = 头脑风暴窗口之外的轮次。默认 `all`。 |
27
+ | `--turns N` | context | 返回的命中轮次数量。默认 `3`。 |
28
+ | `--around N` | context | 每个命中轮次包含的周围轮次数。默认 `1`。 |
29
+ | `--max-chars N` | context | 总字符预算。默认 `6000`(约 1500 tokens)。 |
30
+ | `--include-children` | search / context | OpenCode agent 会话合并到其父会话中。 |
31
+ | `--json` | 全部 | 输出机器可解析的 JSON,而非人类可读输出。 |
32
+
33
+ ## 常用一行命令
34
34
 
35
35
  ```bash
36
- # What past sessions discussed "deadlock" anywhere on this machine?
36
+ # 本机上哪些过往会话讨论过 "deadlock"
37
37
  cviauto mem search "deadlock" --global --limit 20
38
38
 
39
- # Inside a specific session, surface the top 5 turns that mention "lock contention"
40
- # plus 2 turns of surrounding context.
39
+ # 在特定会话中,找出提及 "lock contention" 的前 5 轮,
40
+ # 并附带每轮前后各 2 轮的上下文。
41
41
  cviauto mem context 5842592d --grep "lock contention" --turns 5 --around 2
42
42
 
43
- # Recover the brainstorm window for a session — useful when continuing a task
44
- # the user started a week ago.
43
+ # 恢复某个会话的头脑风暴窗口——当需要继续用户一周前开始的任务时很有用。
45
44
  cviauto mem extract 5842592d --phase brainstorm
46
45
 
47
- # List every project this machine has Cviauto sessions for, with counts.
46
+ # 列出本机所有有 Cviauto 会话的项目及其会话计数。
48
47
  cviauto mem projects
49
48
  ```
50
49
 
51
- ## Output shapes
50
+ ## 输出形态
52
51
 
53
- - **Default human output** (no `--json`): wrapped to a terminal, with session ids highlighted and turn markers visible. Suitable to read inline but messy to paste into a markdown file.
54
- - **`--json`**: stable schema, safe to parse and process. When piping `mem` output into a follow-up step (e.g. summarizing for a Lessons section), prefer `--json`.
52
+ - **默认人类可读输出**(无 `--json`):适配终端宽度,会话 ID 高亮显示,轮次标记可见。适合内联阅读,但不适合粘贴到 markdown 文件中。
53
+ - **`--json`**:稳定 schema,可安全解析和处理。当将 `mem` 输出通过管道传递给后续步骤(例如为经验教训章节做摘要)时,优先使用 `--json`。
55
54
 
56
- ## Caveats
55
+ ## 注意事项
57
56
 
58
- - **OpenCode adapter is a stub on `0.6.0-beta.*`.** When `--platform` resolves to OpenCode (or `all` and OpenCode would be included), `mem` prints a one-line "reader unavailable" notice and continues with the other platforms. Don't promise OpenCode coverage in your reply until the adapter ships.
59
- - **`--phase` slicing depends on `task.py create` / `task.py start` invocations appearing in the recorded bash calls of the session.** Sessions where the user ran `task.py` from a different terminal — outside the recorded AI loop — will not have phase boundaries. `--phase all` is the safe fallback.
60
- - **`mem` indexes platform JSONL files directly.** If the user has cleared their Claude / Codex / Pi session storage, `mem` cannot recover what is no longer on disk.
61
- - **`mem` is read-only.** No remote sync, no edits to platform JSONL. Any write you do based on `mem` findings is your own follow-up call into the editing tools available to you.
57
+ - **OpenCode 适配器在 `0.6.0-beta.*` 上为桩实现。** `--platform` 解析为 OpenCode(或 `all` 且包含 OpenCode)时,`mem` 会打印一行"reader unavailable"通知并继续处理其他平台。在适配器正式发布之前,不要在回复中承诺 OpenCode 覆盖。
58
+ - **`--phase` 切片依赖于会话记录的命令行调用中出现 `task.py create` / `task.py start`。** 如果用户在 AI 循环之外的其他终端中运行了 `task.py`,则这些会话不会有阶段边界。`--phase all` 是安全的回退方案。
59
+ - **`mem` 直接索引平台的 JSONL 文件。** 如果用户清除了 Claude / Codex / Pi 的会话存储,`mem` 无法恢复磁盘上已不存在的数据。
60
+ - **`mem` 是只读的。** 没有远程同步,不会编辑平台 JSONL。你基于 `mem` 发现所做的任何写入操作,都是你自己对可用编辑工具的后续调用。
62
61
 
63
- ## When you need more than this reference
62
+ ## 当需要超出本参考的内容时
64
63
 
65
- Run `cviauto mem help` in the user's shell. The runtime help is authoritative and will be ahead of this reference during fast-moving beta releases.
64
+ 在用户的 shell 中运行 `cviauto mem help`。运行时帮助是权威的,在快速迭代的 beta 版本中会领先于本参考文档。