Skip to content

Hook Generation

Hook workflows generate viral opening lines grounded in real competitor data and trend signals. They can scrape creator channels, classify hook patterns, cluster by similarity, and score for estimated virality.

Workflow: hooks/generate

Generates viral hooks for a niche, optionally grounded in scraped competitor data.

Terminal window
fabric run hooks/generate \
--input niche="AI productivity" \
--input platform="TikTok" \
--input num_hooks=15
scrape_creator_hooks (optional, if competitors provided)
extract_hook_features
cluster_hooks
gather_competitor_insights
generate_hook_ideas
score_hook_ideas
ParameterTypeDefaultDescription
nichestringrequiredContent niche
competitorslist[str][]Channel URLs/handles to scrape
platformstring"YouTube"Target platform
trendsdict{}Trend signals from research
num_hooksint15Number of hooks to generate
{
"hook_ideas": [
{
"hook_text": "Stop building AI features nobody asked for",
"hook_type": "controversial_take",
"emotional_trigger": "frustration",
"estimated_strength": 0.89,
"tone": "authoritative",
"video_angle": "expose common mistake"
}
]
}

The system classifies hooks into these patterns:

TypeExample
controversial_take”Most productivity advice is wrong”
surprising_stat”90% of startups fail because of this”
story_hook”I spent $50K on AI tools last year. Here’s what happened.”
question”Why do the best developers avoid frameworks?”
challenge”Try this for 30 days and your code will improve”
fear_based”Your job is about to change forever”
curiosity_gap”The one thing nobody tells you about AI”

Workflow: hooks/scrape

Scrapes video openers from YouTube or TikTok channels to build a hook corpus.

Terminal window
fabric run hooks/scrape \
--input channels='["@fireship", "@mkbhd"]' \
--input platform="youtube" \
--input max_per_channel=20
ParameterTypeDefaultDescription
channelslist[str]requiredChannel URLs or handles
platformstring"youtube"Platform to scrape
max_per_channelint20Videos per channel
shorts_onlyboolfalseOnly scrape Shorts
{
"scraped_hooks": [
{
"channel": "@fireship",
"video_id": "abc123",
"hook_text": "This new JavaScript framework is wild",
"transcript_excerpt": "..."
}
]
}

Workflow task: hooks/from_research

Transforms deep research output into the format expected by hook generation. Used internally by composed pipelines.

# Bridges research synthesis → hook generation context
# Maps synthesis themes → trends
# Maps raw sources → competitor insights