Dani Akash 752f42d1fe refactor: migrate chat history to direct JSONL file reads via Lima filesystem (#808)
* feat: draft agent chat ui exploration

* feat: refine agent chat ui draft

* feat: remove outer frame from agent chat workspace

* fix: offset agent chat for app sidebar

* fix: simplify agent conversation shell

* fix: remove redundant chat header actions

* fix: unify agent conversation headers

* fix: tighten agent chat spacing

* fix: bound agent chat composer height

* fix: remove agent chat page inset

* fix: align agent header height with sidepanel

* fix: center agent composer resting state

* fix: anchor multiline composer controls

* fix: remove focus grid from agent home

* fix: remove redundant agent home header

* fix: constrain home agent composer

* fix: match home composer default posture

* feat: add openclaw chat history APIs

* feat: add claw chat history hydration

* fix: stabilize claw chat viewport layout

* fix: use conversation scroll base for claw chat

* refactor: split claw chat controller responsibilities

* fix: keep active agent turns in memory

* fix: normalize openclaw chat sessions

* refactor: use HTTP client for agent history instead of CLI client

Replace the CLI-based getChatHistory() call in getAgentHistoryPage()
with the HTTP client's getSessionHistory() from PR #795. This uses
the direct HTTP transport to OpenClaw's /sessions/<key>/history
endpoint instead of shelling out through the CLI.

- Add filterHttpSessionHistoryMessages() for flat-string content format
- Add normalizeHttpHistoryMessages() for OpenClawSessionHistoryMessage shape
- Update getAgentHistoryPage() to call getSessionHistory() via httpClient
- Remove unused getChatHistory(), filterOpenClawSystemMessages(),
  normalizeChatHistoryMessages(), and getTextContent()
- Update test mocks from cliClient.getChatHistory to httpClient.getSessionHistory
- Update MutableOpenClawService type: chatClient -> httpClient

* fix: fetch all session messages by iterating OpenClaw pagination

OpenClaw's HTTP history endpoint returns a limited page by default.
When called without a limit, only the first ~27 messages were returned,
causing all newer conversation messages to be silently dropped.

Add fetchAllSessionMessages() that iterates through OpenClaw's cursor-
based pagination (200 messages per page) until hasMore is false, then
feeds the complete message list into the existing BrowserOS normalization
and in-memory pagination layer.

* refactor: migrate chat history from HTTP gateway to direct JSONL file reads

Replace the HTTP-based chat history pipeline (BrowserOS server → OpenClaw
gateway /sessions/:key/history pagination loop) with direct JSONL file reads
from the host filesystem via Lima's virtiofs mount.

- Add OpenClawJsonlReader that reads session JSONL files directly from
  ~/.browseros/vm/openclaw/.openclaw/agents/<id>/sessions/
- Replace fetchAllSessionMessages() HTTP pagination with single file read
- Replace CLI-based listSessions() with sessions.json file reads
- Make listSessions, resolveAgentSession, getAgentHistoryPage synchronous
- Remove unused toBrowserOSSession, filterHttpSessionHistoryMessages,
  normalizeHttpHistoryMessages helpers
- Update route handlers to drop unnecessary async/await
- Update tests to use temp JSONL files instead of mocked HTTP/CLI clients

* fix: restore async route handlers for test compatibility with mocked service

* fix: address review feedback — path traversal guard, lazy reader, exists flag

- Add safePath() to OpenClawJsonlReader that validates resolved paths stay
  within stateRoot, preventing path traversal via crafted agentId values
- Use lazy initialization for jsonlReader (nulled on rebuildRuntimeClients)
  instead of creating a new instance per property access
- Return exists: false from resolveSpecificAgentSession when no session
  matches instead of fabricating a ghost session with sessionId: ''
2026-04-24 13:19:46 +05:30
2025-09-13 18:04:54 +05:30
2026-01-06 16:24:19 -08:00
2025-09-30 12:54:03 -07:00
2025-06-18 17:48:04 -07:00
2026-04-02 13:00:11 -07:00

BrowserOS is an open-source Chromium fork that runs AI agents natively. The privacy-first alternative to ChatGPT Atlas, Perplexity Comet, and Dia.

Use your own API keys or run local models with Ollama. Your data never leaves your machine.

Documentation · Discord · Slack · Twitter · Feature Requests

Quick Start

  1. Download and install BrowserOS — macOS · Windows · Linux (AppImage) · Linux (Debian)
  2. Import your Chrome data (optional) — bookmarks, passwords, extensions all carry over
  3. Connect your AI provider — Claude, OpenAI, Gemini, ChatGPT Pro via OAuth, or local models via Ollama/LM Studio

Features

Feature Description Docs
AI Agent 53+ browser automation tools — navigate, click, type, extract data, all with natural language Guide
MCP Server Control the browser from Claude Code, Gemini CLI, or any MCP client Setup
Workflows Build repeatable browser automations with a visual graph builder Docs
Cowork Combine browser automation with local file operations — research the web, save reports to your folder Docs
Scheduled Tasks Run agents on autopilot — daily, hourly, or every few minutes Docs
Memory Persistent memory across conversations — your assistant remembers context over time Docs
SOUL.md Define your AI's personality and instructions in a single markdown file Docs
LLM Hub Compare Claude, ChatGPT, and Gemini responses side-by-side on any page Docs
40+ App Integrations Gmail, Slack, GitHub, Linear, Notion, Figma, Salesforce, and more via MCP Docs
Vertical Tabs Side-panel tab management — stay organized even with 100+ tabs open Docs
Ad Blocking uBlock Origin + Manifest V2 support — 10x more protection than Chrome Docs
Cloud Sync Sync browser config and agent history across devices Docs
Skills Custom instruction sets that shape how your AI assistant behaves Docs
Smart Nudges Contextual suggestions to connect apps and use features at the right moment Docs

Demos

BrowserOS agent in action

BrowserOS agent in action

Install BrowserOS as MCP and control it from claude-code

https://github.com/user-attachments/assets/c725d6df-1a0d-40eb-a125-ea009bf664dc



Use BrowserOS to chat

https://github.com/user-attachments/assets/726803c5-8e36-420e-8694-c63a2607beca



Use BrowserOS to scrape data

https://github.com/user-attachments/assets/9f038216-bc24-4555-abf1-af2adcb7ebc0



Install browseros-cli

Use browseros-cli to launch and control BrowserOS from the terminal or from AI coding agents like Claude Code.

macOS / Linux:

curl -fsSL https://cdn.browseros.com/cli/install.sh | bash

Windows:

irm https://cdn.browseros.com/cli/install.ps1 | iex

After install, run browseros-cli init to connect the CLI to your running BrowserOS instance.

LLM Providers

BrowserOS works with any LLM. Bring your own keys, use OAuth, or run models locally.

Provider Type Auth
Kimi K2.5 Cloud (default) Built-in
ChatGPT Pro/Plus Cloud OAuth
GitHub Copilot Cloud OAuth
Qwen Code Cloud OAuth
Claude (Anthropic) Cloud API key
GPT-4o / o3 (OpenAI) Cloud API key
Gemini (Google) Cloud API key
Azure OpenAI Cloud API key
AWS Bedrock Cloud IAM credentials
OpenRouter Cloud API key
Ollama Local Setup
LM Studio Local Setup

How We Compare

BrowserOS Chrome Brave Dia Comet Atlas
Open Source
AI Agent
MCP Server
Visual Workflows
Cowork (files + browser)
Scheduled Tasks
Bring Your Own Keys
Local Models (Ollama)
Local-first Privacy
Ad Blocking (MV2)

Detailed comparisons:

Architecture

BrowserOS is a monorepo with two main subsystems: the browser (Chromium fork) and the agent platform (TypeScript/Go).

BrowserOS/
├── packages/browseros/              # Chromium fork + build system (Python)
│   ├── chromium_patches/            # Patches applied to Chromium source
│   ├── build/                       # Build CLI and modules
│   └── resources/                   # Icons, entitlements, signing
│
├── packages/browseros-agent/        # Agent platform (TypeScript/Go)
│   ├── apps/
│   │   ├── server/                  # MCP server + AI agent loop (Bun)
│   │   ├── agent/                   # Browser extension UI (WXT + React)
│   │   ├── cli/                     # CLI tool (Go)
│   │   ├── eval/                    # Benchmark framework
│   │   └── controller-ext/          # Chrome API bridge extension
│   │
│   └── packages/
│       ├── agent-sdk/               # Node.js SDK (npm: @browseros-ai/agent-sdk)
│       ├── cdp-protocol/            # CDP type bindings
│       └── shared/                  # Shared constants
Package What it does
packages/browseros Chromium fork — patches, build system, signing
apps/server Bun server exposing 53+ MCP tools and running the AI agent loop
apps/agent Browser extension — new tab, side panel chat, onboarding, settings
apps/cli Go CLI — control BrowserOS from the terminal or AI coding agents
apps/eval Benchmark framework — WebVoyager, Mind2Web evaluation
agent-sdk Node.js SDK for browser automation with natural language
cdp-protocol Type-safe Chrome DevTools Protocol bindings

Contributing

We'd love your help making BrowserOS better! See our Contributing Guide for details.

Agent development (TypeScript/Go) — see the agent monorepo README for setup instructions.

Browser development (C++/Python) — requires ~100GB disk space. See packages/browseros for build instructions.

Credits

  • ungoogled-chromium — BrowserOS uses some patches for enhanced privacy. Thanks to everyone behind this project!
  • The Chromium Project — at the core of BrowserOS, making it possible to exist in the first place.

License

BrowserOS is open source under the AGPL-3.0 license.

Copyright © 2026 Felafax, Inc.

Stargazers

Thank you to all our supporters!

Star History Chart

Built with ❤️ from San Francisco

Description
No description provided
Readme AGPL-3.0 18 GiB
Languages
TypeScript 65.6%
C++ 24%
Go 6.5%
C 1.5%
Objective-C++ 1%
Other 1.3%