jishushell 0.4.30 → 0.5.22
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.
- package/Dockerfile.hermes-slim +2 -5
- package/apps/anythingllm-container.yaml +287 -0
- package/apps/browserless-chromium-container.yaml +18 -6
- package/apps/filebrowser-container.yaml +164 -0
- package/apps/ollama-binary.yaml +44 -0
- package/apps/ollama-with-hollama-binary.yaml +45 -1
- package/apps/openclaw-binary.yaml +8 -0
- package/apps/openclaw-container.yaml +9 -1
- package/apps/openclaw-with-searxng-container.yaml +4 -0
- package/apps/searxng-container.yaml +5 -4
- package/apps/weknora-container.yaml +471 -0
- package/dist/cli/doctor.js +144 -16
- package/dist/cli/doctor.js.map +1 -1
- package/dist/cli/panel.js.map +1 -1
- package/dist/config.d.ts +19 -0
- package/dist/config.js +99 -1
- package/dist/config.js.map +1 -1
- package/dist/install.js +4 -4
- package/dist/install.js.map +1 -1
- package/dist/routes/auth.js +2 -2
- package/dist/routes/auth.js.map +1 -1
- package/dist/routes/backup.js +64 -11
- package/dist/routes/backup.js.map +1 -1
- package/dist/routes/external-mounts.d.ts +17 -0
- package/dist/routes/external-mounts.js +73 -0
- package/dist/routes/external-mounts.js.map +1 -0
- package/dist/routes/file-mounts.d.ts +13 -0
- package/dist/routes/file-mounts.js +90 -0
- package/dist/routes/file-mounts.js.map +1 -0
- package/dist/routes/files-organize.d.ts +28 -0
- package/dist/routes/files-organize.js +167 -0
- package/dist/routes/files-organize.js.map +1 -0
- package/dist/routes/files.d.ts +31 -0
- package/dist/routes/files.js +321 -0
- package/dist/routes/files.js.map +1 -0
- package/dist/routes/instances.js +87 -12
- package/dist/routes/instances.js.map +1 -1
- package/dist/routes/internal.d.ts +2 -0
- package/dist/routes/internal.js +59 -0
- package/dist/routes/internal.js.map +1 -0
- package/dist/routes/llm.js +29 -0
- package/dist/routes/llm.js.map +1 -1
- package/dist/routes/setup.js +9 -9
- package/dist/routes/setup.js.map +1 -1
- package/dist/routes/system.js +1 -1
- package/dist/routes/system.js.map +1 -1
- package/dist/routes/webdav.d.ts +17 -0
- package/dist/routes/webdav.js +114 -0
- package/dist/routes/webdav.js.map +1 -0
- package/dist/server.js +358 -6
- package/dist/server.js.map +1 -1
- package/dist/services/agent-apps/catalog.d.ts +3 -0
- package/dist/services/agent-apps/catalog.js +40 -13
- package/dist/services/agent-apps/catalog.js.map +1 -1
- package/dist/services/agent-apps/installers/shell-script.d.ts +1 -1
- package/dist/services/agent-apps/installers/shell-script.js +19 -2
- package/dist/services/agent-apps/installers/shell-script.js.map +1 -1
- package/dist/services/agent-apps/types.d.ts +3 -0
- package/dist/services/app/app-compiler.d.ts +1 -1
- package/dist/services/app/app-compiler.js +5 -5
- package/dist/services/app/app-compiler.js.map +1 -1
- package/dist/services/app/app-manager.d.ts +9 -0
- package/dist/services/app/app-manager.js +248 -43
- package/dist/services/app/app-manager.js.map +1 -1
- package/dist/services/app/custom-manager.js.map +1 -1
- package/dist/services/app/hermes-agent-manager.js +1 -0
- package/dist/services/app/hermes-agent-manager.js.map +1 -1
- package/dist/services/app/ollama-manager.js +1 -1
- package/dist/services/app/ollama-manager.js.map +1 -1
- package/dist/services/app/openclaw-manager.js +37 -5
- package/dist/services/app/openclaw-manager.js.map +1 -1
- package/dist/services/app/platform-transform.d.ts +32 -0
- package/dist/services/app/platform-transform.js +65 -0
- package/dist/services/app/platform-transform.js.map +1 -0
- package/dist/services/app-passwords.d.ts +61 -0
- package/dist/services/app-passwords.js +173 -0
- package/dist/services/app-passwords.js.map +1 -0
- package/dist/services/backup-manager.d.ts +11 -0
- package/dist/services/backup-manager.js +220 -8
- package/dist/services/backup-manager.js.map +1 -1
- package/dist/services/capability-endpoint-validator.js +26 -7
- package/dist/services/capability-endpoint-validator.js.map +1 -1
- package/dist/services/connection-apply.d.ts +2 -0
- package/dist/services/connection-apply.js +55 -1
- package/dist/services/connection-apply.js.map +1 -1
- package/dist/services/connection-resolver.js +1 -1
- package/dist/services/connection-resolver.js.map +1 -1
- package/dist/services/connection-transactor.d.ts +2 -0
- package/dist/services/connection-transactor.js +12 -2
- package/dist/services/connection-transactor.js.map +1 -1
- package/dist/services/external-mounts.d.ts +40 -0
- package/dist/services/external-mounts.js +187 -0
- package/dist/services/external-mounts.js.map +1 -0
- package/dist/services/files-manager.d.ts +252 -0
- package/dist/services/files-manager.js +1075 -0
- package/dist/services/files-manager.js.map +1 -0
- package/dist/services/files-mounts.d.ts +42 -0
- package/dist/services/files-mounts.js +207 -0
- package/dist/services/files-mounts.js.map +1 -0
- package/dist/services/instance-manager.js +90 -32
- package/dist/services/instance-manager.js.map +1 -1
- package/dist/services/llm-proxy/index.d.ts +28 -0
- package/dist/services/llm-proxy/index.js +76 -3
- package/dist/services/llm-proxy/index.js.map +1 -1
- package/dist/services/llm-proxy/ssrf.js +6 -2
- package/dist/services/llm-proxy/ssrf.js.map +1 -1
- package/dist/services/llm-proxy/validate-key.d.ts +41 -0
- package/dist/services/llm-proxy/validate-key.js +672 -0
- package/dist/services/llm-proxy/validate-key.js.map +1 -0
- package/dist/services/macos-launchd.d.ts +89 -0
- package/dist/services/macos-launchd.js +273 -0
- package/dist/services/macos-launchd.js.map +1 -0
- package/dist/services/nomad-manager.d.ts +11 -0
- package/dist/services/nomad-manager.js +343 -98
- package/dist/services/nomad-manager.js.map +1 -1
- package/dist/services/organize/applier.d.ts +46 -0
- package/dist/services/organize/applier.js +218 -0
- package/dist/services/organize/applier.js.map +1 -0
- package/dist/services/organize/rules.d.ts +57 -0
- package/dist/services/organize/rules.js +286 -0
- package/dist/services/organize/rules.js.map +1 -0
- package/dist/services/organize/scanner.d.ts +50 -0
- package/dist/services/organize/scanner.js +366 -0
- package/dist/services/organize/scanner.js.map +1 -0
- package/dist/services/organize/store.d.ts +14 -0
- package/dist/services/organize/store.js +82 -0
- package/dist/services/organize/store.js.map +1 -0
- package/dist/services/panel-manager.js +40 -11
- package/dist/services/panel-manager.js.map +1 -1
- package/dist/services/process-manager.js +3 -2
- package/dist/services/process-manager.js.map +1 -1
- package/dist/services/runtime/adapters/custom.js +56 -0
- package/dist/services/runtime/adapters/custom.js.map +1 -1
- package/dist/services/runtime/adapters/hermes.d.ts +4 -3
- package/dist/services/runtime/adapters/hermes.js +166 -64
- package/dist/services/runtime/adapters/hermes.js.map +1 -1
- package/dist/services/runtime/adapters/openclaw-routes.d.ts +8 -2
- package/dist/services/runtime/adapters/openclaw-routes.js +68 -0
- package/dist/services/runtime/adapters/openclaw-routes.js.map +1 -1
- package/dist/services/runtime/adapters/openclaw.d.ts +118 -0
- package/dist/services/runtime/adapters/openclaw.js +1459 -49
- package/dist/services/runtime/adapters/openclaw.js.map +1 -1
- package/dist/services/runtime/instance.d.ts +1 -1
- package/dist/services/runtime/instance.js +1 -1
- package/dist/services/runtime/instance.js.map +1 -1
- package/dist/services/runtime/mcp-shims/anythingllm-shim.d.ts +46 -0
- package/dist/services/runtime/mcp-shims/anythingllm-shim.js +281 -0
- package/dist/services/runtime/mcp-shims/anythingllm-shim.js.map +1 -0
- package/dist/services/runtime/mcp-shims/drive-shim.d.ts +54 -0
- package/dist/services/runtime/mcp-shims/drive-shim.js +489 -0
- package/dist/services/runtime/mcp-shims/drive-shim.js.map +1 -0
- package/dist/services/runtime/types.d.ts +31 -0
- package/dist/services/setup-manager.js +190 -68
- package/dist/services/setup-manager.js.map +1 -1
- package/dist/services/suggestions.js.map +1 -1
- package/dist/services/update-manager.js +32 -14
- package/dist/services/update-manager.js.map +1 -1
- package/dist/services/webdav/server.d.ts +24 -0
- package/dist/services/webdav/server.js +420 -0
- package/dist/services/webdav/server.js.map +1 -0
- package/dist/services/webdav/xml-builder.d.ts +73 -0
- package/dist/services/webdav/xml-builder.js +156 -0
- package/dist/services/webdav/xml-builder.js.map +1 -0
- package/dist/services/workspace-builder.d.ts +29 -0
- package/dist/services/workspace-builder.js +188 -0
- package/dist/services/workspace-builder.js.map +1 -0
- package/dist/types.d.ts +61 -0
- package/dist/utils/path-locks.d.ts +30 -0
- package/dist/utils/path-locks.js +63 -0
- package/dist/utils/path-locks.js.map +1 -0
- package/dist/utils/path-safety.d.ts +41 -0
- package/dist/utils/path-safety.js +119 -0
- package/dist/utils/path-safety.js.map +1 -0
- package/dist/utils/safe-write.d.ts +24 -0
- package/dist/utils/safe-write.js +82 -0
- package/dist/utils/safe-write.js.map +1 -0
- package/install/jishu-install.sh +247 -35
- package/install/jishu-uninstall.sh +45 -5
- package/package.json +20 -2
- package/public/assets/ApiKeyField-CvyAOcJS.js +1 -0
- package/public/assets/Dashboard-AuJESBlJ.js +1 -0
- package/public/assets/{HermesChatPanel-_GHoklgo.js → HermesChatPanel-CByPREwb.js} +1 -1
- package/public/assets/HermesConfigForm-DRda8FKX.js +4 -0
- package/public/assets/InitPassword-ka4wNpM5.js +1 -0
- package/public/assets/InstanceDetail-Cg1nS8HX.js +92 -0
- package/public/assets/Login-aPajuQzf.js +1 -0
- package/public/assets/NewInstance-Dd1ebNIx.js +1 -0
- package/public/assets/ProviderRecommendations-DFmADQ7V.js +1 -0
- package/public/assets/Settings-BYQnbLYL.js +1 -0
- package/public/assets/Setup-D05lwDOV.js +1 -0
- package/public/assets/WeixinLoginPanel-D89kdhP4.js +9 -0
- package/public/assets/index-HSXCsceK.css +1 -0
- package/public/assets/index-bnBu0nlQ.js +19 -0
- package/public/assets/registry-C_qeFTkZ.js +2 -0
- package/public/assets/usePolling-Bn93fe7M.js +1 -0
- package/public/assets/{vendor-i18n-ucpM0OR0.js → vendor-i18n-flxcMVeP.js} +2 -2
- package/public/assets/{vendor-react-Bk1hRGiY.js → vendor-react-ZC5T_huj.js} +7 -7
- package/public/index.html +4 -4
- package/scripts/check-app-spec.mjs +18 -4
- package/scripts/check-colima-launchd.mjs +230 -0
- package/scripts/check-new-file-tests.mjs +230 -0
- package/scripts/check-quarantine-expiry.mjs +105 -0
- package/scripts/perf/README.md +49 -0
- package/scripts/perf/auth.js +99 -0
- package/scripts/perf/config.js +63 -0
- package/scripts/perf/instances.js +143 -0
- package/scripts/perf/proxy.js +96 -0
- package/scripts/smoke/files-w1.sh +142 -0
- package/scripts/smoke-backend.mjs +122 -0
- package/scripts/smoke-post-publish.mjs +346 -0
- package/public/assets/Dashboard-rkWp-CXd.js +0 -1
- package/public/assets/HermesConfigForm-anDnwUp_.js +0 -4
- package/public/assets/InitPassword-ZU9_-hDr.js +0 -1
- package/public/assets/InstanceDetail-CN0FH1aw.js +0 -92
- package/public/assets/Login-BItXqYAJ.js +0 -1
- package/public/assets/NewInstance-BousE6kY.js +0 -1
- package/public/assets/ProviderRecommendations-DFYj7Fb6.js +0 -1
- package/public/assets/Settings-Bttc6QmM.js +0 -1
- package/public/assets/Setup-Bsxx1zgj.js +0 -1
- package/public/assets/WeixinLoginPanel-DPZpAKgO.js +0 -9
- package/public/assets/index-8xZy1z5k.css +0 -1
- package/public/assets/index-Dw3HhUYE.js +0 -19
- package/public/assets/input-paste-CrNVAyOy.js +0 -1
- package/public/assets/providers-DtNXh9JD.js +0 -1
- package/public/assets/registry-5s2UB6is.js +0 -2
- package/public/assets/usePolling-Do5Erqm_.js +0 -1
|
@@ -36,6 +36,13 @@
|
|
|
36
36
|
import { type InstallResult } from "../../setup-manager.js";
|
|
37
37
|
import type { AdapterHooks, AdapterManifest, AgentType, CapabilityProfile, ConfigDocument, CreateInstanceArgs, CreateInstanceContext, InstanceConfigMeta, InstancePaths, PairingApproveInput, RuntimeAdapter, RuntimeSpec, RuntimeVersionInfo } from "../types.js";
|
|
38
38
|
export declare const OPENCLAW_DEFAULT_GATEWAY_PORT = 18789;
|
|
39
|
+
export declare function isPrivateNetworkBaseUrl(baseUrl: string): boolean;
|
|
40
|
+
/**
|
|
41
|
+
* Ensure `request.allowPrivateNetwork: true` is set on providers whose baseUrl
|
|
42
|
+
* targets a private/internal host (e.g. host.docker.internal). Without this,
|
|
43
|
+
* OpenClaw's SSRF guard blocks requests to the JishuShell local proxy.
|
|
44
|
+
*/
|
|
45
|
+
export declare function patchPrivateNetworkAllowFlag(configPath: string): void;
|
|
39
46
|
/**
|
|
40
47
|
* Ensure the `llm-agent` capability advertised by openclaw-*.yaml works for
|
|
41
48
|
* every instance, including ones created before this code shipped: enable
|
|
@@ -93,6 +100,117 @@ export declare function applySearxngConnectionToConfig(configPath: string, baseU
|
|
|
93
100
|
* No-op when the config file is absent.
|
|
94
101
|
*/
|
|
95
102
|
export declare function clearSearxngConnectionFromConfig(configPath: string): void;
|
|
103
|
+
/**
|
|
104
|
+
* Deep-merge a Browserless CDP connection into an OpenClaw config file at
|
|
105
|
+
* `configPath`. Mirrors `applySearxngConnectionToConfig` for the browser slot.
|
|
106
|
+
*
|
|
107
|
+
* Writes:
|
|
108
|
+
* browser.profiles.browserless.cdpUrl = cdpUrl // ws:// or wss://
|
|
109
|
+
* browser.profiles.browserless.attachOnly = true // since v2026.3.2
|
|
110
|
+
* browser.profiles.browserless.color = "#00AA66" // required by schema
|
|
111
|
+
* browser.defaultProfile = "browserless" // only if unset
|
|
112
|
+
* browser.enabled = true // only if unset
|
|
113
|
+
* gateway.nodes.browser.mode = "off" // only if unset
|
|
114
|
+
*
|
|
115
|
+
* Why per-profile `attachOnly` and not global `browser.attachOnly`: global
|
|
116
|
+
* attachOnly forces every profile to skip launch — that breaks the user's
|
|
117
|
+
* other manually-configured profiles. Per-profile attachOnly was added in
|
|
118
|
+
* OpenClaw v2026.3.2; older versions silently ignore the extra field and
|
|
119
|
+
* fall back to attach-via-cdpUrl semantics (which `cdpUrl` triggers on its
|
|
120
|
+
* own from v2.0.0-beta5), so the schema is forward-compatible all the way
|
|
121
|
+
* back to the first remote-CDP release.
|
|
122
|
+
*
|
|
123
|
+
* Why `gateway.nodes.browser.mode = "off"`: in OpenClaw 2026.5.6 the
|
|
124
|
+
* gateway only registers the `browser.request` WS method when this config
|
|
125
|
+
* block exists. Without it, `openclaw browser …` CLI and the gateway
|
|
126
|
+
* canvas tool both fail with `unknown method: browser.request` or
|
|
127
|
+
* `node required`. Setting `mode: "off"` forces gateway-local CDP
|
|
128
|
+
* dispatch (use `cdpUrl` directly, never look for paired nodes), which
|
|
129
|
+
* matches jishushell's intent: Browserless is a service-style provider,
|
|
130
|
+
* not a node-style provider. Verified end-to-end on Pi 2 (2026-05-07):
|
|
131
|
+
* Browserless `/sessions` shows `numbConnected: 1` and `openclaw browser
|
|
132
|
+
* navigate <allowed-host>` succeeds + screenshots render correctly.
|
|
133
|
+
*
|
|
134
|
+
* `defaultProfile`, `enabled`, and `gateway.nodes.browser.mode` are all
|
|
135
|
+
* set only when absent so user-customized values survive a re-bind. The
|
|
136
|
+
* `enabled` flag is never flipped off — Browserless binding shouldn't
|
|
137
|
+
* override a user who explicitly disabled the browser tool tree.
|
|
138
|
+
*
|
|
139
|
+
* SSRF policy is intentionally NOT touched here: `browser.ssrfPolicy`
|
|
140
|
+
* (`dangerouslyAllowPrivateNetwork`, `allowedHostnames`) is a user-level
|
|
141
|
+
* security decision (default deny-all is correct for an LLM-driven
|
|
142
|
+
* browser); jishushell would be over-reaching to silently widen it on
|
|
143
|
+
* binding. Users who want the agent to reach a specific host configure
|
|
144
|
+
* the allowlist themselves.
|
|
145
|
+
*
|
|
146
|
+
* No-op when the config file is absent (instance not yet started).
|
|
147
|
+
*/
|
|
148
|
+
export declare function applyBrowserlessConnectionToConfig(configPath: string, cdpUrl: string): void;
|
|
149
|
+
/**
|
|
150
|
+
* Counterpart to `applyBrowserlessConnectionToConfig` — invoked when the user
|
|
151
|
+
* unbinds the BROWSER slot in the Connections tab. Removes the
|
|
152
|
+
* jishushell-managed `browserless` profile and clears `defaultProfile` only
|
|
153
|
+
* if it still points at that profile (so user-set defaults pointing at their
|
|
154
|
+
* own profiles survive). Other profiles and `browser.enabled` are left alone.
|
|
155
|
+
*
|
|
156
|
+
* No-op when the config file is absent.
|
|
157
|
+
*/
|
|
158
|
+
export declare function clearBrowserlessConnectionFromConfig(configPath: string): void;
|
|
159
|
+
/**
|
|
160
|
+
* Inject a guarded section into the agent's TOOLS.md telling the LLM that
|
|
161
|
+
* user files live on the local filesystem (host==container bind mount),
|
|
162
|
+
* not on some remote "drive server", and showing the concrete
|
|
163
|
+
* resolve-then-send chain for IM channels (Feishu / WeChat).
|
|
164
|
+
*
|
|
165
|
+
* Why this exists: the LLM defaults to interpreting `drive` as a remote
|
|
166
|
+
* service, then refuses to send NAS files via IM with "I can't access the
|
|
167
|
+
* cloud drive" — even when `drive_list` literally just enumerated them.
|
|
168
|
+
* Verified on pi2 2026-05-11: claw1 saw `文档/宇树G1-D...xlsx` via
|
|
169
|
+
* drive_list, then told the user to "open Feishu cloud space and forward
|
|
170
|
+
* it back" because nothing in TOOLS.md tied drive paths to filesystem
|
|
171
|
+
* paths. This patcher closes that gap by spelling it out.
|
|
172
|
+
*
|
|
173
|
+
* Idempotent: section is bracketed by HTML markers; content between them
|
|
174
|
+
* is rewritten on every call. User edits OUTSIDE the markers are kept.
|
|
175
|
+
*
|
|
176
|
+
* filesRoot is baked in so the example abs path matches the actual install
|
|
177
|
+
* — third-party users on `/home/alice/.jishushell/files/` see their own
|
|
178
|
+
* root, not pi's.
|
|
179
|
+
*/
|
|
180
|
+
export declare function patchToolsMdDriveHint(workspaceDir: string, filesRoot: string): void;
|
|
181
|
+
/**
|
|
182
|
+
* Inject a guarded section into TOOLS.md describing the kb_search MCP
|
|
183
|
+
* tool — only when an AnythingLLM-backed knowledge base is wired into
|
|
184
|
+
* this instance. Mirrors patchToolsMdDriveHint's marker model so an
|
|
185
|
+
* uninstall / unbind can cleanly strip the section.
|
|
186
|
+
*
|
|
187
|
+
* `mode === "install"` writes the kb hint between the markers
|
|
188
|
+
* (overwriting any previous content there). `mode === "remove"`
|
|
189
|
+
* deletes the entire bracketed section, leaving the user's
|
|
190
|
+
* surrounding content intact.
|
|
191
|
+
*/
|
|
192
|
+
export declare function patchToolsMdKbHint(workspaceDir: string, mode: "install" | "remove"): void;
|
|
193
|
+
/**
|
|
194
|
+
* Patch the session fence bug in OpenClaw >= 5.19 by replacing the
|
|
195
|
+
* `eventMayReachTranscriptWriters` function in the minified bundle.
|
|
196
|
+
*
|
|
197
|
+
* Idempotent: uses a marker file containing the SHA-256 of the patched
|
|
198
|
+
* file. Skips if already patched or if the pattern is not found (future
|
|
199
|
+
* fixed version or different bundle layout).
|
|
200
|
+
*
|
|
201
|
+
* Docker-only: the bug manifests through the virtiofs mount timing
|
|
202
|
+
* discrepancy between container and host — raw_exec/process modes are
|
|
203
|
+
* unaffected in practice.
|
|
204
|
+
*/
|
|
205
|
+
export declare function patchSessionFenceBug(openclawHome: string, instanceId: string): void;
|
|
206
|
+
/**
|
|
207
|
+
* Write the container-side patch script and entrypoint wrapper to the
|
|
208
|
+
* openclaw-home directory so they are available inside the container
|
|
209
|
+
* via the bind mount.
|
|
210
|
+
*
|
|
211
|
+
* Called from onBeforeStart. Idempotent — only writes if content changed.
|
|
212
|
+
*/
|
|
213
|
+
export declare function writeContainerPatchScript(openclawHome: string): void;
|
|
96
214
|
declare class OpenClawAdapter implements RuntimeAdapter {
|
|
97
215
|
readonly agentType: AgentType;
|
|
98
216
|
readonly displayName = "OpenClaw";
|