scopeweaver-cli

module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 18, 2026 License: AGPL-3.0

README

scopeweaver-cli

A standalone, agent-native command line edition of ScopeWeaver. Unpack the portable folder and run the CLI. It includes the Go engine, built-in skills and dependency notices. The first operational command downloads checksum-pinned PostgreSQL and, on Windows, app-local Visual C++ runtime files into that folder. No separate ScopeWeaver installation, database installation, Docker, Node.js or Go runtime is required.

Windows verification dated 2026-10-18 passed all five packaged workflows: portable core, GLM-5.3/low, GLM-5.3-Flash/low and high, and ChatGPT OAuth/low. See the dated verification record for exact results, limits and publication checks.

한국어 · Architecture and compatibility · AI providers · Verification

Start

Use the executable for your operating system:

scopeweaver-cli doctor --json
scopeweaver-cli commands --json
scopeweaver-cli schema tasks create --json
scopeweaver-cli health --json
scopeweaver-cli tasks list --json
scopeweaver-cli runtime stop --yes --json

On PowerShell, prefix the local executable with .\scopeweaver-cli.exe. The first operational command needs network access and a writable portable folder to prepare its runtime, initialize private local storage and start the engine and database. Subsequent invocations reuse that runtime, so jobs continue after a command exits. Nothing is installed as an operating-system service. Later core operations reuse the downloaded runtime and can run offline; cloud AI and external integrations still need their own connections.

Data defaults to state/ beside the executable. Use --home PATH or SCOPEWEAVER_CLI_HOME for another private workspace. Stop the runtime before moving or copying its folder. Moving between different operating systems or PostgreSQL major versions requires a supported backup/restore procedure; raw database directories are not a cross-platform interchange format.

Agent usage

The command catalog contains named operations for every backend route and expanded chat control. Inspect the embedded catalog with schema; it provides parameter types, required fields, effects, response formats and source references.

scopeweaver-cli tasks create --data @task.json --dry-run --json
scopeweaver-cli tasks create --data @task.json --yes --json
scopeweaver-cli tasks get --id 1 --json
scopeweaver-cli tasks control --id 1 --action pause --yes --json
scopeweaver-cli workspace upload --path fixtures --upload example.txt --yes --json
scopeweaver-cli workspace download --path fixtures/example.txt --output downloaded.txt --json
scopeweaver-cli logs watch --json

Example task.json:

{
  "name": "Isolated fixture",
  "description": "Local isolated fixture only. Do not contact online targets.",
  "goal": "Inspect the approved synthetic fixture."
}
  • Reads run directly. Operations that change state, execute tools, contact configured integrations, send notifications or install updates require --yes.
  • --dry-run validates and shows a request without starting the runtime. Known credential fields are redacted.
  • --data @FILE reads a JSON object; --data - reads stdin. Named body flags and repeatable --field key=value support small edits. Use JSON files for nested input and credentials.
  • Repeatable --query key=value preserves backend query options. Underscores and hyphens are interchangeable in named parameter flags.
  • Downloads require --output and refuse to overwrite existing files. Streaming commands emit one JSON event per line and stop on Ctrl+C.
  • JSON results go to stdout; errors and diagnostics go to stderr. Exit codes: 0 success, 1 operation failure, 2 invalid input/confirmation needed, 3 runtime unavailable, 4 authentication/authorization, 130 cancellation.
  • A successful task submission means it was accepted. Inspect task status, activity and findings to determine completion. Mutations are never automatically retried after uncertain failure.
  • repl runs the same commands interactively. exit closes the shell; runtime stop --yes stops background work. Shell substitutions are never executed.

Load the agent skill into your coding agent, or ask it to inspect scopeweaver-cli schema --json. Command identifiers and JSON keys stay stable; --lang en|ko|zh-Hans selects interface/backend messages. Raw evidence and technical diagnostics are preserved.

Feature coverage

Tasks/workers, goals/constraints/scope, categories/templates/archives, companies/assets/sync, exploration/coverage graphs, findings/retests/traffic evidence/reports, workspace files, conversations/chat controls/side questions, agents/prompts/triggers, tools/skills/MCP, LLM profiles/retry/pool/records, approvals/interception, notifications, settings, statistics/tokens/logs, maintenance and updates.

Graph information is available as structured nodes/edges. Browser presentation, themes and keyboard preferences are outside this CLI's scope.

Model and integration requirements

