بنقرة واحدة
grokipedia-workflow
Grokipedia article workflow - fetch, verify, submit corrections using browser automation
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Grokipedia article workflow - fetch, verify, submit corrections using browser automation
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
| name | grokipedia-workflow |
| description | Grokipedia article workflow - fetch, verify, submit corrections using browser automation |
This skill covers the end-to-end workflow for checking and correcting Grokipedia articles.
1. FETCH article → 2. VERIFY claims with web_search/Wikipedia → 3. SUBMIT corrections
⚠️ NEVER trust Grok's facts without external verification. The entire point is cross-referencing.
┌─────────────────────┐ ┌──────────────────┐ ┌─────────────────┐
│ TypeScript CLI │────▶│ Playwright/CDP │────▶│ Grokipedia │
│ (Copilot SDK) │ │ Browser Manager │ │ (Target Site) │
└─────────────────────┘ └──────────────────┘ └─────────────────┘
│
▼
┌─────────────────────┐
│ web_search Tool │ ← PRIMARY VERIFICATION METHOD
└─────────────────────┘
cd cli
npm install && npm run build
# Single article, dry run (no submissions)
node dist/index.js -a "Bermuda Triangle" --dry-run
# 10 articles with 3 parallel workers
node dist/index.js -n 10 -p 3 --dry-run
# Theme-based with Comet browser
node dist/index.js -n 5 -t "super bowl" -b comet
# Verbose mode (see AI reasoning)
node dist/index.js -n 2 -v --dry-run
Rule of 50: Refresh Copilot session every 50 articles
Rule of 20: New browser tab every 20 articles
Rule of 100: Full browser restart every 100 articles
Why: Long-running AI sessions accumulate context, degrading response quality. Browser tabs leak memory.
const SESSION_REFRESH_INTERVAL = 50; // Recreate Copilot session
const PAGE_RESET_INTERVAL = 50; // Recreate browser session
const PAGE_REFRESH_INTERVAL = 20; // Recreate browser tab
| Browser | Path | Login Persistence |
|---|---|---|
| Comet | /Applications/Comet.app | ✅ Reuses existing session |
| Chrome | /Applications/Google Chrome.app | ✅ Reuses existing session |
| Chromium | Playwright-bundled | ❌ Fresh session each run |
Design decision: CDP-connected browsers (Comet/Chrome) reuse the user's existing login.
| Symptom | Cause | Fix |
|---|---|---|
| "Not signed in" | CDP can't find browser | Open Comet/Chrome, log into Grokipedia, leave running |
| Text selection fails | Special characters (em-dash, curly quotes) | Copy text EXACTLY from fetched content |
| Port 9222 busy | Stale browser process | lsof -ti:9222 | xargs kill -9 |
| AI gives vague responses | Session context bloat | Restart Copilot session |
| Edits not saving | Grokipedia UI changed | Check if edit button selector still works |
# Using CLI
node dist/index.js -a "Article Name" --dry-run
# Or Python script
python3 .github/skills/grokipedia-fetch-content/fetch_content.py "Article Name"
Returns JSON with content, sections, signed_in status, and url.
Do NOT just skim. Proactively verify:
Verification queries:
web_search("Phineas Gage death date")
web_search("Super Bowl VII final score Dolphins Redskins 1973")
web_fetch url="https://en.wikipedia.org/wiki/Phineas_Gage"
python3 .github/skills/grokipedia-submit-edit/submit_edit.py \
--article "Phineas Gage" \
--text "Phineas Gage (1823–1861)" \
--summary "Death year incorrect: Gage died May 21, 1860" \
--correction "Phineas Gage (1823–1860)" \
--sources "https://en.wikipedia.org/wiki/Phineas_Gage"
web_fetch for known articlesEach worker gets its own browser page and Copilot session:
# 3 parallel workers = 3x throughput
node dist/index.js -n 15 -p 3 --dry-run