How brandonwlii/zero2scraper works
story-watch polls configured Instagram accounts, enriches new story items, classifies and filters them, then delivers Discord notifications and records delivery state. A separate Discord bot collects human labels and ping preferences; evaluation tools compare classifier predictions with archived labels. The graph emphasizes these product workflows. Relationships for the watcher are supported by its documented flow and README; some internal details are inferred only where the indexed source references or excerpts support them.
Main entry points: main.py Polling loop · cli.py Evaluation CLI · discord_app.py Labeling bot · instagram.py Story fetcher
Components 24
Story watcher
- Polling loop
story_watch/main.py - Service config
story_watch/config.py - Story fetcher
story_watch/instagram.py - SQLite state
story_watch/store.py - Story archive
story_watch/archive.py - Job page titles
story_watch/jobs.py
Classification and delivery
- Classifier
story_watch/classify.py - Tag model
story_watch/tags.py - Post-type filters
story_watch/config.py - Ping matching
story_watch/pings.py - Webhook sender
story_watch/notify.py
Discord bot
- Bot entry
story_watch/bot/main.py - Labeling bot
story_watch/bot/discord_app.py - Label storage
story_watch/bot/labels.py - Ping preferences
story_watch/bot/pings_app.py - Preference model
story_watch/bot/prefs.py
Label evaluation
- Evaluation dataset
story_watch/evaluation/data.py - Tagger runner
story_watch/evaluation/runner.py - Metrics
story_watch/evaluation/metrics.py - Report builder
story_watch/evaluation/report.py - Evaluation CLI
story_watch/evaluation/cli.py
Other components
- Operator
- Discord webhook
Connections 26
- Operator → Polling loop: configures and runs
- Polling loop → Service config: loads settings
story_watch/main.py - Polling loop → Story fetcher: fetches stories
story_watch/main.py - Story fetcher → Instagram: polls accounts
- Polling loop → SQLite state: compares and records
story_watch/main.py - Polling loop → Story archive: archives stories
story_watch/main.py - Polling loop → Classifier: classifies items
story_watch/main.py - Classifier → Tag model: returns tags
story_watch/classify.py - Polling loop → Job page titles: enriches job links
story_watch/main.py - Polling loop → Webhook sender: sends notifications
story_watch/main.py - Polling loop → Post-type filters: filters post types
story_watch/main.py - Polling loop → Ping matching: matches preferences
story_watch/main.py - Webhook sender → Discord webhook: posts webhook
story_watch/notify.py - Operator → Bot entry: runs bot
- Bot entry → Labeling bot: starts app
story_watch/bot/main.py - Labeling bot → Label storage: saves labels
story_watch/bot/discord_app.py - Labeling bot → Story fetcher: uses story data
story_watch/bot/discord_app.py - Ping preferences → Preference model: edits preferences
story_watch/bot/pings_app.py - Ping preferences → SQLite state: reads saved preferences
story_watch/bot/pings_app.py - Ping matching → Preference model: matches saved rules
story_watch/pings.py - Evaluation CLI → Evaluation dataset: loads labeled stories
story_watch/evaluation/cli.py - Evaluation CLI → Tagger runner: runs taggers
story_watch/evaluation/cli.py - Tagger runner → Evaluation dataset: uses dataset
story_watch/evaluation/runner.py - Evaluation CLI → Metrics: computes metrics
story_watch/evaluation/cli.py - Evaluation CLI → Report builder: builds report
story_watch/evaluation/cli.py - Report builder → Metrics: renders results
story_watch/evaluation/report.py