{ "name": "user-persona", "displayName": "用户画像生成", "description": "融合电商VOC和社媒VOC,AI生成核心用户画像、使用场景和决策因素", "category": "synthesis", "version": "1.3.0", "type": "analysis", "parameters": { "reviewKeywordCloud": { "type": "object", "required": true, "description": "review-keyword-cloud 输出" }, "reviewPainPoints": { "type": "object", "required": true, "description": "review-pain-point-extraction 输出" }, "reviewHighlights": { "type": "object", "required": true, "description": "review-highlight-extraction 输出" }, "socialTrendAnalysis": { "type": "object", "required": false, "description": "social-trend-analysis 输出(可选)" }, "categoryKeyword": { "type": "string", "required": true, "description": "品类关键词" } }, "pipeline": [ { "step": 1, "name": "提取使用场景", "type": "compute", "logic": "extractScenarios(reviewKeywordCloud, socialTrendAnalysis)", "algorithm": { "keywordClustering": "从评论关键词中提取场景相关词(bedroom/bathroom/gift/office等)", "socialScenarios": "从社媒趋势中提取热门场景(home decor/self-care/gifting等)", "frequencyRank": "按场景出现频率排序", "implementation": "将关键词按场景词典(bedroom/bathroom/gift/office/travel等)匹配分类,统计频率排序" }, "output": "scenarios" }, { "step": 2, "name": "提取决策因素", "type": "compute", "logic": "extractDecisionFactors(reviewPainPoints, reviewHighlights, socialTrendAnalysis)", "algorithm": { "fromPainPoints": "痛点反转 = 用户核心关注点(e.g. “香味太淡”→“香味浓度”)", "fromHighlights": "亮点直接映射为决策因素", "weight": "factor.weight = painFreq*0.4 + highlightFreq*0.3 + socialMention*0.3", "implementation": "痛点topic反转为决策因素 + 亮点topic直接映射 + 社媒热词补充,用weight公式排序" }, "output": "decisionFactors" }, { "step": 3, "name": "AI生成用户画像", "type": "ai", "logic": "generatePersonas(scenarios, decisionFactors, reviewKeywordCloud, socialTrendAnalysis)", "aiConfig": { "systemPrompt": "你是跨境电商用户研究专家。只输出一个合法JSON对象。禁止输出Markdown、代码围栏、解释文字。", "userPromptTemplate": "基于以下VOC数据,生成3-5个核心用户画像。每个画像包含: 名称/年龄段/核心场景/决策因素/价格敏感度/社媒平台偏好/购买动机。\n场景数据: ${scenarios}\n决策因素: ${decisionFactors}\n关键词: ${topKeywords}", "outputFormat": "{\"personas\":[{\"name\":\"“品质生活家”\",\"ageRange\":\"28-40\",\"coreScenario\":\"家居装饰\",\"decisionFactors\":[\"品质\",\"香味\"],\"priceSensitivity\":\"medium\",\"socialPreference\":\"Instagram\",\"motivation\":\"提升家居氛围\"}]}", "temperature": 0.3, "maxTokens": 3000, "promptPattern": "system约束JSON输出 + user提供结构化数据 + outputFormat示例引导格式" }, "output": "personas" }, { "step": 4, "name": "购买行为分析", "type": "compute", "logic": "analyzePurchaseBehavior(personas, reviewKeywordCloud, reviewPainPoints, socialTrendAnalysis)", "algorithm": { "priceSensitivityMapping": { "method": "将用户画像的价格敏感度映射到品类价格带", "high": "偏好低价带/中低价带,重视促销折扣", "medium": "偏好黄金中价带,重视性价比", "low": "偏好中高/高价带,重视品质与品牌" }, "seasonalPatterns": { "method": "从评论日期分布+社媒趋势提取季节性购买规律", "peakMonths": "评论集中的月份 = 购买高峰期", "giftSeason": "Q4(感恩节/圣诞)/情人节/母亲节等送礼场景高峰" }, "channelPreference": { "method": "根据社媒平台偏好+年龄段推断购买渠道", "youngAdult": "TikTok种草→Amazon购买, 重视网红推荐", "middleAge": "搜索驱动→Amazon直购, 重视评论和评分", "giftBuyer": "社媒灵感→直接购买, 重视包装和送达时间" } }, "output": "purchaseBehavior" }, { "step": 5, "name": "生成画像手册", "type": "compute", "logic": "buildHandbook(personas, scenarios, decisionFactors, purchaseBehavior)", "algorithm": { "format": "Markdown格式: 每个画像一个章节,包含基本信息/场景/决策因素/购买行为/营销建议", "scenarioChart": "场景分布饼图数据", "factorRanking": "决策因素权重柱状图数据", "marketingStrategy": "每个画像的精准营销策略: 触达渠道/内容形式/促销引导/复购策略" }, "output": "handbook" } ], "response": { "type": "object", "properties": { "personas": { "type": "array", "description": "核心用户类型列表", "items": { "type": "object", "properties": { "name": { "type": "string" }, "ageRange": { "type": "string" }, "coreScenario": { "type": "string" }, "decisionFactors": { "type": "array", "items": { "type": "string" } }, "priceSensitivity": { "type": "string", "enum": [ "high", "medium", "low" ] }, "socialPreference": { "type": "string" }, "motivation": { "type": "string" }, "proportion": { "type": "number", "description": "估算占比%" } } } }, "scenarioDistribution": { "type": "array", "description": "使用场景分布", "items": { "type": "object", "properties": { "scenario": { "type": "string" }, "proportion": { "type": "number" } } } }, "decisionFactorRanking": { "type": "array", "description": "决策因素权重排序", "items": { "type": "object", "properties": { "factor": { "type": "string" }, "weight": { "type": "number" } } } }, "handbookMarkdown": { "type": "string", "description": "画像手册(Markdown)" }, "purchaseBehavior": { "type": "object", "description": "购买行为分析", "properties": { "priceSensitivityMap": { "type": "array", "items": { "type": "object", "properties": { "persona": { "type": "string" }, "sensitivity": { "type": "string", "enum": [ "high", "medium", "low" ] }, "preferredBand": { "type": "string" }, "promotionResponse": { "type": "string" } } } }, "seasonalPatterns": { "type": "array", "items": { "type": "object", "properties": { "period": { "type": "string" }, "peakLevel": { "type": "string", "enum": [ "high", "medium", "low" ] }, "dominantPersona": { "type": "string" }, "marketingFocus": { "type": "string" } } } }, "channelPreferences": { "type": "array", "items": { "type": "object", "properties": { "persona": { "type": "string" }, "primaryChannel": { "type": "string" }, "discoveryPath": { "type": "string" }, "conversionDriver": { "type": "string" } } } } } } } }, "timeout": 300000, "retry": { "maxAttempts": 2, "delay": 1000, "backoffMultiplier": 2 }, "tokenConfig": { "type": "bearer", "configFile": "~/.openclaw/voc-credentials.json", "tokenField": "vocToken", "resolutionOrder": [ "configFile" ], "apigId": "7HwdQZk55B", "paymentUrlResolution": { "description": "动态构建充值URL:在已存在 session token 时查出用户 objectId,拼接到专属充值页面", "steps": [ "1. 从 voc-credentials.json 获取当前 session token", "2. 调用 GET https://server.fmode.cn/parse/users/me (Header: X-Parse-Application-Id: ncloudmaster, X-Parse-Session-Token: {token})获取用户 objectId", "3. 拼接充值URL: https://app.fmode.cn/dev/apig-pay/?user={objectId}&apigid=7HwdQZk55B&fun_id=HOkkX72PMF", "4. 将该URL展示给用户,引导扫码支付" ], "userResolveEndpoint": "https://server.fmode.cn/parse/users/me", "userResolveHeaders": { "X-Parse-Application-Id": "ncloudmaster", "X-Parse-Session-Token": "{vocToken}" }, "paymentBaseUrl": "https://app.fmode.cn/dev/apig-pay/", "paymentParams": { "user": "{resolvedUserId}", "apigid": "7HwdQZk55B", "fun_id": "HOkkX72PMF" }, "balanceCheckEndpoint": "https://server.fmode.cn/api/apig/getApig" }, "onMissing": { "action": "showPaymentQR", "qrCodeUrl": "https://app.fmode.cn/dev/apig-pay/?apigid=7HwdQZk55B&fun_id=HOkkX72PMF", "title": "扫码开通 VOC-AI 数据服务", "message": "此 Skill 需要有效的 API Token。请先打开充值页面完成登录和充值;当用户提供 session token 后,请由 OpenClaw 运行 node scripts/tools/set-voc-token.js 写入 ~/.openclaw/voc-credentials.json 的 vocToken 字段,再重试当前 Skill。", "tokenSetupCommandTemplate": "node scripts/tools/set-voc-token.js {sessionToken}", "tokenSetupInstructions": "当用户完成登录和充值后,如果用户把 session token 发给你,请直接运行 node scripts/tools/set-voc-token.js 写入 ~/.openclaw/voc-credentials.json,然后重试当前 Skill。" }, "onBalanceInsufficient": { "action": "resolveUserThenShowPayment", "title": "VOC-AI Token 余额不足,请扫码充值", "message": "当前 Token 余额不足,我将为你生成专属充值链接,扫码支付后即可继续使用。" } }, "errorHandling": { "balanceInsufficient": { "conditions": [ { "responseField": "code", "operator": "in", "value": [ -2, -3, -10, 402, 429 ] }, { "responseField": "msg", "operator": "contains", "value": [ "余额不足", "insufficient", "balance", "quota", "没有开通", "权限或余额" ] }, { "responseField": "mess", "operator": "contains", "value": [ "余额不足", "insufficient", "balance", "quota", "没有开通", "权限或余额" ] }, { "responseField": "message", "operator": "contains", "value": [ "余额不足", "insufficient", "balance", "没有开通", "权限或余额" ] } ], "matchMode": "any", "trigger": "tokenConfig.onBalanceInsufficient" }, "unauthorized": { "conditions": [ { "responseField": "code", "operator": "in", "value": [ 401, 403 ] }, { "responseField": "msg", "operator": "contains", "value": [ "unauthorized", "token", "invalid", "auth" ] } ], "matchMode": "any", "trigger": "tokenConfig.onMissing" } } }