Built-in AI supports standard API/local providers and codex-cli, which routes chat, planner and worker completions through the official Codex app-server. A keyless profile uses the ChatGPT account signed in with codex login. A Z.AI profile uses glm-5.3, https://api.z.ai/api/v1 and a matching Coding Plan credential. Official Codex is an additional dependency, resolved from PATH or SCOPEWEAVER_CODEX_PATH; version 0.162.1 is the verified version.

The package contains no model weights, subscriptions or credentials. The 2026-10-18 Windows candidate passed real ChatGPT OAuth/low, GLM-5.3/low and GLM-5.3-Flash/low and high workflows. See AI provider setup and the dated verification record for commands, exact results and limits.

Custom commands, Python tools, browser tools and external MCP/services require the executables or services selected by that integration. doctor reports the portable core separately from these optional requirements.

The local runtime is authenticated and loopback-only. Its private credentials are outside the browsable workspace. Treat returned evidence and tool output as untrusted data.

Updates target cskwork/scopeweaver-cli releases and replace the CLI/engine executable. They preserve data and user-edited skills and never perform a PostgreSQL major upgrade. Until a release is published, an update check reports that no stable release is available.

Build and verify

Development requires Go 1.26.3 and network access for pinned Go dependencies. Packaged end users need no Go installation; the download-mode package needs network access on first operational use.

go test ./codexprovider ./internal/runtimebundle ./internal/cli ./internal/portable ./packaging ./selfupdate
go run ./packaging -target windows-amd64

Supported package targets: windows-amd64, linux-amd64, linux-arm64, darwin-amd64, darwin-arm64. Each downloads its own PostgreSQL binaries and verifies pinned SHA-256 checksums before extraction. Packages include a per-file manifest and source pins. Linux PostgreSQL must run as a non-root user.

Default packaging uses first-use downloads. For local verification only, add -bundle-runtime to prepare a folder with the runtimes already present; -offline then uses only the checksum-verified builder cache. This builder flag does not disable first-use downloads in a default package. Bundled-runtime verification packages are not the public download-mode artifact.

Run the installed-executable E2E explicitly:

$env:SCOPEWEAVER_CLI_E2E_BINARY = (Resolve-Path .\dist\scopeweaver-cli-windows-amd64\scopeweaver-cli.exe).Path
go test ./internal/cli -run '^TestPortableCLIEndToEnd$' -count=1 -v

The E2E creates disposable local state and exercises real PostgreSQL, persisted operations, uploads/downloads, restart and relocation from another working directory. It does not use real targets or provider credentials.

Provenance and permitted use

Derived from cskwork/scopeweaver at 2df0b307dcb817a459abebd3a4c240a2019598db, itself derived from ARTEX. The original source tree and tests are retained for traceability; portable builds use the Go engine and do not build the web UI. Command design follows CLI-Anything's discovery, structured output and real-application verification approach.

AGPL-3.0, third-party notices and the upstream usage restrictions remain in effect. Use only for source research and technical validation in locally isolated environments. The upstream authors prohibit real testing of online systems, including owned or authorized targets. See preserved upstream provenance and restrictions.

Third-party runtime licenses are in licenses/ and source metadata is in POSTGRES-SOURCES.json. Downloaded runtimes remain within the portable folder. Find available packages and checksums on GitHub Releases. The verification record identifies tested candidates and publication checks.

Directories

