Skip to content

AI agent skill that researches any topic across Reddit, X, YouTube, HN, Polymarket, and the web - then synthesizes a grounded summary

feat(main): integrate Bird setup into main flow

Matt Van Hornecdee52d04f1
diff --git a/scripts/last30days.py b/scripts/last30days.py
index 417df215..3882789b 100644
--- a/scripts/last30days.py
+++ b/scripts/last30days.py
@@ -413,9 +413,31 @@ def main():
# Load config
config = env.get_config()
- # Check available sources
+ # Initialize progress display early for Bird prompts
+ progress = ui.ProgressDisplay(args.topic, show_banner=True)
+
+ # Check Bird availability and offer install if needed
+ x_source_status = env.get_x_source_status(config)
+ x_source = x_source_status["source"]
+
+ # If no X source and Bird can be installed, offer it
+ if x_source is None and x_source_status["can_install_bird"]:
+ bird_result = setup_bird_if_needed(progress)
+ if bird_result == 'bird':
+ x_source = 'bird'
+ # Refresh status
+ x_source_status = env.get_x_source_status(config)
+
+ # Check available sources (now accounting for Bird)
available = env.get_available_sources(config)
+ # Override available if Bird is ready
+ if x_source == 'bird':
+ if available == 'reddit':
+ available = 'both' # Now have both Reddit + X (via Bird)
+ elif available == 'web':
+ available = 'x' # Now have X via Bird
+
# Mock mode can work without keys
if args.mock:
if args.sources == "auto":
@@ -439,9 +461,6 @@ def main():
# Check what keys are missing for promo messaging
missing_keys = env.get_missing_keys(config)
- # Initialize progress display
- progress = ui.ProgressDisplay(args.topic, show_banner=True)
-
# Show promo for missing keys BEFORE research
if missing_keys != 'none':
progress.show_promo(missing_keys)
@@ -492,6 +511,7 @@ def main():
depth,
args.mock,
progress,
+ x_source=x_source or "xai",
)
# Processing phase