{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/zh-CN/develop/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"YouCam Skills 技能包","description":"YouCam API documentation by Perfect Corp. Learn how to use Skin analysis API, Virtual try-on API, Image editing API, and Video generative AI APIs.","siteUrl":"https://docs.perfectcorp.com","keywords":"AI Skin Analysis, AI Clothes, AI Hairstyle, AI Outfits","image":"/assets/favicon.cd6fa4d833b2a573b3c6dae68386b293da205b203402cb0c97b80bd2acc07ea2.8351e24f.png"},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"youcam-skills-技能包","__idx":0},"children":["YouCam Skills 技能包"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["把 YouCam AI 装进智能体，直接当技能用。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["YouCam Skills 把 Perfect Corp. 的 YouCam AI 能力打包成可安装的 skill，放进智能体环境里。也就是说，用户用大白话就能调起真正的 YouCam API："]},{"$$mdtype":"Tag","name":"blockquote","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["\"我的皮肤状态怎么样？\"",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"\"给我换这个发型试试。\"",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"\"让我在视频里试穿这件外套。\""]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["背后的活儿都由 skill 包办：调用 API、创建任务、轮询状态、核对费用、汇报结果。每个 skill 也都能直接从 CLI 跑起来，用来测试、做自动化，或走非智能体的流程。"]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"skills-技能包","__idx":1},"children":["Skills 技能包"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["YouCam Skills 仓库：",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://github.com/YouCam-API/skills"},"children":["https://github.com/YouCam-API/skills"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"安装","__idx":2},"children":["安装"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["如果您的智能体环境支持 ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://github.com/vercel-labs/skills"},"children":["Skills CLI"]},"，可以直接从 GitHub"," ","安装："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"npx skills add YouCam-API/skills\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["执行后会列出本仓库的六个 skill，让您挑要装哪几个，再挑装到您已安装的"," ","哪些智能体里（Claude Code、Cursor 等）。不想被一路追问的话，直接指定要装的"," ","skill 和智能体："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"npx skills add YouCam-API/skills --skill skin-analysis-expert -a claude-code\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["或者一次全装，装到所有检测到的智能体上："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"npx skills add YouCam-API/skills --all\n"},"children":[]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["本仓库把 6 种由 AI 驱动的美妆、仪容、发型、肤质与服饰试穿体验，做成了模块化的 Agent Skill："]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Skill"},"children":["Skill"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"适用场景"},"children":["适用场景"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Skin Analysis Expert"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["一张自拍，分析 16 项肌肤困扰加肤质。可选高清/标清精度，出叠加图还是蒙版图。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Facial Consultant"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["读取面部色彩与比例，包括肤色、瞳色、眉色、唇色、发色、五官形状，以及黄金比例测量。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Beauty Advisor"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["按脸型和肤色推荐妆容，再用精选或自定义美妆特效把效果渲染到照片上。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Hair Color & Style Advisor"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["根据五官特征推荐发型与发色，再用模板、参考照、配色预设或自定义色板预览。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Hair Diagnostics"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["评估发量密度、发质、毛躁程度和发长，汇成一份报告。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Clothes Try-on Studio"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["在用户照片上虚拟试穿，可选换背景，还能生成转身、走秀、摆姿势等短动作视频。"]}]}]}]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"为什么值得用","__idx":3},"children":["为什么值得用"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["对开发者来说："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["YouCam API 的自然语言入口"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["适配智能体环境的可安装 skill 结构"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["以 CLI 优先的测试方式，用 ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["youcam_core.py"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["自动跑通「上传 → 创建任务 → 轮询」流程"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["调用付费 API 前先做点数感知的检查"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["结构简单，新增或自定义 skill 很方便"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["对产品和营销来说："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["AI 美妆、护肤、护发与服饰试穿体验"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["基于用户照片的个性化推荐"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["一眼就看得懂的视觉预览"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["跑之前就把花费讲清楚"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["内置针对 AI 生成结果的负责任使用提示"]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"工作流程","__idx":4},"children":["工作流程"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["每个 skill 都走同一套流程："]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["用户用自己的话把需求说出来。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["智能体挑出合适的 YouCam Skill。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["skill 索要必需的输入，比如照片、要做的动作。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["运行前先检查或估算点数花费。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["随附的脚本上传素材并创建 API 任务。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["轮询任务，直到完成。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["结果以结构化 JSON 返回，并给出清楚的小结。"]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"环境准备","__idx":5},"children":["环境准备"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["需要的东西："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Python 3"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["pip"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["YouCam API 密钥"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["requests"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["PyYAML"]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["进入某个 skill 文件夹，运行："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"python scripts/youcam_core.py setup\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["这会创建一个本地虚拟环境并装好依赖。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["也可以这样："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"pip install -r scripts/requirements.txt\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["API 密钥在这里申请："]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["https://yce.makeupar.com/api-console/"]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"api-密钥配置","__idx":6},"children":["API 密钥配置"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["youcam_core.py"]}," 会按下面的顺序找凭据："]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["环境变量："]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"YOUCAM_API_KEY=your_key_here\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"ol","attributes":{"start":2},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["skill 文件夹里的本地 ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["credentials.json"]}," 文件："]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"api_key\": \"your_key_here\"\n}\n","lang":"json"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["每个 skill 有自己的文件夹，所以凭据是按 skill 分别配置的。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["验证密钥、查看余额，都不花点数："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"python scripts/youcam_core.py validate-key\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"执行前先查花费","__idx":7},"children":["执行前先查花费"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["在发起付费 API 调用之前，用户或智能体可以先跑免费的预检："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"python scripts/youcam_core.py cost --feature skin-analysis\npython scripts/youcam_core.py credits\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["这两条命令都免费，返回定价或余额信息。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["有了它，就容易搭出点数感知的流程：花多少，用户先确认。"]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"cli-快速上手","__idx":8},"children":["CLI 快速上手"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["直接跑一个 skill："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"python scripts/youcam_core.py run \\\n  --feature skin-analysis \\\n  --src_file selfie.jpg \\\n  --param format=json \\\n  --param dst_actions='[\"hd_pore\",\"hd_skin_type\"]'\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["这条命令会："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["上传源图片"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["创建 API 任务"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["轮询直到完成"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["打印结构化 JSON 输出"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["常用参数："]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"参数"},"children":["参数"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"作用"},"children":["作用"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--feature"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["选择要用的 YouCam 功能。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--src_file"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["主要输入图片/视频的本地路径或 URL。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--ref_file"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["可选的第二路输入，例如服装照片。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--param"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["可重复使用的键值型 API 参数。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--version"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["需要时覆盖默认 API 版本。"]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["支持的素材格式通常是 JPG、JPEG 或 PNG。视频类功能可能支持 MP4。本工具不会自动转格式。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["如果停止轮询时任务还在跑："]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"python scripts/youcam_core.py status \\\n  --feature skin-analysis \\\n  --task_id <task_id>\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"智能体里的体验","__idx":9},"children":["智能体里的体验"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["在支持 Skills 的智能体环境里，用户不用知道接口叫什么、参数怎么填，直接说要什么结果就行："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["\"分析一下我的皮肤。\""]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["\"给我推荐个发型。\""]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["\"把这套衣服穿我身上，让它动起来。\""]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["\"用这张照片看看我的头发健康情况。\""]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["智能体会挑对 skill、收集必需的输入、确认花费、跑完 API 流程，最后交回一个看得懂的结果。"]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"重要提示","__idx":10},"children":["重要提示"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["所有输出均为 AI 生成，仅供参考，不构成医疗、皮肤科、美妆或专业造型建议。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["结果好坏取决于："]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["照片分辨率"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["光线"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["脸部角度"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["画面清晰度"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["主体是否完整可见"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["输入格式是否在支持范围内"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["个别 API 字段偶尔会取不到。skill 的设计原则是缺什么就不写什么，绝不编数据。"]}]},"headings":[{"value":"YouCam Skills 技能包","id":"youcam-skills-技能包","depth":1},{"value":"Skills 技能包","id":"skills-技能包","depth":2},{"value":"安装","id":"安装","depth":2},{"value":"为什么值得用","id":"为什么值得用","depth":2},{"value":"工作流程","id":"工作流程","depth":2},{"value":"环境准备","id":"环境准备","depth":2},{"value":"API 密钥配置","id":"api-密钥配置","depth":2},{"value":"执行前先查花费","id":"执行前先查花费","depth":2},{"value":"CLI 快速上手","id":"cli-快速上手","depth":2},{"value":"智能体里的体验","id":"智能体里的体验","depth":2},{"value":"重要提示","id":"重要提示","depth":2}],"frontmatter":{"seo":{"title":"YouCam Skills 技能包"}},"lastModified":"2026-10-30T07:26:32.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/zh-cn/develop/agent_skills","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}