dsh-web-app owns --host/--port/--dev/--workspace-root/--trusted-host and its --help in a web-startup row; the rows it configures wait for the webStartup service, and the client-plugin HMR receiver now ships disabled so --dev is a row toggle rather than a runtime insert (the Loader cannot resolve a row inserted from inside a mounting plugin). dsh-headless owns the task positional and rejects a missing task as its own usage error. Its runner ships disabled, not merely waiting: the schema requires the task, and a row's config is validated when its fiber is created, before the startup row can supply one. A composition has exactly one command-line owner, so the patch disables the web startup row and this one provides webStartup too, leaving the web rows on their composed one-shot values. The keyless web scaffold provides the same three values with no arguments, which is what an embedding host with no command line does.
2.7 KiB
@deepseek-ai/dsh-web-app
English | 中文
The dsh browser-surface bundle. cordis.patch.yml rides over dsh-base: it sets the coding persona, inserts the Web host rows (webserver, API gateway, workspace, projection cache, storage) and the browser plugin roster, and mounts this package's web-runtime glue plugin (config {mode, printUrl, surfaceContext, lanAddresses}). That plugin resolves the built frontend dist through @deepseek-ai/dsh-frontend's exports, mounts the frontend-static fallback owner over it, registers the web-surface prompt section and the bash-visible DSH_WEB_URL/DSH_WEB_MODE runtime variables when surfaceContext is true, and prints the dsh web: URL line when printUrl is true. This bundle also owns the app command line: the web-startup row (src/startup.ts) parses --host, --port, --dev, --workspace-root, and repeatable --trusted-host from ctx.cmdlineArgs (dsh-cmdline) and prints the app's --help. Every row it configures injects webStartup, so nothing binds a port before argument resolution and dsh --profile web --help starts no server. mode and lanAddresses resolve on every boot because they describe the invocation. dsh-headless is a sibling surface over the same base and does not mount this bundle.
Model Experience
Web-surface prompt section and bash runtime variables
What the model sees
When surfaceContext is true, the app:web-surface global section (order −98) orients the model to the GUI: the canonical local URL, the "this page" referent, the HMR/rebuild update contract for the active mode, and the instruction not to start replacement servers. DSH_WEB_URL and DSH_WEB_MODE additionally appear in the managed bash environment with their descriptions, resolved per invocation from the live server. When it is false, neither the section nor the variables are registered.
Token effect
One prompt paragraph per session plus two managed-environment variable lines; constant per process.
KV Cache effect
The prompt section sits near the system prompt's head and is stable for the life of the process (port and mode are boot facts), so it does not invalidate the cache across turns.
Known Limitations and Deferred Work
- The frontend dist must be built —
require.resolveof the dist fails loud at activation with a build hint; there is no source-serving fallback. lanAddressesis a boot-time snapshot — interface changes after boot are not re-advertised; the printed LAN URL always matches the configured trust fence.