api-config.json 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. {
  2. "name": "douyin-viral-script-analyzer",
  3. "displayName": "抖音爆款口播结构拆解器",
  4. "description": "读取抖音视频、评论、回复和可选逐字稿,输出钩子类型、开头模式、核心冲突、证明点、评论触发点和可复用口播框架。",
  5. "category": "douyin",
  6. "version": "0.1.0",
  7. "type": "local-script",
  8. "execution": {
  9. "kind": "command",
  10. "command": "node",
  11. "args": [
  12. "scripts/tools/openclaw-tool-runner.js",
  13. "--tool",
  14. "douyin-viral-script-analyzer.js",
  15. "--result-prefix",
  16. "DOUYIN_VIRAL_SCRIPT_RESULT",
  17. "--",
  18. "--input",
  19. "{{input}}",
  20. "--output",
  21. "{{output}}",
  22. "--text",
  23. "{{text}}",
  24. "--transcript",
  25. "{{transcript}}",
  26. "--limit",
  27. "{{limit}}"
  28. ],
  29. "cwd": "{{workspaceRoot}}",
  30. "outputParser": { "type": "stdout-prefix-json", "prefix": "DOUYIN_VIRAL_SCRIPT_RESULT=" },
  31. "exitCodes": { "0": "ok | needs_data", "1": "error" }
  32. },
  33. "parameters": {
  34. "type": "object",
  35. "required": ["output"],
  36. "properties": {
  37. "input": { "type": "string", "description": "抖音采集结果 JSON、目录或 daily-report.json" },
  38. "output": { "type": "string", "description": "输出目录" },
  39. "text": { "type": "string", "description": "单条视频描述或逐字稿文本" },
  40. "transcript": { "type": "string", "description": "transcript.txt 或 transcript.json" },
  41. "limit": { "type": "integer", "default": 10 }
  42. }
  43. },
  44. "output": {
  45. "type": "object",
  46. "properties": {
  47. "status": { "type": "string" },
  48. "outputDir": { "type": "string" },
  49. "analysisCount": { "type": "integer" },
  50. "files": { "type": "array" }
  51. }
  52. },
  53. "deployment": {
  54. "toolInstallPaths": [
  55. "~/.openclaw/tools/douyin-viral-script-analyzer.js",
  56. "~/.openclaw/workspace/scripts/tools/douyin-viral-script-analyzer.js",
  57. "~/.openclaw/workspace/scripts/tools/openclaw-tool-runner.js"
  58. ]
  59. }
  60. }