输出示例(Intent Examples)

June 12, 2026 · View on GitHub

本文展示 python main.py 写到 {output_dir}/intents.jsonl 中的每一行的真实结构。

三条样例的 domains / tasks / persona_id / tools_used / skills_used / complexity / metadata 字段全部由 IntentBuilder 真实采样产出(random.seed(7),使用本仓库 ship 的 1000 personas / 55 tools / 66 skills / 10 domains 池)。

只有 natural_language_intent 字段在文档中用 [LLM-rendered placeholder] 标记代替——线上跑 main.py 时这一段由 IntentGenerator 配合 LLM 后端(OpenAI / Anthropic)按 src/generators/prompts/intent_prompt.txt 模板渲染,典型长度 100–400 字符的自然语言用户表达。

字段语义见 architecture.md 的 "数据模型" 一节。


1. simple(1 domain × 2–3 tasks)

{
  "id": "intent_e3bba52a",
  "natural_language_intent": "[LLM-rendered placeholder — a Policy Advisor asking, in their own voice, to check the status of a running session, gather any completed sub-task outputs, and keep the workflow running periodically.]",
  "domains": ["705bc773-6067-483e-80be-169acedafa37"],
  "tasks": [
    "613dd649-33bb-4fc5-83ff-0bafc1833a6c",
    "03cc60bd-7828-4ecd-b292-49f503d0941d",
    "2c1206b7-ecb8-4f88-a9d7-d399fb6fa9de"
  ],
  "persona_id": "7d9ff5ec-7bfb-4216-b166-244e16f076a1",
  "tools_used": [
    "7f0c85b6-5f8b-4c8a-83b8-bfdd34c9490e",
    "4ec13dc1-dac5-4867-a784-cc32f784f80e",
    "91c54aed-8e46-4525-a0f7-64fb22f4fef0"
  ],
  "skills_used": ["eabfb683-d9a5-48ae-a684-8d9e6dd0f3ef"],
  "complexity": "simple",
  "metadata": {
    "persona": {
      "name": "Kwame Mensah",
      "role": "Policy Advisor",
      "industry": "Government",
      "expertise": ["Legislative Research", "Public Administration", "Stakeholder Engagement"],
      "experience_level": "Executive",
      "communication_style": "Formal",
      "work_context": "Ministry of Infrastructure planning office"
    },
    "domains": [
      {
        "name": "agent-memory",
        "description": "This domain governs the state, context, and inter-session communication of autonomous agents …",
        "selected_tasks": [
          {"name": "Check Session Status", "description": "Tell me if a specific session is running, paused, or completed."},
          {"name": "Consolidate Completed Work Results", "description": "Gather output from finished sessions and archives into a single summary record."},
          {"name": "Maintain Autonomous Long-Term Tasks", "description": "Run continuous workflows that report progress periodically and manage their own state."}
        ]
      }
    ]
  }
}
  • Persona:Kwame Mensah,Government 行业 Executive。
  • Domain:1 个(agent-memory)。
  • Tasks:3 个,全部来自 agent-memory 域。
  • Tools:聚合自三个 task 的 suggested_tools(去重)。
  • LLM 会根据 persona 的 Formal 沟通风格 + Government 行业语气,生成符合该角色的自然语言请求。

2. medium(2–3 domains × 3–4 tasks)

{
  "id": "intent_6317c507",
  "natural_language_intent": "[LLM-rendered placeholder — a Textile Buyer combining an S3 dataset pull, an incident report draft, and a quick memory lookup into one self-contained ask.]",
  "domains": [
    "34e10d5d-6630-4141-a5c7-18db3bbd3ca5",
    "4ef99807-ddbc-4335-87c7-571ab7bf2f1f",
    "705bc773-6067-483e-80be-169acedafa37"
  ],
  "tasks": [
    "e20b9cb4-d1f9-4f5d-b9b1-5d90e1b77b5a",
    "83cf3e10-0eb3-4671-a9d3-a00935fe24bf",
    "0ed3da25-adbc-4e8d-8a0c-938ebed9e9c4"
  ],
  "persona_id": "0540ef12-8f4f-4b56-a8b8-0af72bde7fbd",
  "tools_used": [
    "dd7d5cbe-ed7e-4a7a-9d43-3faff679e84f",
    "4ec13dc1-dac5-4867-a784-cc32f784f80e"
  ],
  "skills_used": ["b4f1e393-b66f-47dd-b8d5-e05300199e21"],
  "complexity": "medium",
  "metadata": {
    "persona": {
      "name": "Li Na",
      "role": "Textile Buyer",
      "industry": "Retail",
      "expertise": ["Fabric Sourcing", "Cost Negotiation", "Trend Forecasting"],
      "experience_level": "Senior",
      "communication_style": "Formal",
      "work_context": "Global apparel brand sourcing materials in Asia."
    },
    "domains": [
      {"name": "system-infrastructure", "description": "...", "selected_tasks": [
        {"name": "Download Files from AWS S3", "description": "Retrieve files or datasets from Amazon S3 …"}
      ]},
      {"name": "comms-social", "description": "...", "selected_tasks": [
        {"name": "Write Incident Report", "description": "Create a structured document detailing a technical issue …"}
      ]},
      {"name": "agent-memory", "description": "...", "selected_tasks": [
        {"name": "Retrieve Specific Memory Item", "description": "Fetch the content of a particular saved memory entry by its identifier."}
      ]}
    ]
  }
}
  • Persona:Li Na,Retail / Textile Buyer / Senior。
  • Domains:3 个(system-infrastructure / comms-social / agent-memory),跨域组合是 medium / complex 档的典型特征。
  • Tasks:3 个,各 domain 各 1 个(builder 优先保证"每个 domain 至少有一个 task")。
  • LLM 渲染时需要把这 3 个看似不相关的 task 编织成一条自洽的用户请求——这是 4D 采样产出 "long-tail 跨域意图" 的关键。

