Skip to content

Conversation

@rcholic
Copy link

@rcholic rcholic commented Jan 11, 2026

.env Example:

BROWSER_USE_API_KEY=bu_browser_use_api_key
SENTIENCE_API_KEY=sk_live_sentience_ai_com_api_key
OPENAI_API_KEY=sk_your_openai_key

Dependencies

pip install browser-use sentienceapi

For local LLM Examples:

pip install browser-use sentienceapi transformers torch accelerate

For local LLM with quantization*

pip install browser-use sentienceapi transformers torch accelerate bitsandbytes

1. Browser-Use LLM with Vision Disabled:

Snapshot Prompt to LLM

Rules: ordinal→DG=1 then ord asc; otherwise imp desc. Use click(ID)/input_text(ID,...).

Elements: ID role text imp is_primary docYq ord DG href
49 link Show HN: Epstein IM – Talk ... 10300 0 0 0 1 epstein
774 textbox 1014 0 6 - 0
238 link Show HN: AI Vibe Coding Hac... 300 0 2 8 1 devpost
685 link Show HN: Rocket Launch and ... 300 0 5 27 1 donuttheje
145 link Show HN: GlyphLang – An AI-... 300 0 1 4 1 ycombinato
355 link Show HN: VAM Seek – 2D vide... 300 0 3 13 1 github
733 link Show HN: A website that auc... 300 0 6 29 1 thedailyau
307 link Show HN: I built an Open So... 300 0 2 11 1 partridge
379 link Show HN: Vehluna – A visual... 300 0 3 14 1 vercel
403 link Show HN: Terminal UI for GCP 300 0 3 15 1 github
547 link Show HN: I built a fast, mi... 300 0 4 21 1 dota2
190 link Show HN: Porting xv6 to HiF... 300 0 1 6 1 github
523 link Show HN: Various shape regu... 300 0 4 20 1 github
709 link Show HN: EuConform – Offlin... 300 0 5 28 1 github
121 link Show HN: I used Claude Code... 300 0 1 3 1 pieterma
214 link Show HN: Play poker with LL... 300 0 2 7 1 llmholdem
619 link Show HN: Executable Markdow... 300 0 5 24 1 ycombinato
499 link Show HN: I made a memory ga... 300 0 4 19 1 specr
262 link Show HN: Librario, a book m... 300 0 2 9 1 ycombinato
97 link Show HN: A MCP for controll... 300 0 1 2 1 github
571 link Show HN: We Identified a Co... 300 0 4 22 1 wordpress
331 link Show HN: Yellopages – New t... 300 0 3 12 1 kawaicheun
73 link Show HN: Interactive Califo... 300 0 1 1 1 california
427 link Show HN: Marten – Elegant G... 300 0 3 16 1 github
451 link Show HN: Enforcing time-bou... 300 0 3 17 1 github
595 link Show HN: ESPTimeCast – DIY ... 300 0 4 23 1 github
640 link Show HN: I put economic rul... 300 0 5 25 1 ycombinato
283 link Show HN: mcpc – Universal c... 300 0 2 10 1 github
166 link Show HN: Ferrite – Markdown... 300 0 1 5 1 github
661 link Show HN: Gyesme – exploring... 300 0 5 26 1 gyesme
475 link Show HN: Umaro – An interac... 300 0 4 18 1 umaro
16 link Hacker News 0 1 0 - 0 ycombinato
22 link show 0 0 0 - 0 ycombinato
17 link new 0 0 0 - 0 ycombinato
11 link 0 0 0 - 0 ycombinato
12 link 0 0 0 - 0 ycombinato
20 link ask 0 0 0 - 0 ycombinato
18 link past 0 0 0 - 0 ycombinato
19 link comments 0 0 0 - 0 ycombinato
INFO     [agent] ✅ Using Sentience snapshot for prompt
INFO     [agent] Context prepared: sentience_used=True, message_length=3621 chars (~905 tokens), history_length=807 chars (~201 tokens)
INFO     [agent] 🤖 Calling LLM (this may trigger model download/loading for Hugging Face models)...
INFO     [agent] ✅ LLM response received
INFO     [agent] LLM response received: 1 actions
INFO     [agent]   ▶️  done: {'text': 'Top post: element ID 49, title: Show HN: Epstein IM – Talk ...', 'success': True}
INFO     [agent]   ✅ Task done: Task completed: True - Top post: element ID 49, title: Show HN: Epstein IM – Talk ...
INFO     [message_manager] Updated history: step=1, items_tracked=3, items_sent_to_llm=3
INFO     [agent] ✅ Task completed
INFO     [agent] Agent completed: total_prompt_tokens=14281 total_prompt_cost=0.0028562 

Per Model Usage

Model Prompt Tokens Completion Tokens Total Tokens Cost Invocations Avg Tokens/Invocation
bu-1-0 14,281 343 14,624 $0.0035422 2 7,312.0

📊 Token Usage Summary:
Total tokens: 14624
Total cost: $0.003542
Steps: 2
Sentience used: True
Sentience usage: 2/2 steps (100.0%)


2. QWen2.5 3B Local LLM:

Snapshot Prompt to LLM

Rules: ordinal→DG=1 then ord asc; otherwise imp desc. Use click(ID)/input_text(ID,...).

