@holoscript/core 8.0.5 → 8.0.7
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/README.md +34 -34
- package/bin/holoscript.cjs +1 -1
- package/dist/GLTFPipeline-3EJLL3TS.cjs +38 -0
- package/dist/GLTFPipeline-3OWJV2VK.js +17 -0
- package/dist/{HoloScriptPlusParser-A2W7OCN2.cjs → HoloScriptPlusParser-ADWRY5OS.cjs} +15 -15
- package/dist/{HoloScriptPlusParser-7FBIFUFC.js → HoloScriptPlusParser-JLJDXHSC.js} +4 -4
- package/dist/HoloScriptPlusParser-QCGFPWIL.cjs +27 -0
- package/dist/{HoloScriptPlusParser-F2Z56FJR.js → HoloScriptPlusParser-WENAFEFV.js} +5 -5
- package/dist/HoloScriptRuntime-GGRVEU4T.cjs +19 -0
- package/dist/HoloScriptRuntime-GJK6VJPH.js +10 -0
- package/dist/{USDZExporter-3FWJ25JI.cjs → USDZExporter-AUHZODOF.cjs} +15 -4
- package/dist/{USDZExporter-D2HQLQYK.js → USDZExporter-GXB4AUSG.js} +15 -4
- package/dist/{chunk-V6MKC2FZ.js → chunk-22Q5A6RV.js} +3 -3
- package/dist/{chunk-IUDGEUDO.cjs → chunk-2BZHWUSR.cjs} +27 -15
- package/dist/{chunk-XJAN7CZG.cjs → chunk-2GCNOI2U.cjs} +2 -2
- package/dist/{chunk-CCATWPXM.js → chunk-2OWDB4FB.js} +13 -25
- package/dist/{chunk-N75IH2HY.js → chunk-2Y3V22SG.js} +5 -14
- package/dist/{chunk-MXFUTKCO.js → chunk-33YHE7HX.js} +3 -7
- package/dist/{chunk-GYZE55MO.js → chunk-3GWWJT7L.js} +4 -4
- package/dist/{chunk-CMT5NMMS.js → chunk-3NGDZZR4.js} +4 -4
- package/dist/{chunk-WRLUBRKS.cjs → chunk-3SKLAUDD.cjs} +2 -2
- package/dist/{chunk-KKFZ3B6J.cjs → chunk-3VBO3IYQ.cjs} +2 -2
- package/dist/{chunk-YF2I3MV3.js → chunk-47RUFYKR.js} +2 -2
- package/dist/{chunk-LHAXPADA.js → chunk-4JGRWHZJ.js} +7 -5
- package/dist/{chunk-ROHLEP2W.cjs → chunk-4W5G5QVL.cjs} +26 -26
- package/dist/{chunk-GQHQOPXZ.cjs → chunk-4YNYPHH3.cjs} +186 -17
- package/dist/{chunk-ZMCVKFXI.cjs → chunk-56VOWURB.cjs} +154 -47
- package/dist/{chunk-FXKAW7ZO.cjs → chunk-5A4TCHOC.cjs} +3 -3
- package/dist/{chunk-M56JSP4A.js → chunk-5EDVCNRT.js} +2 -2
- package/dist/{chunk-UJXISJBN.js → chunk-5ET6L4NS.js} +3 -3
- package/dist/{chunk-5NWINHR5.cjs → chunk-63ZGNR2T.cjs} +43 -39
- package/dist/{chunk-NG77ATEW.cjs → chunk-6PRZIHGL.cjs} +6 -6
- package/dist/{chunk-3WZEJHUQ.cjs → chunk-7DMMMBCY.cjs} +7 -7
- package/dist/{chunk-FHP6LXJS.js → chunk-7E7GCQCK.js} +2 -2
- package/dist/{chunk-YN2YWTXW.js → chunk-7VMGP2FW.js} +44 -28
- package/dist/{chunk-OJXHYNXN.js → chunk-7X5PNIQJ.js} +3 -3
- package/dist/{chunk-FYSPZT4V.cjs → chunk-7ZHYEITD.cjs} +11 -11
- package/dist/{chunk-KPJL34Y7.cjs → chunk-ACVWFGBI.cjs} +2 -2
- package/dist/{chunk-UWXE23BT.cjs → chunk-AWB7QYY6.cjs} +6 -6
- package/dist/{chunk-UO4WPSGQ.js → chunk-B4EKV6HQ.js} +154 -48
- package/dist/{chunk-2X7NGX3M.js → chunk-BRNUPDHJ.js} +5 -5
- package/dist/{chunk-D3STJ56J.js → chunk-BTKZGHAV.js} +23 -11
- package/dist/{chunk-I5CDNPPE.cjs → chunk-C4GSLCHE.cjs} +331 -125
- package/dist/{chunk-QPSKHBJP.js → chunk-C7ZBSV2Q.js} +13 -7
- package/dist/{chunk-YN6V7R3L.cjs → chunk-CCPSNT6B.cjs} +12 -7
- package/dist/{chunk-NW5G5FBQ.js → chunk-DD2JQ7TS.js} +4 -3
- package/dist/{chunk-JD7CIZ33.js → chunk-DUCB6LGL.js} +8 -10
- package/dist/{chunk-ANXZFVY2.js → chunk-DY72BMU5.js} +3 -3
- package/dist/{chunk-AIA52I7T.cjs → chunk-EBS32AJI.cjs} +6 -4
- package/dist/{chunk-6DO5IZ5N.cjs → chunk-EDPYCLRC.cjs} +85 -65
- package/dist/{chunk-WQKJSGVS.js → chunk-F2G6CWFT.js} +271 -66
- package/dist/{chunk-AVJHHUC5.cjs → chunk-F5LKJ6F5.cjs} +43 -31
- package/dist/{chunk-ZU7NIRT6.js → chunk-FGMDMJM7.js} +10 -5
- package/dist/{chunk-YVD3CSO3.js → chunk-FHQFPYV4.js} +4 -4
- package/dist/{chunk-YIMN575O.js → chunk-FNHJRI32.js} +8 -5
- package/dist/{chunk-EXUP2BUM.cjs → chunk-FT6TDR2O.cjs} +27 -27
- package/dist/{chunk-BRQJKJGT.cjs → chunk-FWVYAMNW.cjs} +4 -4
- package/dist/{chunk-PGANYCAG.cjs → chunk-G25QVBA5.cjs} +4 -3
- package/dist/{chunk-XB274MW5.cjs → chunk-G6PNEASF.cjs} +13 -13
- package/dist/{chunk-2BSMSUCE.js → chunk-GASCWJK5.js} +2 -2
- package/dist/{chunk-HKEXJUWS.cjs → chunk-GH6C2QGW.cjs} +12 -21
- package/dist/{chunk-WRKUDAZJ.js → chunk-GSOUNWEL.js} +35 -27
- package/dist/{chunk-QPOQ7VPI.js → chunk-GTA4Q3A3.js} +2 -2
- package/dist/{chunk-JIYN45TV.cjs → chunk-GVFJ6T4S.cjs} +3 -7
- package/dist/{chunk-IVY74O6C.js → chunk-GVOKJNUN.js} +50 -11
- package/dist/{chunk-GZG4KA4E.js → chunk-GW3LKD5C.js} +6 -4
- package/dist/{chunk-NCWCUZNS.cjs → chunk-HFSVMKM3.cjs} +14 -14
- package/dist/{chunk-IUTY5WQ2.cjs → chunk-HLFDZ35S.cjs} +5 -5
- package/dist/{chunk-IWC5DM2M.cjs → chunk-I76GIKN7.cjs} +20 -16
- package/dist/{chunk-ON5QSY35.cjs → chunk-KAIVDEIG.cjs} +175 -59
- package/dist/{chunk-R24NNAEG.js → chunk-KCPHASCO.js} +18 -6
- package/dist/{chunk-T5J7ZKP3.cjs → chunk-KOUAQL2B.cjs} +16 -13
- package/dist/{chunk-GMP623FG.cjs → chunk-KQU64CIX.cjs} +2 -2
- package/dist/{chunk-MVPBWHAC.js → chunk-L5U4W6JC.js} +4 -4
- package/dist/{chunk-2IWC4FP7.cjs → chunk-LMJ5EBV7.cjs} +10 -10
- package/dist/{chunk-KKP7JKN4.cjs → chunk-LODTHGST.cjs} +18 -12
- package/dist/{chunk-4V2E7U7Q.cjs → chunk-LPS5AMQD.cjs} +8 -8
- package/dist/{chunk-PY37LNDP.js → chunk-LWUOUCYL.js} +9 -5
- package/dist/{chunk-6CTRH7HT.cjs → chunk-LYJJI7ZK.cjs} +12 -14
- package/dist/{chunk-GTU2Z2WW.cjs → chunk-M7K4LE66.cjs} +5 -14
- package/dist/{chunk-URG2SJLK.js → chunk-MDR235RZ.js} +3 -7
- package/dist/{chunk-E4M5OAYO.js → chunk-MSYSQ2AJ.js} +132 -16
- package/dist/{chunk-TWUXUCEW.cjs → chunk-NGBXXZLL.cjs} +50 -62
- package/dist/{chunk-FFAOS5HQ.js → chunk-NHJLP37F.js} +6 -6
- package/dist/{chunk-S3MDHNKB.cjs → chunk-NHYRRAGI.cjs} +5 -5
- package/dist/{chunk-U44IKGG7.cjs → chunk-O3MGZDCT.cjs} +89 -52
- package/dist/{chunk-GIOYPNTH.js → chunk-OABEO6HH.js} +185 -16
- package/dist/{chunk-KQCN6AKJ.cjs → chunk-OS533P33.cjs} +37 -29
- package/dist/{chunk-DAJXW4KX.js → chunk-PABONWKI.js} +24 -11
- package/dist/{chunk-QACVP4PM.js → chunk-PXNZ6TME.js} +77 -59
- package/dist/{chunk-OMXII44L.js → chunk-Q2Q34NF3.js} +63 -26
- package/dist/{chunk-OH2FAIVU.js → chunk-QBWNJXNR.js} +10 -6
- package/dist/{chunk-XKTPFXGA.js → chunk-QFU53KRH.js} +4 -4
- package/dist/{chunk-CR4FMIWL.cjs → chunk-QGMUTVVH.cjs} +17 -17
- package/dist/{chunk-MYY4PMWX.cjs → chunk-RUVBFAF7.cjs} +50 -11
- package/dist/{chunk-QD32ADK6.js → chunk-S762UEV5.js} +5 -5
- package/dist/{chunk-HNDK4IQU.cjs → chunk-SH5PPVK7.cjs} +61 -45
- package/dist/{chunk-JC5YBPSF.cjs → chunk-SKZPC5AG.cjs} +5 -5
- package/dist/{chunk-TJHVSBP2.js → chunk-SLHLXUMO.js} +10 -4
- package/dist/{chunk-5KVXXUD4.js → chunk-SSSN7VAM.js} +3 -3
- package/dist/{chunk-KMC6CQH3.js → chunk-SXOSDZD6.js} +6 -6
- package/dist/{chunk-J32ZJZJH.js → chunk-SYTRBGDS.js} +2 -2
- package/dist/{chunk-CIWWXYHZ.cjs → chunk-T6W3Z3SH.cjs} +2 -2
- package/dist/{chunk-QXH7QDSZ.js → chunk-TEVX443G.js} +44 -51
- package/dist/{chunk-UFZZ7TSN.cjs → chunk-TQ377OLB.cjs} +23 -21
- package/dist/{chunk-PJGFU5DN.cjs → chunk-TRCGG42I.cjs} +195 -152
- package/dist/{chunk-H652NHX5.js → chunk-TVANHNJ7.js} +30 -23
- package/dist/{chunk-EKBKLK7P.js → chunk-UDE4OZMR.js} +3 -3
- package/dist/{chunk-LKWQNUE6.cjs → chunk-UGXHYIWT.cjs} +5 -5
- package/dist/{chunk-JBNDTXXV.cjs → chunk-ULMSSHCJ.cjs} +21 -21
- package/dist/{chunk-YWOBW2PV.cjs → chunk-UOL6Y5TD.cjs} +18 -18
- package/dist/{chunk-5S7RKFGR.cjs → chunk-UVFI7XIR.cjs} +10 -4
- package/dist/{chunk-7M3PNU2M.cjs → chunk-V7AKE5VT.cjs} +10 -10
- package/dist/{chunk-J7XZV333.js → chunk-VEPGBETF.js} +6 -6
- package/dist/{chunk-UWJHCOH2.js → chunk-VF257YKO.js} +4 -4
- package/dist/{chunk-4N4SXXWF.js → chunk-VSACG2AR.js} +3 -3
- package/dist/{chunk-ZDSYWBIE.cjs → chunk-VW5CRJBE.cjs} +3 -7
- package/dist/{chunk-YT5L3B57.cjs → chunk-WFKVS2K4.cjs} +65 -27
- package/dist/{chunk-J6M4FPK5.js → chunk-WXQ57LAO.js} +3 -3
- package/dist/{chunk-5H2G27PK.cjs → chunk-X27QRG4C.cjs} +38 -38
- package/dist/{chunk-TVHSPJ4N.cjs → chunk-X2AVEAZM.cjs} +30 -23
- package/dist/{chunk-DHO2YRIM.js → chunk-XQ5MWMP2.js} +4 -4
- package/dist/{chunk-XIVIE43A.cjs → chunk-XW6IXEQH.cjs} +26 -13
- package/dist/{chunk-YIVFJNYV.js → chunk-Y3ZFVUUU.js} +2 -2
- package/dist/{chunk-7H33U5SM.cjs → chunk-Y57W2CT5.cjs} +2 -2
- package/dist/{chunk-OBIYPYYS.cjs → chunk-YCM6QQRT.cjs} +46 -53
- package/dist/{chunk-MBOOR7X4.js → chunk-YFVQWSNJ.js} +3 -3
- package/dist/{chunk-ADADVMXY.js → chunk-YFWRJW4B.js} +2 -2
- package/dist/{chunk-ONDAWTW4.js → chunk-YN6IETRZ.js} +179 -136
- package/dist/{chunk-4SDKXQ4C.js → chunk-YRRAUB35.js} +4 -4
- package/dist/{chunk-OBP5REIV.js → chunk-Z6PMDS4G.js} +62 -24
- package/dist/{chunk-BOVPWH4H.js → chunk-ZA34AN3R.js} +8 -17
- package/dist/{chunk-EKYL4PE3.cjs → chunk-ZLF4YF3U.cjs} +2 -2
- package/dist/{chunk-6FH72EB2.cjs → chunk-ZPZAVHXL.cjs} +20 -20
- package/dist/cli/holoscript-runner.cjs +39 -22
- package/dist/cli/holoscript-runner.js +32 -15
- package/dist/compiler/GasOptimizationAnalyzer.d.ts +73 -0
- package/dist/compiler/NFTMarketplaceCompiler.d.ts +23 -0
- package/dist/compiler/agent-inference.cjs +7 -7
- package/dist/compiler/agent-inference.js +3 -3
- package/dist/compiler/android-xr.cjs +8 -8
- package/dist/compiler/android-xr.js +6 -6
- package/dist/compiler/android.cjs +6 -6
- package/dist/compiler/android.js +4 -4
- package/dist/compiler/ar.cjs +6 -6
- package/dist/compiler/ar.js +4 -4
- package/dist/compiler/babylon.cjs +8 -8
- package/dist/compiler/babylon.js +7 -7
- package/dist/compiler/business-quest.cjs +9 -9
- package/dist/compiler/business-quest.js +1 -1
- package/dist/compiler/context.cjs +6 -6
- package/dist/compiler/context.js +3 -3
- package/dist/compiler/domain-block-utils.cjs +153 -153
- package/dist/compiler/domain-block-utils.js +4 -4
- package/dist/compiler/dtdl.cjs +7 -7
- package/dist/compiler/dtdl.js +4 -4
- package/dist/compiler/gltf-pipeline.cjs +8 -8
- package/dist/compiler/gltf-pipeline.js +1 -1
- package/dist/compiler/godot.cjs +6 -6
- package/dist/compiler/godot.js +5 -5
- package/dist/compiler/incremental.cjs +8 -8
- package/dist/compiler/incremental.js +3 -3
- package/dist/compiler/index.cjs +530 -355
- package/dist/compiler/index.d.ts +20 -0
- package/dist/compiler/index.js +374 -210
- package/dist/compiler/ios.cjs +6 -6
- package/dist/compiler/ios.js +4 -4
- package/dist/compiler/llm-provider-capabilities.cjs +6 -6
- package/dist/compiler/llm-provider-capabilities.js +3 -3
- package/dist/compiler/multi-layer.cjs +10 -10
- package/dist/compiler/multi-layer.js +9 -9
- package/dist/compiler/openxr.cjs +7 -7
- package/dist/compiler/openxr.js +6 -6
- package/dist/compiler/playcanvas.cjs +6 -6
- package/dist/compiler/playcanvas.js +5 -5
- package/dist/compiler/r3f.cjs +13 -13
- package/dist/compiler/r3f.js +8 -8
- package/dist/compiler/sdf.cjs +7 -7
- package/dist/compiler/sdf.js +5 -5
- package/dist/compiler/state.cjs +6 -6
- package/dist/compiler/state.js +4 -4
- package/dist/compiler/trait-composition.cjs +8 -8
- package/dist/compiler/trait-composition.js +4 -4
- package/dist/compiler/unity.cjs +7 -7
- package/dist/compiler/unity.js +6 -6
- package/dist/compiler/unreal.cjs +8 -8
- package/dist/compiler/unreal.js +6 -6
- package/dist/compiler/urdf.cjs +14 -14
- package/dist/compiler/urdf.js +5 -5
- package/dist/compiler/usd-physics.cjs +7 -7
- package/dist/compiler/usd-physics.js +4 -4
- package/dist/compiler/visionos.cjs +7 -7
- package/dist/compiler/visionos.js +6 -6
- package/dist/compiler/vrchat.cjs +7 -7
- package/dist/compiler/vrchat.js +5 -5
- package/dist/compiler/vrr.cjs +7 -7
- package/dist/compiler/vrr.js +5 -5
- package/dist/compiler/wasm.cjs +10 -10
- package/dist/compiler/wasm.js +5 -5
- package/dist/compiler/webgpu.cjs +6 -6
- package/dist/compiler/webgpu.js +5 -5
- package/dist/coordinators/index.cjs +27 -10
- package/dist/coordinators/index.js +27 -10
- package/dist/debugger.cjs +6 -6
- package/dist/debugger.js +4 -4
- package/dist/entries/scripting.cjs +6 -6
- package/dist/entries/scripting.js +2 -2
- package/dist/hololand/index.cjs +36 -36
- package/dist/hololand/index.js +2 -2
- package/dist/index.cjs +1080 -2190
- package/dist/index.js +467 -1577
- package/dist/math/tropical-spmv.cjs +10 -10
- package/dist/math/tropical-spmv.js +1 -1
- package/dist/math/vec3.cjs +13 -13
- package/dist/math/vec3.js +1 -1
- package/dist/parser/NFTMarketplaceTypes.d.ts +191 -0
- package/dist/parser.cjs +16 -16
- package/dist/parser.js +5 -5
- package/dist/reconstruction/index.cjs +37 -37
- package/dist/reconstruction/index.js +4 -4
- package/dist/runtime.cjs +280 -74
- package/dist/runtime.d.ts +10 -1
- package/dist/runtime.js +268 -70
- package/dist/self-improvement/index.cjs +12 -4
- package/dist/self-improvement/index.js +12 -4
- package/dist/{src-HCCCSYP7.js → src-J6CM4AUR.js} +91 -33
- package/dist/{src-4ROC227P.cjs → src-PT2FERDV.cjs} +93 -35
- package/dist/testing.cjs +5 -5
- package/dist/testing.js +1 -1
- package/dist/traits/botanical-lotus.cjs +52 -48
- package/dist/traits/botanical-lotus.js +2 -2
- package/dist/traits/engines/index.cjs +39 -39
- package/dist/traits/engines/index.d.ts +279 -0
- package/dist/traits/engines/index.js +4 -4
- package/dist/traits/index.cjs +889 -773
- package/dist/traits/index.js +371 -259
- package/dist/world/index.cjs +21 -18
- package/dist/world/index.js +21 -18
- package/dist/world-model/index.cjs +11 -5
- package/dist/world-model/index.d.ts +8 -0
- package/dist/world-model/index.js +11 -5
- package/package.json +75 -69
- package/LICENSE +0 -21
- package/dist/GLTFPipeline-37FPRVPH.js +0 -17
- package/dist/GLTFPipeline-EK3LFJKW.cjs +0 -38
- package/dist/HoloScriptPlusParser-WKHRIH6T.cjs +0 -27
- package/dist/HoloScriptRuntime-ACDFKVVH.js +0 -10
- package/dist/HoloScriptRuntime-ON2OQVEF.cjs +0 -19
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { parsePipeline } from './chunk-
|
|
1
|
+
import { parsePipeline } from './chunk-SYTRBGDS.js';
|
|
2
2
|
|
|
3
3
|
// src/parser/TypoDetector.ts
|
|
4
4
|
var TypoDetector = class {
|
|
@@ -775,6 +775,8 @@ var KEYWORDS_AS_IDENTIFIERS = [
|
|
|
775
775
|
"CONSTRAINT",
|
|
776
776
|
"TERRAIN",
|
|
777
777
|
"PARTICLES",
|
|
778
|
+
// Behavior/AI keywords that appear as property names in state + NPC blocks
|
|
779
|
+
"BEHAVIOR",
|
|
778
780
|
// Game/AI keywords that can appear as property names
|
|
779
781
|
"SHAPE",
|
|
780
782
|
"NPC",
|
|
@@ -1176,6 +1178,10 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
1176
1178
|
composition.environment = this.parseEnvironmentBody();
|
|
1177
1179
|
} else if (decoratorName === "state") {
|
|
1178
1180
|
composition.state = this.parseStateBody();
|
|
1181
|
+
} else if (decoratorName === "state_machine") {
|
|
1182
|
+
if (this.check("LBRACE")) {
|
|
1183
|
+
composition.stateMachines.push(this.parseStateMachineFromDecorator());
|
|
1184
|
+
}
|
|
1179
1185
|
} else {
|
|
1180
1186
|
composition.traits = composition.traits || [];
|
|
1181
1187
|
const config = this.parseOptionalTraitConfig();
|
|
@@ -1392,7 +1398,7 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
1392
1398
|
const startLoc = this.currentLocation();
|
|
1393
1399
|
this.pushContext("composition");
|
|
1394
1400
|
this.expect("COMPOSITION");
|
|
1395
|
-
const name = this.expectString();
|
|
1401
|
+
const name = this.check("STRING") ? this.expectString() : this.check("IDENTIFIER") ? this.expectIdentifier() : this.expectString();
|
|
1396
1402
|
this.skipNewlines();
|
|
1397
1403
|
this.expect("LBRACE");
|
|
1398
1404
|
this.skipNewlines();
|
|
@@ -1555,6 +1561,10 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
1555
1561
|
composition.state = this.parseStateBody();
|
|
1556
1562
|
} else if (decoratorName === "world" || decoratorName === "environment") {
|
|
1557
1563
|
composition.environment = this.parseEnvironmentBody();
|
|
1564
|
+
} else if (decoratorName === "state_machine") {
|
|
1565
|
+
if (this.check("LBRACE")) {
|
|
1566
|
+
composition.stateMachines.push(this.parseStateMachineFromDecorator());
|
|
1567
|
+
}
|
|
1558
1568
|
} else {
|
|
1559
1569
|
composition.traits = composition.traits || [];
|
|
1560
1570
|
const config = this.parseOptionalTraitConfig();
|
|
@@ -1867,7 +1877,7 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
1867
1877
|
parseLight() {
|
|
1868
1878
|
const startLoc = this.currentLocation();
|
|
1869
1879
|
this.expect("LIGHT");
|
|
1870
|
-
const name = this.expectString();
|
|
1880
|
+
const name = this.check("STRING") ? this.expectString() : "light";
|
|
1871
1881
|
let lightType = "directional";
|
|
1872
1882
|
const lightTypeNames = {
|
|
1873
1883
|
directional: "directional",
|
|
@@ -1890,6 +1900,21 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
1890
1900
|
while (!this.check("RBRACE") && !this.isAtEnd()) {
|
|
1891
1901
|
this.skipNewlines();
|
|
1892
1902
|
if (this.check("RBRACE")) break;
|
|
1903
|
+
if (this.check("AT")) {
|
|
1904
|
+
this.advance();
|
|
1905
|
+
const traitName = this.parseTraitName();
|
|
1906
|
+
const cfg = this.parseOptionalTraitConfig();
|
|
1907
|
+
const cfgKeys = Object.keys(cfg);
|
|
1908
|
+
let traitValue;
|
|
1909
|
+
if (cfgKeys.length === 0) traitValue = true;
|
|
1910
|
+
else if (cfgKeys.every((k) => /^_arg\d+$/.test(k))) {
|
|
1911
|
+
const arr = cfgKeys.sort().map((k) => cfg[k]);
|
|
1912
|
+
traitValue = arr.length === 1 ? arr[0] : arr;
|
|
1913
|
+
} else traitValue = cfg;
|
|
1914
|
+
properties.push({ type: "LightProperty", key: traitName, value: traitValue });
|
|
1915
|
+
this.skipNewlines();
|
|
1916
|
+
continue;
|
|
1917
|
+
}
|
|
1893
1918
|
const key = this.expectIdentifier();
|
|
1894
1919
|
if (this.check("STRING")) {
|
|
1895
1920
|
this.advance();
|
|
@@ -2555,7 +2580,7 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
2555
2580
|
const traits = [];
|
|
2556
2581
|
while (this.check("AT")) {
|
|
2557
2582
|
this.advance();
|
|
2558
|
-
const traitName = this.
|
|
2583
|
+
const traitName = this.parseTraitName();
|
|
2559
2584
|
if (String(traitName).toLowerCase() === "platform") {
|
|
2560
2585
|
platformConstraint = this.parsePlatformConstraint();
|
|
2561
2586
|
this.skipNewlines();
|
|
@@ -2625,7 +2650,12 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
2625
2650
|
platformConstraint: constraint
|
|
2626
2651
|
};
|
|
2627
2652
|
traits.push(trait2);
|
|
2628
|
-
directives.push({
|
|
2653
|
+
directives.push({
|
|
2654
|
+
type: "trait",
|
|
2655
|
+
name: nextTraitName,
|
|
2656
|
+
config: config2,
|
|
2657
|
+
platformConstraint: constraint
|
|
2658
|
+
});
|
|
2629
2659
|
} else if (this.check("OBJECT") || this.check("SPATIAL_AGENT") || this.check("TOOL_SLOT") || this.check("BEHAVIOR") || this.current().type.startsWith("UI_")) {
|
|
2630
2660
|
const nestedType = this.check("OBJECT") ? void 0 : this.current().value.toLowerCase();
|
|
2631
2661
|
const child = this.parseObject(nestedType);
|
|
@@ -2742,11 +2772,10 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
2742
2772
|
}
|
|
2743
2773
|
if (declarationKind === "instanced_object") {
|
|
2744
2774
|
obj.declarationKind = "instanced_object";
|
|
2745
|
-
obj.instanceMetadata = this.buildInstancedObjectMetadata(
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
);
|
|
2775
|
+
obj.instanceMetadata = this.buildInstancedObjectMetadata(properties, traits, {
|
|
2776
|
+
start: startLoc,
|
|
2777
|
+
end: endLoc
|
|
2778
|
+
});
|
|
2750
2779
|
}
|
|
2751
2780
|
return obj;
|
|
2752
2781
|
}
|
|
@@ -2755,9 +2784,7 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
2755
2784
|
for (const property of properties) {
|
|
2756
2785
|
propertyMap[property.key] = property.value;
|
|
2757
2786
|
}
|
|
2758
|
-
const count = this.asOptionalNumber(
|
|
2759
|
-
propertyMap["instance_count"] ?? propertyMap["count"]
|
|
2760
|
-
);
|
|
2787
|
+
const count = this.asOptionalNumber(propertyMap["instance_count"] ?? propertyMap["count"]);
|
|
2761
2788
|
const anchor = this.asOptionalString(
|
|
2762
2789
|
propertyMap["anchor"] ?? this.propertyFromObject(propertyMap["generator"], "anchor")
|
|
2763
2790
|
);
|
|
@@ -3336,6 +3363,9 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
3336
3363
|
if (this.match("LBRACE")) {
|
|
3337
3364
|
return this.parseObjectValue();
|
|
3338
3365
|
}
|
|
3366
|
+
if (_HoloCompositionParser.DOMAIN_TOKENS.has(this.current().type) || this.isKeywordAsIdentifierType(this.current().type)) {
|
|
3367
|
+
return this.advance().value;
|
|
3368
|
+
}
|
|
3339
3369
|
this.error(`Expected value, got ${this.current().type}`);
|
|
3340
3370
|
this.advance();
|
|
3341
3371
|
return null;
|
|
@@ -3571,7 +3601,7 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
3571
3601
|
if (this.check("RBRACE")) break;
|
|
3572
3602
|
if (this.check("AT")) {
|
|
3573
3603
|
this.advance();
|
|
3574
|
-
const name = this.
|
|
3604
|
+
const name = this.parseTraitName();
|
|
3575
3605
|
const config = this.parseOptionalTraitConfig();
|
|
3576
3606
|
traits.push({ type: "ObjectTrait", name, config });
|
|
3577
3607
|
} else if (this.check("IDENTIFIER")) {
|
|
@@ -3658,6 +3688,34 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
3658
3688
|
this.error(`Expected string, got ${current.type}`, suggestion);
|
|
3659
3689
|
return "";
|
|
3660
3690
|
}
|
|
3691
|
+
/**
|
|
3692
|
+
* Read a trait name after '@'. Trait names may start with a digit (e.g. @2d_canvas, a
|
|
3693
|
+
* registered Semantic2D trait), but the lexer cannot start an IDENTIFIER with a digit, so it
|
|
3694
|
+
* splits "2d_canvas" into NUMBER("2") + IDENTIFIER("d_canvas"). Reassemble those so the
|
|
3695
|
+
* canonical trait name parses in BOTH primitive and object bodies (the primitive body used to
|
|
3696
|
+
* error via expectIdentifier; the object body silently captured only "2", dropping the rest —
|
|
3697
|
+
* which also silently corrupted the shipped 2d-revolution template). Also accepts a quoted
|
|
3698
|
+
* name (@"2d_canvas") and keyword-as-identifier names.
|
|
3699
|
+
*/
|
|
3700
|
+
parseTraitName() {
|
|
3701
|
+
if (this.check("STRING")) {
|
|
3702
|
+
return this.advance().value;
|
|
3703
|
+
}
|
|
3704
|
+
if (this.check("NUMBER")) {
|
|
3705
|
+
let name = this.advance().value;
|
|
3706
|
+
if (this.check("IDENTIFIER")) {
|
|
3707
|
+
name += this.advance().value;
|
|
3708
|
+
}
|
|
3709
|
+
return name;
|
|
3710
|
+
}
|
|
3711
|
+
if (this.check("IDENTIFIER")) {
|
|
3712
|
+
return this.advance().value;
|
|
3713
|
+
}
|
|
3714
|
+
if (this.isKeywordAsIdentifierType(this.current().type)) {
|
|
3715
|
+
return this.advance().value;
|
|
3716
|
+
}
|
|
3717
|
+
return this.isAtEnd() ? "" : this.advance().value;
|
|
3718
|
+
}
|
|
3661
3719
|
expectIdentifier() {
|
|
3662
3720
|
if (this.check("IDENTIFIER")) {
|
|
3663
3721
|
return this.advance().value;
|
|
@@ -4443,6 +4501,117 @@ var _HoloCompositionParser = class _HoloCompositionParser {
|
|
|
4443
4501
|
this.popContext();
|
|
4444
4502
|
return sm;
|
|
4445
4503
|
}
|
|
4504
|
+
/**
|
|
4505
|
+
* Parse the body of an `@state_machine { ... }` decorator.
|
|
4506
|
+
*
|
|
4507
|
+
* Called after @ and state_machine tokens are already consumed — starts
|
|
4508
|
+
* at the opening LBRACE. Handles:
|
|
4509
|
+
* - `initial: "stateName"` / `initialState: "stateName"`
|
|
4510
|
+
* - `state "name" { on_entry { ... } on_exit { ... } transitions { ... } }`
|
|
4511
|
+
* - `state identifier { ... }` (unquoted state names)
|
|
4512
|
+
*
|
|
4513
|
+
* Stores the result in composition.stateMachines so compilers can read it.
|
|
4514
|
+
* Without this, @state_machine blocks were stored as opaque traits and
|
|
4515
|
+
* invisible to compile_to_a2a_agent_card and other compilers.
|
|
4516
|
+
*/
|
|
4517
|
+
parseStateMachineFromDecorator() {
|
|
4518
|
+
const startLoc = this.currentLocation();
|
|
4519
|
+
this.expect("LBRACE");
|
|
4520
|
+
this.skipNewlines();
|
|
4521
|
+
const sm = {
|
|
4522
|
+
type: "StateMachine",
|
|
4523
|
+
name: "implicit",
|
|
4524
|
+
initialState: "",
|
|
4525
|
+
states: {}
|
|
4526
|
+
};
|
|
4527
|
+
while (!this.check("RBRACE") && !this.isAtEnd()) {
|
|
4528
|
+
this.skipNewlines();
|
|
4529
|
+
if (this.check("RBRACE")) break;
|
|
4530
|
+
if (this.check("STATE")) {
|
|
4531
|
+
this.advance();
|
|
4532
|
+
const stateName = this.check("STRING") || this.check("IDENTIFIER") ? this.advance().value : "anonymous";
|
|
4533
|
+
if (!sm.initialState) sm.initialState = stateName;
|
|
4534
|
+
if (this.check("LBRACE")) {
|
|
4535
|
+
this.expect("LBRACE");
|
|
4536
|
+
this.skipNewlines();
|
|
4537
|
+
const state = {
|
|
4538
|
+
type: "State_Machine",
|
|
4539
|
+
name: stateName,
|
|
4540
|
+
actions: [],
|
|
4541
|
+
transitions: []
|
|
4542
|
+
};
|
|
4543
|
+
while (!this.check("RBRACE") && !this.isAtEnd()) {
|
|
4544
|
+
this.skipNewlines();
|
|
4545
|
+
if (this.check("RBRACE")) break;
|
|
4546
|
+
const key2 = this.expectIdentifier();
|
|
4547
|
+
if (this.check("COLON")) {
|
|
4548
|
+
this.advance();
|
|
4549
|
+
if (key2 === "enter" || key2 === "entry" || key2 === "on_entry") {
|
|
4550
|
+
this.expect("LBRACE");
|
|
4551
|
+
this.skipNewlines();
|
|
4552
|
+
state.entry = this.parseStatementBlock();
|
|
4553
|
+
this.expect("RBRACE");
|
|
4554
|
+
} else if (key2 === "exit" || key2 === "on_exit") {
|
|
4555
|
+
this.expect("LBRACE");
|
|
4556
|
+
this.skipNewlines();
|
|
4557
|
+
state.exit = this.parseStatementBlock();
|
|
4558
|
+
this.expect("RBRACE");
|
|
4559
|
+
} else if (key2 === "actions") {
|
|
4560
|
+
state.actions = this.parseBehaviorActions();
|
|
4561
|
+
} else if (key2 === "transitions") {
|
|
4562
|
+
state.transitions = this.parseStateTransitions();
|
|
4563
|
+
} else if (key2 === "timeout") {
|
|
4564
|
+
state.timeout = this.parseValue();
|
|
4565
|
+
} else {
|
|
4566
|
+
this.parseValue();
|
|
4567
|
+
}
|
|
4568
|
+
} else if (this.check("LBRACE")) {
|
|
4569
|
+
if (key2 === "enter" || key2 === "entry" || key2 === "on_entry") {
|
|
4570
|
+
this.expect("LBRACE");
|
|
4571
|
+
this.skipNewlines();
|
|
4572
|
+
state.entry = this.parseStatementBlock();
|
|
4573
|
+
this.expect("RBRACE");
|
|
4574
|
+
} else if (key2 === "exit" || key2 === "on_exit") {
|
|
4575
|
+
this.expect("LBRACE");
|
|
4576
|
+
this.skipNewlines();
|
|
4577
|
+
state.exit = this.parseStatementBlock();
|
|
4578
|
+
this.expect("RBRACE");
|
|
4579
|
+
} else if (key2 === "transitions") {
|
|
4580
|
+
state.transitions = this.parseStateTransitions();
|
|
4581
|
+
} else {
|
|
4582
|
+
this.skipBlock();
|
|
4583
|
+
}
|
|
4584
|
+
}
|
|
4585
|
+
this.skipNewlines();
|
|
4586
|
+
}
|
|
4587
|
+
this.expect("RBRACE");
|
|
4588
|
+
sm.states[stateName] = state;
|
|
4589
|
+
}
|
|
4590
|
+
this.skipNewlines();
|
|
4591
|
+
continue;
|
|
4592
|
+
}
|
|
4593
|
+
const key = this.expectIdentifier();
|
|
4594
|
+
if (key === "initial" || key === "initialState") {
|
|
4595
|
+
this.expect("COLON");
|
|
4596
|
+
sm.initialState = this.parseValue();
|
|
4597
|
+
} else if (key === "name") {
|
|
4598
|
+
this.expect("COLON");
|
|
4599
|
+
sm.name = this.parseValue();
|
|
4600
|
+
} else if (key === "states" && this.check("COLON")) {
|
|
4601
|
+
this.advance();
|
|
4602
|
+
sm.states = this.parseStateMachineStates();
|
|
4603
|
+
} else if (this.check("COLON")) {
|
|
4604
|
+
this.advance();
|
|
4605
|
+
this.parseValue();
|
|
4606
|
+
} else if (this.check("LBRACE")) {
|
|
4607
|
+
this.skipBlock();
|
|
4608
|
+
}
|
|
4609
|
+
this.skipNewlines();
|
|
4610
|
+
}
|
|
4611
|
+
this.expect("RBRACE");
|
|
4612
|
+
sm.loc = { start: startLoc, end: this.currentLocation() };
|
|
4613
|
+
return sm;
|
|
4614
|
+
}
|
|
4446
4615
|
parseStateMachineStates() {
|
|
4447
4616
|
this.expect("LBRACE");
|
|
4448
4617
|
this.skipNewlines();
|
|
@@ -5571,5 +5740,5 @@ function parseHoloPartial(source, options) {
|
|
|
5571
5740
|
}
|
|
5572
5741
|
|
|
5573
5742
|
export { HoloCompositionParser, parseHolo, parseHoloPartial, parseHoloStrict };
|
|
5574
|
-
//# sourceMappingURL=chunk-
|
|
5575
|
-
//# sourceMappingURL=chunk-
|
|
5743
|
+
//# sourceMappingURL=chunk-OABEO6HH.js.map
|
|
5744
|
+
//# sourceMappingURL=chunk-OABEO6HH.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunkFEWUHQNM_cjs = require('./chunk-FEWUHQNM.cjs');
|
|
4
|
-
var
|
|
4
|
+
var chunkLODTHGST_cjs = require('./chunk-LODTHGST.cjs');
|
|
5
5
|
var chunkDTGBOSEM_cjs = require('./chunk-DTGBOSEM.cjs');
|
|
6
6
|
var chunk6EX3I5P4_cjs = require('./chunk-6EX3I5P4.cjs');
|
|
7
7
|
var chunkHCCQLAA4_cjs = require('./chunk-HCCQLAA4.cjs');
|
|
@@ -263,7 +263,9 @@ function emitGeospatialVPSSetup(compiler, composition) {
|
|
|
263
263
|
compiler.emit("node.setParent(anchorNode)");
|
|
264
264
|
compiler.emit("node.renderable = renderable");
|
|
265
265
|
compiler.emit("placedNodes[name] = node");
|
|
266
|
-
compiler.emit(
|
|
266
|
+
compiler.emit(
|
|
267
|
+
'android.util.Log.d("HoloScript", "Geospatial anchor: $name at ($lat, $lng, $alt)")'
|
|
268
|
+
);
|
|
267
269
|
compiler.indentLevel--;
|
|
268
270
|
compiler.emit("}");
|
|
269
271
|
compiler.indentLevel--;
|
|
@@ -278,13 +280,9 @@ function emitGeospatialVPSSetup(compiler, composition) {
|
|
|
278
280
|
compiler.emit("if (earthRef.trackingState != TrackingState.TRACKING) return");
|
|
279
281
|
compiler.emit("");
|
|
280
282
|
compiler.emit("val qx = 0f");
|
|
281
|
-
compiler.emit(
|
|
282
|
-
"val qy = Math.sin(Math.toRadians(heading.toDouble() / 2)).toFloat()"
|
|
283
|
-
);
|
|
283
|
+
compiler.emit("val qy = Math.sin(Math.toRadians(heading.toDouble() / 2)).toFloat()");
|
|
284
284
|
compiler.emit("val qz = 0f");
|
|
285
|
-
compiler.emit(
|
|
286
|
-
"val qw = Math.cos(Math.toRadians(heading.toDouble() / 2)).toFloat()"
|
|
287
|
-
);
|
|
285
|
+
compiler.emit("val qw = Math.cos(Math.toRadians(heading.toDouble() / 2)).toFloat()");
|
|
288
286
|
compiler.emit("");
|
|
289
287
|
compiler.emit(
|
|
290
288
|
"earthRef.resolveAnchorOnTerrainAsync(lat, lng, altOffset, qx, qy, qz, qw) { anchor, state ->"
|
|
@@ -324,13 +322,9 @@ function emitGeospatialVPSSetup(compiler, composition) {
|
|
|
324
322
|
compiler.emit("if (earthRef.trackingState != TrackingState.TRACKING) return");
|
|
325
323
|
compiler.emit("");
|
|
326
324
|
compiler.emit("val qx = 0f");
|
|
327
|
-
compiler.emit(
|
|
328
|
-
"val qy = Math.sin(Math.toRadians(heading.toDouble() / 2)).toFloat()"
|
|
329
|
-
);
|
|
325
|
+
compiler.emit("val qy = Math.sin(Math.toRadians(heading.toDouble() / 2)).toFloat()");
|
|
330
326
|
compiler.emit("val qz = 0f");
|
|
331
|
-
compiler.emit(
|
|
332
|
-
"val qw = Math.cos(Math.toRadians(heading.toDouble() / 2)).toFloat()"
|
|
333
|
-
);
|
|
327
|
+
compiler.emit("val qw = Math.cos(Math.toRadians(heading.toDouble() / 2)).toFloat()");
|
|
334
328
|
compiler.emit("");
|
|
335
329
|
compiler.emit(
|
|
336
330
|
"earthRef.resolveAnchorOnRooftopAsync(lat, lng, altOffset, qx, qy, qz, qw) { anchor, state ->"
|
|
@@ -626,7 +620,9 @@ function emitDepthScanSetup(compiler, composition) {
|
|
|
626
620
|
compiler.emit("} else {");
|
|
627
621
|
compiler.indentLevel++;
|
|
628
622
|
compiler.emit("// GLB export: binary glTF format");
|
|
629
|
-
compiler.emit(
|
|
623
|
+
compiler.emit(
|
|
624
|
+
'android.util.Log.d("HoloScript", "GLB export requires glTF serializer library")'
|
|
625
|
+
);
|
|
630
626
|
compiler.indentLevel--;
|
|
631
627
|
compiler.emit("}");
|
|
632
628
|
compiler.emit("");
|
|
@@ -768,7 +764,9 @@ function emitPortalARSetup(compiler, composition) {
|
|
|
768
764
|
compiler.indentLevel++;
|
|
769
765
|
compiler.emit("val frame = arFragment.arSceneView.arFrame ?: return@addOnUpdateListener");
|
|
770
766
|
compiler.emit("val lightEstimate = frame.lightEstimate");
|
|
771
|
-
compiler.emit(
|
|
767
|
+
compiler.emit(
|
|
768
|
+
"if (lightEstimate != null && lightEstimate.state == LightEstimate.State.VALID) {"
|
|
769
|
+
);
|
|
772
770
|
compiler.indentLevel++;
|
|
773
771
|
compiler.emit("val intensity = lightEstimate.pixelIntensity");
|
|
774
772
|
compiler.emit("val colorCorrection = FloatArray(4)");
|
|
@@ -929,9 +927,7 @@ function emitHandTrackingSetup(compiler, composition) {
|
|
|
929
927
|
if (hasPinch) {
|
|
930
928
|
compiler.emit("// Pinch gesture: thumb tip close to index tip");
|
|
931
929
|
compiler.emit("val pinchDist = Math.sqrt(");
|
|
932
|
-
compiler.emit(
|
|
933
|
-
" Math.pow((thumbTip[0] - indexTip[0]).toDouble(), 2.0) +"
|
|
934
|
-
);
|
|
930
|
+
compiler.emit(" Math.pow((thumbTip[0] - indexTip[0]).toDouble(), 2.0) +");
|
|
935
931
|
compiler.emit(" Math.pow((thumbTip[1] - indexTip[1]).toDouble(), 2.0)");
|
|
936
932
|
compiler.emit(").toFloat()");
|
|
937
933
|
compiler.emit("if (pinchDist < 0.05f) {");
|
|
@@ -1846,7 +1842,9 @@ function generateNodeFactoryFile(compiler, composition) {
|
|
|
1846
1842
|
compiler.indentLevel = 0;
|
|
1847
1843
|
const pkg = compiler.options.packageName;
|
|
1848
1844
|
compiler.emit("// Auto-generated by HoloScript AndroidCompiler");
|
|
1849
|
-
compiler.emit(
|
|
1845
|
+
compiler.emit(
|
|
1846
|
+
`// Node Factory: ${compiler.escapeStringValue(composition.name, "Kotlin")}`
|
|
1847
|
+
);
|
|
1850
1848
|
compiler.emit("");
|
|
1851
1849
|
compiler.emit(`package ${pkg}`);
|
|
1852
1850
|
compiler.emit("");
|
|
@@ -1880,7 +1878,9 @@ function generateNodeFactoryFile(compiler, composition) {
|
|
|
1880
1878
|
compiler.indentLevel--;
|
|
1881
1879
|
compiler.emit("}");
|
|
1882
1880
|
} else {
|
|
1883
|
-
compiler.emit(
|
|
1881
|
+
compiler.emit(
|
|
1882
|
+
"MaterialFactory.makeOpaqueWithColor(context, Color(android.graphics.Color.BLUE))"
|
|
1883
|
+
);
|
|
1884
1884
|
compiler.emit(" .thenCompose { material ->");
|
|
1885
1885
|
compiler.emit(
|
|
1886
1886
|
" ShapeFactory.makeCube(Vector3(0.1f, 0.1f, 0.1f), Vector3.zero(), material)"
|
|
@@ -2129,7 +2129,9 @@ function emitHapticSetup(compiler, composition) {
|
|
|
2129
2129
|
compiler.emit("");
|
|
2130
2130
|
}
|
|
2131
2131
|
if (compiler.compositionHasTrait(composition, "haptic_intensity")) {
|
|
2132
|
-
compiler.emit(
|
|
2132
|
+
compiler.emit(
|
|
2133
|
+
"fun setIntensity(value: Float) { intensityMultiplier = value.coerceIn(0f, 1f) }"
|
|
2134
|
+
);
|
|
2133
2135
|
compiler.emit("");
|
|
2134
2136
|
}
|
|
2135
2137
|
compiler.emit("fun onTouch() { vibrate(VibrationEffect.EFFECT_CLICK) }");
|
|
@@ -2145,7 +2147,9 @@ function emitHapticSetup(compiler, composition) {
|
|
|
2145
2147
|
compiler.emit(
|
|
2146
2148
|
"val amplitude = ((1.0f - distance.coerceIn(0f, 1f)) * 255 * intensityMultiplier).toInt()"
|
|
2147
2149
|
);
|
|
2148
|
-
compiler.emit(
|
|
2150
|
+
compiler.emit(
|
|
2151
|
+
"vibrator.vibrate(VibrationEffect.createOneShot(50, amplitude.coerceIn(1, 255)))"
|
|
2152
|
+
);
|
|
2149
2153
|
compiler.indentLevel--;
|
|
2150
2154
|
compiler.emit("}");
|
|
2151
2155
|
compiler.emit("");
|
|
@@ -2208,7 +2212,9 @@ function emitNearbySetup(compiler, composition) {
|
|
|
2208
2212
|
compiler.indentLevel++;
|
|
2209
2213
|
compiler.emit("override fun onConnectionInitiated(endpointId: String, info: ConnectionInfo) {");
|
|
2210
2214
|
compiler.indentLevel++;
|
|
2211
|
-
compiler.emit(
|
|
2215
|
+
compiler.emit(
|
|
2216
|
+
"Nearby.getConnectionsClient(context).acceptConnection(endpointId, payloadCallback)"
|
|
2217
|
+
);
|
|
2212
2218
|
compiler.indentLevel--;
|
|
2213
2219
|
compiler.emit("}");
|
|
2214
2220
|
compiler.emit(
|
|
@@ -2260,7 +2266,9 @@ function emitNearbySetup(compiler, composition) {
|
|
|
2260
2266
|
"Nearby.getConnectionsClient(context).startDiscovery(SERVICE_ID, object : EndpointDiscoveryCallback() {"
|
|
2261
2267
|
);
|
|
2262
2268
|
compiler.indentLevel++;
|
|
2263
|
-
compiler.emit(
|
|
2269
|
+
compiler.emit(
|
|
2270
|
+
"override fun onEndpointFound(endpointId: String, info: DiscoveredEndpointInfo) {"
|
|
2271
|
+
);
|
|
2264
2272
|
compiler.indentLevel++;
|
|
2265
2273
|
compiler.emit(
|
|
2266
2274
|
'Nearby.getConnectionsClient(context).requestConnection("HoloDevice", endpointId, connectionCallback)'
|
|
@@ -2939,12 +2947,12 @@ function compileToAndroid(composition, options) {
|
|
|
2939
2947
|
exports.AndroidCompiler = void 0;
|
|
2940
2948
|
var init_AndroidCompiler = chunkHCCQLAA4_cjs.__esm({
|
|
2941
2949
|
"src/compiler/AndroidCompiler.ts"() {
|
|
2942
|
-
|
|
2950
|
+
chunkLODTHGST_cjs.init_CompilerBase();
|
|
2943
2951
|
init_AndroidARGenerators();
|
|
2944
2952
|
init_AndroidFeatureGenerators();
|
|
2945
2953
|
init_AndroidPeripheralGenerators();
|
|
2946
2954
|
chunkFEWUHQNM_cjs.init_AndroidKotlinHelpers();
|
|
2947
|
-
exports.AndroidCompiler = class extends
|
|
2955
|
+
exports.AndroidCompiler = class extends chunkLODTHGST_cjs.CompilerBase {
|
|
2948
2956
|
constructor(options = {}) {
|
|
2949
2957
|
super();
|
|
2950
2958
|
this.compilerName = "AndroidCompiler";
|
|
@@ -3038,5 +3046,5 @@ var init_AndroidCompiler = chunkHCCQLAA4_cjs.__esm({
|
|
|
3038
3046
|
exports.AndroidCompiler_exports = AndroidCompiler_exports;
|
|
3039
3047
|
exports.compileToAndroid = compileToAndroid;
|
|
3040
3048
|
exports.init_AndroidCompiler = init_AndroidCompiler;
|
|
3041
|
-
//# sourceMappingURL=chunk-
|
|
3042
|
-
//# sourceMappingURL=chunk-
|
|
3049
|
+
//# sourceMappingURL=chunk-OS533P33.cjs.map
|
|
3050
|
+
//# sourceMappingURL=chunk-OS533P33.cjs.map
|
|
@@ -1,12 +1,21 @@
|
|
|
1
|
-
import { init_CompilerBase, CompilerBase } from './chunk-
|
|
1
|
+
import { init_CompilerBase, CompilerBase } from './chunk-C7ZBSV2Q.js';
|
|
2
2
|
import { ANSCapabilityPath } from '@holoscript/core-types/ans';
|
|
3
3
|
|
|
4
4
|
// src/compiler/LLMProviderCapabilitiesCompiler.ts
|
|
5
5
|
init_CompilerBase();
|
|
6
6
|
var VENDOR_AS_SUBSTRATE_PATTERNS = [
|
|
7
|
-
{
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
{
|
|
8
|
+
pattern: /managed_agents_replaces_holomesh/i,
|
|
9
|
+
rule: "W.GOLD.002 - vendor framework cannot replace HoloMesh"
|
|
10
|
+
},
|
|
11
|
+
{
|
|
12
|
+
pattern: /vector_store_as_source_of_truth/i,
|
|
13
|
+
rule: "docs/LLM_CAPABILITIES.md hard-don'ts - vendor stores never source-of-truth"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
pattern: /api_keys_as_identity/i,
|
|
17
|
+
rule: "W.GOLD.004 - wallets are identity, API keys are sessions"
|
|
18
|
+
}
|
|
10
19
|
];
|
|
11
20
|
var VERIFY_PLACEHOLDER_PATTERN = /\[VERIFY/;
|
|
12
21
|
var STALENESS_DAYS_DEFAULT = 90;
|
|
@@ -407,9 +416,7 @@ var LLMProviderCapabilitiesCompiler = class extends CompilerBase {
|
|
|
407
416
|
}
|
|
408
417
|
lines.push("");
|
|
409
418
|
}
|
|
410
|
-
const routing = ast.routingRecommendations.filter(
|
|
411
|
-
(r) => r.provider === provider.name
|
|
412
|
-
);
|
|
419
|
+
const routing = ast.routingRecommendations.filter((r) => r.provider === provider.name);
|
|
413
420
|
if (routing.length > 0) {
|
|
414
421
|
lines.push("### Routing recommendations");
|
|
415
422
|
lines.push("");
|
|
@@ -650,8 +657,14 @@ function buildAdapterCapabilities(models, capabilities) {
|
|
|
650
657
|
byName.set(capability.name, capability);
|
|
651
658
|
}
|
|
652
659
|
const entries = /* @__PURE__ */ new Map();
|
|
653
|
-
entries.set(
|
|
654
|
-
|
|
660
|
+
entries.set(
|
|
661
|
+
"contextWindow",
|
|
662
|
+
numericCapability(byName, "contextWindow") ?? maxModelNumber(models, "contextWindow")
|
|
663
|
+
);
|
|
664
|
+
entries.set(
|
|
665
|
+
"maxOutput",
|
|
666
|
+
numericCapability(byName, "maxOutput") ?? maxModelNumber(models, "maxOutput")
|
|
667
|
+
);
|
|
655
668
|
const costPerMillion = uniformCostPerMillion(models);
|
|
656
669
|
if (costPerMillion) {
|
|
657
670
|
entries.set("costPerMillion", costPerMillion);
|
|
@@ -721,5 +734,5 @@ function daysBetween(earlier, later) {
|
|
|
721
734
|
}
|
|
722
735
|
|
|
723
736
|
export { LLMCapabilityCompileError, LLMProviderCapabilitiesCompiler, createLLMProviderCapabilitiesCompiler };
|
|
724
|
-
//# sourceMappingURL=chunk-
|
|
725
|
-
//# sourceMappingURL=chunk-
|
|
737
|
+
//# sourceMappingURL=chunk-PABONWKI.js.map
|
|
738
|
+
//# sourceMappingURL=chunk-PABONWKI.js.map
|