arcane-os 0.51.0 → 0.51.2
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 +20 -0
- package/README.md +81 -44
- package/browser-runtime/ai/twin-cloud.mjs +4 -0
- package/docs/architecture.md +33 -17
- package/docs/platform-targets.md +15 -2
- package/docs/reference/README.md +31 -26
- package/docs/reference/ai/browser-speech.md +106 -31
- package/docs/reference/ai/browser-wasm.md +27 -24
- package/docs/reference/ai/twin-cloud.md +30 -11
- package/docs/reference/asset-versioning.md +34 -37
- package/docs/reference/availability-and-normalization.md +31 -20
- package/docs/reference/cli.md +30 -17
- package/docs/reference/inventory/package-api.json +34 -6
- package/docs/reference/inventory/runtime-components.json +25 -11
- package/docs/reference/inventory/runtime-entities.json +6 -3
- package/docs/reference/inventory/runtime-modules.json +63 -8
- package/docs/reference/protocols.md +62 -56
- package/docs/reference/pwa.md +20 -13
- package/docs/reference/runtime-components.md +9 -2
- package/docs/reference/runtime-entities.md +14 -2
- package/docs/reference/runtime-modules.md +59 -2
- package/docs/reference/sdk-api.md +231 -65
- package/docs/roadmap.md +32 -26
- package/package.json +1 -1
- package/runtime/arcane/modules/AI.js +20 -6
- package/src/dev-server.mjs +3 -30
|
@@ -4448,7 +4448,8 @@ class AI {
|
|
|
4448
4448
|
signal,
|
|
4449
4449
|
payload.reasoningEffort,
|
|
4450
4450
|
onRetry,
|
|
4451
|
-
payload.model
|
|
4451
|
+
payload.model,
|
|
4452
|
+
payload.temperature
|
|
4452
4453
|
);
|
|
4453
4454
|
}
|
|
4454
4455
|
|
|
@@ -4480,7 +4481,8 @@ class AI {
|
|
|
4480
4481
|
payload.reasoningEffort,
|
|
4481
4482
|
observeToolText,
|
|
4482
4483
|
onRetry,
|
|
4483
|
-
payload.model
|
|
4484
|
+
payload.model,
|
|
4485
|
+
payload.temperature
|
|
4484
4486
|
);
|
|
4485
4487
|
}
|
|
4486
4488
|
|
|
@@ -4810,7 +4812,8 @@ class AI {
|
|
|
4810
4812
|
normalizedReasoningEffort,
|
|
4811
4813
|
observeToolText,
|
|
4812
4814
|
onRetry,
|
|
4813
|
-
model
|
|
4815
|
+
model,
|
|
4816
|
+
temperature
|
|
4814
4817
|
);
|
|
4815
4818
|
const structuralToolCalls=normalizeAICompletionToolCalls(
|
|
4816
4819
|
completion
|
|
@@ -4920,7 +4923,8 @@ class AI {
|
|
|
4920
4923
|
reasoningEffort,
|
|
4921
4924
|
observeToolText=null,
|
|
4922
4925
|
onRetry = null,
|
|
4923
|
-
model=this.model
|
|
4926
|
+
model=this.model,
|
|
4927
|
+
temperature
|
|
4924
4928
|
){
|
|
4925
4929
|
let speechTurnCompleted=false;
|
|
4926
4930
|
|
|
@@ -4949,6 +4953,10 @@ class AI {
|
|
|
4949
4953
|
stream:true
|
|
4950
4954
|
}
|
|
4951
4955
|
|
|
4956
|
+
if(this.llmService==='TWIN' && temperature!==undefined){
|
|
4957
|
+
request.temperature=temperature;
|
|
4958
|
+
}
|
|
4959
|
+
|
|
4952
4960
|
if(structuredOutputFormat){
|
|
4953
4961
|
request.response_format=openAIResponseFormat(
|
|
4954
4962
|
structuredOutputFormat
|
|
@@ -5740,7 +5748,8 @@ class AI {
|
|
|
5740
5748
|
signal,
|
|
5741
5749
|
normalizedReasoningEffort,
|
|
5742
5750
|
onRetry,
|
|
5743
|
-
model
|
|
5751
|
+
model,
|
|
5752
|
+
temperature
|
|
5744
5753
|
);
|
|
5745
5754
|
}
|
|
5746
5755
|
|
|
@@ -5795,7 +5804,8 @@ class AI {
|
|
|
5795
5804
|
signal=null,
|
|
5796
5805
|
reasoningEffort,
|
|
5797
5806
|
onRetry = null,
|
|
5798
|
-
model=this.model
|
|
5807
|
+
model=this.model,
|
|
5808
|
+
temperature
|
|
5799
5809
|
){
|
|
5800
5810
|
validateAIStructuralRequest(messages,tools,parallel_tool_calls);
|
|
5801
5811
|
this.#assertServiceConfigured(this.llmService);
|
|
@@ -5819,6 +5829,10 @@ class AI {
|
|
|
5819
5829
|
stream:false
|
|
5820
5830
|
}
|
|
5821
5831
|
|
|
5832
|
+
if(this.llmService==='TWIN' && temperature!==undefined){
|
|
5833
|
+
request.temperature=temperature;
|
|
5834
|
+
}
|
|
5835
|
+
|
|
5822
5836
|
if(structuredOutputFormat){
|
|
5823
5837
|
request.response_format=openAIResponseFormat(
|
|
5824
5838
|
structuredOutputFormat
|
package/src/dev-server.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import Is from 'strong-type';
|
|
2
2
|
import {Server} from 'node-http-server';
|
|
3
|
+
import contentTypes from 'node-http-server/mime-types';
|
|
3
4
|
import {constants as FS_CONSTANTS} from 'node:fs';
|
|
4
5
|
import {lstat,open,readFile,readdir,realpath} from 'node:fs/promises';
|
|
5
6
|
import https from 'node:https';
|
|
@@ -19,26 +20,6 @@ import {createPwaArtifacts,selectPwaFiles} from './pwa.mjs';
|
|
|
19
20
|
|
|
20
21
|
const is = new Is(false);
|
|
21
22
|
|
|
22
|
-
const MIME_TYPES=new Map([
|
|
23
|
-
['.css','text/css; charset=utf-8'],
|
|
24
|
-
['.gif','image/gif'],
|
|
25
|
-
['.html','text/html; charset=utf-8'],
|
|
26
|
-
['.htm','text/html; charset=utf-8'],
|
|
27
|
-
['.ico','image/x-icon'],
|
|
28
|
-
['.jpeg','image/jpeg'],
|
|
29
|
-
['.jpg','image/jpeg'],
|
|
30
|
-
['.js','text/javascript; charset=utf-8'],
|
|
31
|
-
['.json','application/json; charset=utf-8'],
|
|
32
|
-
['.mjs','text/javascript; charset=utf-8'],
|
|
33
|
-
['.png','image/png'],
|
|
34
|
-
['.svg','image/svg+xml; charset=utf-8'],
|
|
35
|
-
['.txt','text/plain; charset=utf-8'],
|
|
36
|
-
['.wasm','application/wasm'],
|
|
37
|
-
['.webmanifest','application/manifest+json; charset=utf-8'],
|
|
38
|
-
['.webp','image/webp'],
|
|
39
|
-
['.woff','font/woff'],
|
|
40
|
-
['.woff2','font/woff2']
|
|
41
|
-
]);
|
|
42
23
|
const READ_ONLY_NO_FOLLOW=FS_CONSTANTS.O_RDONLY|(FS_CONSTANTS.O_NOFOLLOW??0);
|
|
43
24
|
const PRIVATE_SOURCE_SEGMENTS=new Set([
|
|
44
25
|
'arcane-app.json','arcane-package.json','test','tests','scripts','node_modules','dist','local'
|
|
@@ -366,7 +347,7 @@ async function serveSourceFile(fileServer, request, response, opened, {
|
|
|
366
347
|
response,
|
|
367
348
|
{
|
|
368
349
|
lastModified,
|
|
369
|
-
contentType:
|
|
350
|
+
contentType: contentTypes[extension.substring(1)] || 'application/octet-stream',
|
|
370
351
|
body: async function createSourceRepresentation() {
|
|
371
352
|
let content = opened.content ?? await readFile(opened.candidate);
|
|
372
353
|
if (rewrite) {
|
|
@@ -1187,7 +1168,7 @@ async function startOwnedDevServer({
|
|
|
1187
1168
|
// An older in-flight snapshot may finish after a newer
|
|
1188
1169
|
// selection. Its body cannot validate that newer output.
|
|
1189
1170
|
lastModified: selectedRoutes === currentSourceRoutes ? generated.lastModified : undefined,
|
|
1190
|
-
contentType:
|
|
1171
|
+
contentType: contentTypes[path.extname(generated.path).substring(1).toLowerCase()],
|
|
1191
1172
|
body: function generatedPwaBody() {
|
|
1192
1173
|
return generated.content;
|
|
1193
1174
|
}
|
|
@@ -1313,13 +1294,6 @@ async function startOwnedDevServer({
|
|
|
1313
1294
|
await task;
|
|
1314
1295
|
return true;
|
|
1315
1296
|
}
|
|
1316
|
-
const contentType = Object.fromEntries(
|
|
1317
|
-
[...MIME_TYPES].map(
|
|
1318
|
-
function serverContentType([extension, value]) {
|
|
1319
|
-
return [extension.substring(1), value];
|
|
1320
|
-
}
|
|
1321
|
-
)
|
|
1322
|
-
);
|
|
1323
1297
|
const fileServer = new Server(
|
|
1324
1298
|
{
|
|
1325
1299
|
root: mappings[0].root,
|
|
@@ -1338,7 +1312,6 @@ async function startOwnedDevServer({
|
|
|
1338
1312
|
})
|
|
1339
1313
|
}
|
|
1340
1314
|
);
|
|
1341
|
-
fileServer.config.contentType = contentType;
|
|
1342
1315
|
fileServer.onRawRequest = serveDevelopmentRequest;
|
|
1343
1316
|
// The module's public HTTPS configuration accepts PEM paths. Its HTTPS
|
|
1344
1317
|
// guide leaves advanced TLS inputs to application code; preserve that
|