This commit is contained in:
Timothy Jaeryang Baek committed 2026-10-31 08:55:46 +09:00
1 parent 12b16a4885
commit 6e87366d21
3 files changed
+5 -4

No files matched your search

+2
View File
@@ -176,6 +176,8 @@ Then open the URL printed in the logs, usually `http://localhost:8000/?token=...
Open WebUI Computer stores its state in `/data`. Mount your project into the container, like `-v "$PWD:/workspace"`, so Open WebUI Computer can access it.
The default image includes Git and GitHub CLI (`gh`). Use `ghcr.io/open-webui/computer:browser` when agent browser automation needs Chromium.
Non-streaming utility tasks also use the `CPTR_STREAM_*` timeout settings. For slow models, increase `CPTR_STREAM_READ_TIMEOUT` (default: 300 seconds), for example with `-e CPTR_STREAM_READ_TIMEOUT=14400` in `docker run`. Restart Computer after changing this setting; Open WebUI and reverse proxies may have their own timeouts.
If you bind-mount a host directory to `/data`, make sure that directory is writable by the container user. SQLite needs to create and update `/data/app.db`, and host directory permissions take precedence over the image's built-in `/data` ownership.
To connect a host-running OpenCode server from Docker, start OpenCode on a host-reachable interface and set the OpenCode agent Server URL to the Docker host address:
+3 -3
View File
@@ -133,7 +133,7 @@ async def chat_completion(
Works with Anthropic, OpenAI Chat Completions, and OpenAI Responses API.
Useful for lightweight tasks like title/summary generation.
"""
async with httpx.AsyncClient(timeout=httpx.Timeout(15)) as client:
async with httpx.AsyncClient(timeout=_STREAM_TIMEOUT) as client:
if provider == "anthropic":
body: dict = {
"model": model,
@@ -241,7 +241,7 @@ async def generate_text(
active_connection: dict | None = None,
active_model: str = "",
request_params: dict | None = None,
timeout_seconds: float = 20,
timeout_seconds: float = STREAM_READ_TIMEOUT_SECONDS,
) -> str | None:
"""Generate text; model_id None inherits active/default."""
from cptr.models import Config
@@ -313,7 +313,7 @@ async def generate_json(
active_connection: dict | None = None,
active_model: str = "",
request_params: dict | None = None,
timeout_seconds: float = 20,
timeout_seconds: float = STREAM_READ_TIMEOUT_SECONDS,
) -> dict | None:
from cptr.utils.json_parser import extract_json
-1
View File
@@ -836,7 +836,6 @@ async def review_tool_approval(
],
system=TOOL_APPROVAL_REVIEW_PROMPT,
max_tokens=150,
timeout_seconds=20,
)
decision = str((parsed or {}).get("decision") or "").strip().lower()
reason = str((parsed or {}).get("reason") or "").strip()