selfbrowse 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- selfbrowse/__init__.py +16 -0
- selfbrowse/__main__.py +3 -0
- selfbrowse/_about.py +11 -0
- selfbrowse/agent.py +722 -0
- selfbrowse/browser.py +737 -0
- selfbrowse/cli.py +179 -0
- selfbrowse/guardrails.py +525 -0
- selfbrowse/handoff.py +89 -0
- selfbrowse/knowledge.py +200 -0
- selfbrowse/llm/__init__.py +119 -0
- selfbrowse/llm/anthropic.py +74 -0
- selfbrowse/llm/base.py +42 -0
- selfbrowse/llm/openai_compat.py +249 -0
- selfbrowse/mcp_server.py +403 -0
- selfbrowse/otel.py +173 -0
- selfbrowse/prompts.py +21 -0
- selfbrowse/py.typed +0 -0
- selfbrowse/tools.py +171 -0
- selfbrowse/trace.py +293 -0
- selfbrowse/types.py +54 -0
- selfbrowse-0.1.0.dist-info/METADATA +628 -0
- selfbrowse-0.1.0.dist-info/RECORD +25 -0
- selfbrowse-0.1.0.dist-info/WHEEL +4 -0
- selfbrowse-0.1.0.dist-info/entry_points.txt +3 -0
- selfbrowse-0.1.0.dist-info/licenses/LICENSE +21 -0
selfbrowse/__init__.py
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"""Selfbrowse — a small browser agent that gets cheaper the more you use it."""
|
|
2
|
+
from selfbrowse.types import RunResult, Step, Usage
|
|
3
|
+
|
|
4
|
+
__version__ = "0.1.0"
|
|
5
|
+
|
|
6
|
+
__all__ = ["BrowseAgent", "Browser", "RunResult", "Step", "Usage", "__version__"]
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def __getattr__(name: str): # lazy: importing `selfbrowse` must not import Playwright
|
|
10
|
+
if name == "BrowseAgent":
|
|
11
|
+
from selfbrowse.agent import BrowseAgent
|
|
12
|
+
return BrowseAgent
|
|
13
|
+
if name == "Browser":
|
|
14
|
+
from selfbrowse.browser import Browser
|
|
15
|
+
return Browser
|
|
16
|
+
raise AttributeError(name)
|
selfbrowse/__main__.py
ADDED
selfbrowse/_about.py
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"""
|
|
2
|
+
The project's name and name-derived defaults, kept in one place.
|
|
3
|
+
|
|
4
|
+
Renaming the project means changing this file, the package folder, ``pyproject.toml``
|
|
5
|
+
and the docs — nothing else hard-codes the name.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
NAME = "selfbrowse" # import name, CLI command, PyPI name
|
|
9
|
+
DISPLAY_NAME = "Selfbrowse"
|
|
10
|
+
HOME_DIRNAME = ".selfbrowse" # per-user data folder under the home directory
|
|
11
|
+
ENV_PREFIX = "SELFBROWSE_" # environment variable prefix
|