{
  "schema": "leumas.docs.page/1",
  "id": "adapter:domain/video-script",
  "slug": "adapters/domain/video-script",
  "kind": "capabilities",
  "bucket": "package",
  "title": "video-script",
  "name": "Video Script",
  "eyebrow": null,
  "chip": null,
  "summary": "Intelligent short-form & long-form video scripting microservice: turn a topic into scroll-stopping hooks, a full beat-structured script for a target duration, a retention-beat map...",
  "keywords": [
    "video-script",
    "scroll-stopping",
    "beat-structured",
    "retention-beat",
    "shot-by-shot",
    "call-to-action",
    "payoff",
    "b-roll"
  ],
  "audience": "both",
  "funnel": {
    "product": null,
    "cta": null
  },
  "body": "# video-script\n\nIntelligent video-scripting microservice. Turns a **topic** into everything you need to shoot a\nshort- or long-form video: scroll-stopping **hooks**, a **beat-structured script** sized to a target\nduration, a **retention-beat** timeline, **timed captions** (SRT), a **scene/B-roll list**, and\n**call-to-action** variants.\n\nEvery tool has a deterministic heuristic/template core that runs **fully offline** with no model. The\ngenerative tools (`hook`, `script`, `cta`) also try an optional LLM (via `../_shared/llm.js`) and\n**silently fall back** to the template when no model is reachable. Results carry `mode: 'heuristic' | 'llm'`.\n\n## Tools\n\n| Tool | Args | Returns |\n|---|---|---|\n| `hook` | `{ topic, count?, tone?, audience?, platform? }` | ranked hook variants (formula-driven; optional LLM rewrite) |\n| `script` | `{ topic, duration?, wpm?, tone?, platform?, audience? }` | beat framework (hook→context→value beats→payoff→CTA) with per-beat word/time budgets + full `scriptText` |\n| `retentionBeats` | `{ topic, duration? }` | pattern-interrupt / open-loop / re-hook timeline + predicted retention curve |\n| `captions` | `{ script, wpm?, options.maxCharsPerCaption? }` | timed subtitle cues + a ready `.srt` string |\n| `sceneList` | `{ topic?, script?, duration?, wpm? }` | shot-by-shot scene plan (shot type, narration, text overlay, B-roll) |\n| `cta` | `{ goal?, platform?, count?, audience?, options.product?, options.link? }` | ranked call-to-action variants |\n\n`duration` accepts `60`, `'60s'`, `'2m'`, `'1m30s'`. `platform` ∈ `tiktok|reels|shorts|youtube|ad|explainer`.\n\n## Example\n\n```js\nimport pack from './index.js';\n\nconst s = await pack.adapters.script({ topic: 'cold email that gets replies', duration: '60s', platform: 'shorts' });\nconsole.log(s.beats.map(b => `${b.label} (${b.durationSec}s): ${b.line}`));\n\nconst caps = pack.adapters.captions({ script: s.scriptText, wpm: 150 });\nconsole.log(caps.srt);\n```\n\n## DRY boundaries\n\n- Not **seo** (that generates page meta tags / sitemaps / JSON-LD, not spoken video narrative).\n- Not **a-text** (generic string transforms) or **chatbots** (conversational agents).\n- Caption timing here is spoken-word cue timing, distinct from **datetime** clock math.\n- Self-contained: no cross-pack imports except `../_shared/llm.js`.\n",
  "source": {
    "path": "shared/engines/adapters/domain/video-script/README.md",
    "blobSha": "",
    "commit": "",
    "committedAt": "",
    "provenance": "no-git",
    "bytes": 2525,
    "hash": "9fb336b488e2ce4632051ff4e83f10956dbbcc04"
  },
  "urls": {
    "html": "/p/adapters/domain/video-script",
    "json": "/docs/adapters/domain/video-script.json",
    "md": "/docs/adapters/domain/video-script.md"
  },
  "links": {
    "composes": [],
    "usedBy": [],
    "product": [],
    "howTo": [],
    "skills": []
  }
}