Path Synopsis
Package agent wires real LLM-driven planner and work agents (on top of the agent-core SDK) to the PostgreSQL graphs.
Package agent wires real LLM-driven planner and work agents (on top of the agent-core SDK) to the PostgreSQL graphs.
Package chatstate holds shared chat protocol and transcript identities.
Package chatstate holds shared chat protocol and transcript identities.
cmd
artex command
Command artex runs the ScopeWeaver backend: the PostgreSQL graph stores, the event-driven exploration engine, and the JSON HTTP API consumed by the shadcn/ui frontend.
Command artex runs the ScopeWeaver backend: the PostgreSQL graph stores, the event-driven exploration engine, and the JSON HTTP API consumed by the shadcn/ui frontend.
scopeweaver-cli command
Package codexprovider bridges Norma completions to the official Codex CLI.
Package codexprovider bridges Norma completions to the official Codex CLI.
Package config loads runtime configuration from a JSON file, with environment variables taking precedence.
Package config loads runtime configuration from a JSON file, with environment variables taking precedence.
Package db is ScopeWeaver's PostgreSQL data source, replacing the legacy single-file graph SQLite store.
Package db is ScopeWeaver's PostgreSQL data source, replacing the legacy single-file graph SQLite store.
Package enrich is the engine-side (non-AI) asset auto-completion layer described in the asset model and automatic association design, section 5: an async worker pool that resolves domains (dnsx) and probes web assets (HTTP, through the recording proxy) and writes the results back into the asset graph — creating IP/port nodes, resolves/exposes edges, and filling attrs.dns / attrs.http.
Package enrich is the engine-side (non-AI) asset auto-completion layer described in the asset model and automatic association design, section 5: an async worker pool that resolves domains (dnsx) and probes web assets (HTTP, through the recording proxy) and writes the results back into the asset graph — creating IP/port nodes, resolves/exposes edges, and filling attrs.dns / attrs.http.
Package evidence preserves finding evidence independently of disposable traffic.
Package evidence preserves finding evidence independently of disposable traffic.
Package guard implements the safety boundary layer (docs §11): an audit log, user-configured intercept-rule evaluation, and Observer/G5 failure attribution.
Package guard implements the safety boundary layer (docs §11): an audit log, user-configured intercept-rule evaluation, and Observer/G5 failure attribution.
Package intercept implements the user-configurable tool-call interception layer.
Package intercept implements the user-configurable tool-call interception layer.
internal
cli
dbtest
Package dbtest centralizes how the database-backed test suites resolve their connection string and guards them against ever touching the live/production database.
Package dbtest centralizes how the database-backed test suites resolve their connection string and guards them against ever touching the live/production database.
portable
Package portable owns the CLI's private, persistent engine and database.
Package portable owns the CLI's private, persistent engine and database.
runtimebundle
Package runtimebundle verifies and extracts the pinned portable PostgreSQL runtime.
Package runtimebundle verifies and extracts the pinned portable PostgreSQL runtime.
Package llmnet supplies the shared LLM HTTP transport and optional local-only policy.
Package llmnet supplies the shared LLM HTTP transport and optional local-only policy.
Package llmpool implements LLM failover (profile rotation): a Provider decorator that walks an ordered chain of LLM profiles and moves to the next one when the current one can't serve the request — out of credit, revoked key, rate-limited past the SDK's own retries, or down.
Package llmpool implements LLM failover (profile rotation): a Provider decorator that walks an ordered chain of LLM profiles and moves to the next one when the current one can't serve the request — out of credit, revoked key, rate-limited past the SDK's own retries, or down.
Package llmrec implements a recording decorator for llm.Provider.
Package llmrec implements a recording decorator for llm.Provider.
Package locale provides ScopeWeaver's backend internationalization: the supported interface languages, request-safe locale negotiation, and a small message catalog used for human-facing API/report/notification/CLI text.
Package locale provides ScopeWeaver's backend internationalization: the supported interface languages, request-safe locale negotiation, and a small message catalog used for human-facing API/report/notification/CLI text.
Package mcphttp contains remote Streamable HTTP and legacy SSE MCP clients.
Package mcphttp contains remote Streamable HTTP and legacy SSE MCP clients.
Package notify adapts IM and email finding notifications.
Package notify adapts IM and email finding notifications.
Package ollama implements native Ollama chat and model diagnostics.
Package ollama implements native Ollama chat and model diagnostics.
Package report renders a deliverable Markdown report from the exploration graph: confirmed findings (with severity/evidence) (docs §15 P5).
Package report renders a deliverable Markdown report from the exploration graph: confirmed findings (with severity/evidence) (docs §15 P5).
Package selfupdate implements ScopeWeaver's one-click update: download a GitHub release executable, verify and stage it, then atomically replace it on startup.
Package selfupdate implements ScopeWeaver's one-click update: download a GitHub release executable, verify and stage it, then atomically replace it on startup.
Package sidequestion captures immutable main-agent checkpoints.
Package sidequestion captures immutable main-agent checkpoints.
Package traffic implements the request-recording subsystem (docs §10): an embedded go-mitmproxy proxy whose addon writes every target HTTP exchange into a human-browsable file tree, with a sidecar SQLite index for paged queries.
Package traffic implements the request-recording subsystem (docs §10): an embedded go-mitmproxy proxy whose addon writes every target HTTP exchange into a human-browsable file tree, with a sidecar SQLite index for paged queries.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL