@neuralis/brain-core 0.3.1 → 0.4.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/README.md +88 -1417
- package/app/README.md +4 -4
- package/app/cards/FilesystemCardShell.tsx +42 -4
- package/app/cards/FilesystemChangeCard.tsx +34 -11
- package/app/cards/README.md +6 -5
- package/app/cards/diffUtils.ts +99 -1
- package/app/filesystem/FilesystemHost.tsx +24 -2
- package/app/filesystem/README.md +1 -1
- package/app/filesystem/api/README.md +3 -3
- package/app/filesystem/api/index.ts +38 -14
- package/app/filesystem/api/projectPackages.ts +13 -102
- package/app/filesystem/domain/types.ts +30 -10
- package/app/filesystem/hooks/README.md +4 -4
- package/app/filesystem/hooks/useDiscoverableSources.ts +19 -30
- package/app/filesystem/hooks/useFilesystemSSE.ts +42 -2
- package/app/filesystem/host/README.md +6 -4
- package/app/filesystem/host/buildFilesystemHostValue.ts +28 -2
- package/app/filesystem/host/installFilesystemHostComponents.tsx +1 -1
- package/app/filesystem/lib/sourceKindForm.ts +210 -27
- package/app/filesystem/lib/treeVisualState.tsx +98 -4
- package/app/filesystem/store/README.md +1 -0
- package/app/filesystem/store/filesystemStore.ts +99 -8
- package/app/filesystem/store/gitSlice.ts +5 -0
- package/app/filesystem/store/helpers.ts +17 -0
- package/app/filesystem/store/listSlice.ts +8 -0
- package/app/filesystem/ui/CodeEditor.tsx +18 -3
- package/app/filesystem/ui/DiscoverDock.tsx +5 -1
- package/app/filesystem/ui/FileEditor.tsx +15 -10
- package/app/filesystem/ui/FileTree.tsx +75 -24
- package/app/filesystem/ui/FilesystemWidget.tsx +10 -2
- package/app/filesystem/ui/FolderPicker.tsx +251 -0
- package/app/filesystem/ui/GitControlPanel.tsx +7 -2
- package/app/filesystem/ui/PackagesPanel.tsx +52 -374
- package/app/filesystem/ui/PendingChangesPanel.tsx +1 -1
- package/app/filesystem/ui/PolicyEditor.tsx +109 -24
- package/app/filesystem/ui/README.md +30 -23
- package/app/filesystem/ui/RawMediaPreview.tsx +58 -0
- package/app/filesystem/ui/SourceBranchHeader.tsx +4 -4
- package/app/filesystem/ui/SourcesPanel.tsx +502 -342
- package/app/filesystem/ui/Toolbar.tsx +1 -2
- package/app/filesystem/ui/VectorHealthPanel.tsx +2 -2
- package/app/shared/filesystem.png +0 -0
- package/dist/app/host.js +58 -46
- package/dist/scripts/sourceRootPairV1.d.ts +47 -0
- package/dist/scripts/sourceRootPairV1.d.ts.map +1 -0
- package/dist/scripts/sourceRootPairV1.js +147 -0
- package/dist/scripts/sourceRootPairV1.js.map +1 -0
- package/dist/scripts/sourceToFolderV1.d.ts +56 -0
- package/dist/scripts/sourceToFolderV1.d.ts.map +1 -0
- package/dist/scripts/sourceToFolderV1.js +152 -0
- package/dist/scripts/sourceToFolderV1.js.map +1 -0
- package/dist/scripts/sourceToHostV1.d.ts +56 -0
- package/dist/scripts/sourceToHostV1.d.ts.map +1 -0
- package/dist/scripts/sourceToHostV1.js +132 -0
- package/dist/scripts/sourceToHostV1.js.map +1 -0
- package/dist/src/channels/filesystem.d.ts +1 -1
- package/dist/src/channels/filesystem.js +1 -1
- package/dist/src/connectors/AppSourceConfigStore.d.ts +17 -3
- package/dist/src/connectors/AppSourceConfigStore.d.ts.map +1 -1
- package/dist/src/connectors/AppSourceConfigStore.js +46 -6
- package/dist/src/connectors/AppSourceConfigStore.js.map +1 -1
- package/dist/src/connectors/HostConnector.d.ts +201 -0
- package/dist/src/connectors/HostConnector.d.ts.map +1 -0
- package/dist/src/connectors/HostConnector.js +903 -0
- package/dist/src/connectors/HostConnector.js.map +1 -0
- package/dist/src/connectors/inProcessTransport.d.ts +131 -0
- package/dist/src/connectors/inProcessTransport.d.ts.map +1 -0
- package/dist/src/connectors/inProcessTransport.js +447 -0
- package/dist/src/connectors/inProcessTransport.js.map +1 -0
- package/dist/src/domain/access/callerPermissions.d.ts +29 -0
- package/dist/src/domain/access/callerPermissions.d.ts.map +1 -1
- package/dist/src/domain/access/callerPermissions.js +85 -5
- package/dist/src/domain/access/callerPermissions.js.map +1 -1
- package/dist/src/domain/access/nativeLocalFence.d.ts +65 -0
- package/dist/src/domain/access/nativeLocalFence.d.ts.map +1 -0
- package/dist/src/domain/access/nativeLocalFence.js +171 -0
- package/dist/src/domain/access/nativeLocalFence.js.map +1 -0
- package/dist/src/domain/access/uriPermission.js +3 -3
- package/dist/src/domain/access/uriPermission.js.map +1 -1
- package/dist/src/domain/byteRange.d.ts +15 -0
- package/dist/src/domain/byteRange.d.ts.map +1 -0
- package/dist/src/domain/byteRange.js +30 -0
- package/dist/src/domain/byteRange.js.map +1 -0
- package/dist/src/domain/defaultPermissions.d.ts.map +1 -1
- package/dist/src/domain/defaultPermissions.js +29 -0
- package/dist/src/domain/defaultPermissions.js.map +1 -1
- package/dist/src/domain/mime.d.ts +11 -19
- package/dist/src/domain/mime.d.ts.map +1 -1
- package/dist/src/domain/mime.js +13 -102
- package/dist/src/domain/mime.js.map +1 -1
- package/dist/src/domain/paths.d.ts.map +1 -1
- package/dist/src/domain/paths.js +5 -3
- package/dist/src/domain/paths.js.map +1 -1
- package/dist/src/domain/scopeAccessCtx.d.ts +2 -2
- package/dist/src/domain/scopeAccessCtx.js +2 -2
- package/dist/src/domain/sourceConfig.d.ts +52 -19
- package/dist/src/domain/sourceConfig.d.ts.map +1 -1
- package/dist/src/domain/sourceConfig.js +103 -19
- package/dist/src/domain/sourceConfig.js.map +1 -1
- package/dist/src/domain/sourcePackages.d.ts +8 -8
- package/dist/src/domain/sourcePackages.d.ts.map +1 -1
- package/dist/src/domain/sourceRootPair.d.ts +88 -0
- package/dist/src/domain/sourceRootPair.d.ts.map +1 -0
- package/dist/src/domain/sourceRootPair.js +108 -0
- package/dist/src/domain/sourceRootPair.js.map +1 -0
- package/dist/src/domain/syncTypes.d.ts +8 -1
- package/dist/src/domain/syncTypes.d.ts.map +1 -1
- package/dist/src/domain/syncTypes.js +1 -0
- package/dist/src/domain/syncTypes.js.map +1 -1
- package/dist/src/domain/types.d.ts +32 -2
- package/dist/src/domain/types.d.ts.map +1 -1
- package/dist/src/domain/uri.d.ts.map +1 -1
- package/dist/src/domain/uri.js +3 -2
- package/dist/src/domain/uri.js.map +1 -1
- package/dist/src/embeddings/clients/GeminiEmbedder.d.ts.map +1 -1
- package/dist/src/embeddings/clients/GeminiEmbedder.js +2 -5
- package/dist/src/embeddings/clients/GeminiEmbedder.js.map +1 -1
- package/dist/src/embeddings/clients/OpenAIEmbedder.d.ts.map +1 -1
- package/dist/src/embeddings/clients/OpenAIEmbedder.js +2 -3
- package/dist/src/embeddings/clients/OpenAIEmbedder.js.map +1 -1
- package/dist/src/embeddings/clients/QwenEmbedder.d.ts +2 -0
- package/dist/src/embeddings/clients/QwenEmbedder.d.ts.map +1 -1
- package/dist/src/embeddings/clients/QwenEmbedder.js +10 -2
- package/dist/src/embeddings/clients/QwenEmbedder.js.map +1 -1
- package/dist/src/embeddings/clients/VoyageEmbedder.d.ts +2 -0
- package/dist/src/embeddings/clients/VoyageEmbedder.d.ts.map +1 -1
- package/dist/src/embeddings/clients/VoyageEmbedder.js +8 -1
- package/dist/src/embeddings/clients/VoyageEmbedder.js.map +1 -1
- package/dist/src/embeddings/factory.d.ts +5 -3
- package/dist/src/embeddings/factory.d.ts.map +1 -1
- package/dist/src/embeddings/factory.js +7 -3
- package/dist/src/embeddings/factory.js.map +1 -1
- package/dist/src/embeddings/models.d.ts +1 -1
- package/dist/src/embeddings/models.d.ts.map +1 -1
- package/dist/src/embeddings/retry.js +1 -1
- package/dist/src/embeddings/retry.js.map +1 -1
- package/dist/src/embeddings/types.d.ts +6 -0
- package/dist/src/embeddings/types.d.ts.map +1 -1
- package/dist/src/embeddings/types.js +11 -0
- package/dist/src/embeddings/types.js.map +1 -1
- package/dist/src/events/pending.d.ts +1 -1
- package/dist/src/events/pending.js +1 -1
- package/dist/src/git/GitRunner.d.ts +110 -30
- package/dist/src/git/GitRunner.d.ts.map +1 -1
- package/dist/src/git/GitRunner.js +511 -199
- package/dist/src/git/GitRunner.js.map +1 -1
- package/dist/src/git/GitWatchRegistry.d.ts +41 -35
- package/dist/src/git/GitWatchRegistry.d.ts.map +1 -1
- package/dist/src/git/GitWatchRegistry.js +61 -79
- package/dist/src/git/GitWatchRegistry.js.map +1 -1
- package/dist/src/git/gitPlace.d.ts +61 -0
- package/dist/src/git/gitPlace.d.ts.map +1 -0
- package/dist/src/git/gitPlace.js +74 -0
- package/dist/src/git/gitPlace.js.map +1 -0
- package/dist/src/git/sourceGitControl.d.ts +33 -21
- package/dist/src/git/sourceGitControl.d.ts.map +1 -1
- package/dist/src/git/sourceGitControl.js +211 -95
- package/dist/src/git/sourceGitControl.js.map +1 -1
- package/dist/src/git/sourceGitStatus.js +1 -1
- package/dist/src/git/sourceGitStatus.js.map +1 -1
- package/dist/src/git/untrackedStats.js +1 -1
- package/dist/src/git/untrackedStats.js.map +1 -1
- package/dist/src/index.d.ts +2 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +2 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/lifecycle.d.ts +9 -12
- package/dist/src/lifecycle.d.ts.map +1 -1
- package/dist/src/lifecycle.js +2 -1
- package/dist/src/lifecycle.js.map +1 -1
- package/dist/src/routes/approve.d.ts +1 -1
- package/dist/src/routes/approve.js +1 -1
- package/dist/src/routes/events.d.ts +1 -1
- package/dist/src/routes/events.js +1 -1
- package/dist/src/routes/git.d.ts +7 -7
- package/dist/src/routes/git.d.ts.map +1 -1
- package/dist/src/routes/git.js +201 -72
- package/dist/src/routes/git.js.map +1 -1
- package/dist/src/routes/health.d.ts +6 -6
- package/dist/src/routes/health.js +12 -12
- package/dist/src/routes/helpers/sourceNotConfigured.d.ts +1 -1
- package/dist/src/routes/helpers/sourceNotConfigured.js +1 -1
- package/dist/src/routes/helpers/uriGuard.d.ts +1 -1
- package/dist/src/routes/helpers/uriGuard.d.ts.map +1 -1
- package/dist/src/routes/helpers/uriGuard.js +3 -2
- package/dist/src/routes/helpers/uriGuard.js.map +1 -1
- package/dist/src/routes/helpers.d.ts +11 -4
- package/dist/src/routes/helpers.d.ts.map +1 -1
- package/dist/src/routes/helpers.js +13 -6
- package/dist/src/routes/helpers.js.map +1 -1
- package/dist/src/routes/list.d.ts +1 -1
- package/dist/src/routes/list.d.ts.map +1 -1
- package/dist/src/routes/list.js +3 -4
- package/dist/src/routes/list.js.map +1 -1
- package/dist/src/routes/pending.d.ts +4 -4
- package/dist/src/routes/pending.js +9 -9
- package/dist/src/routes/policies.d.ts +10 -8
- package/dist/src/routes/policies.d.ts.map +1 -1
- package/dist/src/routes/policies.js +31 -25
- package/dist/src/routes/policies.js.map +1 -1
- package/dist/src/routes/raw.d.ts +1 -1
- package/dist/src/routes/raw.d.ts.map +1 -1
- package/dist/src/routes/raw.js +66 -12
- package/dist/src/routes/raw.js.map +1 -1
- package/dist/src/routes/read.d.ts +1 -1
- package/dist/src/routes/read.js +1 -1
- package/dist/src/routes/search.d.ts +1 -1
- package/dist/src/routes/search.js +1 -1
- package/dist/src/routes/sources.d.ts +63 -6
- package/dist/src/routes/sources.d.ts.map +1 -1
- package/dist/src/routes/sources.js +494 -382
- package/dist/src/routes/sources.js.map +1 -1
- package/dist/src/routes/upload.d.ts +1 -1
- package/dist/src/routes/upload.js +1 -1
- package/dist/src/routes/write.d.ts +2 -2
- package/dist/src/routes/write.js +2 -2
- package/dist/src/services/BridgeService.d.ts +21 -35
- package/dist/src/services/BridgeService.d.ts.map +1 -1
- package/dist/src/services/BridgeService.js +42 -88
- package/dist/src/services/BridgeService.js.map +1 -1
- package/dist/src/services/FilesystemService.d.ts +4 -3
- package/dist/src/services/FilesystemService.d.ts.map +1 -1
- package/dist/src/services/FilesystemService.js +112 -34
- package/dist/src/services/FilesystemService.js.map +1 -1
- package/dist/src/services/FilesystemUiService.d.ts +4 -1
- package/dist/src/services/FilesystemUiService.d.ts.map +1 -1
- package/dist/src/services/FilesystemUiService.js +66 -25
- package/dist/src/services/FilesystemUiService.js.map +1 -1
- package/dist/src/services/SyncScheduler.d.ts +12 -4
- package/dist/src/services/SyncScheduler.d.ts.map +1 -1
- package/dist/src/services/SyncScheduler.js +37 -8
- package/dist/src/services/SyncScheduler.js.map +1 -1
- package/dist/src/services/baselineRepair.d.ts +13 -3
- package/dist/src/services/baselineRepair.d.ts.map +1 -1
- package/dist/src/services/baselineRepair.js +13 -3
- package/dist/src/services/baselineRepair.js.map +1 -1
- package/dist/src/services/declaredSources.d.ts +132 -43
- package/dist/src/services/declaredSources.d.ts.map +1 -1
- package/dist/src/services/declaredSources.js +118 -45
- package/dist/src/services/declaredSources.js.map +1 -1
- package/dist/src/store/dataFormats.d.ts +17 -2
- package/dist/src/store/dataFormats.d.ts.map +1 -1
- package/dist/src/store/dataFormats.js +18 -3
- package/dist/src/store/dataFormats.js.map +1 -1
- package/dist/src/sync/DeltaSyncRunner.d.ts.map +1 -1
- package/dist/src/sync/DeltaSyncRunner.js +144 -4
- package/dist/src/sync/DeltaSyncRunner.js.map +1 -1
- package/dist/src/sync/SyncJobQueue.d.ts +7 -2
- package/dist/src/sync/SyncJobQueue.d.ts.map +1 -1
- package/dist/src/sync/SyncJobQueue.js +16 -10
- package/dist/src/sync/SyncJobQueue.js.map +1 -1
- package/dist/src/sync/SyncWatchService.d.ts +21 -4
- package/dist/src/sync/SyncWatchService.d.ts.map +1 -1
- package/dist/src/sync/SyncWatchService.js +115 -10
- package/dist/src/sync/SyncWatchService.js.map +1 -1
- package/dist/src/sync/categoryInference.d.ts +1 -1
- package/dist/src/sync/categoryInference.js +1 -1
- package/dist/src/tools/execCtx.d.ts +2 -2
- package/dist/src/tools/execCtx.js +2 -2
- package/dist/src/tools/fs_read.d.ts.map +1 -1
- package/dist/src/tools/fs_read.js +5 -0
- package/dist/src/tools/fs_read.js.map +1 -1
- package/dist/src/usecases/admitSourceRoot.d.ts +65 -0
- package/dist/src/usecases/admitSourceRoot.d.ts.map +1 -0
- package/dist/src/usecases/admitSourceRoot.js +85 -0
- package/dist/src/usecases/admitSourceRoot.js.map +1 -0
- package/dist/src/usecases/browseSourceFolders.d.ts +85 -0
- package/dist/src/usecases/browseSourceFolders.d.ts.map +1 -0
- package/dist/src/usecases/browseSourceFolders.js +210 -0
- package/dist/src/usecases/browseSourceFolders.js.map +1 -0
- package/dist/src/usecases/createDeclaredSources.d.ts +13 -2
- package/dist/src/usecases/createDeclaredSources.d.ts.map +1 -1
- package/dist/src/usecases/createDeclaredSources.js +39 -0
- package/dist/src/usecases/createDeclaredSources.js.map +1 -1
- package/dist/src/usecases/embeddingBacklog.js +1 -1
- package/dist/src/usecases/embeddingBacklog.js.map +1 -1
- package/dist/src/usecases/list.d.ts.map +1 -1
- package/dist/src/usecases/list.js +83 -26
- package/dist/src/usecases/list.js.map +1 -1
- package/dist/src/usecases/listAttachableDevices.d.ts +13 -0
- package/dist/src/usecases/listAttachableDevices.d.ts.map +1 -0
- package/dist/src/usecases/listAttachableDevices.js +10 -0
- package/dist/src/usecases/listAttachableDevices.js.map +1 -0
- package/dist/src/usecases/listSourcePackages.d.ts.map +1 -1
- package/dist/src/usecases/listSourcePackages.js +2 -5
- package/dist/src/usecases/listSourcePackages.js.map +1 -1
- package/dist/src/usecases/purgeExcludedPoints.d.ts.map +1 -1
- package/dist/src/usecases/purgeExcludedPoints.js +3 -2
- package/dist/src/usecases/purgeExcludedPoints.js.map +1 -1
- package/dist/src/usecases/readFiles.d.ts.map +1 -1
- package/dist/src/usecases/readFiles.js +99 -1
- package/dist/src/usecases/readFiles.js.map +1 -1
- package/dist/src/usecases/reconcileSourcePackageRoots.d.ts +1 -1
- package/dist/src/usecases/reconcileSourcePackageRoots.d.ts.map +1 -1
- package/dist/src/usecases/reconcileSourcePackageRoots.js +2 -1
- package/dist/src/usecases/reconcileSourcePackageRoots.js.map +1 -1
- package/dist/src/usecases/revokePrincipal.d.ts +7 -5
- package/dist/src/usecases/revokePrincipal.d.ts.map +1 -1
- package/dist/src/usecases/revokePrincipal.js +29 -7
- package/dist/src/usecases/revokePrincipal.js.map +1 -1
- package/dist/src/usecases/scheduleSourceSync.d.ts +7 -0
- package/dist/src/usecases/scheduleSourceSync.d.ts.map +1 -1
- package/dist/src/usecases/scheduleSourceSync.js +6 -5
- package/dist/src/usecases/scheduleSourceSync.js.map +1 -1
- package/dist/src/usecases/syncPointWrites.d.ts +2 -0
- package/dist/src/usecases/syncPointWrites.d.ts.map +1 -1
- package/dist/src/usecases/syncPointWrites.js +5 -1
- package/dist/src/usecases/syncPointWrites.js.map +1 -1
- package/dist/src/usecases/triggerSourceSync.d.ts +46 -0
- package/dist/src/usecases/triggerSourceSync.d.ts.map +1 -0
- package/dist/src/usecases/triggerSourceSync.js +75 -0
- package/dist/src/usecases/triggerSourceSync.js.map +1 -0
- package/dist/src/usecases/uploadBinary.d.ts +2 -1
- package/dist/src/usecases/uploadBinary.d.ts.map +1 -1
- package/dist/src/usecases/uploadBinary.js +2 -2
- package/dist/src/usecases/uploadBinary.js.map +1 -1
- package/dist/src/usecases/vector/endpointGuard.d.ts +1 -1
- package/dist/src/usecases/vector/endpointGuard.js +1 -1
- package/dist/src/usecases/vectorMaintenance.js +1 -1
- package/dist/src/usecases/vectorMaintenance.js.map +1 -1
- package/dist/src/usecases/write/content.js +1 -1
- package/dist/src/vector/qdrantClient.d.ts +1 -1
- package/dist/src/vector/qdrantClient.js +1 -1
- package/dist/src/wiring.d.ts +3 -0
- package/dist/src/wiring.d.ts.map +1 -1
- package/dist/src/wiring.js +72 -6
- package/dist/src/wiring.js.map +1 -1
- package/dist/tools/fs_list.json +1 -1
- package/dist/tools/fs_read.json +1 -1
- package/dist/tools/fs_search.json +1 -1
- package/dist/tools/fs_write.json +1 -1
- package/instructions/brain-model.md +1 -1
- package/package.json +212 -114
- package/rules/brain-rules.md +2 -2
- package/skills/brain-start/SKILL.md +1 -1
- package/skills/connect-business-data/SKILL.md +3 -3
- package/skills/create-package/SKILL.md +26 -26
- package/skills/create-package/references/config-and-credentials.md +16 -13
- package/skills/create-package/references/connectors-and-uri-policies.md +39 -25
- package/skills/create-package/references/manifest-and-discovery.md +12 -12
- package/skills/create-package/references/runtime-and-build.md +19 -19
- package/skills/create-package/references/skills-and-context.md +36 -20
- package/skills/create-package/references/surfaces-and-design.md +16 -16
- package/skills/create-package/references/team-and-workflows.md +2 -2
- package/skills/create-package/references/test-and-ship.md +21 -21
- package/skills/create-package/references/tools-and-schemas.md +5 -5
- package/skills/create-package/scripts/{check-package.sh → check-package.mjs} +79 -65
- package/skills/create-package/scripts/{verify-loaded.sh → verify-loaded.mjs} +156 -162
- package/skills/git/SKILL.md +53 -51
- package/skills/manage-files/SKILL.md +22 -25
- package/skills/manage-sources/SKILL.md +128 -87
- package/skills/manage-uri-policy/SKILL.md +18 -15
- package/skills/organize/SKILL.md +1 -1
- package/skills/sync/SKILL.md +3 -3
- package/tools/fs_list.json +1 -1
- package/tools/fs_read.json +1 -1
- package/tools/fs_search.json +1 -1
- package/tools/fs_write.json +1 -1
- package/workflows/sources-digest.json +1 -1
- package/dist/src/connectors/LocalDiskConnector.d.ts +0 -171
- package/dist/src/connectors/LocalDiskConnector.d.ts.map +0 -1
- package/dist/src/connectors/LocalDiskConnector.js +0 -1233
- package/dist/src/connectors/LocalDiskConnector.js.map +0 -1
- package/docs/drive-overview.md +0 -59
- package/skills/manage-files/scripts/copy.sh +0 -7
- package/skills/manage-files/scripts/create.sh +0 -7
- package/skills/manage-files/scripts/mkdir.sh +0 -7
- package/skills/manage-files/scripts/modify.sh +0 -7
- package/skills/manage-files/scripts/upload.sh +0 -16
- package/skills/manage-files/scripts/write.sh +0 -29
- package/skills/manage-sources/scripts/reembed.sh +0 -23
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sourceToHostV1.js","sourceRoot":"","sources":["../../scripts/sourceToHostV1.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,kB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AC,GAAG,CAAC,IAAI;YAAE,SAAS;QACxB,MAAM,kBAAkB,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,GAAG,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;QACtF,OAAO,IAAI,CAAC,CAAC;IACf,CAAC;IACD,OAAO,OAAO,CAAC;AACjB,CAAC"}
|
|
@@ -9,6 +9,6 @@
|
|
|
9
9
|
import type { ChannelSubscribeHandler } from '@neuralis/package-system/contracts';
|
|
10
10
|
export declare const channel = "filesystem";
|
|
11
11
|
/** The feature of the route this channel mirrors (`routes/events.ts`). */
|
|
12
|
-
export declare const feature = "
|
|
12
|
+
export declare const feature = "files.read";
|
|
13
13
|
export declare const subscribe: ChannelSubscribeHandler;
|
|
14
14
|
//# sourceMappingURL=filesystem.d.ts.map
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
import { subscribeFilesystemEventsImpl } from '../routes/helpers.js';
|
|
10
10
|
export const channel = 'filesystem';
|
|
11
11
|
/** The feature of the route this channel mirrors (`routes/events.ts`). */
|
|
12
|
-
export const feature = '
|
|
12
|
+
export const feature = 'files.read';
|
|
13
13
|
export const subscribe = async (session, params, emit, state) => {
|
|
14
14
|
if (params.agentIds.length === 0)
|
|
15
15
|
return () => { };
|
|
@@ -22,19 +22,27 @@ import { type Logger } from '@neuralis/package-system/data';
|
|
|
22
22
|
import type { SourceConfigPort, SourceConfigScope, ScopedSourceConfig } from './types.js';
|
|
23
23
|
import type { SourceConfig } from '../domain/sourceConfig.js';
|
|
24
24
|
import { type PackageSourceRoot } from '../services/declaredSources.js';
|
|
25
|
+
import { type SourceRootPlane } from '../domain/sourceRootPair.js';
|
|
25
26
|
/**
|
|
26
27
|
* Convert a source string to a safe filename slug.
|
|
27
28
|
* "data" → "data", "github:neuralis/Neuralis" → "github-neuralis-Neuralis"
|
|
28
29
|
*/
|
|
29
30
|
declare function sourceSlug(source: string): string;
|
|
30
31
|
export declare const SOURCE_CONFIG_FORMAT_KIND: "brain-core/source-config";
|
|
31
|
-
export declare const SOURCE_CONFIG_FORMAT_VERSION:
|
|
32
|
+
export declare const SOURCE_CONFIG_FORMAT_VERSION: 7;
|
|
32
33
|
export declare class AppSourceConfigStore implements SourceConfigPort {
|
|
33
34
|
#private;
|
|
34
35
|
readonly mutations: SourceConfigMutation;
|
|
35
36
|
private readonly baseDir;
|
|
37
|
+
/**
|
|
38
|
+
* `rootPlane` — the runtime stack's plane facts, read at write time. With it
|
|
39
|
+
* every `upsert` FILLS a missing half of a `local` source's root pair
|
|
40
|
+
* (`fillSourceRootPair`); without it (or before the facts exist) a write
|
|
41
|
+
* stores the config as given. Never overwrites a stored half, never refuses.
|
|
42
|
+
*/
|
|
36
43
|
constructor(appRoot: string, opts?: {
|
|
37
44
|
logger?: Logger;
|
|
45
|
+
rootPlane?: () => SourceRootPlane | null;
|
|
38
46
|
});
|
|
39
47
|
get(scope: SourceConfigScope, source: string): Promise<SourceConfig | null>;
|
|
40
48
|
list(scope: SourceConfigScope): Promise<SourceConfig[]>;
|
|
@@ -49,9 +57,15 @@ export declare class AppSourceConfigStore implements SourceConfigPort {
|
|
|
49
57
|
/**
|
|
50
58
|
* The project's package-source roots off the STRICT persisted listing — for
|
|
51
59
|
* the offline upgrade, which has no runtime and must not read a partial
|
|
52
|
-
* inventory.
|
|
60
|
+
* inventory. Its one consumer (`package-identity-v2`) runs on records as they
|
|
61
|
+
* stood BEFORE the folder kinds were merged — or, on a resumed chain, after
|
|
62
|
+
* `source-to-folder-v1` or `source-to-host-v1` — so the stored shape is read
|
|
63
|
+
* as any of them: an in-process folder is `local`, a device-less `folder` or
|
|
64
|
+
* a device-less `host`, and its package folders are `packageFolders` or the
|
|
65
|
+
* whole source when `recognizesPackages` was set. The runtime listing reads
|
|
66
|
+
* v5 only.
|
|
53
67
|
*/
|
|
54
|
-
listPackageSourceRoots(projectId: string, projectRoot: string): Promise<PackageSourceRoot[]>;
|
|
68
|
+
listPackageSourceRoots(projectId: string, projectRoot: string, isDocker: boolean): Promise<PackageSourceRoot[]>;
|
|
55
69
|
upsert(scope: SourceConfigScope, config: SourceConfig): Promise<SourceConfig>;
|
|
56
70
|
delete(scope: SourceConfigScope, source: string): Promise<boolean>;
|
|
57
71
|
seed(scope: SourceConfigScope, config: SourceConfig): Promise<void>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppSourceConfigStore.d.ts","sourceRoot":"","sources":["../../../src/connectors/AppSourceConfigStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAA2B,KAAK,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AAG/F,OAAO,EAIL,KAAK,MAAM,EACZ,MAAM,+BAA+B,CAAC;AAEvC,OAAO,KAAK,EACV,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EACnB,MAAM,YAAY,CAAC;AACpB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAG9D,OAAO,EAAuB,KAAK,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;
|
|
1
|
+
{"version":3,"file":"AppSourceConfigStore.d.ts","sourceRoot":"","sources":["../../../src/connectors/AppSourceConfigStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAA2B,KAAK,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AAG/F,OAAO,EAIL,KAAK,MAAM,EACZ,MAAM,+BAA+B,CAAC;AAEvC,OAAO,KAAK,EACV,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EACnB,MAAM,YAAY,CAAC;AACpB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAG9D,OAAO,EAAuB,KAAK,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAC7F,OAAO,EAAsB,KAAK,eAAe,EAAE,MAAM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AEK,IAAI,CAAC,KAAK,EAAE,iBAAiB,EAAE,MAAM,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CASxE;CAuBF;AAED,OAAO,EAAE,UAAU,EAAE,CAAC"}
|
|
@@ -25,6 +25,15 @@ import { SOURCE_CONFIG_FORMAT } from '../store/dataFormats.js';
|
|
|
25
25
|
import { validateSourceConfig } from '../domain/sourceConfig.js';
|
|
26
26
|
import { normalizeSource } from '../domain/source.js';
|
|
27
27
|
import { toPackageSourceRoot } from '../services/declaredSources.js';
|
|
28
|
+
import { fillSourceRootPair } from '../domain/sourceRootPair.js';
|
|
29
|
+
import { HOST_SOURCE_KIND } from '@neuralis/package-system/contracts';
|
|
30
|
+
/**
|
|
31
|
+
* The folder kind as records spelled it before `source-to-host-v1`: `local`
|
|
32
|
+
* (in process, v1–v3) and `folder` (either transport, v4). Pinned, offline
|
|
33
|
+
* reads only — a v3 device record (`host`) never reaches this projection
|
|
34
|
+
* unconverted, because `source-device-v1` and `source-to-folder-v1` run first.
|
|
35
|
+
*/
|
|
36
|
+
const PRE_HOST_KINDS = new Set(['local', 'folder']);
|
|
28
37
|
/**
|
|
29
38
|
* Convert a source string to a safe filename slug.
|
|
30
39
|
* "data" → "data", "github:neuralis/Neuralis" → "github-neuralis-Neuralis"
|
|
@@ -38,10 +47,18 @@ export class AppSourceConfigStore {
|
|
|
38
47
|
mutations;
|
|
39
48
|
baseDir;
|
|
40
49
|
#logger;
|
|
50
|
+
#rootPlane;
|
|
51
|
+
/**
|
|
52
|
+
* `rootPlane` — the runtime stack's plane facts, read at write time. With it
|
|
53
|
+
* every `upsert` FILLS a missing half of a `local` source's root pair
|
|
54
|
+
* (`fillSourceRootPair`); without it (or before the facts exist) a write
|
|
55
|
+
* stores the config as given. Never overwrites a stored half, never refuses.
|
|
56
|
+
*/
|
|
41
57
|
constructor(appRoot, opts = {}) {
|
|
42
58
|
this.mutations = sourceConfigMutationFor(path.resolve(appRoot));
|
|
43
59
|
this.baseDir = path.join(appRoot, 'config', 'sources');
|
|
44
60
|
this.#logger = opts.logger ?? noopLogger;
|
|
61
|
+
this.#rootPlane = opts.rootPlane;
|
|
45
62
|
}
|
|
46
63
|
/** A persisted config that failed to load — named once per read, never a path or a value. */
|
|
47
64
|
#warnInvalid(projectId, entry, reason) {
|
|
@@ -80,6 +97,13 @@ export class AppSourceConfigStore {
|
|
|
80
97
|
* Used by connector wiring during bootstrap when no user session exists.
|
|
81
98
|
*/
|
|
82
99
|
async listByProject(projectId, opts = {}) {
|
|
100
|
+
return (await this.#list(projectId, opts)).map(({ config }) => config);
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* The listing behind `listByProject`. `readAs` (the offline projection only)
|
|
104
|
+
* re-spells a record BEFORE validation and keeps the stored kind beside it.
|
|
105
|
+
*/
|
|
106
|
+
async #list(projectId, opts) {
|
|
83
107
|
const dir = this.#projectDir(projectId);
|
|
84
108
|
let listed = false;
|
|
85
109
|
try {
|
|
@@ -101,10 +125,11 @@ export class AppSourceConfigStore {
|
|
|
101
125
|
throw new Error('Source inventory contains a non-regular config');
|
|
102
126
|
}
|
|
103
127
|
const raw = await fs.readFile(path.join(dir, entry), 'utf-8');
|
|
104
|
-
const
|
|
128
|
+
const stored = JSON.parse(raw);
|
|
129
|
+
const parsed = opts.readAs ? opts.readAs(stored) : stored;
|
|
105
130
|
const validation = validateSourceConfig(parsed);
|
|
106
131
|
if (validation.ok)
|
|
107
|
-
configs.push(parsed);
|
|
132
|
+
configs.push({ config: parsed, storedKind: String(stored.connection?.kind ?? '') });
|
|
108
133
|
else {
|
|
109
134
|
if (opts.strict)
|
|
110
135
|
throw new Error('Source inventory contains an invalid config');
|
|
@@ -150,17 +175,32 @@ export class AppSourceConfigStore {
|
|
|
150
175
|
/**
|
|
151
176
|
* The project's package-source roots off the STRICT persisted listing — for
|
|
152
177
|
* the offline upgrade, which has no runtime and must not read a partial
|
|
153
|
-
* inventory.
|
|
178
|
+
* inventory. Its one consumer (`package-identity-v2`) runs on records as they
|
|
179
|
+
* stood BEFORE the folder kinds were merged — or, on a resumed chain, after
|
|
180
|
+
* `source-to-folder-v1` or `source-to-host-v1` — so the stored shape is read
|
|
181
|
+
* as any of them: an in-process folder is `local`, a device-less `folder` or
|
|
182
|
+
* a device-less `host`, and its package folders are `packageFolders` or the
|
|
183
|
+
* whole source when `recognizesPackages` was set. The runtime listing reads
|
|
184
|
+
* v5 only.
|
|
154
185
|
*/
|
|
155
|
-
async listPackageSourceRoots(projectId, projectRoot) {
|
|
156
|
-
|
|
186
|
+
async listPackageSourceRoots(projectId, projectRoot, isDocker) {
|
|
187
|
+
const readAs = (record) => PRE_HOST_KINDS.has(record.connection?.kind)
|
|
188
|
+
? { ...record, connection: { ...record.connection, kind: HOST_SOURCE_KIND } }
|
|
189
|
+
: record;
|
|
190
|
+
return (await this.#list(projectId, { strict: true, readAs })).map(({ config, storedKind }) => {
|
|
191
|
+
const stored = config;
|
|
192
|
+
const packageFolders = stored.recognizesPackages === true ? [''] : (stored.packageFolders ?? []);
|
|
193
|
+
return { ...toPackageSourceRoot(stored, projectRoot, isDocker), packageFolders: [...packageFolders], kind: storedKind };
|
|
194
|
+
});
|
|
157
195
|
}
|
|
158
196
|
// ---------------------------------------------------------------------------
|
|
159
197
|
// Write
|
|
160
198
|
// ---------------------------------------------------------------------------
|
|
161
199
|
async upsert(scope, config) {
|
|
200
|
+
const plane = this.#rootPlane?.() ?? null;
|
|
201
|
+
const cloned = structuredClone(config);
|
|
162
202
|
const normalized = {
|
|
163
|
-
...
|
|
203
|
+
...(plane ? fillSourceRootPair(cloned, plane) : cloned),
|
|
164
204
|
source: normalizeSource(config.source),
|
|
165
205
|
};
|
|
166
206
|
const validation = validateSourceConfig(normalized);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppSourceConfigStore.js","sourceRoot":"","sources":["../../../src/connectors/AppSourceConfigStore.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;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C,yBAAyB,EAAE,MAAM,EAAE,aAAa,EAAE,4BAA4B,CAAC,CAAC;QACnG,MAAM,GAAG,GAAG,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC;QACxC,MAAM,EAAE,CAAC,KAAK,CAAC,GAAG,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC,CAAC;QAEtD,MAAM,QAAQ,GAAG,IAAI,CAAC,SAAS,CAAC,SAAS,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC;QAC1D,MAAM,kBAAkB,CAAC,QAAQ,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;IACtE,CAAC;CACF;AAED,OAAO,EAAE,UAAU,EAAE,CAAC"}
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
import { ConnectorRootAccessError, type ConnectorCapability, type ConnectorChangeEvent, type ConnectorConnectionProbe, type ConnectorCountOpts, type ConnectorDeltaRequest, type ConnectorDeltaResult, type ConnectorEventSubscription, type ConnectorFactory, type ConnectorListItem, type ConnectorMoveResult, type ConnectorPort, type ConnectorReadRawOpts, type ConnectorReadRawResult, type ConnectorReadResult, type ConnectorStatResult, type ConnectorSubscribeOpts, type ConnectorWalkOpts, type ConnectorWriteResult, type HostFsTransport, type PackageReader, type ScanContentOpts, type ScanContentResult, type SourceLiveReason, type DeviceNotReadyCode } from '@neuralis/package-system/contracts';
|
|
2
|
+
/**
|
|
3
|
+
* The capability set of the `host` kind. It MUST equal the `host` connector's
|
|
4
|
+
* `capabilities` array in `package.json#neuralis.connectors` — the loader binds
|
|
5
|
+
* one kind to one set and refuses a drifted instance (boot-fatal for a native
|
|
6
|
+
* connector). `hostCapabilities.test.ts` derives the expectation from the manifest.
|
|
7
|
+
*/
|
|
8
|
+
export declare const HOST_CAPABILITIES: readonly ConnectorCapability[];
|
|
9
|
+
/** How long a `count` is fresh for `peekCount` and `count` (`brainCountCacheTtlMs`); older, `count` serves it while one walk refreshes it. */
|
|
10
|
+
export declare const COUNT_CACHE_TTL_MS = 60000;
|
|
11
|
+
/** Count-cache entries one source keeps (each a key string + two numbers), fresh or stale; past it the oldest goes. */
|
|
12
|
+
export declare const MAX_COUNT_CACHE_ENTRIES = 256;
|
|
13
|
+
/** The folder budget of ONE package folder's watch (a device's broker clamps above). */
|
|
14
|
+
export declare const PACKAGE_FOLDER_WATCH_MAX_FOLDERS = 5000;
|
|
15
|
+
/** One write RPC/syscall carries at most this many bytes; a larger file goes in chunks. */
|
|
16
|
+
export declare const WRITE_CHUNK_BYTES: number;
|
|
17
|
+
/**
|
|
18
|
+
* The source root itself is missing or unreadable — a listing of the ROOT
|
|
19
|
+
* throws this (the abstract base is what routes and services catch); a missing
|
|
20
|
+
* sub-folder lists as empty.
|
|
21
|
+
*/
|
|
22
|
+
export declare class HostRootAccessError extends ConnectorRootAccessError {
|
|
23
|
+
constructor(code: 'ROOT_MISSING' | 'ROOT_PERMISSION_DENIED', rootPath: string, uri: string, cause?: unknown);
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* The fixed code a transport refusal carries (`devices_disabled`,
|
|
27
|
+
* `device_offline`, `others_denied`, `device_owner_ungranted`, …) — never its
|
|
28
|
+
* text, which can name a device path. `undefined` for anything else (an errno,
|
|
29
|
+
* a plain failure): "could not ask" and "gone" stay apart.
|
|
30
|
+
*/
|
|
31
|
+
export declare function transportRefusalReason(error: unknown): string | undefined;
|
|
32
|
+
/** Why a device folder could not serve a call: its plane is down, or the device refused it. */
|
|
33
|
+
export type HostFolderUnavailable = {
|
|
34
|
+
live: false;
|
|
35
|
+
reason: SourceLiveReason;
|
|
36
|
+
notReady?: DeviceNotReadyCode[];
|
|
37
|
+
} | {
|
|
38
|
+
refused: string;
|
|
39
|
+
};
|
|
40
|
+
export type HostConnectorInit = {
|
|
41
|
+
source: string;
|
|
42
|
+
/** Absolute root on the transport's machine, in its flavour. */
|
|
43
|
+
root: string;
|
|
44
|
+
transport: HostFsTransport;
|
|
45
|
+
/**
|
|
46
|
+
* The root as the MACHINE's user sees it (`os_uri`): the device path, the
|
|
47
|
+
* native path, or a Docker mount's host half. `undefined` inside Docker with
|
|
48
|
+
* no host pair ⇒ `resolveOsUri` throws `OsUriUnresolvableError`.
|
|
49
|
+
*/
|
|
50
|
+
osRoot?: string;
|
|
51
|
+
};
|
|
52
|
+
export declare class HostConnector implements ConnectorPort {
|
|
53
|
+
#private;
|
|
54
|
+
readonly kind: "host";
|
|
55
|
+
readonly source: string;
|
|
56
|
+
readonly portVersion: 4;
|
|
57
|
+
constructor(init: HostConnectorInit);
|
|
58
|
+
capabilities(): ReadonlySet<ConnectorCapability>;
|
|
59
|
+
/** The paired device this folder lives on; `undefined` for an in-process folder. */
|
|
60
|
+
get device(): string | undefined;
|
|
61
|
+
/** The root on the folder's OWN machine (a device path for a device folder) — server-side only, never serialized. */
|
|
62
|
+
get root(): string;
|
|
63
|
+
/** The root on THIS process's disk — `undefined` for a device folder (that disk is not ours). */
|
|
64
|
+
get localRoot(): string | undefined;
|
|
65
|
+
/** The transport this folder is reached through (the git engine's exec seam). */
|
|
66
|
+
get transport(): HostFsTransport;
|
|
67
|
+
probeConnection(): Promise<ConnectorConnectionProbe>;
|
|
68
|
+
/**
|
|
69
|
+
* Why a device folder could not serve a call that threw: the plane is down —
|
|
70
|
+
* answered by the SAME probe the listing's `live`/`live_reason` comes from —
|
|
71
|
+
* or the device refused it by its fixed code. `undefined` for an in-process
|
|
72
|
+
* folder and for an error that is no transport refusal: the caller keeps its
|
|
73
|
+
* own answer. One probe on a failure path only (the device verdict is cached).
|
|
74
|
+
*/
|
|
75
|
+
unavailable(error: unknown): Promise<HostFolderUnavailable | undefined>;
|
|
76
|
+
/** Wiring diagnostics (operator log only — the root names a machine path). */
|
|
77
|
+
probeRoot(): Promise<{
|
|
78
|
+
rootPath: string;
|
|
79
|
+
exists: boolean;
|
|
80
|
+
readable: boolean;
|
|
81
|
+
error?: string;
|
|
82
|
+
}>;
|
|
83
|
+
list(uri: string): Promise<ConnectorListItem[]>;
|
|
84
|
+
stat(uri: string): Promise<ConnectorStatResult | null>;
|
|
85
|
+
/**
|
|
86
|
+
* The byte-exact read: the whole file or a refusal, never a prefix or a
|
|
87
|
+
* marker. Cap = `min(opts.maxBytes, brainMaxReadFileMb)`, checked before any
|
|
88
|
+
* byte moves; a file that grows past it while it is read is refused too.
|
|
89
|
+
*/
|
|
90
|
+
readRaw(uri: string, opts: ConnectorReadRawOpts): Promise<ConnectorReadRawResult>;
|
|
91
|
+
/**
|
|
92
|
+
* Bytes `[offset, offset+length)` of one file and the WHOLE file's size — the
|
|
93
|
+
* byte lane's `Range` answer. Moves only that range (in transport-sized
|
|
94
|
+
* pieces); the caller bounds `length`. Not a kernel port member.
|
|
95
|
+
*/
|
|
96
|
+
readByteRange(uri: string, offset: number, length: number): Promise<{
|
|
97
|
+
bytes: Uint8Array;
|
|
98
|
+
size: number;
|
|
99
|
+
mimeType: string;
|
|
100
|
+
}>;
|
|
101
|
+
/**
|
|
102
|
+
* The MODEL read: text decoded, a PDF as its text (or its rendered first
|
|
103
|
+
* page, opt-in), an image/video/audio inline as base64 under its per-MIME
|
|
104
|
+
* cap and as a `[binary file too large…]` marker above it. Same answer on
|
|
105
|
+
* both transports — the PDF helpers run on THIS server over a private copy.
|
|
106
|
+
*/
|
|
107
|
+
read(uri: string): Promise<ConnectorReadResult>;
|
|
108
|
+
/**
|
|
109
|
+
* The sync media lane's PDF read (not a kernel port member): the raw bytes'
|
|
110
|
+
* sha256 and pages `first..last` rendered by the ONE renderer — none when the
|
|
111
|
+
* hash equals `unlessHash`. `null` when `pdftoppm` is not installed.
|
|
112
|
+
*/
|
|
113
|
+
renderPdfPages(uri: string, opts: {
|
|
114
|
+
first: number;
|
|
115
|
+
last: number;
|
|
116
|
+
unlessHash?: string;
|
|
117
|
+
}): Promise<{
|
|
118
|
+
contentHash: string;
|
|
119
|
+
pages: Array<{
|
|
120
|
+
page: number;
|
|
121
|
+
png: Buffer;
|
|
122
|
+
}>;
|
|
123
|
+
} | null>;
|
|
124
|
+
write(uri: string, content: string | Uint8Array): Promise<ConnectorWriteResult>;
|
|
125
|
+
delete(uri: string): Promise<void>;
|
|
126
|
+
move(fromUri: string, toUri: string): Promise<ConnectorMoveResult>;
|
|
127
|
+
mkdir(uri: string): Promise<void>;
|
|
128
|
+
rmdir(uri: string): Promise<void>;
|
|
129
|
+
walk(rootUri: string, opts?: ConnectorWalkOpts): Promise<ConnectorListItem[]>;
|
|
130
|
+
/** `complete` proves absence; `walkWithStatus` exists on BOTH transports (the export's verifier reads it). */
|
|
131
|
+
walkWithStatus(rootUri: string, opts?: ConnectorWalkOpts): Promise<{
|
|
132
|
+
items: ConnectorListItem[];
|
|
133
|
+
complete: boolean;
|
|
134
|
+
truncated: boolean;
|
|
135
|
+
}>;
|
|
136
|
+
/** The last `count` for the same root and options while younger than the TTL — never I/O. */
|
|
137
|
+
peekCount(rootUri: string, opts?: ConnectorCountOpts): number | undefined;
|
|
138
|
+
/**
|
|
139
|
+
* Fresh ⇒ the cached total, or the cached FAILURE rethrown at once (a walk
|
|
140
|
+
* that failed or timed out is not tried again within the TTL; a total from
|
|
141
|
+
* before it is still answered). Expired with a total ⇒ that stale total AT
|
|
142
|
+
* ONCE while one walk refreshes it. Otherwise ⇒ the walk's answer.
|
|
143
|
+
* Concurrent callers of one key share ONE walk.
|
|
144
|
+
*/
|
|
145
|
+
count(rootUri: string, opts?: ConnectorCountOpts): Promise<number>;
|
|
146
|
+
scanContent(rootUri: string, query: string, opts?: ScanContentOpts): Promise<ScanContentResult[]>;
|
|
147
|
+
/**
|
|
148
|
+
* Change events under `rootUri` from a watcher on the folder's own machine
|
|
149
|
+
* (this process's `FsWatchHub`, or the device's broker over its link, re-opened
|
|
150
|
+
* on loss with ONE `overflow {watcher_restarted}`). An `overflow` means event
|
|
151
|
+
* delivery can no longer be trusted — the consumer reconciles the source.
|
|
152
|
+
*/
|
|
153
|
+
subscribeEvents(rootUri: string, listener: (event: ConnectorChangeEvent) => void, opts?: ConnectorSubscribeOpts): ConnectorEventSubscription;
|
|
154
|
+
scanDelta(request: ConnectorDeltaRequest): Promise<ConnectorDeltaResult>;
|
|
155
|
+
/**
|
|
156
|
+
* The machine path of `uri` (`os_uri`): the device's own path for a device
|
|
157
|
+
* folder, the native path, or a Docker mount's host half. Inside Docker with
|
|
158
|
+
* no host pair it THROWS `OsUriUnresolvableError` — never a container path.
|
|
159
|
+
*/
|
|
160
|
+
resolveOsUri(uri: string): string;
|
|
161
|
+
/**
|
|
162
|
+
* The package-byte reader of ONE package folder (`folder` is source-relative,
|
|
163
|
+
* `isPackageFolderPath`). Every path must lie inside `<root>/<folder>` —
|
|
164
|
+
* judged lexically in the folder's own flavour before any call, then by the
|
|
165
|
+
* transport's clamp. Nothing is cached or copied: `readText`/`readBytes` are
|
|
166
|
+
* one bounded read each, `list`/`stat` one call each; `available()` is the
|
|
167
|
+
* transport's (the live link table, no RPC); `watch` rides this folder's own
|
|
168
|
+
* watch plus — on a device — the link's come-and-go.
|
|
169
|
+
*/
|
|
170
|
+
packageReader(folder: string, onReachabilityChange?: (listener: () => void) => () => void): {
|
|
171
|
+
root: string;
|
|
172
|
+
reader: PackageReader;
|
|
173
|
+
};
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* An in-process `host` connector over `root` on this machine. `osRoot` is the
|
|
177
|
+
* root as the machine's user sees it: natively the root itself, in Docker the
|
|
178
|
+
* stored `hostRoot` or the os-mount pair's host half (absent ⇒ `resolveOsUri`
|
|
179
|
+
* throws, never a container path).
|
|
180
|
+
*/
|
|
181
|
+
export declare function inProcessHostConnector(input: {
|
|
182
|
+
source: string;
|
|
183
|
+
root: string;
|
|
184
|
+
osRoot?: string;
|
|
185
|
+
}): HostConnector;
|
|
186
|
+
/**
|
|
187
|
+
* The device half of a `host` source: the stored `root` must be absolute ON
|
|
188
|
+
* THAT DEVICE — its flavour is its own shape (`C:\…` Windows, `/…` POSIX; a
|
|
189
|
+
* drive-relative `C:x` or a UNC share is refused) — and the device's transport
|
|
190
|
+
* comes from agent-core. A root whose shape contradicts the platform the device
|
|
191
|
+
* claimed is refused by agent-core (`openTransport`).
|
|
192
|
+
*/
|
|
193
|
+
export declare function deviceHostRoot(source: string, rawRoot: unknown): string;
|
|
194
|
+
/**
|
|
195
|
+
* The `host` kind's factory — ONE connector class; the STORED config picks the
|
|
196
|
+
* transport (the kernel's `sourcePlane` reads the same field). A device folder
|
|
197
|
+
* without agent-core loaded cannot be served — the binding fails and the source
|
|
198
|
+
* reads as unavailable.
|
|
199
|
+
*/
|
|
200
|
+
export declare const createHostConnector: ConnectorFactory;
|
|
201
|
+
//# sourceMappingURL=HostConnector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"HostConnector.d.ts","sourceRoot":"","sources":["../../../src/connectors/HostConnector.ts"],"names":[],"mappings":"AAwBA,OAAO,EAGL,wBAAwB,EAIxB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,kBAAkB,EAEvB,KAAK,qBAAqB,EAC1B,KAAK,oBAAoB,EACzB,KAAK,0BAA0B,EAC/B,KAAK,gBAAgB,EAErB,KAAK,iBAAiB,EACtB,KAAK,mBAAmB,EACxB,KAAK,aAAa,EAElB,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,oBAAoB,EACzB,KAAK,eAAe,EACpB,KAAK,aAAa,EAElB,KAAK,eAAe,EACpB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACxB,MAAM,oCAAoC,CAAC;AAuB5C;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,EAAE,SAAS,mBAAmB,EAI3D,CAAC;AAEF,8IAA8I;AAC9I,eAA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