Skip to content

Commit 3f0e081

Browse files
authored
Merge branch 'main' into feature/arm64-support
2 parents 1d26f29 + 0cdcfd2 commit 3f0e081

26 files changed

+833
-986
lines changed

.env.example

+14-4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ OPENAI_ENDPOINT=https://api.openai.com/v1
22
OPENAI_API_KEY=
33

44
ANTHROPIC_API_KEY=
5+
ANTHROPIC_ENDPOINT=https://api.anthropic.com
56

67
GOOGLE_API_KEY=
78

@@ -11,6 +12,11 @@ AZURE_OPENAI_API_KEY=
1112
DEEPSEEK_ENDPOINT=https://api.deepseek.com
1213
DEEPSEEK_API_KEY=
1314

15+
MISTRAL_API_KEY=
16+
MISTRAL_ENDPOINT=https://api.mistral.ai/v1
17+
18+
OLLAMA_ENDPOINT=http://localhost:11434
19+
1420
# Set to false to disable anonymized telemetry
1521
ANONYMIZED_TELEMETRY=true
1622

@@ -22,12 +28,16 @@ CHROME_PATH=
2228
CHROME_USER_DATA=
2329
CHROME_DEBUGGING_PORT=9222
2430
CHROME_DEBUGGING_HOST=localhost
25-
CHROME_PERSISTENT_SESSION=false # Set to true to keep browser open between AI tasks
31+
# Set to true to keep browser open between AI tasks
32+
CHROME_PERSISTENT_SESSION=false
2633

2734
# Display settings
28-
RESOLUTION=1920x1080x24 # Format: WIDTHxHEIGHTxDEPTH
29-
RESOLUTION_WIDTH=1920 # Width in pixels
30-
RESOLUTION_HEIGHT=1080 # Height in pixels
35+
# Format: WIDTHxHEIGHTxDEPTH
36+
RESOLUTION=1920x1080x24
37+
# Width in pixels
38+
RESOLUTION_WIDTH=1920
39+
# Height in pixels
40+
RESOLUTION_HEIGHT=1080
3141

3242
# VNC settings
3343
VNC_PASSWORD=youvncpassword

Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ FROM python:3.11-slim
33
# Install system dependencies
44
RUN apt-get update && apt-get install -y \
55
wget \
6+
netcat-traditional \
67
gnupg \
78
curl \
89
unzip \

README.md

