emergent-thinking

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Emergent Thinking

涌现思维

Use
emergent-thinking
when work needs durable project-local memory that survives context compression, multi-agent concurrency, or long architectural discussions.
当工作需要能在上下文压缩、多Agent并发或长时间架构讨论后仍留存的持久化项目本地记忆时,使用
emergent-thinking

When To Use

适用场景

  • The task has multiple architecture branches, revisions, or tradeoffs.
  • You need to preserve user requirements or your own decisions verbatim.
  • The work may be continued by another agent or after a context reset.
  • You need a compact
    <history>
    artifact before compression.
  • 任务存在多个架构分支、修订版本或权衡取舍。
  • 你需要逐字留存用户需求或你自己做出的决策。
  • 工作可能由另一个Agent继续,或在上下文重置后继续。
  • 你需要在压缩前生成精简的
    <history>
    构件。

Workflow

使用流程

  1. Resolve project context:
    • Run
      emergent-thinking context show
      .
  2. Choose a stable session key:
    • Use
      <agent>/<thread-or-run-id>
      .
    • Examples:
      codex/abc123
      ,
      claude-code/review-42
      .
  3. Ensure or reuse the session:
    • Run
      emergent-thinking session ensure --session-key <key>
      .
  4. Append durable thoughts as JSON via stdin:
    • Record user raw requirements with
      historyEntry.role = "user"
      and
      kind = "requirement"
      or
      "suggestion"
      .
    • Record your own decisions with
      historyEntry.role = "ai"
      and
      kind = "decision"
      or
      "plan"
      .
    • Always set
      cognitivePhase
      ,
      architecturalTarget
      ,
      thoughtNumber
      ,
      totalThoughts
      , and
      nextThoughtNeeded
      .
    • Set
      clientRequestId
      so retries are idempotent.
  5. Before context compression or handoff:
    • Run
      emergent-thinking compact --session-key <key>
      .
    • Reuse the emitted
      <history>
      block in the next context.
  1. 解析项目上下文:
    • 运行
      emergent-thinking context show
  2. 选择稳定的会话密钥:
    • 使用
      <agent>/<thread-or-run-id>
      格式。
    • 示例:
      codex/abc123
      claude-code/review-42
  3. 确认或复用会话:
    • 运行
      emergent-thinking session ensure --session-key <key>
  4. 通过标准输入将持久化思路以JSON格式追加:
    • 记录用户原始需求时,设置
      historyEntry.role = "user"
      kind = "requirement"
      "suggestion"
    • 记录自身决策时,设置
      historyEntry.role = "ai"
      kind = "decision"
      "plan"
    • 始终设置
      cognitivePhase
      architecturalTarget
      thoughtNumber
      totalThoughts
      nextThoughtNeeded
      字段。
    • 设置
      clientRequestId
      以保证重试操作具备幂等性。
  5. 在上下文压缩或工作移交前:
    • 运行
      emergent-thinking compact --session-key <key>
    • 在后续上下文中复用输出的
      <history>
      块。

Notes

注意事项

  • The CLI stores data inside the current project boundary, not in a global service.
  • Do not invent a hidden “current session”. Always pass
    --session-key
    .
  • Treat
    historyEntry.content
    as durable source material:
    • User content should stay objective and verbatim.
    • AI content should capture your concrete decisions and plans.
  • 该CLI将数据存储在当前项目边界内,不会存储到全局服务中。
  • 不要虚构隐藏的「当前会话」,始终传入
    --session-key
    参数。
  • historyEntry.content
    视为持久化源数据:
    • 用户内容应保持客观、逐字留存。
    • AI内容应记录你做出的具体决策和计划。",