智能体分身设计器
Use this skill in WorkBuddy when the user wants to list, inspect, design, configure, improve, or diagnose a wxoa/wxcw-bound XAgent charagent: identity, persona, behavior, role memory, knowledge, FAQ, special events, ASR hotwords, avatar/portrait media, templates, or wizard-generated candidates.
This is a standalone SkillHub package. A separately installed WorkBuddy custom connector is optional, not a prerequisite.
First Step
Load xcharagent_design by the first available route:
- If native MCP tool
xagent_skill_loadis visible, call it with{ "skill": "xcharagent_design" }. - Otherwise immediately use the adapter bundled in this installed skill. Do not stop and do not ask the user or an organization administrator to install a connector:
node "{baseDir}/scripts/xagent_mcp.mjs" skill-load xcharagent_design
Read result.content, cache result.skill_version and its rules in this task, and follow the returned server-side skill as the source of truth.
Calling Tools Without A Native Connector
Prefer a visible native XAgent tool. If the needed tool is not visible, call the same remote tool through the bundled adapter:
node "{baseDir}/scripts/xagent_mcp.mjs" call charagent_manageable_list '{}'
node "{baseDir}/scripts/xagent_mcp.mjs" call <tool_name> '<json arguments>'
For complex JSON, pass stdin instead of wrestling with shell quoting:
printf '%s' '<json arguments>' | node "{baseDir}/scripts/xagent_mcp.mjs" call <tool_name> -
The adapter never prints the MCP token. It retries only safe reads; it never automatically retries configuration writes or wizard generation. If a write result is uncertain, follow the loaded skill and read the affected module before deciding whether another write is needed.
For avatar or portrait files, the adapter can complete prepare plus upload without exposing the signed target:
node "{baseDir}/scripts/xagent_mcp.mjs" media-upload --account-key <key> --account-kind <wxoa|wxcw> --kind <avatar|portrait> --local <image_path>
Only report the returned public reference after uploaded: true. Persist it in base config only when the loaded dynamic skill requires that step.
Ordinary User Behavior
- Accept the display name users know and resolve internal keys with
charagent_manageable_list. - Show a short choice only when more than one account matches. Do not expose raw JSON, internal keys, tokens, signed URLs, object paths, prompts, or audit payloads.
- Read before writing, preserve unrelated configuration, use returned item ids for updates, and read back after writes.
- Explain results using module names such as “人格画像”、“行为向导”、“知识库” and “常见问题”. Do not describe candidate generation as saved configuration.
- Ask for explicit confirmation before deletes, template apply/append, broad reset, or creation of a new wxoa/wxcw platform object.
Absence of a WorkBuddy custom-connector entry is not an error condition. Only if the bundled adapter returns auth_required should you ask the user to sign in to XAgent and create/save an MCP token. That is account authentication, not another plugin or connector installation.
Handoff
XApp code/workspace/preview/publish belongs to the XApp development skill. Broad wxoa/wxca/wxcw integration, plugin upgrade, quota administration, goods, grants, resource objects, and risk-record operations belong to the admin skill.