Communitygithub.com

ComeOnOliver/skillshub

Intelligently compress and rewrite documents into TTS-friendly scripts. Uses Claude AI to analyze content, compress to target duration, convert to spoken style with emotional language, and auto-segment. Perfect for video narration.

skillshub とは?

skillshub is a Claude Code agent skill that intelligently compress and rewrite documents into TTS-friendly scripts. Uses Claude AI to analyze content, compress to target duration, convert to spoken style with emotional language, and auto-segment. Perfect for video narration.

対応✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/ComeOnOliver/skillshub/tree/HEAD/skills/huangserva/servasyy_skills/tts-script-generator

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

TTS Script Generator

智能压缩和改写文档为适合 TTS 朗读的脚本。

核心能力

  • 🤖 AI 智能分析:Claude 分析文章内容,判断最佳视频时长和配图风格
  • ⏱️ 智能时长决策:根据内容自动决定合适的时长(3-8分钟)
  • 🎨 智能风格决策:根据主题自动选择配图风格(纽约客/浮世绘/扁平/写实等)
  • 📉 智能压缩:按最佳时长压缩内容(如 19分钟 → 5分钟)
  • 💬 口语化转换:书面语 → 自然口语
  • 😊 情感优化:添加情感词语,让 TTS 更生动
  • 🎯 自动分段:根据内容自动判断最佳段数(每段 10-20 秒)
  • 📊 时长预估:精确计算每段朗读时长

工作原理

在 Claude 对话中执行:

  1. Claude 读取原文档
  2. Claude 分析内容:
    • 文章主题和结构
    • 核心观点数量
    • 内容密度
    • 判断最佳视频时长(3-8分钟)
    • 判断最适合的配图风格(如:历史类→浮世绘,科技类→扁平,人文类→纽约客)
  3. Claude 智能改写:
    • 提取核心观点
    • 按最佳时长压缩
    • 转换为口语化表达
    • 添加情感词语和停顿
  4. Claude 自动分段(每段适合配一张图)
  5. 根据文章主题判断最适合的配图风格
  6. 为每段生成配图描述(使用判断的风格)
  7. 输出两个文件:
    • tts_script.json(TTS文本脚本 + 动画标记)
    • visual_config.json(配图描述,供 illustration-generator 使用)

tts_script.json 格式(新增动画标记):

[
  {
    "segment": 1,
    "text": "今天聊聊唐朝真实生活。想穿越?先等等!",
    "duration": 15,
    "animation_style": "fade_in",
    "emphasis": true
  },
  {
    "segment": 2,
    "text": "唐朝可没卫生纸,上厕所用什么?",
    "duration": 12,
    "animation_style": "none",
    "emphasis": false
  }
]

动画标记规则(Claude 智能决策):

  • animation_style:
    • "fade_in" - 标题、开场、重点强调
    • "write" - 核心观点、关键结论
    • "typewriter" - 数据、事实陈述
    • "none" - 普通内容(使用 ASS 字幕)
  • emphasis: 是否为重点片段(true/false)

决策原则:

  1. 第1段(开场)→ fade_in
  2. 核心观���(每个章节的第1段)→ write
  3. 数据/事实 → typewriter
  4. 其他内容 → none(ASS 字幕)
  5. 建议:24段中,3-5段用动画即可

执行脚本

generate.py - 生成 TTS 脚本

python ~/.claude/skills/tts-script-generator/scripts/generate.py <markdown文件>
  • 读取 Markdown 文件
  • 提取 H2 章节
  • 转换为口语化
  • 按时长分割
  • 输出 tts_script.json

使用场景

  1. 视频配音:配合 image-to-video(主要用途)
  2. 播客生成:配合 podcast-generator

输出说明

本 skill 输出:

  • ✅ tts_script.json - TTS 文本脚本
  • ✅ visual_config.json - 配图描述

不包含:

  • ❌ TTS 音频生成(由 image-to-video skill 负责)
  • ❌ 配图生成(需调用 illustration-generator skill)
  • ❌ 视频合成(需调用 image-to-video skill)

调用方式

由 image-to-video skill 自动调用:

image-to-video 检测到长文档 
  → 调用 tts-script-generator
  → Claude 在对话中改写
  → 输出压缩后的 TTS 脚本
  → image-to-video 继续处理

手动调用(在 Claude 对话中):

用户: "请用 tts-script-generator 改写这篇文章"

Claude: 
1. 读取文档(5947 字,19 分钟)
2. 分析内容:
   - 主题:唐朝生活科普(历史人文类)
   - 核心观点:4个(卫生、饮食、管制、阶级)
   - 判断最佳时长:5 分钟(内容密度适中)
   - 判断配图风格:浮世绘风格(历史题材,东方古典美学)
3. 改写为 1350 字
4. 分成 20 段(每段 15 秒)
5. 为每段生成浮世绘风格配图描述
6. 保存 tts_script.json + visual_config.json

输出格式

tts_script.json

[
  {
    "segment": 1,
    "text": "今天聊聊唐朝真实生活。想穿越?先等等!唐朝可没卫生纸...",
    "duration": 15
  }
]

visual_config.json

{
  "article_title": "穿越唐朝的真相",
  "style": "ukiyo-e",
  "sections": [
    {
      "section": 1,
      "visual_description": "A person standing at a crossroads between modern city and ancient Tang Dynasty palace, looking confused, ukiyo-e style with traditional Japanese woodblock print aesthetics"
    }
  ]
}

配图风格决策规则

