{
  "schema": "leumas.docs.page/1",
  "id": "adapter:domain/content-repurposer",
  "slug": "adapters/domain/content-repurposer",
  "kind": "capabilities",
  "bucket": "package",
  "title": "content-repurposer — content atomization microservice",
  "name": "content-repurposer",
  "eyebrow": "content atomization microservice",
  "chip": null,
  "summary": "Content repurposing & atomization microservice: take one long piece (blog post, article, transcript, essay) and reshape it for every channel — a numbered X/Twitter thread, a LinkedIn post, an...",
  "keywords": [
    "content-repurposer",
    "atomization",
    "essay",
    "newsletter",
    "pull-quotes",
    "content repurposer api",
    "distilled",
    "takeaways"
  ],
  "audience": "both",
  "funnel": {
    "product": null,
    "cta": null
  },
  "body": "# content-repurposer — content atomization microservice\n\nTakes ONE long piece (blog post, article, transcript, essay) and reshapes it for every channel while\nrespecting each platform's length and format rules. A paid \"intelligent microservice\": every tool has\na **deterministic sentence/section-reshaping core that runs fully offline**, and the generative tools\n**optionally** call an LLM (via `../_shared/llm.js`) to polish, silently falling back to the heuristic.\nEvery result is tagged `mode: 'heuristic' | 'llm'`.\n\n## Tools\n\n| tool | output |\n|---|---|\n| `toThread` | Numbered X/Twitter thread, each tweet ≤280 chars, hook first + CTA last. |\n| `toLinkedIn` | LinkedIn post: hook line, short paragraphs, → takeaways, CTA, hashtags (≤3000 chars). |\n| `toInstagramCaption` | IG caption: hook, short body, CTA, auto hashtag block (≤30, ≤2200 chars). |\n| `toNewsletter` | Email: subject, preview text, intro, headed sections, CTA. |\n| `toYoutubeDescription` | Hook, summary, timestamped chapter scaffold, link, keyword hashtags. |\n| `toTikTokScript` | Short-form script: 3s hook, timed beats + on-screen text, follow CTA. |\n| `extractQuotes` | The N most quotable pull-quotes (tweetable-flagged). |\n| `keyPoints` | The N distilled key points/takeaways + top keywords. |\n\nAll tools require `text`. Optional: `title`, `hashtags`, `cta`, `url`, `handle`, `maxTweets`, `count`.\n\n## Usage\n\n```js\nimport repurposer from './index.js';\n\nawait repurposer.adapters.toThread({ text: longPost, title: 'How we cut churn 40%', maxTweets: 8, cta: 'Follow for more' });\nawait repurposer.adapters.toInstagramCaption({ text: longPost, hashtags: ['saas', 'growth'] });\nrepurposer.adapters.keyPoints({ text: longPost, count: 5 });\nrepurposer.adapters.extractQuotes({ text: longPost, count: 3 });\n```\n\nEach call takes ONE args object (maps 1:1 to an HTTP POST body). Missing `text` throws `TypeError`.\n\n## Hybrid intelligence\n\nThe extractive engine (sentence ranking by content-word frequency + position) always produces output.\nWhen an LLM is reachable, `toLinkedIn`, `toInstagramCaption`, and `toTikTokScript` polish the result and\nkeep the heuristic as `fallback`. A down/absent model never throws — the pack works 100% offline.\n\n## DRY boundaries\n\n- **Reshapes** one input across channels. It does **not** generate net-new copy from a product brief\n  (that's `copywriter`), audit HTML/meta (`seo`), or build keyword briefs (`seo-brief`).\n- General NLP primitives (tokenize/summarize/sentiment) live in `nlp`; this is the platform-formatting layer.\n- No cross-pack imports except `../_shared/llm.js`. Pure ESM, Node built-ins only, zero npm deps.\n",
  "source": {
    "path": "shared/engines/adapters/domain/content-repurposer/README.md",
    "blobSha": "",
    "commit": "",
    "committedAt": "",
    "provenance": "no-git",
    "bytes": 2862,
    "hash": "42c3f2f17d780246427c52afe33675200763068a"
  },
  "urls": {
    "html": "/p/adapters/domain/content-repurposer",
    "json": "/docs/adapters/domain/content-repurposer.json",
    "md": "/docs/adapters/domain/content-repurposer.md"
  },
  "links": {
    "composes": [],
    "usedBy": [],
    "product": [],
    "howTo": [],
    "skills": []
  }
}