+83-38
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ This project builds upon the foundation of the [browser-use](https://github.com/
1111

1212
We would like to officially thank [WarmShao](https://github.com/warmshao) for his contribution to this project.
1313

14-
**WebUI:** is built on Gradio and supports a most of `browser-use` functionalities. This UI is designed to be user-friendly and enables easy interaction with the browser agent.
14+
**WebUI:** is built on Gradio and supports most of `browser-use` functionalities. This UI is designed to be user-friendly and enables easy interaction with the browser agent.
1515

1616
**Expanded LLM Support:** We've integrated support for various Large Language Models (LLMs), including: Gemini, OpenAI, Azure OpenAI, Anthropic, DeepSeek, Ollama etc. And we plan to add support for even more models in the future.
1717

@@ -21,81 +21,126 @@ We would like to officially thank [WarmShao](https://github.com/warmshao) for hi
2121

2222
<video src="https://github.com/user-attachments/assets/56bc7080-f2e3-4367-af22-6bf2245ff6cb" controls="controls">Your browser does not support playing this video!</video>
2323

24-
## Installation Options
24+
## Installation Guide
25+
26+
### Prerequisites
27+
- Python 3.11 or higher
28+
- Git (for cloning the repository)
2529

2630
### Option 1: Local Installation
2731

2832
Read the [quickstart guide](https://docs.browser-use.com/quickstart#prepare-the-environment) or follow the steps below to get started.
2933

30-
> Python 3.11 or higher is required.
34+
#### Step 1: Clone the Repository
35+
```bash
36+
git clone https://github.com/browser-use/web-ui.git
37+
cd web-ui
38+
```
3139

32-
First, we recommend using [uv](https://docs.astral.sh/uv/) to setup the Python environment.
40+
#### Step 2: Set Up Python Environment
41+
We recommend using [uv](https://docs.astral.sh/uv/) for managing the Python environment.
3342

43+
Using uv (recommended):
3444
```bash
3545
uv venv --python 3.11
3646
```
3747

38-
and activate it with:
39-
48+
Activate the virtual environment:
49+
- Windows (Command Prompt):
50+
```cmd
51+
.venv\Scripts\activate
52+
```
53+
- Windows (PowerShell):
54+
```powershell
55+
.\.venv\Scripts\Activate.ps1
56+
```
57+
- macOS/Linux:
4058
```bash
4159
source .venv/bin/activate
4260
```
4361

44-
Install the dependencies:
45-
62+
#### Step 3: Install Dependencies
63+
Install Python packages:
4664
```bash
4765
uv pip install -r requirements.txt
4866
```
4967

50-
Then install playwright:
51-
68+
Install Playwright:
5269
```bash
5370
playwright install
5471
```
5572

56-
### Option 2: Docker Installation
57-
58-
1. **Prerequisites:**
59-
- Docker and Docker Compose installed on your system
60-
- Git to clone the repository
73+
#### Step 4: Configure Environment
74+
1. Create a copy of the example environment file:
75+
- Windows (Command Prompt):
76+
```bash
77+
copy .env.example .env
78+
```
79+
- macOS/Linux/Windows (PowerShell):
80+
```bash
81+
cp .env.example .env
82+
```
83+
2. Open `.env` in your preferred text editor and add your API keys and other settings
6184

62-
2. **Setup:**
63-
```bash
64-
# Clone the repository
65-
git clone https://github.com/browser-use/web-ui.git
66-
cd web-ui
85+
### Option 2: Docker Installation
6786

68-
# Copy and configure environment variables
69-
cp .env.example .env
70-
# Edit .env with your preferred text editor and add your API keys
71-
```
87+
#### Prerequisites
88+
- Docker and Docker Compose installed
89+
- [Docker Desktop](https://www.docker.com/products/docker-desktop/) (For Windows/macOS)
90+
- [Docker Engine](https://docs.docker.com/engine/install/) and [Docker Compose](https://docs.docker.com/compose/install/) (For Linux)
7291

73-
3. **Run with Docker:**
74-
```bash
75-
# Build and start the container with default settings (browser closes after AI tasks)
76-
docker compose up --build
92+
#### Installation Steps
93+
1. Clone the repository:
94+
```bash
95+
git clone https://github.com/browser-use/web-ui.git
96+
cd web-ui
97+
```
7798

78-
# Or run with persistent browser (browser stays open between AI tasks)
79-
CHROME_PERSISTENT_SESSION=true docker compose up --build
80-
```
99+
2. Create and configure environment file:
100+
- Windows (Command Prompt):
101+
```bash
102+
copy .env.example .env
103+
```
104+
- macOS/Linux/Windows (PowerShell):
105+
```bash
106+
cp .env.example .env
107+
```
108+
Edit `.env` with your preferred text editor and add your API keys
81109

110+
feature/arm64-support
82111
4. **Access the Application:**
83112
- WebUI: `http://localhost:7788`
84113
- VNC Viewer (to see browser interactions): `http://localhost:6080/vnc.html`
85114
- Direct VNC access is available on port 5901 (especially useful for Mac users)
86115

87116
Default VNC password is "vncpassword". You can change it by setting the `VNC_PASSWORD` environment variable in your `.env` file.
88117

118+
3. Run with Docker:
119+
```bash
120+
# Build and start the container with default settings (browser closes after AI tasks)
121+
docker compose up --build
122+
```
123+
```bash
124+
# Or run with persistent browser (browser stays open between AI tasks)
125+
CHROME_PERSISTENT_SESSION=true docker compose up --build
126+
```
127+
128+
129+
4. Access the Application:
130+
- Web Interface: Open `http://localhost:7788` in your browser
131+
- VNC Viewer (for watching browser interactions): Open `http://localhost:6080/vnc.html`
132+
- Default VNC password: "youvncpassword"
133+
- Can be changed by setting `VNC_PASSWORD` in your `.env` file
89134

90135
## Usage
91136

92137
### Local Setup
93-
1. Copy `.env.example` to `.env` and set your environment variables, including API keys for the LLM. `cp .env.example .env`
94-
2. **Run the WebUI:**
138+
1. **Run the WebUI:**
139+
After completing the installation steps above, start the application:
95140
```bash
96141
python webui.py --ip 127.0.0.1 --port 7788
97142
```
98-
4. WebUI options:
143+
2. WebUI options:
99144
- `--ip`: The IP address to bind the WebUI to. Default is `127.0.0.1`.
100145
- `--port`: The port to bind the WebUI to. Default is `7788`.
101146
- `--theme`: The theme for the user interface. Default is `Ocean`.
@@ -109,7 +154,7 @@ playwright install
109154
- `--dark-mode`: Enables dark mode for the user interface.
110155
3. **Access the WebUI:** Open your web browser and navigate to `http://127.0.0.1:7788`.
111156
4. **Using Your Own Browser(Optional):**
112-
- Set `CHROME_PATH` to the executable path of your browser and `CHROME_USER_DATA` to the user data directory of your browser.
157+
- Set `CHROME_PATH` to the executable path of your browser and `CHROME_USER_DATA` to the user data directory of your browser. Leave `CHROME_USER_DATA` empty if you want to use local user data.
113158
- Windows
114159
```env
115160
CHROME_PATH="C:\Program Files\Google\Chrome\Application\chrome.exe"
@@ -119,7 +164,7 @@ playwright install
119164
- Mac
120165
```env
121166
CHROME_PATH="/Applications/Google Chrome.app/Contents/MacOS/Google Chrome"
122-
CHROME_USER_DATA="~/Library/Application Support/Google/Chrome/Profile 1"
167+
CHROME_USER_DATA="/Users/YourUsername/Library/Application Support/Google/Chrome"
123168
```
124169
- Close all Chrome windows
125170
- Open the WebUI in a non-Chrome browser, such as Firefox or Edge. This is important because the persistent browser context will use the Chrome data when running the agent.
@@ -185,6 +230,6 @@ playwright install
185230
```
186231

187232
## Changelog
188-
233+
- [x] **2025/01/26:** Thanks to @vvincent1234. Now browser-use-webui can combine with DeepSeek-r1 to engage in deep thinking!
189234
- [x] **2025/01/10:** Thanks to @casistack. Now we have Docker Setup option and also Support keep browser open between tasks.[Video tutorial demo](https://github.com/browser-use/web-ui/issues/1#issuecomment-2582511750).
190-
- [x] **2025/01/06:** Thanks to @richard-devbot. A New and Well-Designed WebUI is released. [Video tutorial demo](https://github.com/warmshao/browser-use-webui/issues/1#issuecomment-2573393113).
235+
- [x] **2025/01/06:** Thanks to @richard-devbot. A New and Well-Designed WebUI is released. [Video tutorial demo](https://github.com/warmshao/browser-use-webui/issues/1#issuecomment-2573393113).

SECURITY.md

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
## Reporting Security Issues
2+
3+
If you believe you have found a security vulnerability in browser-use, please report it through coordinated disclosure.
4+
5+
**Please do not report security vulnerabilities through the repository issues, discussions, or pull requests.**
6+
7+
Instead, please open a new [Github security advisory](https://github.com/browser-use/web-ui/security/advisories/new).
8+
9+
Please include as much of the information listed below as you can to help me better understand and resolve the issue:
10+
11+
* The type of issue (e.g., buffer overflow, SQL injection, or cross-site scripting)
12+
* Full paths of source file(s) related to the manifestation of the issue
13+
* The location of the affected source code (tag/branch/commit or direct URL)
14+
* Any special configuration required to reproduce the issue
15+
* Step-by-step instructions to reproduce the issue
16+
* Proof-of-concept or exploit code (if possible)
17+
* Impact of the issue, including how an attacker might exploit the issue
18+
19+
This information will help me triage your report more quickly.

docker-compose.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
services:
22
browser-use-webui:
3+
platform: linux/amd64
34
build:
45
context: .
56
dockerfile: ${DOCKERFILE:-Dockerfile}

requirements.txt

+4-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
browser-use==0.1.19
2-
langchain-google-genai==2.0.8
1+
browser-use==0.1.29
32
pyperclip==1.9.0
4-
gradio==5.9.1
5-
langchain-ollama==0.2.2
6-
langchain-openai==0.2.14
3+
gradio==5.10.0
4+
json-repair
5+
langchain-mistralai==0.2.4

src/__init__.py

-6
Original file line numberDiff line numberDiff line change
@@ -1,6 +0,0 @@
1-
# -*- coding: utf-8 -*-
2-
# @Time : 2025/1/1
3-
# @Author : wenshao
4-
5-
# @Project : browser-use-webui
6-
# @FileName: __init__.py.py

src/agent/__init__.py

-6
Original file line numberDiff line numberDiff line change
@@ -1,6 +0,0 @@
1-
# -*- coding: utf-8 -*-
2-
# @Time : 2025/1/1
3-
# @Author : wenshao
4-
5-
# @Project : browser-use-webui
6-
# @FileName: __init__.py.py

0 commit comments

Comments
 (0)