arcane-os 0.4.1 → 0.5.0
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/CHANGELOG.md +25 -0
- package/README.md +47 -11
- package/browser-runtime/ai/browser-wasm-llm-provider.mjs +1140 -79
- package/package.json +1 -1
- package/runtime/arcane/components/chat.html +162 -5
- package/runtime/arcane/components/local-ai-status.html +2 -2
- package/runtime/arcane/modules/AI.js +22 -6
- package/runtime/arcane/modules/LocalAIReadiness.js +8 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,30 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.5.0
|
|
4
|
+
|
|
5
|
+
- Added bounded parallel Browser-WASM model downloads across split GGUF
|
|
6
|
+
members and resumable HTTP Range parts while preserving descriptor order and
|
|
7
|
+
the configured transfer limit.
|
|
8
|
+
- Added retry pickup for completed shards and Range parts, with transparent
|
|
9
|
+
fallback to one full fetch when a source does not support usable ranges.
|
|
10
|
+
- Added determinate aggregate download progress with transferred and remaining
|
|
11
|
+
data, live speed, approximate time remaining, active transfers, and transfer
|
|
12
|
+
mode.
|
|
13
|
+
- Reused complete same-model legacy cache entries in preference to incomplete
|
|
14
|
+
replacements and removed redundant legacy files and completed fragments when
|
|
15
|
+
cleanup succeeds.
|
|
16
|
+
- Replaced the default remote LLM destination and model with TWiN Cloud at the
|
|
17
|
+
OpenAI-compatible DigitalOcean inference endpoint, added the TWiN access-key
|
|
18
|
+
configuration surface, and retained the prior route and credential names as
|
|
19
|
+
compatibility aliases.
|
|
20
|
+
|
|
21
|
+
## 0.4.2
|
|
22
|
+
|
|
23
|
+
- Added transparent Browser-WASM model loading status across cache checks,
|
|
24
|
+
ordered model-file downloads, and WebGPU initialization, including file
|
|
25
|
+
counts, elapsed time, and five-second heartbeats so long downloads remain
|
|
26
|
+
visibly active without byte-based progress.
|
|
27
|
+
|
|
3
28
|
## 0.4.1
|
|
4
29
|
|
|
5
30
|
- Preserved complete DirectoryPicker titles, paths, caller options, and
|
package/README.md
CHANGED
|
@@ -19,7 +19,7 @@ version-locked SDK runtime, while an integrated Arcane checkout uses its live
|
|
|
19
19
|
`arcane/` runtime. Both profiles preserve the same app URLs, theme, packaging,
|
|
20
20
|
event, cancellation, and browser run contracts.
|
|
21
21
|
|
|
22
|
-
This checkout defines the `0.
|
|
22
|
+
This checkout defines the `0.5.0` SDK contract. Applications pin one exact npm
|
|
23
23
|
version and lockfile; registry state is deliberately not baked into application
|
|
24
24
|
artifacts.
|
|
25
25
|
|
|
@@ -79,6 +79,17 @@ Arcane OS must consume the same locked SDK projection as other applications;
|
|
|
79
79
|
any remaining OS-side duplicate is legacy consumer migration state, not source
|
|
80
80
|
authority.
|
|
81
81
|
|
|
82
|
+
## TWiN Cloud
|
|
83
|
+
|
|
84
|
+
TWiN Cloud is the SDK's default remote language-model service. It sends
|
|
85
|
+
OpenAI-compatible chat-completion requests to
|
|
86
|
+
`https://inference.do-ai.run/v1/chat/completions` with model
|
|
87
|
+
`openai-gpt-oss-120b`. Supply the bearer credential through `ai.twinKey` or
|
|
88
|
+
`globalThis.arcane.config.twinCloud.accessKey`. The established `ai.license`
|
|
89
|
+
property and internal `OPENAI` route identifier remain compatibility aliases;
|
|
90
|
+
applications should present the service and credential as **TWiN Cloud** and
|
|
91
|
+
**TWiN access key**.
|
|
92
|
+
|
|
82
93
|
## Browser-local AI
|
|
83
94
|
|
|
84
95
|
`arcane-os/ai/browser-wasm` provides the shared Wllama LLM provider. The app
|
|
@@ -96,11 +107,36 @@ const source=createBrowserModelSource({
|
|
|
96
107
|
});
|
|
97
108
|
```
|
|
98
109
|
|
|
99
|
-
Model members require only their names and URLs.
|
|
100
|
-
|
|
110
|
+
Model members require only their names and URLs. A member may also declare a
|
|
111
|
+
positive safe-integer `bytes` value so the application can present determinate
|
|
112
|
+
progress and the transport can plan parallel HTTP ranges. An unusable value is
|
|
113
|
+
treated as unavailable and never blocks the ordinary download. That value is observational
|
|
114
|
+
transfer metadata: it never validates, admits, identifies, or decides cache
|
|
115
|
+
reuse for model content. During a cache miss, the store reports live aggregate
|
|
116
|
+
`loadedBytes`, `totalBytes`, `remainingBytes`, `bytesPerSecond`, `etaSeconds`,
|
|
117
|
+
`activeTransfers`, `transferLimit`, and `transferMode` alongside the existing
|
|
118
|
+
completed-file counts. Chunk-driven updates are coalesced on a 250 ms cadence;
|
|
119
|
+
transfer-plan, active-worker, and completion boundaries publish immediately.
|
|
101
120
|
Optional hardening is inactive unless the caller explicitly selects
|
|
102
|
-
`secure:true`. The DBOPFS store
|
|
103
|
-
|
|
121
|
+
`secure:true`. The DBOPFS store downloads ordered members with one bounded
|
|
122
|
+
parallel transfer pool and returns them in descriptor order. Completed shards
|
|
123
|
+
survive an interrupted attempt and only missing shard or Range-part work is
|
|
124
|
+
fetched on retry. A
|
|
125
|
+
monolithic file uses up to `downloadConcurrency` active workers (four by
|
|
126
|
+
default) over up to 16 deterministic, resumable HTTP range parts when the server
|
|
127
|
+
confirms `206` responses and the total comes from `Content-Range` or, when that
|
|
128
|
+
header is not exposed, optional declared `bytes`.
|
|
129
|
+
When a followed redirect turns the first Range probe into `200`, the SDK probes
|
|
130
|
+
the final URL directly before reusing that original response as the single-fetch
|
|
131
|
+
fallback. Completed range parts survive restart and are presented to Wllama as
|
|
132
|
+
one logical model. Split members use the same Range negotiation with one active
|
|
133
|
+
Range worker per member, so completed parts within a shard can also resume
|
|
134
|
+
without multiplying the configured transfer bound. A probe without an
|
|
135
|
+
observable or declared total falls back to one full fetch. Once a complete
|
|
136
|
+
whole file or Range set is available, the store removes superseded fragments
|
|
137
|
+
and the exact legacy duplicate for that model when DBOPFS deletion succeeds;
|
|
138
|
+
cleanup failure is warned without hiding the usable model.
|
|
139
|
+
Capability reports evaluate each
|
|
104
140
|
app-supplied model as `compatible`, `incompatible`, or `unknown`; the app can
|
|
105
141
|
render that result without the SDK inventing or filtering its catalog.
|
|
106
142
|
|
|
@@ -126,7 +162,7 @@ uses the same controller for automatic memory extraction.
|
|
|
126
162
|
Create a new repository-shaped Arcane application with the exact stable SDK:
|
|
127
163
|
|
|
128
164
|
```bash
|
|
129
|
-
npx arcane-os@0.
|
|
165
|
+
npx arcane-os@0.5.0 new my-app --path ./my-app --target portable --git
|
|
130
166
|
cd my-app
|
|
131
167
|
npm install
|
|
132
168
|
npm run check
|
|
@@ -137,7 +173,7 @@ To enroll an existing repository, install the exact SDK and initialize only
|
|
|
137
173
|
missing Arcane files:
|
|
138
174
|
|
|
139
175
|
```bash
|
|
140
|
-
npm install --save-dev --save-exact arcane-os@0.
|
|
176
|
+
npm install --save-dev --save-exact arcane-os@0.5.0
|
|
141
177
|
npm exec -- arcane init my-app --target portable
|
|
142
178
|
```
|
|
143
179
|
|
|
@@ -153,7 +189,7 @@ npm exec -- arcane-os targets
|
|
|
153
189
|
No global SDK install or standalone Arcane CLI is required. The application
|
|
154
190
|
repository's exact npm dependency and lockfile own the CLI and toolchain version.
|
|
155
191
|
|
|
156
|
-
Use `npx arcane-os@0.
|
|
192
|
+
Use `npx arcane-os@0.5.0` for the initial bootstrap because it names this npm
|
|
157
193
|
package explicitly; bare `npx arcane` outside an installed project could resolve
|
|
158
194
|
a different package. Both installed commands invoke the same headless toolchain.
|
|
159
195
|
Project-local npm scripts use the SDK pinned by that app's `package-lock.json`,
|
|
@@ -174,7 +210,7 @@ node ./bin/arcane.mjs new local-app --path ../local-app --target portable --git
|
|
|
174
210
|
|
|
175
211
|
# From the generated app repository
|
|
176
212
|
cd ../local-app
|
|
177
|
-
npm install --save-dev --save-exact ../arcane-os-sdk/arcane-os-0.
|
|
213
|
+
npm install --save-dev --save-exact ../arcane-os-sdk/arcane-os-0.5.0.tgz
|
|
178
214
|
npm run check
|
|
179
215
|
npm ci
|
|
180
216
|
```
|
|
@@ -184,7 +220,7 @@ same location. The lockfile retains the selected package dependency while
|
|
|
184
220
|
Arcane uses the installed package name and version. Local directory `file:` dependencies are not
|
|
185
221
|
accepted because npm may install them as links; use a packed `.tgz`. A GitHub
|
|
186
222
|
runner also needs that tarball at the locked path. After publication, replace
|
|
187
|
-
the local declaration with the exact `arcane-os@0.
|
|
223
|
+
the local declaration with the exact `arcane-os@0.5.0` registry package and
|
|
188
224
|
commit the regenerated lock.
|
|
189
225
|
|
|
190
226
|
Generated repositories use `npm ci --ignore-scripts` in CI. Run dependency
|
|
@@ -322,7 +358,7 @@ package installation, or assertions.
|
|
|
322
358
|
|
|
323
359
|
## Current target support
|
|
324
360
|
|
|
325
|
-
Version `0.
|
|
361
|
+
Version `0.5.0` exposes one browser target and five explicitly paired
|
|
326
362
|
native development targets: a non-runnable portable directory, a
|
|
327
363
|
Windows x64 unsigned-local-test EXE bundle, Linux x64 and Linux ARM64
|
|
328
364
|
unsigned-local-test DEBs, and an Android development-signed APK. The
|