@adaas/a-frame 0.0.21 → 0.0.23
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/.conf/tsconfig.browser.json +13 -0
- package/.conf/tsconfig.node.json +14 -0
- package/.env.example +12 -0
- package/dist/browser/A-FrameBrowserStorageBlobs.context-OEQr85oq.d.mts +40 -0
- package/dist/browser/A-FrameBundle.types-DaaUvViw.d.mts +33 -0
- package/dist/browser/A-FrameChannel.types-DWOEUs28.d.mts +142 -0
- package/dist/browser/A-FrameDefinition.entity-DWGN_Ujr.d.mts +329 -0
- package/dist/browser/A-FrameDynamicStructure.entity-DaBgSRCR.d.mts +188 -0
- package/dist/browser/A-FrameLogger.component.env-browser-BIPAP4oQ.d.mts +112 -0
- package/dist/browser/A-FrameNamespace.entity-rCm1AavP.d.mts +125 -0
- package/dist/browser/bundle.d.mts +8 -0
- package/dist/browser/bundle.mjs +2 -0
- package/dist/browser/bundle.mjs.map +1 -0
- package/dist/browser/channel.d.mts +165 -0
- package/dist/browser/channel.mjs +3 -0
- package/dist/browser/channel.mjs.map +1 -0
- package/dist/browser/chunk-5TTVFB3G.mjs +2 -0
- package/dist/browser/chunk-5TTVFB3G.mjs.map +1 -0
- package/dist/browser/chunk-AYN7KUQT.mjs +3 -0
- package/dist/browser/chunk-AYN7KUQT.mjs.map +1 -0
- package/dist/browser/chunk-DMGQW3AO.mjs +2 -0
- package/dist/browser/chunk-DMGQW3AO.mjs.map +1 -0
- package/dist/browser/chunk-G66IL2DR.mjs +2 -0
- package/dist/browser/chunk-G66IL2DR.mjs.map +1 -0
- package/dist/browser/chunk-H6OZP4ZV.mjs +2 -0
- package/dist/browser/chunk-H6OZP4ZV.mjs.map +1 -0
- package/dist/browser/chunk-INS7RO3B.mjs +2 -0
- package/dist/browser/chunk-INS7RO3B.mjs.map +1 -0
- package/dist/browser/chunk-K4MZY4ME.mjs +2 -0
- package/dist/browser/chunk-K4MZY4ME.mjs.map +1 -0
- package/dist/browser/chunk-OFKV5GNB.mjs +3 -0
- package/dist/browser/chunk-OFKV5GNB.mjs.map +1 -0
- package/dist/browser/chunk-QATIN7CO.mjs +3 -0
- package/dist/browser/chunk-QATIN7CO.mjs.map +1 -0
- package/dist/browser/chunk-QBBQ37P3.mjs +2 -0
- package/dist/browser/chunk-QBBQ37P3.mjs.map +1 -0
- package/dist/browser/chunk-VDVJWU5T.mjs +2 -0
- package/dist/browser/chunk-VDVJWU5T.mjs.map +1 -0
- package/dist/browser/chunk-X3C4I6YJ.mjs +2 -0
- package/dist/browser/chunk-X3C4I6YJ.mjs.map +1 -0
- package/dist/browser/chunk-ZVCTU2DN.mjs +3 -0
- package/dist/browser/chunk-ZVCTU2DN.mjs.map +1 -0
- package/dist/browser/core.d.mts +97 -0
- package/dist/browser/core.mjs +2 -0
- package/dist/browser/core.mjs.map +1 -0
- package/dist/browser/crypto.d.mts +35 -0
- package/dist/browser/crypto.mjs +2 -0
- package/dist/browser/crypto.mjs.map +1 -0
- package/dist/browser/definition.d.mts +13 -0
- package/dist/browser/definition.mjs +2 -0
- package/dist/browser/definition.mjs.map +1 -0
- package/dist/browser/dynamic-feature.d.mts +10 -0
- package/dist/browser/dynamic-feature.mjs +2 -0
- package/dist/browser/dynamic-feature.mjs.map +1 -0
- package/dist/browser/dynamic-structure.d.mts +12 -0
- package/dist/browser/dynamic-structure.mjs +2 -0
- package/dist/browser/dynamic-structure.mjs.map +1 -0
- package/dist/browser/env.d.mts +2 -0
- package/dist/browser/env.mjs +2 -0
- package/dist/browser/env.mjs.map +1 -0
- package/dist/browser/frame-index.d.mts +95 -0
- package/dist/browser/frame-index.mjs +2 -0
- package/dist/browser/frame-index.mjs.map +1 -0
- package/dist/browser/index.browser-CZlhzfSP.d.mts +22 -0
- package/dist/browser/index.d.mts +1 -144
- package/dist/browser/index.mjs +1 -1
- package/dist/browser/index.mjs.map +1 -1
- package/dist/browser/logger.d.mts +41 -0
- package/dist/browser/logger.mjs +2 -0
- package/dist/browser/logger.mjs.map +1 -0
- package/dist/browser/namespace.d.mts +13 -0
- package/dist/browser/namespace.mjs +2 -0
- package/dist/browser/namespace.mjs.map +1 -0
- package/dist/browser/storage.d.mts +194 -0
- package/dist/browser/storage.mjs +2 -0
- package/dist/browser/storage.mjs.map +1 -0
- package/dist/browser/vector.d.mts +15 -0
- package/dist/browser/vector.mjs +2 -0
- package/dist/browser/vector.mjs.map +1 -0
- package/dist/index.cjs +0 -0
- package/dist/node/A-FrameChannel.component-BfBcs734.d.ts +62 -0
- package/dist/node/A-FrameChannel.component-NNKcFViw.d.mts +62 -0
- package/dist/node/A-FrameChannel.types-DQF-IiRq.d.mts +146 -0
- package/dist/node/A-FrameChannel.types-DQF-IiRq.d.ts +146 -0
- package/dist/node/A-FrameDefinition.entity-CAUOdEvU.d.ts +329 -0
- package/dist/node/A-FrameDefinition.entity-DWGN_Ujr.d.mts +329 -0
- package/dist/node/A-FrameDynamicStructure.entity-DaBgSRCR.d.mts +188 -0
- package/dist/node/A-FrameDynamicStructure.entity-DaBgSRCR.d.ts +188 -0
- package/dist/node/A-FrameNamespace.entity-D3fZBGDx.d.ts +125 -0
- package/dist/node/A-FrameNamespace.entity-rCm1AavP.d.mts +125 -0
- package/dist/node/A-FrameStorage.component-BYjHfHJJ.d.mts +107 -0
- package/dist/node/A-FrameStorage.component-CT01fs-t.d.ts +107 -0
- package/dist/node/bundle.cjs +101 -0
- package/dist/node/bundle.cjs.map +1 -0
- package/dist/node/bundle.d.mts +69 -0
- package/dist/node/bundle.d.ts +69 -0
- package/dist/node/bundle.mjs +76 -0
- package/dist/node/bundle.mjs.map +1 -0
- package/dist/node/channel.cjs +60 -0
- package/dist/node/channel.cjs.map +1 -0
- package/dist/node/channel.d.mts +61 -0
- package/dist/node/channel.d.ts +61 -0
- package/dist/node/channel.mjs +11 -0
- package/dist/node/channel.mjs.map +1 -0
- package/dist/node/chunk-3LOMGNWA.cjs +8 -0
- package/dist/node/chunk-3LOMGNWA.cjs.map +1 -0
- package/dist/node/chunk-3ONWH75E.mjs +257 -0
- package/dist/node/chunk-3ONWH75E.mjs.map +1 -0
- package/dist/node/chunk-3TD2PEDZ.mjs +53 -0
- package/dist/node/chunk-3TD2PEDZ.mjs.map +1 -0
- package/dist/node/chunk-442DXGOD.mjs +16 -0
- package/dist/node/chunk-442DXGOD.mjs.map +1 -0
- package/dist/node/chunk-6EFXNUL4.mjs +6 -0
- package/dist/node/chunk-6EFXNUL4.mjs.map +1 -0
- package/dist/node/chunk-7A6XGT5J.cjs +541 -0
- package/dist/node/chunk-7A6XGT5J.cjs.map +1 -0
- package/dist/node/chunk-AOQRXZPC.mjs +207 -0
- package/dist/node/chunk-AOQRXZPC.mjs.map +1 -0
- package/dist/node/chunk-APRYHBEF.mjs +171 -0
- package/dist/node/chunk-APRYHBEF.mjs.map +1 -0
- package/dist/node/chunk-B7BXP7K4.mjs +253 -0
- package/dist/node/chunk-B7BXP7K4.mjs.map +1 -0
- package/dist/node/chunk-B7ZDJXD3.cjs +35 -0
- package/dist/node/chunk-B7ZDJXD3.cjs.map +1 -0
- package/dist/node/chunk-CP6JHUU6.cjs +541 -0
- package/dist/node/chunk-CP6JHUU6.cjs.map +1 -0
- package/dist/node/chunk-DDCEMKBP.mjs +655 -0
- package/dist/node/chunk-DDCEMKBP.mjs.map +1 -0
- package/dist/node/chunk-DMY44VUG.mjs +655 -0
- package/dist/node/chunk-DMY44VUG.mjs.map +1 -0
- package/dist/node/chunk-F4UCOZW5.mjs +33 -0
- package/dist/node/chunk-F4UCOZW5.mjs.map +1 -0
- package/dist/node/chunk-GBTFMT3K.cjs +256 -0
- package/dist/node/chunk-GBTFMT3K.cjs.map +1 -0
- package/dist/node/chunk-GNVXVK2B.cjs +8 -0
- package/dist/node/chunk-GNVXVK2B.cjs.map +1 -0
- package/dist/node/chunk-IIVYTS5M.mjs +239 -0
- package/dist/node/chunk-IIVYTS5M.mjs.map +1 -0
- package/dist/node/chunk-JQBYDEMW.mjs +33 -0
- package/dist/node/chunk-JQBYDEMW.mjs.map +1 -0
- package/dist/node/chunk-K4MZY4ME.mjs +3 -0
- package/dist/node/chunk-K4MZY4ME.mjs.map +1 -0
- package/dist/node/chunk-KK64VLZN.cjs +4 -0
- package/dist/node/chunk-KK64VLZN.cjs.map +1 -0
- package/dist/node/chunk-KLG6HKFU.cjs +175 -0
- package/dist/node/chunk-KLG6HKFU.cjs.map +1 -0
- package/dist/node/chunk-LJIZ47HO.cjs +688 -0
- package/dist/node/chunk-LJIZ47HO.cjs.map +1 -0
- package/dist/node/chunk-NIXKAQVP.cjs +35 -0
- package/dist/node/chunk-NIXKAQVP.cjs.map +1 -0
- package/dist/node/chunk-OI76LHVT.mjs +21 -0
- package/dist/node/chunk-OI76LHVT.mjs.map +1 -0
- package/dist/node/chunk-OJGCQNAH.mjs +529 -0
- package/dist/node/chunk-OJGCQNAH.mjs.map +1 -0
- package/dist/node/chunk-QFHZIG7Y.cjs +25 -0
- package/dist/node/chunk-QFHZIG7Y.cjs.map +1 -0
- package/dist/node/chunk-QFUZVN4Y.cjs +259 -0
- package/dist/node/chunk-QFUZVN4Y.cjs.map +1 -0
- package/dist/node/chunk-RRLTGGM7.cjs +209 -0
- package/dist/node/chunk-RRLTGGM7.cjs.map +1 -0
- package/dist/node/chunk-TO4BPKCY.mjs +6 -0
- package/dist/node/chunk-TO4BPKCY.mjs.map +1 -0
- package/dist/node/chunk-UKKCN7CQ.cjs +688 -0
- package/dist/node/chunk-UKKCN7CQ.cjs.map +1 -0
- package/dist/node/chunk-UPA7VN4R.mjs +153 -0
- package/dist/node/chunk-UPA7VN4R.mjs.map +1 -0
- package/dist/node/chunk-UTJ7CVVB.cjs +248 -0
- package/dist/node/chunk-UTJ7CVVB.cjs.map +1 -0
- package/dist/node/chunk-YVX4W6SI.cjs +155 -0
- package/dist/node/chunk-YVX4W6SI.cjs.map +1 -0
- package/dist/node/chunk-YWWGJ6EJ.cjs +55 -0
- package/dist/node/chunk-YWWGJ6EJ.cjs.map +1 -0
- package/dist/node/chunk-Z4HUCRK2.mjs +529 -0
- package/dist/node/chunk-Z4HUCRK2.mjs.map +1 -0
- package/dist/node/chunk-ZM2RLVVH.cjs +18 -0
- package/dist/node/chunk-ZM2RLVVH.cjs.map +1 -0
- package/dist/node/core.cjs +261 -0
- package/dist/node/core.cjs.map +1 -0
- package/dist/node/core.d.mts +76 -0
- package/dist/node/core.d.ts +76 -0
- package/dist/node/core.mjs +250 -0
- package/dist/node/core.mjs.map +1 -0
- package/dist/node/crypto.cjs +13 -0
- package/dist/node/crypto.cjs.map +1 -0
- package/dist/node/crypto.d.mts +44 -0
- package/dist/node/crypto.d.ts +44 -0
- package/dist/node/crypto.mjs +4 -0
- package/dist/node/crypto.mjs.map +1 -0
- package/dist/node/definition.cjs +19 -0
- package/dist/node/definition.cjs.map +1 -0
- package/dist/node/definition.d.mts +13 -0
- package/dist/node/definition.d.ts +13 -0
- package/dist/node/definition.mjs +6 -0
- package/dist/node/definition.mjs.map +1 -0
- package/dist/node/dynamic-feature.cjs +14 -0
- package/dist/node/dynamic-feature.cjs.map +1 -0
- package/dist/node/dynamic-feature.d.mts +10 -0
- package/dist/node/dynamic-feature.d.ts +10 -0
- package/dist/node/dynamic-feature.mjs +12 -0
- package/dist/node/dynamic-feature.mjs.map +1 -0
- package/dist/node/dynamic-structure.cjs +143 -0
- package/dist/node/dynamic-structure.cjs.map +1 -0
- package/dist/node/dynamic-structure.d.mts +12 -0
- package/dist/node/dynamic-structure.d.ts +12 -0
- package/dist/node/dynamic-structure.mjs +138 -0
- package/dist/node/dynamic-structure.mjs.map +1 -0
- package/dist/node/env.cjs +14 -0
- package/dist/node/env.cjs.map +1 -0
- package/dist/node/env.d.mts +22 -0
- package/dist/node/env.d.ts +22 -0
- package/dist/node/env.mjs +5 -0
- package/dist/node/env.mjs.map +1 -0
- package/dist/node/frame-index.cjs +16 -0
- package/dist/node/frame-index.cjs.map +1 -0
- package/dist/node/frame-index.d.mts +95 -0
- package/dist/node/frame-index.d.ts +95 -0
- package/dist/node/frame-index.mjs +7 -0
- package/dist/node/frame-index.mjs.map +1 -0
- package/dist/node/index.cjs +0 -288
- package/dist/node/index.cjs.map +1 -1
- package/dist/node/index.d.mts +1 -144
- package/dist/node/index.d.ts +1 -144
- package/dist/node/index.mjs +0 -284
- package/dist/node/index.mjs.map +1 -1
- package/dist/node/logger.cjs +41 -0
- package/dist/node/logger.cjs.map +1 -0
- package/dist/node/logger.d.mts +150 -0
- package/dist/node/logger.d.ts +150 -0
- package/dist/node/logger.mjs +4 -0
- package/dist/node/logger.mjs.map +1 -0
- package/dist/node/namespace.cjs +24 -0
- package/dist/node/namespace.cjs.map +1 -0
- package/dist/node/namespace.d.mts +13 -0
- package/dist/node/namespace.d.ts +13 -0
- package/dist/node/namespace.mjs +7 -0
- package/dist/node/namespace.mjs.map +1 -0
- package/dist/node/storage.cjs +42 -0
- package/dist/node/storage.cjs.map +1 -0
- package/dist/node/storage.d.mts +110 -0
- package/dist/node/storage.d.ts +110 -0
- package/dist/node/storage.mjs +13 -0
- package/dist/node/storage.mjs.map +1 -0
- package/dist/node/vector.cjs +13 -0
- package/dist/node/vector.cjs.map +1 -0
- package/dist/node/vector.d.mts +15 -0
- package/dist/node/vector.d.ts +15 -0
- package/dist/node/vector.mjs +4 -0
- package/dist/node/vector.mjs.map +1 -0
- package/jest.config.browser.ts +41 -0
- package/jest.config.ts +18 -8
- package/package.json +125 -13
- package/{index.ts → src/concept.ts} +5 -2
- package/src/helpers/Hash.helper.ts +14 -0
- package/src/index.ts +0 -24
- package/src/lib/A-Frame/A-Frame.component.env-browser.ts +124 -0
- package/src/lib/A-Frame/A-Frame.component.env-node.ts +106 -0
- package/src/lib/A-Frame/A-Frame.component.ts +62 -0
- package/src/lib/A-Frame/A-Frame.context.ts +40 -0
- package/src/lib/{components/Index.component.ts/Index.error.ts → A-Frame/A-Frame.error.ts} +1 -1
- package/src/lib/{components/Index.component.ts/Index.guard.ts → A-Frame/A-Frame.guard.ts} +9 -6
- package/src/lib/A-Frame/A-Frame.meta.ts +27 -0
- package/src/lib/{components/Index.component.ts/Index.types.ts → A-Frame/A-Frame.types.ts} +52 -17
- package/src/lib/A-Frame/decorators/A-FrameDefine.decorator.ts +104 -0
- package/src/lib/A-Frame/decorators/A-FrameNamespace.decorator.ts +33 -0
- package/src/lib/A-Frame/index.browser.ts +10 -0
- package/src/lib/A-Frame/index.ts +10 -0
- package/src/lib/A-FrameBundle/A-FrameBundle.builder.env-node.ts +95 -0
- package/src/lib/A-FrameBundle/A-FrameBundle.constants.ts +5 -0
- package/src/lib/A-FrameBundle/A-FrameBundle.types.ts +31 -0
- package/src/lib/A-FrameBundle/index.browser.ts +6 -0
- package/src/lib/A-FrameBundle/index.ts +7 -0
- package/src/lib/A-FrameCLI/A-FrameCLI.container.ts +333 -0
- package/src/lib/A-FrameChannel/A-FrameChannel.component.env-browser.ts +63 -0
- package/src/lib/A-FrameChannel/A-FrameChannel.component.env-node.ts +586 -0
- package/src/lib/A-FrameChannel/A-FrameChannel.component.ts +273 -0
- package/src/lib/A-FrameChannel/A-FrameChannel.constants.ts +39 -0
- package/src/lib/A-FrameChannel/A-FrameChannel.error.ts +10 -0
- package/src/lib/A-FrameChannel/A-FrameChannel.types.ts +143 -0
- package/src/lib/A-FrameChannel/A-FrameChannelEvent.context.ts +28 -0
- package/src/lib/A-FrameChannel/A-FrameChannelRequest.context.ts +36 -0
- package/src/lib/A-FrameChannel/A-FrameChannelSocket.entity.ts +189 -0
- package/src/lib/A-FrameChannel/A-FrameChannelStream.entity.ts +144 -0
- package/src/lib/A-FrameChannel/index.browser.ts +3 -0
- package/src/lib/A-FrameChannel/index.ts +10 -0
- package/src/lib/A-FrameCrypto/A-FrameCrypto.component.env-browser.ts +123 -0
- package/src/lib/A-FrameCrypto/A-FrameCrypto.component.env-node.ts +204 -0
- package/src/lib/A-FrameCrypto/index.browser.ts +1 -0
- package/src/lib/A-FrameCrypto/index.ts +1 -0
- package/src/lib/A-FrameDefinition/A-FrameDefinition.constants.ts +8 -0
- package/src/lib/A-FrameDefinition/A-FrameDefinition.entity.ts +290 -0
- package/src/lib/A-FrameDefinition/A-FrameDefinition.types.ts +109 -0
- package/src/lib/A-FrameDefinition/index.ts +3 -0
- package/src/lib/A-FrameDynamicFeature/A-FrameDynamicFeature.entity.ts +13 -0
- package/src/lib/A-FrameDynamicFeature/A-FrameDynamicFeature.types.ts +10 -0
- package/src/lib/A-FrameDynamicFeature/index.ts +2 -0
- package/src/lib/A-FrameDynamicPatch/A-FrameDynamicPatch.entity.ts +38 -0
- package/src/lib/A-FrameDynamicPatch/A-FrameDynamicPatch.types.ts +20 -0
- package/src/lib/A-FrameDynamicSession/A-FrameDynamicSession.constants.ts +9 -0
- package/src/lib/A-FrameDynamicSession/A-FrameDynamicSession.entity.ts +91 -0
- package/src/lib/A-FrameDynamicSession/A-FrameDynamicSession.types.ts +18 -0
- package/src/lib/A-FrameDynamicStructure/A-FrameDynamicStructure.constants.ts +13 -0
- package/src/lib/A-FrameDynamicStructure/A-FrameDynamicStructure.entity.ts +187 -0
- package/src/lib/A-FrameDynamicStructure/A-FrameDynamicStructure.error.ts +13 -0
- package/src/lib/A-FrameDynamicStructure/A-FrameDynamicStructure.types.ts +128 -0
- package/src/lib/A-FrameDynamicStructure/A-FrameDynamicStructureOperation.context.ts +32 -0
- package/src/lib/A-FrameDynamicStructure/index.ts +5 -0
- package/src/lib/A-FrameEnv/A-FrameEnv.fragment.env-browser.ts +31 -0
- package/src/lib/A-FrameEnv/A-FrameEnv.fragment.env-node.ts +39 -0
- package/src/lib/A-FrameEnv/A-FrameEnv.types.ts +7 -0
- package/src/lib/A-FrameEnv/index.browser.ts +1 -0
- package/src/lib/A-FrameEnv/index.ts +1 -0
- package/src/lib/A-FrameIndex/A-FrameIndex.context.ts +321 -0
- package/src/lib/A-FrameIndex/A-FrameIndex.types.ts +63 -0
- package/src/lib/A-FrameIndex/index.browser.ts +3 -0
- package/src/lib/A-FrameIndex/index.ts +3 -0
- package/src/lib/A-FrameLogger/A-FrameLogger.component.env-browser.ts +99 -0
- package/src/lib/A-FrameLogger/A-FrameLogger.component.env-node.ts +129 -0
- package/src/lib/A-FrameLogger/A-FrameLogger.component.ts +123 -0
- package/src/lib/A-FrameLogger/A-FrameLogger.constants.ts +66 -0
- package/src/lib/A-FrameLogger/A-FrameLogger.types.ts +67 -0
- package/src/lib/A-FrameLogger/index.browser.ts +4 -0
- package/src/lib/A-FrameLogger/index.ts +4 -0
- package/src/lib/A-FrameNamespace/A-FrameNamespace.constants.ts +12 -0
- package/src/lib/A-FrameNamespace/A-FrameNamespace.entity.ts +211 -0
- package/src/lib/A-FrameNamespace/A-FrameNamespace.types.ts +72 -0
- package/src/lib/A-FrameNamespace/index.ts +3 -0
- package/src/lib/A-FrameStorage/A-FrameStorage.codec.ts +338 -0
- package/src/lib/A-FrameStorage/A-FrameStorage.component.ts +191 -0
- package/src/lib/A-FrameStorage/A-FrameStorage.constants.ts +11 -0
- package/src/lib/A-FrameStorage/A-FrameStorage.error.ts +13 -0
- package/src/lib/A-FrameStorage/A-FrameStorage.types.ts +98 -0
- package/src/lib/A-FrameStorage/A-FrameStorageOperation.context.ts +59 -0
- package/src/lib/A-FrameStorage/browser/A-FrameBrowserStorage.component.ts +312 -0
- package/src/lib/A-FrameStorage/browser/A-FrameBrowserStorageBlobs.context.ts +77 -0
- package/src/lib/A-FrameStorage/index.browser.ts +11 -0
- package/src/lib/A-FrameStorage/index.ts +10 -0
- package/src/lib/A-FrameStorage/node/A-FrameNodeStorage.component.ts +464 -0
- package/src/lib/A-FrameStorage/server/A-FrameServerStorage.component.ts +177 -0
- package/src/lib/{entities/A_FrameVector/A_FrameVector.entity.ts → A-FrameVector/A-FrameVector.entity.ts} +10 -0
- package/src/lib/A-FrameVector/index.ts +3 -0
- package/tests/A-Frame.browser.test.ts +94 -0
- package/tests/A-Frame.test.ts +73 -68
- package/tests/jest.browser-environment.js +30 -0
- package/tests/jest.polyfills.browser.ts +13 -0
- package/tests/jest.setup.browser.ts +33 -0
- package/tsconfig.browser.json +54 -0
- package/tsconfig.json +16 -0
- package/tsup.config.ts +32 -2
- package/src/lib/components/Builder.component.ts/Builder.component.ts +0 -0
- package/src/lib/components/Index.component.ts/Index.component.ts +0 -79
- package/src/lib/components/Index.component.ts/Index.constants.ts +0 -0
- package/src/lib/components/Index.component.ts/Index.meta.ts +0 -28
- package/src/lib/components/Index.component.ts/IndexConfigurations.meta.ts +0 -78
- package/src/lib/components/Index.component.ts/decorators/IndexComponent.decorator.ts +0 -97
- package/src/lib/components/Index.component.ts/decorators/IndexDescribe.decorator.ts +0 -59
- package/src/lib/components/Index.component.ts/decorators/IndexNamespace.decorator.ts +0 -57
- package/src/lib/components/Search/A_FrameSearch.component.ts +0 -66
- package/src/lib/containers/CLI.container.ts +0 -27
- package/src/lib/entities/Namespace/Namespace.entity.ts +0 -8
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
import { A_CommonHelper, A_Context, A_Meta } from "@adaas/a-concept";
|
|
2
|
-
import { A_Frame_IndexError } from "../Index.error";
|
|
3
|
-
import { A_Frame_IndexDecoratorTarget, A_Frame_IndexOptions, A_Frame_IndexTargetType, A_Frame_IndexDecoratorDescriptor, A_Frame_IndexMetaTarget } from "../Index.types";
|
|
4
|
-
import { A_Frame_Index } from "../Index.component";
|
|
5
|
-
import { A_Frame_IndexMeta } from "../Index.meta";
|
|
6
|
-
import { A_Frame_IndexTypeGuard } from "../Index.guard";
|
|
7
|
-
|
|
8
|
-
export function A_Frame_IndexDecorator(
|
|
9
|
-
componentType: A_Frame_IndexTargetType,
|
|
10
|
-
config: Partial<A_Frame_IndexOptions> = {}
|
|
11
|
-
) {
|
|
12
|
-
return function (
|
|
13
|
-
target: A_Frame_IndexDecoratorTarget,
|
|
14
|
-
propertyKey?: string | symbol,
|
|
15
|
-
descriptor?: A_Frame_IndexDecoratorDescriptor
|
|
16
|
-
): any {
|
|
17
|
-
|
|
18
|
-
// Handle method decorator case
|
|
19
|
-
if (propertyKey && descriptor && componentType === A_Frame_IndexTargetType.METHOD) {
|
|
20
|
-
// For methods, target is the class prototype
|
|
21
|
-
const targetClass = target.constructor as A_Frame_IndexMetaTarget;
|
|
22
|
-
const methodName = String(propertyKey);
|
|
23
|
-
|
|
24
|
-
try {
|
|
25
|
-
const indexMeta: A_Frame_IndexMeta = A_Context.meta(A_Frame_Index) as any;
|
|
26
|
-
const targetMeta = indexMeta.getMetaFor(targetClass);
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
if (!!config.namespace && !!targetMeta.namespace && config.namespace !== targetMeta.namespace) {
|
|
30
|
-
throw new A_Frame_IndexError(
|
|
31
|
-
A_Frame_IndexError.InvalidConfiguration,
|
|
32
|
-
`Method namespace '${config.namespace}' does not match target class namespace '${targetMeta.namespace}'.`
|
|
33
|
-
);
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
// Store method information
|
|
37
|
-
const methodInfo = {
|
|
38
|
-
name: config.name || methodName,
|
|
39
|
-
description: config.description,
|
|
40
|
-
namespace: config.namespace || targetMeta.namespace,
|
|
41
|
-
methodName: methodName
|
|
42
|
-
};
|
|
43
|
-
|
|
44
|
-
// Add to methods array
|
|
45
|
-
targetMeta.addMethod(methodInfo);
|
|
46
|
-
|
|
47
|
-
indexMeta.seMetaFor(targetClass, targetMeta);
|
|
48
|
-
|
|
49
|
-
return descriptor;
|
|
50
|
-
|
|
51
|
-
} catch (error) {
|
|
52
|
-
|
|
53
|
-
throw new A_Frame_IndexError(
|
|
54
|
-
A_Frame_IndexError.IndexDefinitionError,
|
|
55
|
-
`Unable to apply @A_Frame_Index.Method decorator on '${targetClass.name}.${methodName}': ${error instanceof Error ? error.message : 'Unknown error'}`
|
|
56
|
-
);
|
|
57
|
-
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
// Handle class decorator case
|
|
62
|
-
if (!A_Frame_IndexTypeGuard.isAllowedTarget(target)) {
|
|
63
|
-
throw new A_Frame_IndexError(
|
|
64
|
-
A_Frame_IndexError.InvalidTarget,
|
|
65
|
-
`@A_Frame_Index.${componentType} decorator can only be applied to allowed targets.`
|
|
66
|
-
);
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
// for error messages
|
|
70
|
-
const componentName = A_CommonHelper.getComponentName(target);
|
|
71
|
-
|
|
72
|
-
try {
|
|
73
|
-
// Get the index meta for the global A_Frame_Index component
|
|
74
|
-
const indexMeta: A_Frame_IndexMeta = A_Context.meta(A_Frame_Index) as any;
|
|
75
|
-
|
|
76
|
-
const targetClass = A_Frame_IndexTypeGuard.getTargetConstructor(target);
|
|
77
|
-
|
|
78
|
-
// Check for pending namespace and description from other decorators
|
|
79
|
-
const targetMeta = indexMeta.getMetaFor(targetClass);
|
|
80
|
-
|
|
81
|
-
targetMeta.name = config.name || componentName;
|
|
82
|
-
targetMeta.description = config.description;
|
|
83
|
-
targetMeta.namespace = config.namespace;
|
|
84
|
-
targetMeta.type = componentType;
|
|
85
|
-
|
|
86
|
-
indexMeta.seMetaFor(targetClass, targetMeta);
|
|
87
|
-
|
|
88
|
-
return target;
|
|
89
|
-
|
|
90
|
-
} catch (error) {
|
|
91
|
-
throw new A_Frame_IndexError(
|
|
92
|
-
A_Frame_IndexError.IndexDefinitionError,
|
|
93
|
-
`Unable to apply @A_Frame_Index.${componentType} decorator on '${componentName}': ${error instanceof Error ? error.message : 'Unknown error'}`
|
|
94
|
-
);
|
|
95
|
-
}
|
|
96
|
-
};
|
|
97
|
-
}
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
import { A_CommonHelper, A_Context } from "@adaas/a-concept";
|
|
2
|
-
import { A_Frame_IndexDecoratorDescriptor, A_Frame_IndexDecoratorTarget, A_Frame_IndexNamespaceDecoratorTarget } from "../Index.types";
|
|
3
|
-
import { A_Frame_Index } from "../Index.component";
|
|
4
|
-
import { A_Frame_IndexMeta } from "../Index.meta";
|
|
5
|
-
import { A_Frame_IndexTypeGuard } from "../Index.guard";
|
|
6
|
-
import { A_Frame_IndexError } from "../Index.error";
|
|
7
|
-
|
|
8
|
-
export function A_Frame_IndexDescribeDecorator(description: string) {
|
|
9
|
-
return function (
|
|
10
|
-
target: A_Frame_IndexDecoratorTarget,
|
|
11
|
-
propertyKey?: string | symbol,
|
|
12
|
-
descriptor?: A_Frame_IndexDecoratorDescriptor
|
|
13
|
-
|
|
14
|
-
): A_Frame_IndexDecoratorTarget {
|
|
15
|
-
const componentName = A_CommonHelper.getComponentName(target);
|
|
16
|
-
|
|
17
|
-
if (!A_Frame_IndexTypeGuard.isAllowedTarget(target)) {
|
|
18
|
-
throw new A_Frame_IndexError(
|
|
19
|
-
A_Frame_IndexError.InvalidTarget,
|
|
20
|
-
`Unable Apply Describe Index Decorator for '${componentName}': Target type is not allowed.`
|
|
21
|
-
);
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
// for error messages
|
|
25
|
-
|
|
26
|
-
// for error messages
|
|
27
|
-
|
|
28
|
-
try {
|
|
29
|
-
// Get the index meta for the global A_Frame_Index component
|
|
30
|
-
// TODO: Type casting hack to avoid circular dependency issues
|
|
31
|
-
const indexMeta: A_Frame_IndexMeta = A_Context.meta(A_Frame_Index) as any;
|
|
32
|
-
|
|
33
|
-
const targetClass = A_Frame_IndexTypeGuard.getTargetConstructor(target);
|
|
34
|
-
|
|
35
|
-
// Check for pending namespace and description from other decorators
|
|
36
|
-
const targetMeta = indexMeta.getMetaFor(targetClass)
|
|
37
|
-
if (!!propertyKey || !!descriptor) {
|
|
38
|
-
|
|
39
|
-
const targetMethodName = propertyKey ? propertyKey.toString() : '';
|
|
40
|
-
|
|
41
|
-
const methodMeta = targetMeta.methods.get(targetMethodName);
|
|
42
|
-
if (!!methodMeta) {
|
|
43
|
-
methodMeta.description = description;
|
|
44
|
-
targetMeta.methods.set(targetMethodName, methodMeta);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
} else {
|
|
48
|
-
targetMeta.description = description;
|
|
49
|
-
|
|
50
|
-
indexMeta.seMetaFor(targetClass, targetMeta);
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
return target;
|
|
54
|
-
|
|
55
|
-
} catch (error) {
|
|
56
|
-
throw new A_Frame_IndexError(error);
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
}
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import { A_CommonHelper, A_Context } from "@adaas/a-concept";
|
|
2
|
-
import { A_Frame_IndexDecoratorDescriptor, A_Frame_IndexDecoratorTarget, A_Frame_IndexNamespaceDecoratorTarget } from "../Index.types";
|
|
3
|
-
import { A_Frame_Index } from "../Index.component";
|
|
4
|
-
import { A_Frame_IndexTypeGuard } from "../Index.guard";
|
|
5
|
-
import { A_Frame_IndexMeta } from "../Index.meta";
|
|
6
|
-
import { A_Frame_IndexError } from "../Index.error";
|
|
7
|
-
|
|
8
|
-
export function A_Frame_IndexNamespaceDecorator(name?: string) {
|
|
9
|
-
return function (
|
|
10
|
-
target: A_Frame_IndexDecoratorTarget,
|
|
11
|
-
propertyKey?: string | symbol,
|
|
12
|
-
descriptor?: A_Frame_IndexDecoratorDescriptor
|
|
13
|
-
|
|
14
|
-
): A_Frame_IndexDecoratorTarget {
|
|
15
|
-
const componentName = A_CommonHelper.getComponentName(target);
|
|
16
|
-
|
|
17
|
-
if (!A_Frame_IndexTypeGuard.isAllowedTarget(target)) {
|
|
18
|
-
throw new A_Frame_IndexError(
|
|
19
|
-
A_Frame_IndexError.InvalidTarget,
|
|
20
|
-
`Unable Apply Describe Index Decorator for '${componentName}': Target type is not allowed.`
|
|
21
|
-
);
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
// for error messages
|
|
25
|
-
|
|
26
|
-
try {
|
|
27
|
-
// Get the index meta for the global A_Frame_Index component
|
|
28
|
-
// TODO: Type casting hack to avoid circular dependency issues
|
|
29
|
-
const indexMeta: A_Frame_IndexMeta = A_Context.meta(A_Frame_Index) as any;
|
|
30
|
-
|
|
31
|
-
const targetClass = A_Frame_IndexTypeGuard.getTargetConstructor(target);
|
|
32
|
-
|
|
33
|
-
// Check for pending namespace and description from other decorators
|
|
34
|
-
const targetMeta = indexMeta.getMetaFor(targetClass)
|
|
35
|
-
if (!!propertyKey || !!descriptor) {
|
|
36
|
-
|
|
37
|
-
// const targetMethodName = propertyKey ? propertyKey.toString() : '';
|
|
38
|
-
|
|
39
|
-
// const methodMeta = targetMeta.methods.get(targetMethodName);
|
|
40
|
-
// if (!!methodMeta) {
|
|
41
|
-
// methodMeta.namespace = name;
|
|
42
|
-
// targetMeta.methods.set(targetMethodName, methodMeta);
|
|
43
|
-
// }
|
|
44
|
-
|
|
45
|
-
} else {
|
|
46
|
-
targetMeta.namespace = name;
|
|
47
|
-
|
|
48
|
-
indexMeta.seMetaFor(targetClass, targetMeta);
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
return target;
|
|
52
|
-
|
|
53
|
-
} catch (error) {
|
|
54
|
-
throw new A_Frame_IndexError(error);
|
|
55
|
-
}
|
|
56
|
-
};
|
|
57
|
-
}
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
import { A_Component } from "@adaas/a-concept"
|
|
2
|
-
import { A_FrameVector } from "../../entities/A_FrameVector/A_FrameVector.entity"
|
|
3
|
-
|
|
4
|
-
export class A_FrameSearch extends A_Component {
|
|
5
|
-
|
|
6
|
-
static cosineSimilarity(
|
|
7
|
-
a: A_FrameVector,
|
|
8
|
-
b: A_FrameVector
|
|
9
|
-
): number {
|
|
10
|
-
const dot = a.dot(b)
|
|
11
|
-
const mag = a.magnitude() * b.magnitude()
|
|
12
|
-
return mag === 0 ? 0 : dot / mag
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
static euclideanDistance(
|
|
16
|
-
a: A_FrameVector,
|
|
17
|
-
b: A_FrameVector
|
|
18
|
-
): number {
|
|
19
|
-
A_FrameSearch.assertSameLength(a, b)
|
|
20
|
-
|
|
21
|
-
let sum = 0
|
|
22
|
-
for (let i = 0; i < a.length; i++) {
|
|
23
|
-
const diff = a.values[i] - b.values[i]
|
|
24
|
-
sum += diff * diff
|
|
25
|
-
}
|
|
26
|
-
return Math.sqrt(sum)
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
static nearest(
|
|
30
|
-
query: A_FrameVector,
|
|
31
|
-
vectors: readonly A_FrameVector[],
|
|
32
|
-
limit = 1
|
|
33
|
-
): A_FrameVector[] {
|
|
34
|
-
return [...vectors]
|
|
35
|
-
.map(v => ({
|
|
36
|
-
vector: v,
|
|
37
|
-
score: A_FrameSearch.cosineSimilarity(query, v),
|
|
38
|
-
}))
|
|
39
|
-
.sort((a, b) => b.score - a.score)
|
|
40
|
-
.slice(0, limit)
|
|
41
|
-
.map(r => r.vector)
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
static rank(
|
|
45
|
-
query: A_FrameVector,
|
|
46
|
-
vectors: readonly A_FrameVector[]
|
|
47
|
-
): Array<{ vector: A_FrameVector; score: number }> {
|
|
48
|
-
return vectors
|
|
49
|
-
.map(v => ({
|
|
50
|
-
vector: v,
|
|
51
|
-
score: A_FrameSearch.cosineSimilarity(query, v),
|
|
52
|
-
}))
|
|
53
|
-
.sort((a, b) => b.score - a.score)
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
private static assertSameLength(
|
|
57
|
-
a: A_FrameVector,
|
|
58
|
-
b: A_FrameVector
|
|
59
|
-
) {
|
|
60
|
-
if (a.length !== b.length) {
|
|
61
|
-
throw new Error(
|
|
62
|
-
`Embedding dimension mismatch: ${a.length} vs ${b.length}`
|
|
63
|
-
)
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { A_Concept, A_Container, A_Context, A_Error } from "@adaas/a-concept";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export class A_Frame_CLIContainer extends A_Container {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
@A_Concept.Load()
|
|
9
|
-
async initialize() {
|
|
10
|
-
if (A_Context.environment !== 'server') {
|
|
11
|
-
throw new A_Error('A-Frame CLI can only be used in Node.js environment.');
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
@A_Concept.Start()
|
|
17
|
-
async readCommandParams() {
|
|
18
|
-
console.log('Reading command parameters from CLI...');
|
|
19
|
-
|
|
20
|
-
const args = process.argv.slice(2);
|
|
21
|
-
|
|
22
|
-
console.log('Command Line Arguments:', args);
|
|
23
|
-
|
|
24
|
-
// Here you can parse the args and set them to the container's state or properties as needed
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
}
|