跳到主要内容

ideon write [idea]

命令作用

ideon write [idea] 会运行完整 Ideon 流水线,生成一个必需主输出和可选次级输出;当主输出包含 article 时,会执行图像渲染。

用法

ideon write [idea] [--idea <idea>] [--audience <description>] [--job <path>] [--primary <type=1>] [--secondary <type=count> ...] [--style <style>] [--intent <intent>] [--length <size-or-words>] [--no-interactive] [--dry-run] [--enrich-links]

参数与选项

参数/选项简写必填类型默认值允许值说明
[idea]stringn/a任意自然语言文本未提供 --idea 时使用的位置参数。
--idea <idea>-istringn/a任意自然语言文本显式 idea,优先级高于位置参数。
--audience <description>string泛化受众任意自然语言文本用于 shared-brief 规划的受众提示。
--job <path>-jstring (path)n/a有效 JSON 文件路径从文件加载 job 定义。
--primary <type=1>非交互模式必填string交互模式下会提示articleblog-postlinkedin-postnewsletterpress-releasereddit-postscience-paperx-postx-thread,且 count 必须为 1必需主目标,数量必须是 1
--secondary <type=count>可重复 string与主目标相同的类型,count >= 1可重复的次级目标。
--style <style>enumprofessionalacademicanalyticalauthoritativeconversationalempatheticfriendlyjournalisticminimalistpersuasiveplayfulprofessionalstorytellingtechnical生成内容风格。
--intent <intent>非交互模式必填enum交互模式下会提示announcementcase-studycornerstonecounterargumentcritique-reviewdeep-dive-analysishow-to-guideinterview-q-and-alisticleopinion-piecepersonal-essayroundup-curationtutorial内容意图,会影响所有输出的结构与论证方式。
--length <size-or-words>enum 或整数medium 别名(900 词)smallmediumlarge 或正整数按词数控制目标篇幅。别名映射:small=500medium=900large=1400
--no-interactivebooleanfalsetrue 或省略禁用所有提示,在缺少必填输入时立即失败。
--dry-runbooleanfalsetrue 或省略不调用外部提供商 API,仅执行编排流程。
--enrich-linksbooleanfalsetrue 或省略在 markdown 生成后执行链接增强阶段。

示例

最小可用示例
ideon write "How AI changes technical publishing"
常见生产示例
ideon write "How small editorial teams scale content" --primary article=1 --secondary x-thread=2 --style technical --intent how-to-guide --length large
排障与安全示例
ideon write --dry-run "How to test Ideon pipeline changes" --primary article=1
单次执行 agent 安全示例
ideon write --no-interactive --idea "How to productionize docs operations" --primary article=1 --style technical --intent tutorial --length 1200

非交互行为

当设置 --no-interactive 时,Ideon 在 TTY 环境中也不会弹出任何提示。

  • 缺少 idea 输入会立即失败。
  • 在 no-interactive 模式下缺少 --primary--style--intent--length 会立即失败并给出可执行错误提示。
  • --length 同时支持别名(smallmediumlarge)和正整数词数。
  • 这是 one-shot agent 与 CI 工作流推荐模式。

链接增强

  • 链接增强是面向符合条件的长内容 markdown 输出的后处理链接建议流程。
  • Ideon 会先选取可链接短语,再通过模型 + web search 解析相关来源 URL,并写入 *.links.json sidecar 文件。
  • 该步骤不会改写原始 markdown 文件。
  • ideon write 中,只有显式传入 --enrich-links 时才会执行链接增强。
  • 短内容渠道(如 x-postx-thread)会被跳过。

输出与退出码

成功时,Ideon 会将生成结果写入 output/<timestamp>-<slug>/,并输出流程完成信息。

退出码含义
0写作流程执行成功。
1发生参数校验或运行时错误。
130命令被 Ctrl+C 中断。

相关命令

版本与弃用说明

  • 当前行为对应 Ideon 0.1.6
  • 已弃用的 --target 已由 --primary 与可重复 --secondary 替代。