Setup and configuration

Initialize

SimularBrowser(
    path: str,
    anthropic_key: str = '',
    planner_model: str = 'claude-3-5-sonnet',
    planner_mode: str = 'system_1_2',
    allow_subtasks: bool = False,
    max_parallelism: int = 5,
    enable_vision: bool = False,
    max_steps: int = 200,
    timeout: float = 600.0
)
path
string
required

Absolute path to the Simular Browser

Planner Configuration

Planner Configuration: anthropic_key, planner_model, planner_mode

Execution Configuration

Execution Configuration: allow_subtasks, max_parallelism, enable_vision, max_steps, timeout

Browser Functions

is_app_running

#Check if Simular Browser is running on the system
def is_app_running()-> bool:

launch_app

# Launch Simular Browser Application
def launch_app() -> None:

run

# Run a Query in SimularBrowser's frontmost tab
def run(query, timeout=None, reset: bool = False) -> dict:
query
required

Query sent to the browser

timeout
float
default:
"None"

Timeout for the operation

reset
bool
default:
"False"

Reset the tab chat history before running the query

Browser Tab

Initialize

Tab(
    browser: 'SimularBrowser',
    id: str = None,
    verbose: bool = False
)
browser
SimularBrowser
required

Reference to parent browser

Configuration

Configuration: id, responses, images, info, verbose

reset_storage

# reset tab's response history, images, and info
def reset_storage(self) -> None:

open

open and connect the tab in SimularBrowser

async def open(self: 'Tab') -> str: # Returns the tab id

close

close and disconnect the tab from SimularBrowser

async def close(self: 'Tab') -> str: # Returns the tab id

After closing, you can still retain the tab reference to access its storage

query

query the tab using browser’s api key, returns tab.responses

async def query(
                query, 
                model: str = 'claude-3-5-sonnet',
                planner_mode: str = 'system_1_2',
                allow_subtasks: bool = False,
                max_parallelism: int = 3,
                enable_vision: bool = False,
                max_steps: int = 100,
                timeout=600.0) -> dict:
query
string
required

Query send to the browser tab

Planner Configuration

Planner Configuration: model, planner_mode

Execution Configuration

Execution Configuration: allow_subtasks, max_parallelism, enable_vision, max_steps, timeout