feat(x): resolve X handles for person/brand topics via agent WebSearch
When a topic is a person/brand (e.g. "Dor Brothers", "Jason Calacanis"), the agent now resolves their X handle via WebSearch before running the script, then passes --x-handle to search their posts unfiltered (no topic keywords required). This finds posts the entity made without mentioning their own name. - SKILL.md + OpenClaw variant: Step 0.5 handle resolution instructions - last30days.py: --x-handle CLI arg, passed through to _run_supplemental() - bird_x.search_handles(): topic is now Optional[str] for unfiltered mode - schema.py: resolved_x_handle field on Report - render.py: show resolved handle in stats output Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -31,12 +31,24 @@ Research typically takes 2-8 minutes. Starting now.
|
||||
|
||||
---
|
||||
|
||||
## Step 0.5: Resolve X Handle (if topic is a person/brand)
|
||||
|
||||
If TOPIC looks like a **person, creator, brand, or specific account** (1-3 words, proper noun), do ONE quick WebSearch:
|
||||
|
||||
```
|
||||
WebSearch("{TOPIC} X twitter handle")
|
||||
```
|
||||
|
||||
Extract their X handle from results (look for `x.com/{handle}` URLs or "@handle" mentions). If found, pass it to the script as `--x-handle={handle}` (no @). Skip if TOPIC is generic, already has @, or uses `--quick`.
|
||||
|
||||
---
|
||||
|
||||
## Research Execution
|
||||
|
||||
**Step 1: Run the research script (FOREGROUND)**
|
||||
|
||||
```bash
|
||||
python3 "${SKILL_ROOT}/scripts/last30days.py" "$ARGUMENTS" --emit=compact --store 2>&1
|
||||
python3 "${SKILL_ROOT}/scripts/last30days.py" "$ARGUMENTS" --emit=compact --store 2>&1 # Add --x-handle=HANDLE if resolved
|
||||
```
|
||||
|
||||
Use a **timeout of 300000** (5 minutes). The `--store` flag persists findings for watchlist/briefing integration.
|
||||
|
||||
Reference in New Issue
Block a user