OpenClaw Role Builder
Build and manage OpenClaw roles — create AI character personas and generate identity-consistent photos — installable via ClawHub or git clone.
What This Skill Does
| Capability | Sub-skill | Example triggers |
|---|
| Character creation — build a full 6-file persona (identity, soul, voiceprint, …) for any public figure or fictional character | INLINECODE0 | 创建角色, 创建clone, 新建人物, "create a character" |
| Character switching — swap the active character in your workspace |
openclaw-character-creator | /shift, 切换角色 |
|
Identity-consistent selfies & portraits — generate images where the character's face stays consistent |
tuqu-photo-api | 自拍, 写真, 发张图, "take a selfie" |
|
Freestyle image generation — landscapes, objects, edits without a character in frame |
tuqu-photo-api | 风景, 物品, 角色出镜, edit-only |
|
Prompt enhancement, presets, billing — discover styles, improve prompts, check balance, recharge |
tuqu-photo-api | "enhance prompt", "check balance" |
Installation
Via ClawHub (recommended)
CODEBLOCK0
Via npx skills
CODEBLOCK1
Or install individual sub-skills:
CODEBLOCK2
Manual (git clone)
CODEBLOCK3
Prerequisites
| Requirement | Why |
|---|
| python3 | Required by tuqu-photo-api for the tuqu_request.py helper |
| TuQu service key |
Needed for authenticated image-generation calls — obtain from
|
| OpenClaw | The host agent that loads and executes these skills |
Verify Installation
CODEBLOCK4
Quick Start
Once installed, start a new OpenClaw session and try:
- - "帮我创建一个科比的角色" — creates a Kobe Bryant character with full persona files
- "来张自拍" — generates an identity-consistent selfie of the current character
- "/shift" — switches to a different character in your roster
- "拍张风景照" — generates a landscape without forcing the character into frame
Included Skills
openclaw-character-creator
Build high-consistency AI character personas with a full 6-file model (3 auxiliary + 3 main). Supports both well-known public figures and fictional/original characters, with workspace scaffolding and global role registration.
See openclaw-character-creator/SKILL.md for full usage.
tuqu-photo-api
Generate identity-consistent selfies, portraits, group photos, and freestyle images for OpenClaw characters via the tuqu.ai API. Covers prompt enhancement, preset discovery, character management, billing, and recharge flows.
See tuqu-photo-api/SKILL.md for full usage.
File System Access
This skill collection writes to the following paths:
| Skill | Path | What is stored |
|---|
| openclaw-character-creator | INLINECODE9 | Character names and workspace paths (no credentials) |
| openclaw-character-creator |
~/.openclaw/workspace-*/ | Character persona files and workspace state |
| openclaw-character-creator | ~/.openclaw/workspace/ | Active character workspace (managed by /shift) |
No service keys, tokens, or other credentials are persisted to disk by any script in this collection.
TuQu service keys are only used at runtime via --service-key CLI flags and are never written to config files.
Security Boundaries
- 1. Write scope: All file writes are confined to
~/.openclaw/ (the paths listed above). No
skill in this collection writes outside that directory.
- 2. Read scope: Skills read only their own bundled reference files (under the skill's
references/ directory) and character workspace files under ~/.openclaw/. No arbitrary
filesystem reads.
- 3. Credential handling: TuQu service keys are passed exclusively via the
--service-key CLI
flag to tuqu_request.py. The script does not read credentials from environment variables,
config files, or any persisted store. Keys must never be written to disk.
- 4. Network scope: All outbound API calls go through
scripts/tuqu_request.py, which restricts
requests to the known hosts (photo.tuqu.ai, billing.tuqu.ai). No ad-hoc curl, wget, or
other HTTP tools.
- 5. Shell commands: Only the specific bundled Python scripts and
mkdir for workspace
scaffolding are executed. No arbitrary shell commands.
Dependencies
The openclaw-character-creator skill expects tuqu-photo-api to be installed as well. Install both for full functionality.
OpenClaw 角色构建器
构建和管理OpenClaw角色——创建AI角色人设并生成身份一致的照片——可通过ClawHub或git clone安装。
该技能的功能
| 能力 | 子技能 | 触发示例 |
|---|
| 角色创建 — 为任何公众人物或虚构角色构建完整的6文件人设(身份、灵魂、声纹……) | openclaw-character-creator | 创建角色, 创建clone, 新建人物, create a character |
| 角色切换 — 在工作区中切换当前激活的角色 |
openclaw-character-creator | /shift, 切换角色 |
|
身份一致的自拍与肖像 — 生成角色面部保持一致性的图像 | tuqu-photo-api | 自拍, 写真, 发张图, take a selfie |
|
自由风格图像生成 — 风景、物品、编辑,角色不出镜 | tuqu-photo-api | 风景, 物品, 角色出镜, edit-only |
|
提示词增强、预设、计费 — 发现风格、优化提示词、查询余额、充值 | tuqu-photo-api | enhance prompt, check balance |
安装
通过ClawHub(推荐)
bash
clawhub install openclaw-role-builder
通过npx skills
bash
npx skills add tuquai/openclaw-role-builder --all
或安装单个子技能:
bash
npx skills add tuquai/openclaw-role-builder --skill openclaw-character-creator
npx skills add tuquai/openclaw-role-builder --skill tuqu-photo-api
手动安装(git clone)
bash
git clone https://github.com/tuquai/openclaw-role-builder.git ~/.openclaw/skills/openclaw-role-builder
前提条件
| 要求 | 原因 |
|---|
| python3 | tuqu-photo-api 的 tuqu_request.py 辅助脚本需要 |
| TuQu服务密钥 |
用于认证的图像生成调用——从
获取 |
| OpenClaw | 加载和执行这些技能的主代理 |
验证安装
bash
openclaw skills list
应同时显示 openclaw-character-creator 和 tuqu-photo-api
快速开始
安装完成后,启动一个新的OpenClaw会话并尝试:
- - 帮我创建一个科比的角色 — 创建包含完整人设文件的科比·布莱恩特角色
- 来张自拍 — 生成当前角色身份一致的自拍照
- /shift — 切换到角色列表中的另一个角色
- 拍张风景照 — 生成风景图像,不强制角色出镜
包含的技能
openclaw-character-creator
使用完整的6文件模型(3个辅助文件 + 3个主文件)构建高一致性的AI角色人设。支持知名公众人物和虚构/原创角色,包含工作区脚手架和全局角色注册。
完整用法请参见 openclaw-character-creator/SKILL.md。
tuqu-photo-api
通过tuqu.ai API为OpenClaw角色生成身份一致的自拍、肖像、合影和自由风格图像。涵盖提示词增强、预设发现、角色管理、计费和充值流程。
完整用法请参见 tuqu-photo-api/SKILL.md。
文件系统访问
该技能集合写入以下路径:
| 技能 | 路径 | 存储内容 |
|---|
| openclaw-character-creator | ~/.openclaw/ROLES.json | 角色名称和工作区路径(不含凭证) |
| openclaw-character-creator |
~/.openclaw/workspace-*/ | 角色人设文件和工作区状态 |
| openclaw-character-creator | ~/.openclaw/workspace/ | 当前激活角色工作区(由 /shift 管理) |
本集合中的任何脚本均不会将服务密钥、令牌或其他凭证持久化到磁盘。
TuQu服务密钥仅在运行时通过 --service-key CLI标志使用,绝不会写入配置文件。
安全边界
- 1. 写入范围: 所有文件写入仅限于 ~/.openclaw/(上述列出的路径)。本集合中的任何技能都不会写入该目录之外。
- 读取范围: 技能仅读取其自带的参考文件(位于技能的 references/ 目录下)以及 ~/.openclaw/ 下的角色工作区文件。不进行任意文件系统读取。
- 凭证处理: TuQu服务密钥仅通过 --service-key CLI标志传递给 tuqurequest.py。该脚本不会从环境变量、配置文件或任何持久化存储中读取凭证。密钥绝不能写入磁盘。
- 网络范围: 所有出站API调用均通过 scripts/tuqurequest.py 进行,该脚本将请求限制在已知主机(photo.tuqu.ai、billing.tuqu.ai)。不使用临时的 curl、wget 或其他HTTP工具。
- Shell命令: 仅执行特定的捆绑Python脚本和用于工作区脚手架搭建的 mkdir 命令。不执行任意shell命令。
依赖关系
openclaw-character-creator 技能期望同时安装 tuqu-photo-api。请同时安装两者以获得完整功能。