codex-memory-task-init
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseCodex Memory Task Init
Codex Memory Task Init
Pre-Write Checks
预写入检查
Before creating the task directory, first define an absolute path variable: .
PROJECT_ROOT- must be the project root for the current session
PROJECT_ROOT - Do not treat ,
~,/,~/.config/opencode, a skills directory, or a config directory as the project root~/.codex - If the current directory looks like a home directory or a config directory, or if the project root is still unclear, stop and confirm it first
- All task directories and files must be created under
{PROJECT_ROOT}/.codex-memory/tasks/active/<task-slug>/ - Do not treat the bare relative path as the final target path
.codex-memory/tasks/...
在创建任务目录之前,首先定义一个绝对路径变量:。
PROJECT_ROOT- 必须是当前会话的项目根目录
PROJECT_ROOT - 请勿将、
~、/、~/.config/opencode、技能目录或配置目录视为项目根目录~/.codex - 如果当前目录看起来是主目录或配置目录,或者项目根目录仍不明确,请先停止并确认
- 所有任务目录和文件必须创建在下
{PROJECT_ROOT}/.codex-memory/tasks/active/<task-slug>/ - 请勿将相对路径视为最终目标路径
.codex-memory/tasks/...
When To Use
使用场景
Use this when any of the following is true:
- The user explicitly says "This is a long-running task. Record it."
- The user explicitly says "Create task memory for this long-running task"
- The task will continue across multiple sessions
- The task needs its own target, decisions, and reference tracking
- The task no longer fits cleanly inside
current.md
当满足以下任一条件时使用:
- 用户明确说出“这是一项长期运行的任务,请记录下来。”
- 用户明确说出“为这项长期运行的任务创建任务记忆”
- 任务将跨多个会话持续进行
- 任务需要独立跟踪自身目标、决策和参考资料
- 任务无法清晰适配到中
current.md
Natural Trigger Phrases
自然触发语句
- This is a long-running task. Record it.
- Create task memory for this long-running task
- 这是一项长期运行的任务,请记录下来。
- 为这项长期运行的任务创建任务记忆
Goal
目标
Create the standard task memory skeleton under .
.codex-memory/tasks/active/<task-slug>/在下创建标准的任务记忆框架。
.codex-memory/tasks/active/<task-slug>/Required Output
要求输出
The actual target path must be:
text
{PROJECT_ROOT}/.codex-memory/tasks/active/<task-slug>/The structure below is shown only as the project-relative layout:
Create:
text
.codex-memory/tasks/active/<task-slug>/
├── brief.md
├── decisions.md
└── refs.mdAlso update:
text
.codex-memory/tasks/index.md实际目标路径必须为:
text
{PROJECT_ROOT}/.codex-memory/tasks/active/<task-slug>/以下结构仅展示项目相对布局:
创建:
text
.codex-memory/tasks/active/<task-slug>/
├── brief.md
├── decisions.md
└── refs.md同时更新:
text
.codex-memory/tasks/index.mdRules
规则
- Confirm first; all actual write paths must use absolute
PROJECT_ROOTpaths.{PROJECT_ROOT}/.codex-memory/... - should be short, stable, and readable, without a date.
<task-slug> - ,
brief.md, anddecisions.mdmust always be created together.refs.md - All files must be generated from this skill's built-in templates.
- If the task directory already exists, do not rebuild it; only fill gaps and validate.
- When updating , add the task entry and a one-line summary.
tasks/index.md - Run a structure validation after writing; if validation fails, stop and report it.
- 首先确认;所有实际写入路径必须使用绝对路径
PROJECT_ROOT。{PROJECT_ROOT}/.codex-memory/... - 应简短、稳定且易读,不含日期。
<task-slug> - 、
brief.md和decisions.md必须始终同时创建。refs.md - 所有文件必须从本技能的内置模板生成。
- 如果任务目录已存在,请勿重新构建;仅补充缺失文件并验证。
- 更新时,添加任务条目和一行摘要。
tasks/index.md - 写入后运行结构验证;如果验证失败,请停止并报告问题。
Report Back
反馈内容
- the used this time
PROJECT_ROOT - the task slug
- created files
- backfilled files
- update result
tasks/index.md - validation result
- 本次使用的
PROJECT_ROOT - 任务slug
- 创建的文件
- 补充的文件
- 的更新结果
tasks/index.md - 验证结果
Constraints
约束条件
- Do not create any directories or files before
.codex-memory/tasks/is confirmedPROJECT_ROOT - If the target path is not , stop immediately and do not continue
{PROJECT_ROOT}/.codex-memory/tasks/active/<task-slug>/
- 在确认之前,请勿创建任何
PROJECT_ROOT目录或文件.codex-memory/tasks/ - 如果目标路径不是,请立即停止,不要继续执行
{PROJECT_ROOT}/.codex-memory/tasks/active/<task-slug>/