Elements ID role text imp is_primary docYq ord DG href
49 link Show HN: Epstein IM – Talk ... 10300 0 0 0 1 epstein
774 textbox 1014 0 6 - 0
238 link Show HN: AI Vibe Coding Hac... 300 0 2 8 1 devpost
685 link Show HN: Rocket Launch and ... 300 0 5 27 1 donuttheje
145 link Show HN: GlyphLang – An AI-... 300 0 1 4 1 ycombinato
355 link Show HN: VAM Seek – 2D vide... 300 0 3 13 1 github
733 link Show HN: A website that auc... 300 0 6 29 1 thedailyau
307 link Show HN: I built an Open So... 300 0 2 11 1 partridge
379 link Show HN: Vehluna – A visual... 300 0 3 14 1 vercel
403 link Show HN: Terminal UI for GCP 300 0 3 15 1 github
547 link Show HN: I built a fast, mi... 300 0 4 21 1 dota2
190 link Show HN: Porting xv6 to HiF... 300 0 1 6 1 github
523 link Show HN: Various shape regu... 300 0 4 20 1 github
709 link Show HN: EuConform – Offlin... 300 0 5 28 1 github
121 link Show HN: I used Claude Code... 300 0 1 3 1 pieterma
214 link Show HN: Play poker with LL... 300 0 2 7 1 llmholdem
619 link Show HN: Executable Markdow... 300 0 5 24 1 ycombinato
499 link Show HN: I made a memory ga... 300 0 4 19 1 specr
262 link Show HN: Librario, a book m... 300 0 2 9 1 ycombinato
97 link Show HN: A MCP for controll... 300 0 1 2 1 github
571 link Show HN: We Identified a Co... 300 0 4 22 1 wordpress
331 link Show HN: Yellopages – New t... 300 0 3 12 1 kawaicheun
73 link Show HN: Interactive Califo... 300 0 1 1 1 california
427 link Show HN: Marten – Elegant G... 300 0 3 16 1 github
451 link Show HN: Enforcing time-bou... 300 0 3 17 1 github
595 link Show HN: ESPTimeCast – DIY ... 300 0 4 23 1 github
640 link Show HN: I put economic rul... 300 0 5 25 1 ycombinato
283 link Show HN: mcpc – Universal c... 300 0 2 10 1 github
166 link Show HN: Ferrite – Markdown... 300 0 1 5 1 github
661 link Show HN: Gyesme – exploring... 300 0 5 26 1 gyesme
475 link Show HN: Umaro – An interac... 300 0 4 18 1 umaro
16 link Hacker News 0 1 0 - 0 ycombinato
22 link show 0 0 0 - 0 ycombinato
17 link new 0 0 0 - 0 ycombinato
11 link 0 0 0 - 0 ycombinato
12 link 0 0 0 - 0 ycombinato
20 link ask 0 0 0 - 0 ycombinato
18 link past 0 0 0 - 0 ycombinato
19 link comments 0 0 0 - 0 ycombinato
INFO     [agent] ✅ Using Sentience snapshot for prompt
INFO     [agent] Context prepared: sentience_used=True, message_length=3262 chars (~815 tokens), history_length=448 chars (~112 tokens)
INFO     [agent] 🤖 Calling LLM (this may trigger model download/loading for Hugging Face models)...
INFO     [agent] ✅ LLM response received
INFO     [agent] LLM response received: 1 actions
INFO     [agent]   ▶️  done: {'text': 'Top post: element ID 49, title: Show HN: Epstein IM – Talk ...', 'files_to_display': []}
INFO     [agent]   ✅ Task done: Task completed: True - Top post: element ID 49, title: Show HN: Epstein IM – Talk ...
INFO     [message_manager] Updated history: step=0, items_tracked=2, items_sent_to_llm=2
INFO     [agent] ✅ Task completed
INFO     [agent] Agent completed: total_prompt_tokens=0 total_prompt_cost=0.0 total_prompt_cached_tokens=0 total_prompt_cached_cost=0.0 total_completion_tokens=0 total_completion_cost=0.0 total_tokens=0 total_cost=0.0 entry_count=0 by_model={}

Per Model Usage

Model Prompt Tokens Completion Tokens Total Tokens Cost Invocations Avg Tokens/Invocation
Qwen/Qwen2.5-3B-Instruct 5,578 248 5,826 $0.00 1 5,826.0

📊 Token Usage Summary:
Total tokens: 5826
Total cost: $0.000000
Steps: 1
Sentience used: True
Sentience usage: 1/1 steps (100.0%)

INFO     [BrowserSession] 📢 on_BrowserStopEvent - Calling reset() (force=False, keep_alive=None)
INFO     [BrowserSession] [SessionManager] Cleared all owned data (targets, sessions, mappings)
INFO     [BrowserSession] ✅ Browser session reset complete
INFO     [BrowserSession] ✅ Browser session reset complete

When to Use Quantization?

  • Use if: You have limited RAM/VRAM, want faster inference, or need to run larger models on consumer hardware
  • Skip if: You have plenty of memory, want maximum quality, or are running on high-end GPUs

@rcholic rcholic changed the title Sentience agent Sentience agent examples using BU 1.0 & QWen2.5 3B Local LLM Jan 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants