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