3. complex(2–3 domains × 5–6 tasks)

{
  "id": "intent_a822a766",
  "natural_language_intent": "[LLM-rendered placeholder — a Junior Legal Associate driving a multi-step infrastructure-plus-multimedia workflow, asked in formal legal-firm voice.]",
  "domains": [
    "34e10d5d-6630-4141-a5c7-18db3bbd3ca5",
    "2fce4956-1902-46a9-ae11-765ce55a8f25"
  ],
  "tasks": [
    "b77544d3-6d13-4faf-9b19-03aa2163b273",
    "3a500a3e-b7d6-4a1a-ac23-c4f0a254e4df",
    "a2719e81-15f3-4a4e-be32-a4fb0e4ea267",
    "5a15fbc7-cdf4-4295-a259-5ad6db338e33",
    "54f2f2c1-00af-4041-a17e-54b7b4f40375"
  ],
  "persona_id": "473f6e7d-6b32-44af-ba1e-10a9531db48f",
  "tools_used": [
    "676af1e1-c64d-4d94-bf6c-e3d83b94ed80",
    "adf06b8a-8d40-4202-8d8a-b218614c9f26",
    "7e98d01f-6ce3-49dc-bd19-c4819d264cf4",
    "98bf3570-38c7-4f7f-88b2-99ad2d27bfc3"
  ],
  "skills_used": [
    "3924efcd-8405-428f-9d31-6b5309ff7a17",
    "3384d70a-31e6-4756-8a27-e147ac46c956"
  ],
  "complexity": "complex",
  "metadata": {
    "persona": {
      "name": "Camille Dubois",
      "role": "Junior Legal Associate",
      "industry": "Legal",
      "expertise": ["Contract Review", "Case Law Research", "Compliance Auditing"],
      "experience_level": "Junior",
      "communication_style": "Formal",
      "work_context": "Corporate law firm in Paris."
    },
    "domains": [
      {"name": "system-infrastructure", "description": "...", "selected_tasks": [
        {"name": "Mount Network File System", "description": "..."},
        {"name": "Run Security Compliance Audit", "description": "..."},
        {"name": "Coordinate Multi-Tier Infrastructure Setup", "description": "..."},
        {"name": "Check Deployed Software Versions", "description": "..."}
      ]},
      {"name": "multimedia", "description": "...", "selected_tasks": [
        {"name": "<one multimedia task>", "description": "..."}
      ]}
    ]
  }
}
  • Persona:Camille Dubois,Legal / Junior。
  • Domains:2 个;Tasks:5 个(complex 档区间 5–6)。
  • 多个 task 同一个 domain 是允许的——builder 先保证"每个 domain 至少 1 个 task",再继续从全部候选 task 池里随机补足到目标数量。
  • 这条意图横跨 system-infrastructure + multimedia,合理性的"工作流"骨架要靠 LLM 在渲染时补充("帮我先挂载文件系统、做合规审计、生成一段多媒体截图作为附件…")。

备注:metadata 结构

  • persona:被采样到的 persona 全字段镜像,便于下游分析者不用回查 libraries/personas/personas.jsonl
  • domains[]:每个被选中域的 name + description + 该域里被选中的 task 列表(name + description)。
  • domains[].selected_tasks 仅含被本次 intent 选中的 task(与顶层 tasks: [...] 一一对应),不是该域所有 task。

intents.jsonl 每一行即一条完整 JSON,适合直接喂给 Stage 2(openclaw_gen_data)的用户模拟器。