Skip to content

Commit

Permalink
feat: x services (#43)
Browse files Browse the repository at this point in the history
* feat: twitter services

* fix: package.json

* fix: type error

* refactor: launcher

* refactor: BrowserBase/Stagehand

* fix: config & startup

* chore: i18n

* fix: continue i18n

* feat: cookie login

* fix: save cookie to session json

* docs: architecture

* chore: remove cli & use mcp adapter for mcp-server

* refactor: remove browser adapter, use playwright directly

* refactor: remove launcher services, replace twitter.com to x.com

* feat: load session to auto login

* docs: update architecture md

* chore: more debug logs

* feat: tweet parser without hast and rehype

* fix: type error

* fix: env example
  • Loading branch information
luoling8192 authored Mar 4, 2025
1 parent 31ec4cc commit 4e1870d
Show file tree
Hide file tree
Showing 22 changed files with 4,030 additions and 74 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,5 @@ coverage/
*.mp3

**/temp/

twitter-session.json
1 change: 1 addition & 0 deletions cspell.config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ words:
- baiducloud
- bigserial
- Bitstream
- browserbasehq
- bumpp
- catppuccin
- changelogithub
Expand Down
766 changes: 692 additions & 74 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

21 changes: 21 additions & 0 deletions services/twitter-services/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Browser Config
BROWSER_HEADLESS=false
BROWSER_USER_AGENT=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36
BROWSER_VIEWPORT_WIDTH=1280
BROWSER_VIEWPORT_HEIGHT=800
BROWSER_TIMEOUT=30000
BROWSER_REQUEST_TIMEOUT=20000
BROWSER_REQUEST_RETRIES=2

# Adapter Config
ENABLE_AIRI=false
AIRI_URL=http://localhost:3000
AIRI_TOKEN=your_airi_token

ENABLE_MCP=true
MCP_PORT=8080

# System Config
LOG_LEVEL=info # Optional: error, warn, info, verbose, debug
LOG_FORMAT=pretty # Optional: json, pretty
CONCURRENCY=1
Loading

0 comments on commit 4e1870d

Please sign in to comment.