| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229 |
- {
- "name": "category-landscape",
- "displayName": "品类格局分析",
- "description": "品类全景分析,计算CR5/HHI市场集中度,生成风险预警汇总和优先行动清单,输出《品类认知校准表》",
- "category": "synthesis",
- "version": "1.1.0",
- "type": "orchestration",
- "parameters": {
- "keywords": {
- "type": "array",
- "items": { "type": "string" },
- "required": true,
- "description": "品类核心关键词列表"
- },
- "domain": {
- "type": "integer",
- "required": false,
- "default": 1,
- "description": "Amazon站点(1=美国)"
- },
- "topN": {
- "type": "integer",
- "required": false,
- "default": 100,
- "description": "分析的产品数量"
- }
- },
- "pipeline": [
- {
- "step": 1,
- "name": "搜索品类Top N产品",
- "forEach": "keywords",
- "api": {
- "service": "SorftimeApiService.searchProductsByQuery",
- "endpoint": "/api/ProductQuery",
- "method": "POST",
- "forwardUrl": "https://server.fmode.cn/api/voc/forward",
- "headers": { "Authorization": "Bearer r:858b3ee92314d5447d1fc3cdc10462d7" },
- "requestBody": { "Page": 1, "Query": "1", "QueryType": "7", "Pattern": "${keyword}" },
- "queryParams": { "domain": "${domain}" }
- },
- "output": "searchResults",
- "responseExtract": "Array<{ Asin, Title, Price, Rating, RatingsCount, MonthlySales, Brand, BSR, Photo }>"
- },
- {
- "step": 2,
- "name": "批量获取销量数据",
- "forEach": "searchResults[].Asin (去重)",
- "api": {
- "service": "SorftimeApiService.getAsinSalesVolume",
- "endpoint": "/api/AsinSalesVolume",
- "method": "POST",
- "requestBody": { "ASIN": "${asin}" },
- "queryParams": { "domain": "${domain}" }
- },
- "output": "salesData"
- },
- {
- "step": 3,
- "name": "定位品类类目",
- "api": {
- "service": "SorftimeApiService.getCategoryTree",
- "endpoint": "/api/CategoryTree",
- "method": "POST",
- "requestBody": { "keyword": "${keywords[0]}" },
- "queryParams": { "domain": "${domain}" }
- },
- "output": "categoryTree"
- },
- {
- "step": 4,
- "name": "获取核心关键词搜索量和竞争度",
- "forEach": "keywords",
- "api": {
- "service": "SorftimeApiService.searchKeywords",
- "endpoint": "/api/KeywordQuery",
- "method": "POST",
- "requestBody": { "Keyword": "${keyword}" },
- "queryParams": { "domain": "${domain}" }
- },
- "output": "keywordData"
- },
- {
- "step": 5,
- "name": "获取关键词趋势",
- "forEach": "keywords",
- "api": {
- "service": "SorftimeApiService.getKeywordTrend",
- "endpoint": "/api/KeywordSearchTrend",
- "method": "POST",
- "requestBody": { "Keyword": "${keyword}" },
- "queryParams": { "domain": "${domain}" }
- },
- "output": "keywordTrend"
- },
- {
- "step": 6,
- "name": "市场集中度+价格带+增长判断计算",
- "type": "compute",
- "logic": "analyzeMarket(searchResults, salesData, keywordData, keywordTrend)",
- "algorithm": {
- "cr5": "前5品牌销售额占品类总销售额的比例",
- "cr10": "前10品牌销售额占比",
- "hhi": "赫芬达尔-赫希曼指数(各品牌市场份额平方和 × 10000)",
- "marketSize": "品类月销量总和、月销售额总和",
- "priceBands": "按价格区间统计产品数量和销量占比",
- "brandConcentration": "Top 10 品牌的市场份额",
- "ratingDistribution": "品类整体评分水平",
- "growthStage": "基于搜索趋势判断品类处于增长/成熟/衰退期"
- },
- "output": "marketAnalysis"
- },
- {
- "step": 7,
- "name": "风险预警汇总",
- "type": "compute",
- "logic": "generateRiskAlerts(marketAnalysis)",
- "algorithm": {
- "brandConcentrationRisk": "品牌集中度风险",
- "lowSalesRisk": "低销量风险",
- "ratingRisk": "评分风险",
- "priceWarRisk": "价格战风险",
- "inventoryRisk": "库存风险",
- "complianceRisk": "合规风险",
- "levelLabels": "每项风险标注级别(high/medium/low)和具体描述"
- },
- "output": "riskAlerts"
- },
- {
- "step": 8,
- "name": "优先行动清单",
- "type": "compute",
- "logic": "generatePriorityActions(marketAnalysis, riskAlerts)",
- "algorithm": {
- "triggers": "条件触发式优先级: Listing优化→SKU聚焦→促销→产品迭代→库存→差异化"
- },
- "output": "priorityActions"
- }
- ],
- "response": {
- "type": "object",
- "properties": {
- "marketOverview": {
- "type": "object",
- "properties": {
- "totalProducts": { "type": "integer" },
- "totalMonthlySales": { "type": "integer" },
- "totalMonthlyRevenue": { "type": "number" },
- "avgPrice": { "type": "number" },
- "medianPrice": { "type": "number" },
- "avgRating": { "type": "number" },
- "categoryStage": { "type": "string" }
- }
- },
- "concentration": {
- "type": "object",
- "properties": {
- "cr5": { "type": "number" },
- "cr10": { "type": "number" },
- "hhi": { "type": "integer" },
- "interpretation": { "type": "string" }
- }
- },
- "topBrands": {
- "type": "array",
- "items": {
- "type": "object",
- "properties": {
- "brand": { "type": "string" },
- "marketShare": { "type": "number" },
- "productCount": { "type": "integer" },
- "avgPrice": { "type": "number" },
- "avgRating": { "type": "number" }
- }
- }
- },
- "priceBands": {
- "type": "array",
- "items": {
- "type": "object",
- "properties": {
- "range": { "type": "string" },
- "productCount": { "type": "integer" },
- "salesShare": { "type": "number" },
- "avgRating": { "type": "number" }
- }
- }
- },
- "searchTrend": {
- "type": "object",
- "properties": {
- "mainKeyword": { "type": "string" },
- "monthlySearchVolume": { "type": "integer" },
- "trendDirection": { "type": "string" },
- "growthRate": { "type": "number" }
- }
- },
- "calibrationTable": { "type": "string", "description": "品类认知校准表(Markdown格式)" },
- "riskAlerts": {
- "type": "array",
- "items": {
- "type": "object",
- "properties": {
- "level": { "type": "string", "enum": ["high", "medium", "low"] },
- "title": { "type": "string" },
- "description": { "type": "string" }
- }
- }
- },
- "priorityActions": {
- "type": "array",
- "items": {
- "type": "object",
- "properties": {
- "action": { "type": "string" },
- "priority": { "type": "integer" },
- "trigger": { "type": "string" }
- }
- }
- }
- }
- },
- "timeout": 90000,
- "retry": {
- "maxAttempts": 2,
- "delay": 2000,
- "backoffMultiplier": 2
- }
- }
|