A Chrome extension that captures X (Twitter) Articles, translates them via LLM, and exports to Obsidian as bilingual Markdown notes.
- One-click capture of X Articles and long posts
- Multi-provider LLM translation (Claude, OpenAI, DeepSeek, custom)
- Automatic image download and local asset management
- Bilingual notes with translated + original sections
- YAML frontmatter with metadata (author, source URL, language, tags)
- Cinema Dark UI that follows X's theme
- Capture history with export support
git clone https://github.com/Moolan-d/x2o.git
cd x2o
npm install
npm run buildThen load the .output/chrome-mv3 directory as an unpacked extension in Chrome (chrome://extensions/ > Developer mode > Load unpacked).
Open the extension's Options page to configure:
- LLM Provider - Claude, OpenAI, DeepSeek, or custom endpoint + API key
- Translation - Source and target language
- Obsidian - Local REST API URL and API token
Install Obsidian Local REST API plugin, then set the API URL and token in the extension options.
- Navigate to any X Article page (
x.com/user/article/...) - Click the floating button (bottom-right) or use the extension popup
- The article is captured, translated, and saved to your Obsidian vault
# Build once
npm run build
# Watch mode - rebuilds on file changes
npm run dev
# Build release zip
npm run zipentrypoints/
├── content.ts # Content script - DOM scraping + FAB injection
├── background.ts # Service worker - translation pipeline + Obsidian export
├── popup.html/ts # Extension popup UI
└── options.html/ts # Settings page
lib/
├── markdown.ts # Turndown HTML→MD with X Article custom rules
├── scraper.ts # DOM scraper for X Article pages
├── translator.ts # Multi-provider LLM translation
├── obsidian.ts # Obsidian Local REST API client
├── settings.ts # Chrome storage wrapper
├── history.ts # Capture history storage
├── theme.ts # X theme detection
├── logger.ts # Pipeline logger
└── types.ts # Shared TypeScript types
components/
├── fab.ts # Floating action button
└── toast.ts # Toast notifications
- CI: Pull requests run typecheck and build checks
- Release: Pushes to
maintriggersemantic-release, which analyzes commit messages and creates a new version automatically (feat:= minor,fix:= patch) - Publish: New releases are zipped via
wxt zipand uploaded to GitHub Releases