.hermes-plugin/SKILL.md
Multi-query social search with intelligent planning. Research any topic across Reddit, X, YouTube, TikTok, Instagram, Hacker News, Polymarket, and the web.
npx skillsauth add mvanhorn/last30days-skill last30daysInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Permissions overview: Reads public web/platform data and optionally saves research briefings to
~/Documents/Last30Days/. X/Twitter search uses optional user-provided tokens (AUTH_TOKEN/CT0 env vars). Bluesky search uses optional app password (BSKY_HANDLE/BSKY_APP_PASSWORD env vars - create at bsky.app/settings/app-passwords). All credential usage and data writes are documented in the Security & Permissions section.
Research ANY topic across Reddit, X, YouTube, and other sources. Surface what people are actually discussing, recommending, betting on, and debating right now.
Before running any last30days.py command in this skill, resolve a Python 3.12+ interpreter once and keep it in LAST30DAYS_PYTHON:
for py in python3.14 python3.13 python3.12 python3; do
command -v "$py" >/dev/null 2>&1 || continue
"$py" -c 'import sys; raise SystemExit(0 if sys.version_info >= (3, 12) else 1)' || continue
LAST30DAYS_PYTHON="$py"
break
done
if [ -z "${LAST30DAYS_PYTHON:-}" ]; then
echo "ERROR: last30days v3 requires Python 3.12+. Install python3.12 or python3.13 and rerun." >&2
exit 1
fi
CRITICAL: ALWAYS execute Step 0 BEFORE Step 1, even if the user provided a topic. If the user typed last30days Mercer Island, you MUST check for FIRST_RUN and present the wizard BEFORE running research. The topic "Mercer Island" is preserved — research runs immediately after the wizard completes. Do NOT skip the wizard because a topic was provided. The wizard takes 10 seconds and only runs once ever.
To detect first run: check if ~/.config/last30days/.env exists. If it does NOT exist, this is a first run. Do NOT run any Bash commands or show any command output to detect this — just check the file existence silently. If the file exists and contains SETUP_COMPLETE=true, skip this section silently and proceed to Step 1. Do NOT say "Setup is complete" or any other status message — just move on. The user doesn't need to be told setup is done every time they run the skill.
When first run is detected, detect your platform first:
If you do NOT have WebSearch capability (raw CLI): Run the terminal-only setup flow below. If you DO have WebSearch (Hermes): Run the standard setup flow below.
Run environment detection first:
"${LAST30DAYS_PYTHON}" "${SKILL_ROOT}/scripts/last30days.py" setup --terminal
Read the JSON output. It tells you what's already configured. Display a status summary:
👋 Welcome to last30days!
Detected:
{✅ or ❌} yt-dlp (YouTube search)
{✅ or ❌} X/Twitter ({method} configured)
{✅ or ❌} ScrapeCreators (TikTok, Instagram, Reddit backup)
{✅ or ❌} Web search ({backend} configured)
Then for each missing item, offer setup in priority order:
ScrapeCreators (if not configured): "ScrapeCreators adds TikTok and Instagram search (plus a Reddit backup if public Reddit gets rate-limited). 10,000 free calls, no credit card. (No referrals, no kickbacks - we don't get a cut.)"
gh CLI was detected in the environment detection output above. If gh IS detected: description should say "Registers directly via GitHub CLI in ~2 seconds - no browser needed". Before running the command, display: "Registering via GitHub CLI..." If gh is NOT detected: description should say "Copies a one-time code to your clipboard and opens GitHub to authorize". Then run "${LAST30DAYS_PYTHON}" "${SKILL_ROOT}/scripts/last30days.py" setup --github, parse JSON output. Tries PAT first (if gh is installed), falls back to device flow which copies a one-time code to your clipboard and opens your browser. If status is success, write `SCRAPECREATORS_API_KEY=*** to .env.X/Twitter (if not configured): "X search finds tweets and conversations. To unlock X: add FROM_BROWSER=auto (reads browser cookies, free), XAI_API_KEY (no browser access, api.x.ai), or AUTH_TOKEN+CT0 (manual cookies)."
YouTube (if yt-dlp not found): "YouTube search needs yt-dlp. Run: pip install yt-dlp"
Web search (if no Brave/Exa/Serper key): "A web search key enables smarter results. Brave Search is free for 2,000 queries/month at brave.com/search/api"
After setup, write SETUP_COMPLETE=true to .env and proceed to research.
Skip to "END OF FIRST-RUN WIZARD" below after completing the terminal-only flow.
You MUST follow these steps IN ORDER. Do NOT skip ahead to the topic picker or research. The sequence is: (1) welcome text -> (2) setup modal -> (3) run setup if chosen -> (4) optional ScrapeCreators modal -> (5) topic picker. You MUST start at step 1.
Step 1: Display the following welcome text ONCE as a normal message (not blockquoted). Then IMMEDIATELY call AskUserQuestion - do NOT repeat any of the welcome text inside the AskUserQuestion call.
Welcome to last30days!
I research any topic across Reddit, X, YouTube, and other sources - synthesizing what people are actually saying right now.
Auto setup gives you 5 core sources for free in 30 seconds:
gh CLI installed) - always on, zero configWant TikTok and Instagram too? ScrapeCreators adds those (10,000 free calls, scrapecreators.com). No kickbacks, no affiliation.
Then call AskUserQuestion with ONLY this question and these options - no additional text:
Question: "How would you like to set up?" Options:
If the user picks 1 (Auto setup):
Before running the setup command, get cookie consent:
Check if BROWSER_CONSENT=true already exists in ~/.config/last30days/.env. If it does, skip the consent prompt and run setup directly.
If BROWSER_CONSENT=true is NOT present, call AskUserQuestion:
Question: "Auto setup will scan your browser for x.com cookies to authenticate X search. Cookies are read live, not saved to disk. Chrome on macOS will prompt for Keychain access. OK to proceed?"
Options:
BROWSER_CONSENT=true to .env after setup completes.Run the setup subcommand:
cd {SKILL_DIR} && "${LAST30DAYS_PYTHON}" scripts/last30days.py setup
Show the user the results (what cookies were found, whether yt-dlp was installed).
Then show the optional ScrapeCreators offer (plain text, then modal):
Want TikTok and Instagram too? ScrapeCreators adds those platforms - 10,000 free calls, no credit card. It also serves as a Reddit backup if public Reddit ever gets rate-limited.
Before showing the ScrapeCreators modal, check for gh CLI: Run which gh via Bash silently. Store the result as gh_available (true if found, false if not).
Call AskUserQuestion: Question: "Want to add TikTok, Instagram, and Reddit backup via ScrapeCreators? (We don't get a cut.)" Options:
cd {SKILL_DIR} && "${LAST30DAYS_PYTHON}" scripts/last30days.py setup --github via Bash with a 5-minute timeout. This tries PAT auth first (if gh CLI is installed, zero browser needed), then falls back to GitHub device flow which copies a one-time code to your clipboard and opens GitHub in your browser. Parse the JSON stdout. If status is success, write SCRAPECREATORS_API_KEY=*** to ~/.config/last30days/.env. If methodispat, show: "You're in! Registered via GitHub CLI - zero browser needed. 10,000 free calls. TikTok, Instagram, and Reddit backup are now active." If methodisdeviceandclipboard_okis true, show: "You're in! (The authorization code was copied to your clipboard automatically.) 10,000 free calls. TikTok, Instagram, and Reddit backup are now active." Ifmethodisdeviceandclipboard_okis false, show: "You're in! 10,000 free calls. TikTok, Instagram, and Reddit backup are now active." Ifstatusistimeoutorerror`, show: "GitHub auth didn't complete. No worries - you can sign up at scrapecreators.com instead or try again later." Then offer the web signup option.open https://scrapecreators.com via Bash to open in the user's browser. Then ask them to paste the API key they get. When they paste it, write SCRAPECREATORS_API_KEY=*** to ~/.config/last30days/.envAfter SC key is saved (not if skipped), show the TikTok/Instagram opt-in:
Call AskUserQuestion: Question: "Enable TikTok and Instagram search?" Options:
TIKTOK_ENABLED=true and INSTAGRAM_ENABLED=true to .env. Then show: "TikTok and Instagram are now enabled. You can disable them later by editing ~/.config/last30days/.env."After setup completes, write SETUP_COMPLETE=true to .env.
Proceed to Step 1.
The user invoked: last30days {QUERY}
Extract the topic. If the query is empty or ambiguous, ask for clarification.
Run the research engine:
cd {SKILL_DIR} && "${LAST30DAYS_PYTHON}" scripts/last30days.py "{TOPIC}" --emit=compact --lookback-days=30
Optional flags based on user request:
--search=reddit,youtube,hackernews - Specific sources only--days=7 - Shorter time range--deep - Higher recall mode--save - Save to ~/Documents/Last30Days/Show the research output to the user. The compact output includes:
What this skill does:
api.scrapecreators.com) for TikTok and Instagram search, and as a Reddit backup when public Reddit is unavailable (requires SCRAPECREATORS_API_KEY)api.openai.com) for Reddit discovery (fallback if no SCRAPECREATORS_API_KEY)api.x.ai) for X searchhn.algolia.com) for Hacker News story and comment discovery (free, no auth)gamma-api.polymarket.com) for prediction market discovery (free, no auth)yt-dlp locally for YouTube search and transcript extraction (no API key, public data)api.scrapecreators.com) for TikTok and Instagram search, transcript/caption extraction (PAYG after 10,000 free API calls)reddit.com for engagement metricsWhat this skill does NOT do:
--agent for non-interactive report outputBundled scripts: scripts/last30days.py (main research engine), scripts/lib/ (search, enrichment, rendering modules), scripts/lib/vendor/bird-search/ (vendored X search client, MIT licensed)
Review scripts before first use to verify behavior.
development
Research what people actually say about any topic in the last 30 days. Pulls posts and engagement from Reddit, X, YouTube, TikTok, Hacker News, Polymarket, GitHub, and the web.
development
Research what people actually say about any topic in the last 30 days. Pulls posts and engagement from Reddit, X, YouTube, TikTok, Hacker News, Polymarket, GitHub, and the web.
development
Multi-query social search with intelligent planning. Agent plans queries when possible, falls back to Gemini/OpenAI when not. Research any topic across Reddit, X, YouTube, TikTok, Instagram, Hacker News, Polymarket, and the web.
development
[V3 DEV] Research any topic from the last 30 days. Side-by-side test version of the v3 pipeline.