Claude 会根据文章主题自动选择最适合的风格:

  • 历史/古典类 → ukiyo-e(浮世绘):唐朝、宋朝、日本历史等
  • 人文/社会类 → new-yorker(纽约客):社会观察、人物故事等
  • 科技/商业类 → flat(扁平风格):科技产品、商业分析等
  • 自然/旅行类 → realistic(写实风格):风景、动物、旅行等
  • 艺术/创意类 → abstract(抽象风格):艺术评论、创意思考等

改写原则

  1. 保留核心:保留最重要的观点和故事
  2. 口语化:
    • "但是" → "但是呢"
    • "因为...所以..." → "为什么呢?因为..."
    • 添加语气词:"啊"、"呢"、"吧"
  3. 情感词语:
    • 强调:"真的"、"非常"、"特别"
    • 惊叹:"哇"、"天哪"、"想象一下"
  4. 节奏控制:
    • 短句为主
    • 适当停顿
    • 每段一个核心点

可被调用

  • image-to-video skill(主要)
  • podcast-generator skill
  • 其他需要 TTS 的 skills

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

ComeOnOliver/skillshub

Create stunning, animation-rich HTML presentations from scratch or by converting PowerPoint files. Use when the user wants to build a presentation, convert a PPT/PPTX to web, or create slides for a talk/pitch. Helps non-designers discover their aesthetic through visual exploration rather than abstract choices.

ComeOnOliver/skillshub

Next.js 16+ 和 Turbopack — 增量打包、文件系统缓存、开发速度,以及何时使用 Turbopack 与 webpack。

ComeOnOliver/skillshub

SwiftUI architecture patterns, state management with @Observable, view composition, navigation, performance optimization, and modern iOS/macOS UI best practices.

ComeOnOliver/skillshub

See, Understand, Act on video and audio. See- ingest from local files, URLs, RTSP/live feeds, or live record desktop; return realtime context and playable stream links. Understand- extract frames, build visual/semantic/temporal indexes, and search moments with timestamps and auto-clips. Act- transcode and normalize (codec, fps, resolution, aspect ratio), perform timeline edits (subtitles, text/image overlays, branding, audio overlays, dubbing, translation), generate media assets (image, audio, video), and create real time alerts for events from live streams or desktop capture.

ComeOnOliver/skillshub

AI-assisted video editing workflows for cutting, structuring, and augmenting real footage. Covers the full pipeline from raw capture through FFmpeg, Remotion, ElevenLabs, fal.ai, and final polish in Descript or CapCut. Use when the user wants to edit video, cut footage, create vlogs, or build video content.

ComeOnOliver/skillshub

Next.js 15 애플리케이션을 위한 프론트엔드 개발 가이드라인. React 19, TypeScript, Shadcn/ui, Tailwind CSS를 사용한 모던 패턴. Server Components, Client Components, App Router, 파일 구조, Shadcn/ui 컴포넌트, 성능 최적화, TypeScript 모범 사례 포함. 컴포넌트, 페이지, 기능 생성, 데이터 페칭, 스타일링, 라우팅, 프론트엔드 코드 작업 시 사용.

ComeOnOliver/skillshub

Provides Tamagui patterns for config v4, compiler optimization, styled context, and cross-platform styling. Must use when working with Tamagui projects (tamagui.config.ts, @tamagui imports).

ComeOnOliver/skillshub

Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.

ComeOnOliver/skillshub

Create high-converting, visually distinctive landing pages. Use when building marketing pages, product launches, SaaS homepages, or any single-page conversion-focused website. Guides section-by-section composition with anti-AI-slop principles.

ComeOnOliver/skillshub

Auto-loaded context for Portfolio Buddy 2 development. Use for ANY task involving: React 19 development, TypeScript, portfolio analysis features, metrics calculations, trading strategy comparison, or working with the Portfolio Buddy 2 codebase. Contains tech stack, known issues, and architectural constraints.

ComeOnOliver/skillshub

Next.js development tooling via MCP. Inspect routes, components, build info, and debug Next.js apps. Use when working on Next.js applications, debugging routing, or inspecting app structure. NOT for general React or non-Next.js projects.

ComeOnOliver/skillshub

Implement UI using Shadcn MCP (atoms/theme) and 21st.dev MCP (complex sections). Use when adding buttons, layouts, or generating landing pages.

ComeOnOliver/skillshub

A conceptual skill for building an API client in Next.js that handles JWT tokens

ComeOnOliver/skillshub

Best practices and patterns for Next.js App Router, Server Actions, and Routing in this project.

ComeOnOliver/skillshub

The Design System, Theme, and UX rules for the Physical AI Hub.

ComeOnOliver/skillshub

Comprehensive frontend development skill for building modern, performant web applications using ReactJS, NextJS, TypeScript, Tailwind CSS. Includes component scaffolding, performance optimization, bundle analysis, and UI best practices. Use when developing frontend features, optimizing performance, implementing UI/UX designs, managing state, or reviewing frontend code.

ComeOnOliver/skillshub

This document captures learnings from fixing keyboard navigation issues when floating components (Select, DropdownMenu, Popover) have CSS open/close animations.

ComeOnOliver/skillshub

Build Next.js 16 applications with correct patterns and distinctive design. Use when creating pages, layouts, dynamic routes, upgrading from Next.js 15, or implementing proxy.ts. Covers breaking changes (async params/searchParams, Turbopack, cacheComponents) and frontend aesthetics. NOT when building non-React or backend-only applications.

ComeOnOliver/skillshub

Comprehensive Framer Motion animation library for React. Covers motion components, variants, gestures, page transitions, and scroll animations. Use when adding animations to React/Next.js applications.

ComeOnOliver/skillshub

Build interfaces that resonate, not just render. This skill enforces bold, intentional

関連スキル