@coasys/ad4m 0.13.0-test-flows-1 → 0.13.1-staging.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -0
- package/lib/index.cjs +9613 -7069
- package/lib/index.js +7367 -4840
- package/lib/src/Ad4mClient.d.ts +12 -4
- package/lib/src/Ad4mClient.js +15 -11
- package/lib/src/Literal.js +3 -3
- package/lib/src/agent/Agent.d.ts +4 -1
- package/lib/src/agent/Agent.js +6 -0
- package/lib/src/agent/AgentClient.d.ts +9 -23
- package/lib/src/agent/AgentClient.js +68 -148
- package/lib/src/ai/AIClient.d.ts +10 -6
- package/lib/src/ai/AIClient.js +29 -27
- package/lib/src/apiClient.d.ts +54 -42
- package/lib/src/apiClient.js +279 -252
- package/lib/src/expression/Expression.d.ts +13 -4
- package/lib/src/expression/Expression.js +0 -1
- package/lib/src/expression/ExpressionClient.js +1 -1
- package/lib/src/generated/api/AIPromptExamples.d.ts +4 -0
- package/lib/src/generated/api/AIPromptExamples.js +2 -0
- package/lib/src/generated/api/AIPromptExamplesInput.d.ts +4 -0
- package/lib/src/generated/api/AIPromptExamplesInput.js +2 -0
- package/lib/src/generated/api/AITask.d.ts +11 -0
- package/lib/src/generated/api/AITaskInput.d.ts +8 -0
- package/lib/src/generated/api/AddAgentInfosRequest.d.ts +3 -0
- package/lib/src/generated/api/AddAgentInfosRequest.js +2 -0
- package/lib/src/generated/api/AddLinkExpressionRequest.d.ts +2 -2
- package/lib/src/generated/api/AddLinkRequest.d.ts +2 -2
- package/lib/src/generated/api/AddLinksBulkRequest.d.ts +2 -2
- package/lib/src/generated/api/AddSdnaRequest.d.ts +2 -2
- package/lib/src/generated/api/Agent.d.ts +6 -0
- package/lib/src/generated/api/AgentAddEntanglementProofsParams.d.ts +9 -0
- package/lib/src/generated/api/AgentByDidParams.d.ts +3 -0
- package/lib/src/generated/api/AgentByDidParams.js +2 -0
- package/lib/src/generated/api/AgentRemoveAppParams.d.ts +3 -0
- package/lib/src/generated/api/AgentRemoveAppParams.js +2 -0
- package/lib/src/generated/api/AgentRevokeTokenParams.d.ts +3 -0
- package/lib/src/generated/api/AgentRevokeTokenParams.js +2 -0
- package/lib/src/generated/api/AgentSignature.d.ts +4 -0
- package/lib/src/generated/api/AgentSignature.js +2 -0
- package/lib/src/generated/api/AgentStatus.d.ts +8 -0
- package/lib/src/generated/api/AgentStatusChangedEvent.d.ts +7 -0
- package/lib/src/generated/api/AgentUpdatedEvent.d.ts +7 -0
- package/lib/src/generated/api/AgentsByDidsRequest.d.ts +3 -0
- package/lib/src/generated/api/AgentsByDidsRequest.js +2 -0
- package/lib/src/generated/api/AiAddModelParams.d.ts +4 -0
- package/lib/src/generated/api/AiAddTaskParams.d.ts +4 -0
- package/lib/src/generated/api/AiDiscoverModelsParams.d.ts +8 -0
- package/lib/src/generated/api/AiDiscoverModelsParams.js +2 -0
- package/lib/src/generated/api/AiGetDefaultModelParams.d.ts +4 -0
- package/lib/src/generated/api/AiIdParams.d.ts +3 -0
- package/lib/src/generated/api/AiIdParams.js +2 -0
- package/lib/src/generated/api/AiModelLoadingStatusParams.d.ts +7 -0
- package/lib/src/generated/api/AiModelLoadingStatusParams.js +2 -0
- package/lib/src/generated/api/AiSetDefaultModelParams.d.ts +5 -0
- package/lib/src/generated/api/AiSetDefaultModelParams.js +1 -0
- package/lib/src/generated/api/AiTranscriptionCloseParams.d.ts +3 -0
- package/lib/src/generated/api/AiTranscriptionCloseParams.js +2 -0
- package/lib/src/generated/api/AiTranscriptionOpenParams.d.ts +5 -0
- package/lib/src/generated/api/AiTranscriptionOpenParams.js +1 -0
- package/lib/src/generated/api/AiUpdateModelParams.d.ts +5 -0
- package/lib/src/generated/api/AiUpdateModelParams.js +1 -0
- package/lib/src/generated/api/AiUpdateTaskParams.d.ts +4 -0
- package/lib/src/generated/api/AiUpdateTaskParams.js +1 -0
- package/lib/src/generated/api/Apps.d.ts +7 -0
- package/lib/src/generated/api/Apps.js +1 -0
- package/lib/src/generated/api/AuthInfo.d.ts +10 -0
- package/lib/src/generated/api/AuthInfo.js +1 -0
- package/lib/src/generated/api/AuthInfoInput.d.ts +4 -4
- package/lib/src/generated/api/AutoProcessorEvent.d.ts +89 -0
- package/lib/src/generated/api/AutoProcessorEvent.js +1 -0
- package/lib/src/generated/api/AutoProcessorNeighbourhoodState.d.ts +32 -0
- package/lib/src/generated/api/AutoProcessorNeighbourhoodState.js +1 -0
- package/lib/src/generated/api/AutoProcessorStep.d.ts +7 -0
- package/lib/src/generated/api/AutoProcessorStep.js +2 -0
- package/lib/src/generated/api/BroadcastRequest.d.ts +5 -0
- package/lib/src/generated/api/BroadcastRequest.js +2 -0
- package/lib/src/generated/api/CallSessionInfo.d.ts +23 -0
- package/lib/src/generated/api/CallSessionInfo.js +2 -0
- package/lib/src/generated/api/Capability.d.ts +5 -0
- package/lib/src/generated/api/Capability.js +1 -0
- package/lib/src/generated/api/CreateSubjectRequest.d.ts +2 -2
- package/lib/src/generated/api/CreateUserRequest.d.ts +4 -0
- package/lib/src/generated/api/CreateUserRequest.js +2 -0
- package/lib/src/generated/api/DateTime.d.ts +1 -0
- package/lib/src/generated/api/DateTime.js +2 -0
- package/lib/src/generated/api/DecoratedExpressionProof.d.ts +6 -0
- package/lib/src/generated/api/DecoratedExpressionProof.js +2 -0
- package/lib/src/generated/api/DecoratedLinkExpression.d.ts +10 -0
- package/lib/src/generated/api/DecoratedLinkExpression.js +1 -0
- package/lib/src/generated/api/DecoratedNeighbourhoodExpression.d.ts +8 -0
- package/lib/src/generated/api/DecoratedNeighbourhoodExpression.js +1 -0
- package/lib/src/generated/api/DecoratedPerspective.d.ts +4 -0
- package/lib/src/generated/api/DecoratedPerspective.js +1 -0
- package/lib/src/generated/api/DiscardBatchRequest.d.ts +3 -0
- package/lib/src/generated/api/DiscardBatchRequest.js +2 -0
- package/lib/src/generated/api/DisposeQueryRequest.d.ts +3 -0
- package/lib/src/generated/api/DisposeQueryRequest.js +2 -0
- package/lib/src/generated/api/EntanglementProof.d.ts +8 -0
- package/lib/src/generated/api/EntanglementProof.js +2 -0
- package/lib/src/generated/api/EntanglementProofInput.d.ts +1 -1
- package/lib/src/generated/api/EntanglementProofPreflightRequest.d.ts +4 -0
- package/lib/src/generated/api/EntanglementProofPreflightRequest.js +2 -0
- package/lib/src/generated/api/EntanglementProofsWrapper.d.ts +7 -0
- package/lib/src/generated/api/EntanglementProofsWrapper.js +1 -0
- package/lib/src/generated/api/Events.d.ts +56 -0
- package/lib/src/generated/api/Events.js +18 -0
- package/lib/src/generated/api/ExceptionInfo.d.ts +7 -0
- package/lib/src/generated/api/ExceptionInfo.js +1 -0
- package/lib/src/generated/api/ExceptionOccurredEvent.d.ts +7 -0
- package/lib/src/generated/api/ExceptionOccurredEvent.js +1 -0
- package/lib/src/generated/api/ExceptionType.d.ts +1 -0
- package/lib/src/generated/api/ExceptionType.js +2 -0
- package/lib/src/generated/api/ExecuteCommandsRequest.d.ts +4 -2
- package/lib/src/generated/api/ExportRequest.d.ts +1 -1
- package/lib/src/generated/api/ExpressionInteractRequest.d.ts +5 -0
- package/lib/src/generated/api/ExpressionInteractRequest.js +1 -0
- package/lib/src/generated/api/ExpressionProofInput.d.ts +4 -4
- package/lib/src/generated/api/ExpressionRendered.d.ts +11 -0
- package/lib/src/generated/api/ExpressionRendered.js +1 -0
- package/lib/src/generated/api/ExpressionUrlRequest.d.ts +3 -0
- package/lib/src/generated/api/ExpressionUrlRequest.js +2 -0
- package/lib/src/generated/api/FireOutcome.d.ts +14 -0
- package/lib/src/generated/api/FireOutcome.js +2 -0
- package/lib/src/generated/api/FlowStateChangedEvent.d.ts +38 -0
- package/lib/src/generated/api/FlowStateChangedEvent.js +2 -0
- package/lib/src/generated/api/FlowStateEntry.d.ts +18 -0
- package/lib/src/generated/api/FlowStateEntry.js +2 -0
- package/lib/src/generated/api/FriendSendMessageRequest.d.ts +1 -1
- package/lib/src/generated/api/HostRate.d.ts +7 -0
- package/lib/src/generated/api/HostRate.js +2 -0
- package/lib/src/generated/api/HostingInfoResult.d.ts +13 -0
- package/lib/src/generated/api/HostingInfoResult.js +1 -0
- package/lib/src/generated/api/HostingInfoUser.d.ts +9 -0
- package/lib/src/generated/api/HostingInfoUser.js +2 -0
- package/lib/src/generated/api/HostingRequestPaymentResult.d.ts +4 -0
- package/lib/src/generated/api/HostingRequestPaymentResult.js +2 -0
- package/lib/src/generated/api/HostingUserInfo.d.ts +6 -0
- package/lib/src/generated/api/HostingUserInfo.js +2 -0
- package/lib/src/generated/api/HostingVersionInfo.d.ts +7 -0
- package/lib/src/generated/api/HostingVersionInfo.js +2 -0
- package/lib/src/generated/api/HostingWalletResult.d.ts +8 -0
- package/lib/src/generated/api/HostingWalletResult.js +1 -0
- package/lib/src/generated/api/IceServer.d.ts +18 -0
- package/lib/src/generated/api/IceServer.js +2 -0
- package/lib/src/generated/api/Icon.d.ts +3 -0
- package/lib/src/generated/api/Icon.js +2 -0
- package/lib/src/generated/api/ImportResult.d.ts +15 -0
- package/lib/src/generated/api/ImportResult.js +1 -0
- package/lib/src/generated/api/ImportStats.d.ts +7 -0
- package/lib/src/generated/api/ImportStats.js +2 -0
- package/lib/src/generated/api/InteractionCall.d.ts +4 -0
- package/lib/src/generated/api/InteractionCall.js +2 -0
- package/lib/src/generated/api/InteractionCallWrapper.d.ts +6 -0
- package/lib/src/generated/api/InteractionCallWrapper.js +2 -0
- package/lib/src/generated/api/InteractionMeta.d.ts +6 -0
- package/lib/src/generated/api/InteractionMeta.js +1 -0
- package/lib/src/generated/api/InteractionParameter.d.ts +4 -0
- package/lib/src/generated/api/InteractionParameter.js +2 -0
- package/lib/src/generated/api/LanguageAddressParams.d.ts +3 -0
- package/lib/src/generated/api/LanguageAddressParams.js +2 -0
- package/lib/src/generated/api/LanguageHandle.d.ts +9 -0
- package/lib/src/generated/api/LanguageHandle.js +1 -0
- package/lib/src/generated/api/LanguageListParams.d.ts +3 -0
- package/lib/src/generated/api/LanguageListParams.js +2 -0
- package/lib/src/generated/api/LanguageMeta.d.ts +11 -0
- package/lib/src/generated/api/LanguageMeta.js +2 -0
- package/lib/src/generated/api/LanguageMetaInput.d.ts +2 -2
- package/lib/src/generated/api/LanguageRef.d.ts +4 -0
- package/lib/src/generated/api/LanguageRef.js +2 -0
- package/lib/src/generated/api/LanguageSettingsWrapper.d.ts +6 -0
- package/lib/src/generated/api/LanguageSettingsWrapper.js +2 -0
- package/lib/src/generated/api/LanguageWriteSettingsParams.d.ts +4 -0
- package/lib/src/generated/api/LanguageWriteSettingsParams.js +2 -0
- package/lib/src/generated/api/LinkExpressionInput.d.ts +1 -1
- package/lib/src/generated/api/LinkInput.d.ts +1 -1
- package/lib/src/generated/api/LinkMutationRequest.d.ts +12 -0
- package/lib/src/generated/api/LinkMutationRequest.js +1 -0
- package/lib/src/generated/api/LinkMutationsRequest.d.ts +5 -0
- package/lib/src/generated/api/LinkMutationsRequest.js +1 -0
- package/lib/src/generated/api/LinkStatus.d.ts +1 -1
- package/lib/src/generated/api/LinkUpdateInput.d.ts +5 -0
- package/lib/src/generated/api/LinkUpdateInput.js +1 -0
- package/lib/src/generated/api/LocalModel.d.ts +7 -0
- package/lib/src/generated/api/LocalModel.js +1 -0
- package/lib/src/generated/api/LocalModelInput.d.ts +7 -0
- package/lib/src/generated/api/LocalModelInput.js +1 -0
- package/lib/src/generated/api/MessageReceivedEvent.d.ts +7 -0
- package/lib/src/generated/api/MessageReceivedEvent.js +1 -0
- package/lib/src/generated/api/Model.d.ts +10 -0
- package/lib/src/generated/api/Model.js +1 -0
- package/lib/src/generated/api/ModelApi.d.ts +17 -0
- package/lib/src/generated/api/ModelApi.js +1 -0
- package/lib/src/generated/api/ModelApiInput.d.ts +11 -0
- package/lib/src/generated/api/ModelApiInput.js +2 -0
- package/lib/src/generated/api/ModelApiType.d.ts +1 -0
- package/lib/src/generated/api/ModelApiType.js +2 -0
- package/lib/src/generated/api/ModelInput.d.ts +9 -0
- package/lib/src/generated/api/ModelInput.js +1 -0
- package/lib/src/generated/api/ModelType.d.ts +1 -1
- package/lib/src/generated/api/Neighbourhood.d.ts +5 -0
- package/lib/src/generated/api/Neighbourhood.js +1 -0
- package/lib/src/generated/api/NeighbourhoodBroadcastParams.d.ts +7 -0
- package/lib/src/generated/api/NeighbourhoodBroadcastParams.js +1 -0
- package/lib/src/generated/api/NeighbourhoodOnlineStatusParams.d.ts +6 -0
- package/lib/src/generated/api/NeighbourhoodOnlineStatusParams.js +1 -0
- package/lib/src/generated/api/NeighbourhoodPerspectivePayload.d.ts +7 -0
- package/lib/src/generated/api/NeighbourhoodPerspectivePayload.js +1 -0
- package/lib/src/generated/api/NeighbourhoodPhase.d.ts +6 -0
- package/lib/src/generated/api/NeighbourhoodPhase.js +2 -0
- package/lib/src/generated/api/NeighbourhoodSignalFilter.d.ts +8 -0
- package/lib/src/generated/api/NeighbourhoodSignalFilter.js +1 -0
- package/lib/src/generated/api/NeighbourhoodSignalParams.d.ts +7 -0
- package/lib/src/generated/api/NeighbourhoodSignalParams.js +1 -0
- package/lib/src/generated/api/NeighbourhoodSignedPerspective.d.ts +8 -0
- package/lib/src/generated/api/NeighbourhoodSignedPerspective.js +1 -0
- package/lib/src/generated/api/NeighbourhoodUuidParams.d.ts +3 -0
- package/lib/src/generated/api/NeighbourhoodUuidParams.js +2 -0
- package/lib/src/generated/api/Notification.d.ts +16 -0
- package/lib/src/generated/api/Notification.js +2 -0
- package/lib/src/generated/api/NotificationGrantRequest.d.ts +6 -0
- package/lib/src/generated/api/NotificationGrantRequest.js +2 -0
- package/lib/src/generated/api/NotificationInput.d.ts +1 -1
- package/lib/src/generated/api/NotificationTriggeredEvent.d.ts +9 -0
- package/lib/src/generated/api/NotificationTriggeredEvent.js +1 -0
- package/lib/src/generated/api/OnlineAgent.d.ts +9 -0
- package/lib/src/generated/api/OnlineAgent.js +1 -0
- package/lib/src/generated/api/OutputRef.d.ts +12 -0
- package/lib/src/generated/api/OutputRef.js +2 -0
- package/lib/src/generated/api/OverlayView.d.ts +24 -0
- package/lib/src/generated/api/OverlayView.js +1 -0
- package/lib/src/generated/api/Perspective.d.ts +4 -0
- package/lib/src/generated/api/Perspective.js +1 -0
- package/lib/src/generated/api/PerspectiveAddAutoProcessorParams.d.ts +26 -0
- package/lib/src/generated/api/PerspectiveAddAutoProcessorParams.js +2 -0
- package/lib/src/generated/api/PerspectiveAddLinkExpressionParams.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveAddLinkExpressionParams.js +1 -0
- package/lib/src/generated/api/PerspectiveAddLinkParams.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveAddLinkParams.js +1 -0
- package/lib/src/generated/api/PerspectiveAddLinksParams.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveAddLinksParams.js +1 -0
- package/lib/src/generated/api/PerspectiveAddSdnaParams.d.ts +14 -0
- package/lib/src/generated/api/PerspectiveAddSdnaParams.js +1 -0
- package/lib/src/generated/api/PerspectiveAddSdnaResult.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveAddSdnaResult.js +2 -0
- package/lib/src/generated/api/PerspectiveCommitBatchParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveCommitBatchParams.js +2 -0
- package/lib/src/generated/api/PerspectiveCreateSubjectParams.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveCreateSubjectParams.js +2 -0
- package/lib/src/generated/api/PerspectiveDiscardBatchParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveDiscardBatchParams.js +2 -0
- package/lib/src/generated/api/PerspectiveEvaluateGettersParams.d.ts +9 -0
- package/lib/src/generated/api/PerspectiveEvaluateGettersParams.js +2 -0
- package/lib/src/generated/api/PerspectiveExecuteCommandsParams.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveExecuteCommandsParams.js +2 -0
- package/lib/src/generated/api/PerspectiveExpression.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveExpression.js +1 -0
- package/lib/src/generated/api/PerspectiveFlowFiredParams.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveFlowFiredParams.js +2 -0
- package/lib/src/generated/api/PerspectiveFlowProposalParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveFlowProposalParams.js +2 -0
- package/lib/src/generated/api/PerspectiveFlowReceiptVerdict.d.ts +12 -0
- package/lib/src/generated/api/PerspectiveFlowReceiptVerdict.js +1 -0
- package/lib/src/generated/api/PerspectiveFlowStatesParams.d.ts +11 -0
- package/lib/src/generated/api/PerspectiveFlowStatesParams.js +2 -0
- package/lib/src/generated/api/PerspectiveFlowValidOutputsParams.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveFlowValidOutputsParams.js +2 -0
- package/lib/src/generated/api/PerspectiveGetAllShaclParams.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveGetAllShaclParams.js +2 -0
- package/lib/src/generated/api/PerspectiveGetSubjectDataParams.d.ts +5 -0
- package/lib/src/generated/api/PerspectiveGetSubjectDataParams.js +2 -0
- package/lib/src/generated/api/PerspectiveHandle.d.ts +10 -0
- package/lib/src/generated/api/PerspectiveHandle.js +1 -0
- package/lib/src/generated/api/PerspectiveLinkDiff.d.ts +9 -0
- package/lib/src/generated/api/PerspectiveLinkDiff.js +1 -0
- package/lib/src/generated/api/PerspectiveLinkMutationsParams.d.ts +6 -0
- package/lib/src/generated/api/PerspectiveLinkMutationsParams.js +1 -0
- package/lib/src/generated/api/PerspectiveLinkUpdatedWithOwner.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveLinkUpdatedWithOwner.js +1 -0
- package/lib/src/generated/api/PerspectiveLinkWithOwner.d.ts +6 -0
- package/lib/src/generated/api/PerspectiveLinkWithOwner.js +1 -0
- package/lib/src/generated/api/PerspectiveMintFlowReceiptParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveMintFlowReceiptParams.js +2 -0
- package/lib/src/generated/api/PerspectiveMintFlowReceiptResult.d.ts +9 -0
- package/lib/src/generated/api/PerspectiveMintFlowReceiptResult.js +1 -0
- package/lib/src/generated/api/PerspectiveModelQueryParams.d.ts +13 -0
- package/lib/src/generated/api/PerspectiveModelQueryParams.js +2 -0
- package/lib/src/generated/api/PerspectiveNamedShacl.d.ts +6 -0
- package/lib/src/generated/api/PerspectiveNamedShacl.js +1 -0
- package/lib/src/generated/api/PerspectiveProposeFlowTransitionParams.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveProposeFlowTransitionParams.js +1 -0
- package/lib/src/generated/api/PerspectiveQueryLinksParams.d.ts +15 -0
- package/lib/src/generated/api/PerspectiveQueryLinksParams.js +2 -0
- package/lib/src/generated/api/PerspectiveQueryParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveQueryParams.js +2 -0
- package/lib/src/generated/api/PerspectiveReceiptOutcome.d.ts +1 -0
- package/lib/src/generated/api/PerspectiveReceiptOutcome.js +2 -0
- package/lib/src/generated/api/PerspectiveRejectFlowProposalResult.d.ts +3 -0
- package/lib/src/generated/api/PerspectiveRejectFlowProposalResult.js +2 -0
- package/lib/src/generated/api/PerspectiveRemoveAutoProcessorParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveRemoveAutoProcessorParams.js +2 -0
- package/lib/src/generated/api/PerspectiveRemoveLinkParams.d.ts +6 -0
- package/lib/src/generated/api/PerspectiveRemoveLinkParams.js +1 -0
- package/lib/src/generated/api/PerspectiveRemoveLinksParams.d.ts +6 -0
- package/lib/src/generated/api/PerspectiveRemoveLinksParams.js +1 -0
- package/lib/src/generated/api/PerspectiveRemoveSubjectParams.d.ts +6 -0
- package/lib/src/generated/api/PerspectiveRemoveSubjectParams.js +2 -0
- package/lib/src/generated/api/PerspectiveRemovedWithOwner.d.ts +5 -0
- package/lib/src/generated/api/PerspectiveRemovedWithOwner.js +2 -0
- package/lib/src/generated/api/PerspectiveResolveInterpretationParams.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveResolveInterpretationParams.js +2 -0
- package/lib/src/generated/api/PerspectiveResynced.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveResynced.js +2 -0
- package/lib/src/generated/api/PerspectiveShacl.d.ts +5 -0
- package/lib/src/generated/api/PerspectiveShacl.js +1 -0
- package/lib/src/generated/api/PerspectiveShaclNameParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveShaclNameParams.js +2 -0
- package/lib/src/generated/api/PerspectiveSparqlParams.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveSparqlParams.js +2 -0
- package/lib/src/generated/api/PerspectiveState.d.ts +1 -0
- package/lib/src/generated/api/PerspectiveState.js +2 -0
- package/lib/src/generated/api/PerspectiveStateFilter.d.ts +7 -0
- package/lib/src/generated/api/PerspectiveStateFilter.js +1 -0
- package/lib/src/generated/api/PerspectiveSubjectClassesOfParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveSubjectClassesOfParams.js +2 -0
- package/lib/src/generated/api/PerspectiveSubscribed.d.ts +10 -0
- package/lib/src/generated/api/PerspectiveSubscribed.js +2 -0
- package/lib/src/generated/api/PerspectiveSubscriptionParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveSubscriptionParams.js +2 -0
- package/lib/src/generated/api/PerspectiveUnsignedInput.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveUnsignedInput.js +1 -0
- package/lib/src/generated/api/PerspectiveUpdateLinkParams.d.ts +8 -0
- package/lib/src/generated/api/PerspectiveUpdateLinkParams.js +1 -0
- package/lib/src/generated/api/PerspectiveUpdateParams.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveUpdateParams.js +2 -0
- package/lib/src/generated/api/PerspectiveUpdateSubjectParams.d.ts +10 -0
- package/lib/src/generated/api/PerspectiveUpdateSubjectParams.js +2 -0
- package/lib/src/generated/api/PerspectiveUuidParams.d.ts +3 -0
- package/lib/src/generated/api/PerspectiveUuidParams.js +2 -0
- package/lib/src/generated/api/PerspectiveVerifyFlowReceiptParams.d.ts +9 -0
- package/lib/src/generated/api/PerspectiveVerifyFlowReceiptParams.js +1 -0
- package/lib/src/generated/api/PerspectiveWithOwner.d.ts +6 -0
- package/lib/src/generated/api/PerspectiveWithOwner.js +1 -0
- package/lib/src/generated/api/ProposeOutcome.d.ts +45 -0
- package/lib/src/generated/api/ProposeOutcome.js +1 -0
- package/lib/src/generated/api/PublicPerspectiveInput.d.ts +4 -0
- package/lib/src/generated/api/PublicPerspectiveInput.js +1 -0
- package/lib/src/generated/api/PublishNeighbourhoodRequest.d.ts +2 -2
- package/lib/src/generated/api/QuerySubscriptionUpdate.d.ts +19 -0
- package/lib/src/generated/api/QuerySubscriptionUpdate.js +2 -0
- package/lib/src/generated/api/QuerySubscriptionUpdateEvent.d.ts +7 -0
- package/lib/src/generated/api/QuerySubscriptionUpdateEvent.js +1 -0
- package/lib/src/generated/api/QueryUpdatesLagged.d.ts +7 -0
- package/lib/src/generated/api/QueryUpdatesLagged.js +2 -0
- package/lib/src/generated/api/RemoveLinkRequest.d.ts +1 -1
- package/lib/src/generated/api/RemoveLinksBulkRequest.d.ts +1 -1
- package/lib/src/generated/api/RemoveSubjectRequest.d.ts +9 -0
- package/lib/src/generated/api/RemoveSubjectRequest.js +2 -0
- package/lib/src/generated/api/RequestCapabilityRequest.d.ts +4 -0
- package/lib/src/generated/api/RequestCapabilityRequest.js +1 -0
- package/lib/src/generated/api/RequestPaymentRequest.d.ts +3 -0
- package/lib/src/generated/api/RequestPaymentRequest.js +2 -0
- package/lib/src/generated/api/Resource.d.ts +4 -0
- package/lib/src/generated/api/Resource.js +2 -0
- package/lib/src/generated/api/ResyncSubscriptionRequest.d.ts +3 -0
- package/lib/src/generated/api/ResyncSubscriptionRequest.js +2 -0
- package/lib/src/generated/api/RpcMethods.d.ts +961 -0
- package/lib/src/generated/api/RpcMethods.js +98 -0
- package/lib/src/generated/api/RunInterpretationRequest.d.ts +27 -1
- package/lib/src/generated/api/RunInterpretationWithHarnessRequest.d.ts +52 -0
- package/lib/src/generated/api/RunInterpretationWithHarnessRequest.js +1 -0
- package/lib/src/generated/api/RuntimeComputeLogParams.d.ts +14 -0
- package/lib/src/generated/api/RuntimeComputeLogParams.js +2 -0
- package/lib/src/generated/api/RuntimeFriendStatusParams.d.ts +3 -0
- package/lib/src/generated/api/RuntimeFriendStatusParams.js +2 -0
- package/lib/src/generated/api/RuntimeGrantNotificationParams.d.ts +4 -0
- package/lib/src/generated/api/RuntimeGrantNotificationParams.js +2 -0
- package/lib/src/generated/api/RuntimeImportPerspectiveResult.d.ts +4 -0
- package/lib/src/generated/api/RuntimeImportPerspectiveResult.js +2 -0
- package/lib/src/generated/api/RuntimeImportResult.d.ts +6 -0
- package/lib/src/generated/api/RuntimeImportResult.js +1 -0
- package/lib/src/generated/api/RuntimeInfo.d.ts +5 -0
- package/lib/src/generated/api/RuntimeInfo.js +2 -0
- package/lib/src/generated/api/RuntimeNotificationIdParams.d.ts +3 -0
- package/lib/src/generated/api/RuntimeNotificationIdParams.js +2 -0
- package/lib/src/generated/api/RuntimeSendFriendMessageParams.d.ts +8 -0
- package/lib/src/generated/api/RuntimeSendFriendMessageParams.js +1 -0
- package/lib/src/generated/api/RuntimeSetFreeHostingEnabledParams.d.ts +3 -0
- package/lib/src/generated/api/RuntimeSetFreeHostingEnabledParams.js +2 -0
- package/lib/src/generated/api/RuntimeUnytSendHotParams.d.ts +4 -0
- package/lib/src/generated/api/RuntimeUnytSendHotParams.js +2 -0
- package/lib/src/generated/api/RuntimeUnytWalletHistoryParams.d.ts +4 -0
- package/lib/src/generated/api/RuntimeUnytWalletHistoryParams.js +2 -0
- package/lib/src/generated/api/RuntimeUpdateNotificationParams.d.ts +11 -0
- package/lib/src/generated/api/RuntimeUpdateNotificationParams.js +2 -0
- package/lib/src/generated/api/SentMessage.d.ts +5 -0
- package/lib/src/generated/api/SentMessage.js +1 -0
- package/lib/src/generated/api/SetHostRatesRequest.d.ts +4 -0
- package/lib/src/generated/api/SetHostRatesRequest.js +1 -0
- package/lib/src/generated/api/SetHotWalletAddressRequest.d.ts +3 -0
- package/lib/src/generated/api/SetHotWalletAddressRequest.js +2 -0
- package/lib/src/generated/api/SetOnlineStatusRequest.d.ts +4 -0
- package/lib/src/generated/api/SetOnlineStatusRequest.js +2 -0
- package/lib/src/generated/api/SetUnytMembraneProofRequest.d.ts +6 -0
- package/lib/src/generated/api/SetUnytMembraneProofRequest.js +2 -0
- package/lib/src/generated/api/SetUserFreeAccessRequest.d.ts +4 -0
- package/lib/src/generated/api/SetUserFreeAccessRequest.js +2 -0
- package/lib/src/generated/api/SfuAddIceCandidateParams.d.ts +8 -0
- package/lib/src/generated/api/SfuAddIceCandidateParams.js +2 -0
- package/lib/src/generated/api/SfuAnswerServerOfferParams.d.ts +8 -0
- package/lib/src/generated/api/SfuAnswerServerOfferParams.js +2 -0
- package/lib/src/generated/api/SfuCallJoinParams.d.ts +14 -0
- package/lib/src/generated/api/SfuCallJoinParams.js +2 -0
- package/lib/src/generated/api/SfuCallRenegotiationOffer.d.ts +30 -0
- package/lib/src/generated/api/SfuCallRenegotiationOffer.js +1 -0
- package/lib/src/generated/api/SfuCascadePipe.d.ts +4 -0
- package/lib/src/generated/api/SfuCascadePipe.js +2 -0
- package/lib/src/generated/api/SfuCascadeStatus.d.ts +8 -0
- package/lib/src/generated/api/SfuCascadeStatus.js +1 -0
- package/lib/src/generated/api/SfuConfig.d.ts +52 -0
- package/lib/src/generated/api/SfuConfig.js +1 -0
- package/lib/src/generated/api/SfuDataMessage.d.ts +24 -0
- package/lib/src/generated/api/SfuDataMessage.js +2 -0
- package/lib/src/generated/api/SfuEnsureMembershipParams.d.ts +4 -0
- package/lib/src/generated/api/SfuEnsureMembershipParams.js +2 -0
- package/lib/src/generated/api/SfuMigrateEvent.d.ts +21 -0
- package/lib/src/generated/api/SfuMigrateEvent.js +2 -0
- package/lib/src/generated/api/SfuNeighbourhoodParams.d.ts +3 -0
- package/lib/src/generated/api/SfuNeighbourhoodParams.js +2 -0
- package/lib/src/generated/api/SfuParticipantQualityPreference.d.ts +7 -0
- package/lib/src/generated/api/SfuParticipantQualityPreference.js +2 -0
- package/lib/src/generated/api/SfuPerspectiveParams.d.ts +6 -0
- package/lib/src/generated/api/SfuPerspectiveParams.js +2 -0
- package/lib/src/generated/api/SfuQualityPreferenceParams.d.ts +8 -0
- package/lib/src/generated/api/SfuQualityPreferenceParams.js +2 -0
- package/lib/src/generated/api/SfuRoomInfo.d.ts +11 -0
- package/lib/src/generated/api/SfuRoomInfo.js +1 -0
- package/lib/src/generated/api/SfuRoomParams.d.ts +4 -0
- package/lib/src/generated/api/SfuRoomParams.js +2 -0
- package/lib/src/generated/api/SfuRoomParticipantInfo.d.ts +11 -0
- package/lib/src/generated/api/SfuRoomParticipantInfo.js +2 -0
- package/lib/src/generated/api/SfuRoomRoster.d.ts +13 -0
- package/lib/src/generated/api/SfuRoomRoster.js +2 -0
- package/lib/src/generated/api/SfuSendDataParams.d.ts +10 -0
- package/lib/src/generated/api/SfuSendDataParams.js +2 -0
- package/lib/src/generated/api/SfuSetConfigParams.d.ts +5 -0
- package/lib/src/generated/api/SfuSetConfigParams.js +1 -0
- package/lib/src/generated/api/SfuStatus.d.ts +24 -0
- package/lib/src/generated/api/SfuStatus.js +2 -0
- package/lib/src/generated/api/ShaclLinkTriple.d.ts +10 -0
- package/lib/src/generated/api/ShaclLinkTriple.js +2 -0
- package/lib/src/generated/api/SignalRequest.d.ts +5 -0
- package/lib/src/generated/api/SignalRequest.js +2 -0
- package/lib/src/generated/api/SubscribeQueryRequest.d.ts +3 -0
- package/lib/src/generated/api/SubscribeQueryRequest.js +2 -0
- package/lib/src/generated/api/TokenizerSource.d.ts +5 -0
- package/lib/src/generated/api/TokenizerSource.js +2 -0
- package/lib/src/generated/api/TokenizerSourceInput.d.ts +5 -0
- package/lib/src/generated/api/TokenizerSourceInput.js +2 -0
- package/lib/src/generated/api/TrackMapEntry.d.ts +17 -0
- package/lib/src/generated/api/TrackMapEntry.js +2 -0
- package/lib/src/generated/api/TranscriptionTextFilter.d.ts +5 -0
- package/lib/src/generated/api/TranscriptionTextFilter.js +2 -0
- package/lib/src/generated/api/TriggeredNotification.d.ts +6 -0
- package/lib/src/generated/api/TriggeredNotification.js +1 -0
- package/lib/src/generated/api/TrustedAgentsWrapper.d.ts +6 -0
- package/lib/src/generated/api/TrustedAgentsWrapper.js +2 -0
- package/lib/src/generated/api/UnlockAgentRequest.d.ts +1 -1
- package/lib/src/generated/api/UnytVersionInfo.d.ts +19 -0
- package/lib/src/generated/api/UnytVersionInfo.js +2 -0
- package/lib/src/generated/api/UpdateLinkRequest.d.ts +1 -1
- package/lib/src/generated/api/UpdateProfileRequest.d.ts +5 -0
- package/lib/src/generated/api/UpdateProfileRequest.js +1 -0
- package/lib/src/generated/api/UpdateSubjectRequest.d.ts +12 -0
- package/lib/src/generated/api/UpdateSubjectRequest.js +2 -0
- package/lib/src/generated/api/UserCreationResult.d.ts +5 -0
- package/lib/src/generated/api/UserCreationResult.js +2 -0
- package/lib/src/generated/api/UserStatistics.d.ts +2 -1
- package/lib/src/generated/api/UserStatistics.js +0 -1
- package/lib/src/generated/api/UsersAppInfo.d.ts +6 -0
- package/lib/src/generated/api/UsersAppInfo.js +2 -0
- package/lib/src/generated/api/UsersEmailParams.d.ts +3 -0
- package/lib/src/generated/api/UsersEmailParams.js +2 -0
- package/lib/src/generated/api/UsersEmailTestAction.d.ts +1 -0
- package/lib/src/generated/api/UsersEmailTestAction.js +2 -0
- package/lib/src/generated/api/UsersEmailTestParams.d.ts +14 -0
- package/lib/src/generated/api/UsersEmailTestParams.js +1 -0
- package/lib/src/generated/api/UsersEmailTestResult.d.ts +5 -0
- package/lib/src/generated/api/UsersEmailTestResult.js +2 -0
- package/lib/src/generated/api/UsersLoginParams.d.ts +8 -0
- package/lib/src/generated/api/UsersLoginParams.js +2 -0
- package/lib/src/generated/api/UsersRequestVerificationParams.d.ts +5 -0
- package/lib/src/generated/api/UsersRequestVerificationParams.js +1 -0
- package/lib/src/generated/api/UsersSetCreditsParams.d.ts +4 -0
- package/lib/src/generated/api/UsersSetCreditsParams.js +2 -0
- package/lib/src/generated/api/UsersVerifyEmailParams.d.ts +12 -0
- package/lib/src/generated/api/UsersVerifyEmailParams.js +2 -0
- package/lib/src/generated/api/ValidOutput.d.ts +29 -0
- package/lib/src/generated/api/ValidOutput.js +1 -0
- package/lib/src/generated/api/VoiceActivityParamsInput.d.ts +7 -0
- package/lib/src/generated/api/VoiceActivityParamsInput.js +2 -0
- package/lib/src/generated/api/index.d.ts +11 -0
- package/lib/src/generated/api/index.js +5 -3
- package/lib/src/generated/api/serde_json/JsonValue.d.ts +3 -0
- package/lib/src/generated/api/serde_json/JsonValue.js +2 -0
- package/lib/src/index.d.ts +9 -3
- package/lib/src/index.js +5 -3
- package/lib/src/language/LanguageClient.d.ts +3 -3
- package/lib/src/language/LanguageClient.js +6 -6
- package/lib/src/language/LanguageMeta.d.ts +1 -1
- package/lib/src/links/Links.d.ts +16 -5
- package/lib/src/links/Links.js +34 -0
- package/lib/src/model/Ad4mModel.d.ts +84 -0
- package/lib/src/model/Ad4mModel.js +365 -72
- package/lib/src/model/ModelQueryBuilder.d.ts +15 -13
- package/lib/src/model/ModelQueryBuilder.js +78 -221
- package/lib/src/model/decorators.d.ts +52 -2
- package/lib/src/model/decorators.js +83 -8
- package/lib/src/model/query-sparql.js +2 -3
- package/lib/src/model/shacl-gen.d.ts +3 -1
- package/lib/src/model/shacl-gen.js +40 -10
- package/lib/src/model/types.d.ts +19 -0
- package/lib/src/neighbourhood/MeshManager.d.ts +384 -0
- package/lib/src/neighbourhood/MeshManager.js +1144 -0
- package/lib/src/neighbourhood/Neighbourhood.d.ts +1 -1
- package/lib/src/neighbourhood/NeighbourhoodClient.d.ts +96 -5
- package/lib/src/neighbourhood/NeighbourhoodClient.js +211 -15
- package/lib/src/neighbourhood/NeighbourhoodProxy.d.ts +55 -1
- package/lib/src/neighbourhood/NeighbourhoodProxy.js +170 -3
- package/lib/src/neighbourhood/Session.d.ts +105 -0
- package/lib/src/neighbourhood/Session.js +412 -0
- package/lib/src/neighbourhood/SfuManager.d.ts +174 -0
- package/lib/src/neighbourhood/SfuManager.js +619 -0
- package/lib/src/neighbourhood/SfuTypes.d.ts +35 -0
- package/lib/src/neighbourhood/SfuTypes.js +8 -0
- package/lib/src/notifyListeners.d.ts +2 -0
- package/lib/src/notifyListeners.js +12 -0
- package/lib/src/perspectives/AutoProcessor.d.ts +12 -80
- package/lib/src/perspectives/FlowInstance.d.ts +73 -26
- package/lib/src/perspectives/FlowInstance.js +96 -31
- package/lib/src/perspectives/FlowModels.d.ts +30 -9
- package/lib/src/perspectives/FlowModels.js +43 -14
- package/lib/src/perspectives/InterpretationModels.d.ts +2 -0
- package/lib/src/perspectives/InterpretationModels.js +6 -0
- package/lib/src/perspectives/LiveQuery.d.ts +49 -0
- package/lib/src/perspectives/LiveQuery.js +169 -0
- package/lib/src/perspectives/Perspective.d.ts +8 -1
- package/lib/src/perspectives/Perspective.js +11 -0
- package/lib/src/perspectives/PerspectiveClient.d.ts +38 -65
- package/lib/src/perspectives/PerspectiveClient.js +87 -257
- package/lib/src/perspectives/PerspectiveDiff.d.ts +1 -1
- package/lib/src/perspectives/PerspectiveHandle.d.ts +15 -8
- package/lib/src/perspectives/PerspectiveHandle.js +25 -9
- package/lib/src/perspectives/PerspectiveProxy.d.ts +102 -228
- package/lib/src/perspectives/PerspectiveProxy.js +247 -673
- package/lib/src/perspectives/TextContent.d.ts +31 -0
- package/lib/src/perspectives/TextContent.js +52 -0
- package/lib/src/perspectives/WakerSubscriptionManager.d.ts +23 -0
- package/lib/src/perspectives/WakerSubscriptionManager.js +58 -21
- package/lib/src/runtime/RuntimeClient.d.ts +15 -27
- package/lib/src/runtime/RuntimeClient.js +57 -113
- package/lib/src/runtime/RuntimeTypes.d.ts +2 -2
- package/lib/src/runtime/RuntimeTypes.js +2 -2
- package/lib/src/shacl/SHACLFlow.d.ts +34 -6
- package/lib/src/shacl/SHACLFlow.js +62 -15
- package/lib/src/shacl/SHACLShape.d.ts +12 -0
- package/lib/src/shacl/SHACLShape.js +206 -321
- package/package.json +15 -16
- package/pnpm-workspace.yaml +4 -1
- package/src/Ad4mClient.test.ts +481 -144
- package/src/Ad4mClient.ts +16 -12
- package/src/Literal.test.ts +32 -0
- package/src/Literal.ts +3 -3
- package/src/agent/Agent.ts +8 -0
- package/src/agent/AgentClient.ts +87 -195
- package/src/agent/mutatePublicPerspective.test.ts +110 -0
- package/src/ai/AIClient.ts +40 -43
- package/src/ai/transcription-stream.test.ts +54 -0
- package/src/apiClient.test.ts +613 -185
- package/src/apiClient.ts +282 -288
- package/src/cache/cache.test.ts +7 -8
- package/src/expression/Expression.ts +12 -3
- package/src/expression/ExpressionClient.ts +6 -7
- package/src/generated/api/AIPromptExamples.ts +3 -0
- package/src/generated/api/AIPromptExamplesInput.ts +3 -0
- package/src/generated/api/AITask.ts +4 -0
- package/src/generated/api/AITaskInput.ts +4 -0
- package/src/generated/api/AddAgentInfosRequest.ts +3 -0
- package/src/generated/api/AddLinkExpressionRequest.ts +1 -1
- package/src/generated/api/AddLinkRequest.ts +1 -1
- package/src/generated/api/AddLinksBulkRequest.ts +1 -1
- package/src/generated/api/AddSdnaRequest.ts +1 -1
- package/src/generated/api/Agent.ts +4 -0
- package/src/generated/api/AgentAddEntanglementProofsParams.ts +8 -0
- package/src/generated/api/AgentByDidParams.ts +3 -0
- package/src/generated/api/AgentRemoveAppParams.ts +3 -0
- package/src/generated/api/AgentRevokeTokenParams.ts +3 -0
- package/src/generated/api/AgentSignature.ts +3 -0
- package/src/generated/api/AgentStatus.ts +4 -0
- package/src/generated/api/AgentStatusChangedEvent.ts +7 -0
- package/src/generated/api/AgentUpdatedEvent.ts +7 -0
- package/src/generated/api/AgentsByDidsRequest.ts +3 -0
- package/src/generated/api/AiAddModelParams.ts +4 -0
- package/src/generated/api/AiAddTaskParams.ts +4 -0
- package/src/generated/api/AiDiscoverModelsParams.ts +7 -0
- package/src/generated/api/AiGetDefaultModelParams.ts +4 -0
- package/src/generated/api/AiIdParams.ts +3 -0
- package/src/generated/api/AiModelLoadingStatusParams.ts +6 -0
- package/src/generated/api/AiSetDefaultModelParams.ts +4 -0
- package/src/generated/api/AiTranscriptionCloseParams.ts +3 -0
- package/src/generated/api/AiTranscriptionOpenParams.ts +4 -0
- package/src/generated/api/AiUpdateModelParams.ts +4 -0
- package/src/generated/api/AiUpdateTaskParams.ts +4 -0
- package/src/generated/api/Apps.ts +4 -0
- package/src/generated/api/AuthInfo.ts +4 -0
- package/src/generated/api/AuthInfoInput.ts +1 -1
- package/src/generated/api/AutoProcessorEvent.ts +90 -0
- package/src/generated/api/AutoProcessorNeighbourhoodState.ts +33 -0
- package/src/generated/api/AutoProcessorStep.ts +9 -0
- package/src/generated/api/BroadcastRequest.ts +3 -0
- package/src/generated/api/CallSessionInfo.ts +20 -0
- package/src/generated/api/Capability.ts +4 -0
- package/src/generated/api/CreateSubjectRequest.ts +1 -1
- package/src/generated/api/CreateUserRequest.ts +3 -0
- package/src/generated/api/DateTime.ts +3 -0
- package/src/generated/api/DecoratedExpressionProof.ts +3 -0
- package/src/generated/api/DecoratedLinkExpression.ts +6 -0
- package/src/generated/api/DecoratedNeighbourhoodExpression.ts +5 -0
- package/src/generated/api/DecoratedPerspective.ts +4 -0
- package/src/generated/api/DiscardBatchRequest.ts +3 -0
- package/src/generated/api/DisposeQueryRequest.ts +3 -0
- package/src/generated/api/EntanglementProof.ts +3 -0
- package/src/generated/api/EntanglementProofInput.ts +1 -1
- package/src/generated/api/EntanglementProofPreflightRequest.ts +3 -0
- package/src/generated/api/EntanglementProofsWrapper.ts +7 -0
- package/src/generated/api/Events.ts +77 -0
- package/src/generated/api/ExceptionInfo.ts +4 -0
- package/src/generated/api/ExceptionOccurredEvent.ts +7 -0
- package/src/generated/api/ExceptionType.ts +3 -0
- package/src/generated/api/ExecuteCommandsRequest.ts +1 -1
- package/src/generated/api/ExportRequest.ts +1 -1
- package/src/generated/api/ExpressionInteractRequest.ts +4 -0
- package/src/generated/api/ExpressionProofInput.ts +1 -1
- package/src/generated/api/ExpressionRendered.ts +6 -0
- package/src/generated/api/ExpressionUrlRequest.ts +3 -0
- package/src/generated/api/FireOutcome.ts +11 -0
- package/src/generated/api/FlowStateChangedEvent.ts +36 -0
- package/src/generated/api/FlowStateEntry.ts +18 -0
- package/src/generated/api/FriendSendMessageRequest.ts +1 -1
- package/src/generated/api/HostRate.ts +6 -0
- package/src/generated/api/HostingInfoResult.ts +13 -0
- package/src/generated/api/HostingInfoUser.ts +7 -0
- package/src/generated/api/HostingRequestPaymentResult.ts +3 -0
- package/src/generated/api/HostingUserInfo.ts +3 -0
- package/src/generated/api/HostingVersionInfo.ts +7 -0
- package/src/generated/api/HostingWalletResult.ts +8 -0
- package/src/generated/api/IceServer.ts +19 -0
- package/src/generated/api/Icon.ts +3 -0
- package/src/generated/api/ImportResult.ts +4 -0
- package/src/generated/api/ImportStats.ts +3 -0
- package/src/generated/api/InteractionCall.ts +3 -0
- package/src/generated/api/InteractionCallWrapper.ts +6 -0
- package/src/generated/api/InteractionMeta.ts +4 -0
- package/src/generated/api/InteractionParameter.ts +3 -0
- package/src/generated/api/LanguageAddressParams.ts +3 -0
- package/src/generated/api/LanguageHandle.ts +4 -0
- package/src/generated/api/LanguageListParams.ts +3 -0
- package/src/generated/api/LanguageMeta.ts +3 -0
- package/src/generated/api/LanguageMetaInput.ts +1 -1
- package/src/generated/api/LanguageRef.ts +3 -0
- package/src/generated/api/LanguageSettingsWrapper.ts +6 -0
- package/src/generated/api/LanguageWriteSettingsParams.ts +3 -0
- package/src/generated/api/LinkExpressionInput.ts +1 -1
- package/src/generated/api/LinkInput.ts +1 -1
- package/src/generated/api/LinkMutationRequest.ts +8 -0
- package/src/generated/api/LinkMutationsRequest.ts +4 -0
- package/src/generated/api/LinkStatus.ts +1 -1
- package/src/generated/api/LinkUpdateInput.ts +4 -0
- package/src/generated/api/LocalModel.ts +4 -0
- package/src/generated/api/LocalModelInput.ts +4 -0
- package/src/generated/api/MessageReceivedEvent.ts +7 -0
- package/src/generated/api/Model.ts +6 -0
- package/src/generated/api/ModelApi.ts +14 -0
- package/src/generated/api/ModelApiInput.ts +8 -0
- package/src/generated/api/ModelApiType.ts +3 -0
- package/src/generated/api/ModelInput.ts +6 -0
- package/src/generated/api/ModelType.ts +1 -1
- package/src/generated/api/Neighbourhood.ts +4 -0
- package/src/generated/api/NeighbourhoodBroadcastParams.ts +4 -0
- package/src/generated/api/NeighbourhoodOnlineStatusParams.ts +4 -0
- package/src/generated/api/NeighbourhoodPerspectivePayload.ts +9 -0
- package/src/generated/api/NeighbourhoodPhase.ts +8 -0
- package/src/generated/api/NeighbourhoodSignalFilter.ts +5 -0
- package/src/generated/api/NeighbourhoodSignalParams.ts +4 -0
- package/src/generated/api/NeighbourhoodSignedPerspective.ts +8 -0
- package/src/generated/api/NeighbourhoodUuidParams.ts +3 -0
- package/src/generated/api/Notification.ts +7 -0
- package/src/generated/api/NotificationGrantRequest.ts +6 -0
- package/src/generated/api/NotificationInput.ts +1 -1
- package/src/generated/api/NotificationTriggeredEvent.ts +8 -0
- package/src/generated/api/OnlineAgent.ts +9 -0
- package/src/generated/api/OutputRef.ts +11 -0
- package/src/generated/api/OverlayView.ts +25 -0
- package/src/generated/api/Perspective.ts +4 -0
- package/src/generated/api/PerspectiveAddAutoProcessorParams.ts +11 -0
- package/src/generated/api/PerspectiveAddLinkExpressionParams.ts +4 -0
- package/src/generated/api/PerspectiveAddLinkParams.ts +4 -0
- package/src/generated/api/PerspectiveAddLinksParams.ts +4 -0
- package/src/generated/api/PerspectiveAddSdnaParams.ts +7 -0
- package/src/generated/api/PerspectiveAddSdnaResult.ts +6 -0
- package/src/generated/api/PerspectiveCommitBatchParams.ts +3 -0
- package/src/generated/api/PerspectiveCreateSubjectParams.ts +3 -0
- package/src/generated/api/PerspectiveDiscardBatchParams.ts +3 -0
- package/src/generated/api/PerspectiveEvaluateGettersParams.ts +6 -0
- package/src/generated/api/PerspectiveExecuteCommandsParams.ts +3 -0
- package/src/generated/api/PerspectiveExpression.ts +5 -0
- package/src/generated/api/PerspectiveFlowFiredParams.ts +7 -0
- package/src/generated/api/PerspectiveFlowProposalParams.ts +3 -0
- package/src/generated/api/PerspectiveFlowReceiptVerdict.ts +8 -0
- package/src/generated/api/PerspectiveFlowStatesParams.ts +11 -0
- package/src/generated/api/PerspectiveFlowValidOutputsParams.ts +7 -0
- package/src/generated/api/PerspectiveGetAllShaclParams.ts +6 -0
- package/src/generated/api/PerspectiveGetSubjectDataParams.ts +3 -0
- package/src/generated/api/PerspectiveHandle.ts +5 -0
- package/src/generated/api/PerspectiveLinkDiff.ts +7 -0
- package/src/generated/api/PerspectiveLinkMutationsParams.ts +4 -0
- package/src/generated/api/PerspectiveLinkUpdatedWithOwner.ts +4 -0
- package/src/generated/api/PerspectiveLinkWithOwner.ts +4 -0
- package/src/generated/api/PerspectiveMintFlowReceiptParams.ts +3 -0
- package/src/generated/api/PerspectiveMintFlowReceiptResult.ts +9 -0
- package/src/generated/api/PerspectiveModelQueryParams.ts +10 -0
- package/src/generated/api/PerspectiveNamedShacl.ts +4 -0
- package/src/generated/api/PerspectiveProposeFlowTransitionParams.ts +4 -0
- package/src/generated/api/PerspectiveQueryLinksParams.ts +11 -0
- package/src/generated/api/PerspectiveQueryParams.ts +3 -0
- package/src/generated/api/PerspectiveReceiptOutcome.ts +3 -0
- package/src/generated/api/PerspectiveRejectFlowProposalResult.ts +3 -0
- package/src/generated/api/PerspectiveRemoveAutoProcessorParams.ts +3 -0
- package/src/generated/api/PerspectiveRemoveLinkParams.ts +4 -0
- package/src/generated/api/PerspectiveRemoveLinksParams.ts +4 -0
- package/src/generated/api/PerspectiveRemoveSubjectParams.ts +3 -0
- package/src/generated/api/PerspectiveRemovedWithOwner.ts +3 -0
- package/src/generated/api/PerspectiveResolveInterpretationParams.ts +6 -0
- package/src/generated/api/PerspectiveResynced.ts +7 -0
- package/src/generated/api/PerspectiveShacl.ts +4 -0
- package/src/generated/api/PerspectiveShaclNameParams.ts +3 -0
- package/src/generated/api/PerspectiveSparqlParams.ts +7 -0
- package/src/generated/api/PerspectiveState.ts +3 -0
- package/src/generated/api/PerspectiveStateFilter.ts +5 -0
- package/src/generated/api/PerspectiveSubjectClassesOfParams.ts +3 -0
- package/src/generated/api/PerspectiveSubscribed.ts +8 -0
- package/src/generated/api/PerspectiveSubscriptionParams.ts +3 -0
- package/src/generated/api/PerspectiveUnsignedInput.ts +4 -0
- package/src/generated/api/PerspectiveUpdateLinkParams.ts +5 -0
- package/src/generated/api/PerspectiveUpdateParams.ts +3 -0
- package/src/generated/api/PerspectiveUpdateSubjectParams.ts +7 -0
- package/src/generated/api/PerspectiveUuidParams.ts +3 -0
- package/src/generated/api/PerspectiveVerifyFlowReceiptParams.ts +9 -0
- package/src/generated/api/PerspectiveWithOwner.ts +4 -0
- package/src/generated/api/ProposeOutcome.ts +46 -0
- package/src/generated/api/PublicPerspectiveInput.ts +4 -0
- package/src/generated/api/PublishNeighbourhoodRequest.ts +2 -2
- package/src/generated/api/QuerySubscriptionUpdate.ts +10 -0
- package/src/generated/api/QuerySubscriptionUpdateEvent.ts +9 -0
- package/src/generated/api/QueryUpdatesLagged.ts +7 -0
- package/src/generated/api/RemoveLinkRequest.ts +1 -1
- package/src/generated/api/RemoveLinksBulkRequest.ts +1 -1
- package/src/generated/api/RemoveSubjectRequest.ts +7 -0
- package/src/generated/api/RequestCapabilityRequest.ts +4 -0
- package/src/generated/api/RequestPaymentRequest.ts +3 -0
- package/src/generated/api/Resource.ts +3 -0
- package/src/generated/api/ResyncSubscriptionRequest.ts +3 -0
- package/src/generated/api/RpcMethods.ts +479 -0
- package/src/generated/api/RunInterpretationRequest.ts +28 -2
- package/src/generated/api/RunInterpretationWithHarnessRequest.ts +51 -0
- package/src/generated/api/RuntimeComputeLogParams.ts +15 -0
- package/src/generated/api/RuntimeFriendStatusParams.ts +3 -0
- package/src/generated/api/RuntimeGrantNotificationParams.ts +3 -0
- package/src/generated/api/RuntimeImportPerspectiveResult.ts +3 -0
- package/src/generated/api/RuntimeImportResult.ts +8 -0
- package/src/generated/api/RuntimeInfo.ts +3 -0
- package/src/generated/api/RuntimeNotificationIdParams.ts +3 -0
- package/src/generated/api/RuntimeSendFriendMessageParams.ts +8 -0
- package/src/generated/api/RuntimeSetFreeHostingEnabledParams.ts +3 -0
- package/src/generated/api/RuntimeUnytSendHotParams.ts +3 -0
- package/src/generated/api/RuntimeUnytWalletHistoryParams.ts +3 -0
- package/src/generated/api/RuntimeUpdateNotificationParams.ts +3 -0
- package/src/generated/api/SentMessage.ts +4 -0
- package/src/generated/api/SetHostRatesRequest.ts +4 -0
- package/src/generated/api/SetHotWalletAddressRequest.ts +3 -0
- package/src/generated/api/SetOnlineStatusRequest.ts +3 -0
- package/src/generated/api/SetUnytMembraneProofRequest.ts +7 -0
- package/src/generated/api/SetUserFreeAccessRequest.ts +3 -0
- package/src/generated/api/SfuAddIceCandidateParams.ts +7 -0
- package/src/generated/api/SfuAnswerServerOfferParams.ts +7 -0
- package/src/generated/api/SfuCallJoinParams.ts +13 -0
- package/src/generated/api/SfuCallRenegotiationOffer.ts +29 -0
- package/src/generated/api/SfuCascadePipe.ts +3 -0
- package/src/generated/api/SfuCascadeStatus.ts +7 -0
- package/src/generated/api/SfuConfig.ts +53 -0
- package/src/generated/api/SfuDataMessage.ts +23 -0
- package/src/generated/api/SfuEnsureMembershipParams.ts +3 -0
- package/src/generated/api/SfuMigrateEvent.ts +20 -0
- package/src/generated/api/SfuNeighbourhoodParams.ts +3 -0
- package/src/generated/api/SfuParticipantQualityPreference.ts +6 -0
- package/src/generated/api/SfuPerspectiveParams.ts +6 -0
- package/src/generated/api/SfuQualityPreferenceParams.ts +7 -0
- package/src/generated/api/SfuRoomInfo.ts +7 -0
- package/src/generated/api/SfuRoomParams.ts +3 -0
- package/src/generated/api/SfuRoomParticipantInfo.ts +8 -0
- package/src/generated/api/SfuRoomRoster.ts +12 -0
- package/src/generated/api/SfuSendDataParams.ts +7 -0
- package/src/generated/api/SfuSetConfigParams.ts +4 -0
- package/src/generated/api/SfuStatus.ts +24 -0
- package/src/generated/api/ShaclLinkTriple.ts +8 -0
- package/src/generated/api/SignalRequest.ts +3 -0
- package/src/generated/api/SubscribeQueryRequest.ts +3 -0
- package/src/generated/api/TokenizerSource.ts +3 -0
- package/src/generated/api/TokenizerSourceInput.ts +3 -0
- package/src/generated/api/TrackMapEntry.ts +18 -0
- package/src/generated/api/TranscriptionTextFilter.ts +3 -0
- package/src/generated/api/TriggeredNotification.ts +4 -0
- package/src/generated/api/TrustedAgentsWrapper.ts +6 -0
- package/src/generated/api/UnlockAgentRequest.ts +1 -1
- package/src/generated/api/UnytVersionInfo.ts +20 -0
- package/src/generated/api/UpdateLinkRequest.ts +1 -1
- package/src/generated/api/UpdateProfileRequest.ts +4 -0
- package/src/generated/api/UpdateSubjectRequest.ts +10 -0
- package/src/generated/api/UserCreationResult.ts +3 -0
- package/src/generated/api/UserStatistics.ts +2 -1
- package/src/generated/api/UsersAppInfo.ts +6 -0
- package/src/generated/api/UsersEmailParams.ts +3 -0
- package/src/generated/api/UsersEmailTestAction.ts +3 -0
- package/src/generated/api/UsersEmailTestParams.ts +12 -0
- package/src/generated/api/UsersEmailTestResult.ts +7 -0
- package/src/generated/api/UsersLoginParams.ts +7 -0
- package/src/generated/api/UsersRequestVerificationParams.ts +4 -0
- package/src/generated/api/UsersSetCreditsParams.ts +3 -0
- package/src/generated/api/UsersVerifyEmailParams.ts +11 -0
- package/src/generated/api/ValidOutput.ts +30 -0
- package/src/generated/api/VoiceActivityParamsInput.ts +3 -0
- package/src/generated/api/index.ts +14 -2
- package/src/generated/api/serde_json/JsonValue.ts +3 -0
- package/src/index.ts +9 -3
- package/src/language/LanguageClient.ts +12 -13
- package/src/links/Links.ts +49 -3
- package/src/model/Ad4mModel.test.ts +480 -173
- package/src/model/Ad4mModel.ts +407 -77
- package/src/model/ModelQueryBuilder.ts +95 -255
- package/src/model/abstract-classes.test.ts +225 -0
- package/src/model/decorators.ts +145 -9
- package/src/model/query-sparql.ts +2 -3
- package/src/model/relation-filtering.test.ts +191 -0
- package/src/model/shacl-gen.ts +32 -9
- package/src/model/shacl-roundtrip.test.ts +52 -0
- package/src/model/types.ts +19 -0
- package/src/neighbourhood/MeshManager.test.ts +2640 -0
- package/src/neighbourhood/MeshManager.ts +1350 -0
- package/src/neighbourhood/NeighbourhoodClient.test.ts +60 -0
- package/src/neighbourhood/NeighbourhoodClient.ts +298 -27
- package/src/neighbourhood/NeighbourhoodProxy.test.ts +37 -9
- package/src/neighbourhood/NeighbourhoodProxy.ts +247 -1
- package/src/neighbourhood/Session.test.ts +800 -0
- package/src/neighbourhood/Session.ts +525 -0
- package/src/neighbourhood/SfuManager.test.ts +677 -0
- package/src/neighbourhood/SfuManager.ts +803 -0
- package/src/neighbourhood/SfuTypes.ts +40 -0
- package/src/notifyListeners.test.ts +19 -0
- package/src/notifyListeners.ts +10 -0
- package/src/perspectives/AutoProcessor.ts +13 -82
- package/src/perspectives/FlowInstance.ts +136 -32
- package/src/perspectives/FlowModels.ts +46 -11
- package/src/perspectives/InterpretationModels.ts +4 -0
- package/src/perspectives/LiveQuery.test.ts +197 -0
- package/src/perspectives/LiveQuery.ts +189 -0
- package/src/perspectives/Perspective.ts +18 -2
- package/src/perspectives/PerspectiveClient.test.ts +122 -45
- package/src/perspectives/PerspectiveClient.ts +146 -343
- package/src/perspectives/PerspectiveHandle.ts +32 -9
- package/src/perspectives/PerspectiveProxy.test.ts +216 -528
- package/src/perspectives/PerspectiveProxy.ts +259 -736
- package/src/perspectives/TextContent.test.ts +123 -0
- package/src/perspectives/TextContent.ts +36 -0
- package/src/perspectives/WakerSubscriptionManager.test.ts +136 -1
- package/src/perspectives/WakerSubscriptionManager.ts +69 -22
- package/src/perspectives/link-updated-type.test.ts +55 -0
- package/src/perspectives/listener-leaks.test.ts +204 -0
- package/src/perspectives/shacl-rpc.test.ts +22 -27
- package/src/runtime/RuntimeClient.ts +75 -157
- package/src/runtime/RuntimeTypes.ts +3 -3
- package/src/shacl/SHACLFlow.test.ts +49 -1
- package/src/shacl/SHACLFlow.ts +73 -15
- package/src/shacl/SHACLShape.test.ts +161 -16
- package/src/shacl/SHACLShape.ts +210 -439
- package/lib/shims/reflect-metadata.d.ts +0 -0
- package/lib/shims/reflect-metadata.js +0 -0
- package/lib/shims/type-graphql.d.ts +0 -32
- package/lib/shims/type-graphql.js +0 -70
- package/lib/src/PubSub.d.ts +0 -17
- package/lib/src/PubSub.js +0 -17
- package/lib/src/agent/AgentResolver.d.ts +0 -30
- package/lib/src/agent/AgentResolver.js +0 -325
- package/lib/src/ai/AIResolver.d.ts +0 -75
- package/lib/src/ai/AIResolver.js +0 -455
- package/lib/src/buildSchema.d.ts +0 -1
- package/lib/src/buildSchema.js +0 -38
- package/lib/src/expression/ExpressionResolver.d.ts +0 -10
- package/lib/src/expression/ExpressionResolver.js +0 -106
- package/lib/src/language/LanguageContext.d.ts +0 -37
- package/lib/src/language/LanguageContext.js +0 -2
- package/lib/src/language/LanguageResolver.d.ts +0 -19
- package/lib/src/language/LanguageResolver.js +0 -143
- package/lib/src/links/Links.test.js +0 -33
- package/lib/src/model/Ad4mModel.test.js +0 -2055
- package/lib/src/model/Subject.d.ts +0 -25
- package/lib/src/model/Subject.js +0 -164
- package/lib/src/model/hydration-batch.d.ts +0 -34
- package/lib/src/model/hydration-batch.js +0 -147
- package/lib/src/model/hydration-batching.test.d.ts +0 -7
- package/lib/src/model/hydration-batching.test.js +0 -456
- package/lib/src/model/model-manifest.d.ts +0 -41
- package/lib/src/model/model-manifest.js +0 -11
- package/lib/src/model/prolog-facts.d.ts +0 -37
- package/lib/src/model/prolog-facts.js +0 -134
- package/lib/src/model/query-cache.test.js +0 -43
- package/lib/src/model/query-prolog.d.ts +0 -15
- package/lib/src/model/query-prolog.js +0 -140
- package/lib/src/model/query-sparql-batch.d.ts +0 -17
- package/lib/src/model/query-sparql-batch.js +0 -260
- package/lib/src/model/query-sparql.test.js +0 -312
- package/lib/src/model/relation-filtering.test.js +0 -838
- package/lib/src/model/subscription-delta.test.d.ts +0 -24
- package/lib/src/model/subscription-delta.test.js +0 -180
- package/lib/src/model/subscription-pool.d.ts +0 -39
- package/lib/src/model/subscription-pool.js +0 -165
- package/lib/src/neighbourhood/NeighbourhoodProxy.test.js +0 -73
- package/lib/src/neighbourhood/NeighbourhoodResolver.d.ts +0 -24
- package/lib/src/neighbourhood/NeighbourhoodResolver.js +0 -182
- package/lib/src/perspectives/Perspective.test.js +0 -20
- package/lib/src/perspectives/PerspectiveClient.test.js +0 -224
- package/lib/src/perspectives/PerspectiveResolver.d.ts +0 -56
- package/lib/src/perspectives/PerspectiveResolver.js +0 -519
- package/lib/src/runtime/RuntimeResolver.d.ts +0 -173
- package/lib/src/runtime/RuntimeResolver.js +0 -1122
- package/lib/src/schema.gql +0 -631
- package/lib/src/shacl/SHACLFlow.test.js +0 -205
- package/lib/src/shacl/SHACLShape.test.js +0 -418
- package/lib/src/unwrapApolloResult.d.ts +0 -2
- package/lib/src/unwrapApolloResult.js +0 -14
- /package/lib/src/{links/Links.test.d.ts → generated/api/AITask.js} +0 -0
- /package/lib/src/{model/Ad4mModel.test.d.ts → generated/api/AITaskInput.js} +0 -0
- /package/lib/src/{model/query-cache.test.d.ts → generated/api/Agent.js} +0 -0
- /package/lib/src/{model/query-sparql.test.d.ts → generated/api/AgentAddEntanglementProofsParams.js} +0 -0
- /package/lib/src/{model/relation-filtering.test.d.ts → generated/api/AgentStatus.js} +0 -0
- /package/lib/src/{neighbourhood/NeighbourhoodProxy.test.d.ts → generated/api/AgentStatusChangedEvent.js} +0 -0
- /package/lib/src/{perspectives/Perspective.test.d.ts → generated/api/AgentUpdatedEvent.js} +0 -0
- /package/lib/src/{perspectives/PerspectiveClient.test.d.ts → generated/api/AiAddModelParams.js} +0 -0
- /package/lib/src/{shacl/SHACLFlow.test.d.ts → generated/api/AiAddTaskParams.js} +0 -0
- /package/lib/src/{shacl/SHACLShape.test.d.ts → generated/api/AiGetDefaultModelParams.js} +0 -0
|
@@ -30,6 +30,21 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
30
30
|
import { Ad4mModel } from "../model/Ad4mModel";
|
|
31
31
|
import { HasMany, Optional, Property } from "../model/decorators";
|
|
32
32
|
import { Model } from "../model/decorators";
|
|
33
|
+
/**
|
|
34
|
+
* The engine's proposer rule (`self_authored_proposer`: a `proposer` link
|
|
35
|
+
* signed by the DID it names) as a getter. Must match the `proposer` getter in
|
|
36
|
+
* `hardwired_sdna/flow_transition_proposal.json` byte for byte, as
|
|
37
|
+
* `ACCEPTED_BY_GETTER` must.
|
|
38
|
+
*/
|
|
39
|
+
export const PROPOSER_GETTER = 'SELECT ?target WHERE { ?source <ad4m://flow/proposer> ?target . FILTER EXISTS { ?_claim <http://www.w3.org/1999/02/22-rdf-syntax-ns#reifies> <<( ?source <ad4m://flow/proposer> ?target )>> ; <ad4m://ontology/author> ?_author ; <ad4m://ontology/proofValid> ?_valid . FILTER(STR(?_author) = STR(?target) && STR(?_valid) = "true") } }';
|
|
40
|
+
/**
|
|
41
|
+
* The engine's vote rule (`signed_by`: the link's author is the DID it names,
|
|
42
|
+
* and its signature verified) as a getter over the link's reifier. Must match
|
|
43
|
+
* the `acceptedBy` getter in `hardwired_sdna/flow_transition_proposal.json`
|
|
44
|
+
* byte for byte: whichever side registers the class first decides the stored
|
|
45
|
+
* shape.
|
|
46
|
+
*/
|
|
47
|
+
export const ACCEPTED_BY_GETTER = 'SELECT ?target WHERE { ?source <ad4m://acceptedBy> ?target . FILTER EXISTS { ?_vote <http://www.w3.org/1999/02/22-rdf-syntax-ns#reifies> <<( ?source <ad4m://acceptedBy> ?target )>> ; <ad4m://ontology/author> ?_author ; <ad4m://ontology/proofValid> ?_valid . FILTER(STR(?_author) = STR(?target) && STR(?_valid) = "true") } }';
|
|
33
48
|
// ── FlowTransitionProposal ──────────────────────────────────────────────────
|
|
34
49
|
// Mirrors the Rust hardwired `flow_transition_proposal.json` SDNA (once wired
|
|
35
50
|
// on the engine side; see file header). One node per proposed transition; the
|
|
@@ -54,7 +69,12 @@ let FlowTransitionProposal = class FlowTransitionProposal extends Ad4mModel {
|
|
|
54
69
|
this.fromState = "";
|
|
55
70
|
/** Name of the state the proposal wants to transition to. */
|
|
56
71
|
this.toState = "";
|
|
57
|
-
/**
|
|
72
|
+
/**
|
|
73
|
+
* DID of the agent that issued the proposal, read the way the engine reads
|
|
74
|
+
* it: only from a `proposer` link signed by the DID it names. Any member
|
|
75
|
+
* can write a `proposer` link naming someone else, and an unchecked read
|
|
76
|
+
* would show that DID instead (and drop the real proposer from the voters).
|
|
77
|
+
*/
|
|
58
78
|
this.proposer = "";
|
|
59
79
|
/**
|
|
60
80
|
* URIs of instances offered as evidence that `toState.requires` is now
|
|
@@ -96,6 +116,19 @@ let FlowTransitionProposal = class FlowTransitionProposal extends Ad4mModel {
|
|
|
96
116
|
* (#1108).
|
|
97
117
|
*/
|
|
98
118
|
this.nonce = "";
|
|
119
|
+
/**
|
|
120
|
+
* DIDs that accepted this proposal, as the consensus engine counts them:
|
|
121
|
+
* an `ad4m://acceptedBy` link counts only when it is signed by the DID it
|
|
122
|
+
* names, since anyone can write one naming someone else, and each DID once.
|
|
123
|
+
* The proposer's vote is implicit and the proposer may also accept, so the
|
|
124
|
+
* voters are the *set* `{ proposer } ∪ acceptedBy`, not its sum.
|
|
125
|
+
* Read-only: vote with `acceptProposal`, withdraw with `rejectProposal`.
|
|
126
|
+
*/
|
|
127
|
+
this.acceptedBy = [];
|
|
128
|
+
// Whether this proposal settled an edge is not on the record: the
|
|
129
|
+
// executor keeps that per agent, outside the graph (#1424). Ask
|
|
130
|
+
// `PerspectiveProxy.flowFired(instance)` for the proposals your replica
|
|
131
|
+
// recorded as fired, or listen with `onFlowStateChanged`.
|
|
99
132
|
// "When was this proposal written?" is answered by `Ad4mModel`'s built-in
|
|
100
133
|
// `createdAt`, synthesized on hydration from the earliest link timestamp
|
|
101
134
|
// of the proposal's own links (all written together during create_subject).
|
|
@@ -114,7 +147,7 @@ __decorate([
|
|
|
114
147
|
__metadata("design:type", String)
|
|
115
148
|
], FlowTransitionProposal.prototype, "toState", void 0);
|
|
116
149
|
__decorate([
|
|
117
|
-
Property({ through: "ad4m://flow/proposer", required: true }),
|
|
150
|
+
Property({ through: "ad4m://flow/proposer", required: true, getter: PROPOSER_GETTER, datatype: "xsd:string" }),
|
|
118
151
|
__metadata("design:type", String)
|
|
119
152
|
], FlowTransitionProposal.prototype, "proposer", void 0);
|
|
120
153
|
__decorate([
|
|
@@ -145,6 +178,10 @@ __decorate([
|
|
|
145
178
|
Optional({ through: "ad4m://flow/rationale" }),
|
|
146
179
|
__metadata("design:type", String)
|
|
147
180
|
], FlowTransitionProposal.prototype, "rationale", void 0);
|
|
181
|
+
__decorate([
|
|
182
|
+
HasMany({ through: "ad4m://acceptedBy", getter: ACCEPTED_BY_GETTER, readOnly: true }),
|
|
183
|
+
__metadata("design:type", Array)
|
|
184
|
+
], FlowTransitionProposal.prototype, "acceptedBy", void 0);
|
|
148
185
|
FlowTransitionProposal = __decorate([
|
|
149
186
|
Model({ name: "FlowTransitionProposal" })
|
|
150
187
|
], FlowTransitionProposal);
|
|
@@ -197,14 +234,10 @@ let FlowInstanceRecord = class FlowInstanceRecord extends Ad4mModel {
|
|
|
197
234
|
* on read.
|
|
198
235
|
*/
|
|
199
236
|
this.subject = "";
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
* synced in from a peer carries no value until the local consensus pass
|
|
205
|
-
* has run, so an empty string means "not yet derived here".
|
|
206
|
-
*/
|
|
207
|
-
this.currentState = "";
|
|
237
|
+
// The flow's state is not on the record. It is derived from the signed
|
|
238
|
+
// proposals, and each agent's executor keeps what it last derived outside
|
|
239
|
+
// the graph (#1424): read it with `PerspectiveProxy.flowStates`, or use
|
|
240
|
+
// the `FlowInstance` wrapper, whose `currentStateName` is filled from it.
|
|
208
241
|
// "When was this flow started?" is answered by `Ad4mModel`'s built-in
|
|
209
242
|
// `createdAt`, synthesized on hydration from the earliest link timestamp
|
|
210
243
|
// of the instance's own links (all written together during `mint_flow_instance`).
|
|
@@ -218,10 +251,6 @@ __decorate([
|
|
|
218
251
|
Property({ through: "ad4m://flow/base", required: true }),
|
|
219
252
|
__metadata("design:type", String)
|
|
220
253
|
], FlowInstanceRecord.prototype, "subject", void 0);
|
|
221
|
-
__decorate([
|
|
222
|
-
Property({ through: "ad4m://flow/current_state", local: true }),
|
|
223
|
-
__metadata("design:type", String)
|
|
224
|
-
], FlowInstanceRecord.prototype, "currentState", void 0);
|
|
225
254
|
FlowInstanceRecord = __decorate([
|
|
226
255
|
Model({ name: "FlowInstance" })
|
|
227
256
|
], FlowInstanceRecord);
|
|
@@ -24,6 +24,8 @@ export declare class AutoProcessorConfig extends Ad4mModel {
|
|
|
24
24
|
basePrefix?: string;
|
|
25
25
|
/** Class URIs (SHACL targetClass) to materialise each pass. */
|
|
26
26
|
interpretationClasses: string[];
|
|
27
|
+
/** Flow URIs (`{namespace}{name}Flow`) this processor runs flow features on; empty = off. */
|
|
28
|
+
flows: string[];
|
|
27
29
|
/** Quiet-window (ms) after the last new item before a pass runs. */
|
|
28
30
|
debounceMs: string;
|
|
29
31
|
/** Minimum batch size before a pass runs (default 1). */
|
|
@@ -49,6 +49,8 @@ let AutoProcessorConfig = class AutoProcessorConfig extends Ad4mModel {
|
|
|
49
49
|
this.sourceScopeQuery = "";
|
|
50
50
|
/** Class URIs (SHACL targetClass) to materialise each pass. */
|
|
51
51
|
this.interpretationClasses = [];
|
|
52
|
+
/** Flow URIs (`{namespace}{name}Flow`) this processor runs flow features on; empty = off. */
|
|
53
|
+
this.flows = [];
|
|
52
54
|
/** Quiet-window (ms) after the last new item before a pass runs. */
|
|
53
55
|
this.debounceMs = "200";
|
|
54
56
|
/** Maximum items per pass. */
|
|
@@ -78,6 +80,10 @@ __decorate([
|
|
|
78
80
|
HasMany({ through: "ad4m://interpretation_class", datatype: "xsd:string" }),
|
|
79
81
|
__metadata("design:type", Array)
|
|
80
82
|
], AutoProcessorConfig.prototype, "interpretationClasses", void 0);
|
|
83
|
+
__decorate([
|
|
84
|
+
HasMany({ through: "ad4m://flow", datatype: "xsd:string" }),
|
|
85
|
+
__metadata("design:type", Array)
|
|
86
|
+
], AutoProcessorConfig.prototype, "flows", void 0);
|
|
81
87
|
__decorate([
|
|
82
88
|
Property({ through: "ad4m://debounce_ms", required: true }),
|
|
83
89
|
__metadata("design:type", String)
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { PerspectiveClient } from "./PerspectiveClient";
|
|
2
|
+
/** Reply to `perspective.subscribeQuery` / `perspective.modelSubscribe`. */
|
|
3
|
+
export interface Subscribed {
|
|
4
|
+
subscriptionId: string;
|
|
5
|
+
result: any;
|
|
6
|
+
revision: number;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* A `query-subscription-update` event: the change from the previous revision.
|
|
10
|
+
* Model results carry `ids` (the new order), `upsert` (new or changed
|
|
11
|
+
* instances) and `totalCount`; query results carry `added` / `removed` rows;
|
|
12
|
+
* a result that could not be diffed comes whole as `result`.
|
|
13
|
+
*/
|
|
14
|
+
export interface QueryUpdate {
|
|
15
|
+
subscriptionId: string;
|
|
16
|
+
revision: number;
|
|
17
|
+
ids?: string[];
|
|
18
|
+
upsert?: any[];
|
|
19
|
+
totalCount?: number;
|
|
20
|
+
added?: any[];
|
|
21
|
+
removed?: any[];
|
|
22
|
+
result?: any;
|
|
23
|
+
}
|
|
24
|
+
/** The executor dropped updates, maybe for any live query on this socket:
|
|
25
|
+
* every live query resyncs. */
|
|
26
|
+
export interface QueryLagged {
|
|
27
|
+
lagged: true;
|
|
28
|
+
}
|
|
29
|
+
/** Apply one update to the last result. Query rows are a multiset: added rows are appended.
|
|
30
|
+
* Throws when the update names an instance that neither the last result nor
|
|
31
|
+
* the update holds: the last result was wrong, and the caller must resync. */
|
|
32
|
+
export declare function applyUpdate(result: any, update: QueryUpdate): any;
|
|
33
|
+
/**
|
|
34
|
+
* One live query on the executor. Holds the last result, applies each update
|
|
35
|
+
* to it, calls `resyncSubscription` when a revision is missing, and opens a
|
|
36
|
+
* new subscription after a reconnect (the executor ends a socket's
|
|
37
|
+
* subscriptions when it closes). `onResult` gets every result after the
|
|
38
|
+
* first; `start()` returns the first.
|
|
39
|
+
*/
|
|
40
|
+
export declare class LiveQuery {
|
|
41
|
+
#private;
|
|
42
|
+
constructor(client: PerspectiveClient, uuid: string, open: () => Promise<Subscribed>, onResult: (result: any) => void);
|
|
43
|
+
get id(): string | undefined;
|
|
44
|
+
get result(): any;
|
|
45
|
+
/** Open the subscription (again) and return its initial result. A start
|
|
46
|
+
* that a newer one overtakes resolves with the newer one's result. */
|
|
47
|
+
start(): Promise<any>;
|
|
48
|
+
dispose(): void;
|
|
49
|
+
}
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
|
|
2
|
+
if (kind === "m") throw new TypeError("Private method is not writable");
|
|
3
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
|
|
4
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
5
|
+
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
6
|
+
};
|
|
7
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
8
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
9
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
10
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
11
|
+
};
|
|
12
|
+
var _LiveQuery_instances, _LiveQuery_client, _LiveQuery_uuid, _LiveQuery_open, _LiveQuery_onResult, _LiveQuery_id, _LiveQuery_revision, _LiveQuery_result, _LiveQuery_started, _LiveQuery_disposed, _LiveQuery_generation, _LiveQuery_latest, _LiveQuery_buffer, _LiveQuery_unlisten, _LiveQuery_unreconnect, _LiveQuery_start, _LiveQuery_replace, _LiveQuery_receive, _LiveQuery_resync;
|
|
13
|
+
/** Apply one update to the last result. Query rows are a multiset: added rows are appended.
|
|
14
|
+
* Throws when the update names an instance that neither the last result nor
|
|
15
|
+
* the update holds: the last result was wrong, and the caller must resync. */
|
|
16
|
+
export function applyUpdate(result, update) {
|
|
17
|
+
if ('result' in update)
|
|
18
|
+
return update.result;
|
|
19
|
+
if (update.ids) {
|
|
20
|
+
const byId = new Map(result.instances.map((i) => [i.id, i]));
|
|
21
|
+
for (const instance of update.upsert)
|
|
22
|
+
byId.set(instance.id, instance);
|
|
23
|
+
const instances = update.ids.map(id => {
|
|
24
|
+
if (!byId.has(id))
|
|
25
|
+
throw new Error(`Live query update names unknown instance ${id}`);
|
|
26
|
+
return byId.get(id);
|
|
27
|
+
});
|
|
28
|
+
return { ...result, instances, totalCount: update.totalCount };
|
|
29
|
+
}
|
|
30
|
+
const toRemove = new Map();
|
|
31
|
+
for (const row of update.removed) {
|
|
32
|
+
const key = JSON.stringify(row);
|
|
33
|
+
toRemove.set(key, (toRemove.get(key) ?? 0) + 1);
|
|
34
|
+
}
|
|
35
|
+
const kept = result.filter(row => {
|
|
36
|
+
const key = JSON.stringify(row);
|
|
37
|
+
const n = toRemove.get(key);
|
|
38
|
+
if (!n)
|
|
39
|
+
return true;
|
|
40
|
+
toRemove.set(key, n - 1);
|
|
41
|
+
return false;
|
|
42
|
+
});
|
|
43
|
+
return [...kept, ...update.added];
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* One live query on the executor. Holds the last result, applies each update
|
|
47
|
+
* to it, calls `resyncSubscription` when a revision is missing, and opens a
|
|
48
|
+
* new subscription after a reconnect (the executor ends a socket's
|
|
49
|
+
* subscriptions when it closes). `onResult` gets every result after the
|
|
50
|
+
* first; `start()` returns the first.
|
|
51
|
+
*/
|
|
52
|
+
export class LiveQuery {
|
|
53
|
+
constructor(client, uuid, open, onResult) {
|
|
54
|
+
_LiveQuery_instances.add(this);
|
|
55
|
+
_LiveQuery_client.set(this, void 0);
|
|
56
|
+
_LiveQuery_uuid.set(this, void 0);
|
|
57
|
+
_LiveQuery_open.set(this, void 0);
|
|
58
|
+
_LiveQuery_onResult.set(this, void 0);
|
|
59
|
+
_LiveQuery_id.set(this, void 0);
|
|
60
|
+
_LiveQuery_revision.set(this, 0);
|
|
61
|
+
_LiveQuery_result.set(this, void 0);
|
|
62
|
+
_LiveQuery_started.set(this, false);
|
|
63
|
+
_LiveQuery_disposed.set(this, false);
|
|
64
|
+
_LiveQuery_generation.set(this, 0);
|
|
65
|
+
_LiveQuery_latest.set(this, void 0);
|
|
66
|
+
// Updates that arrive while a subscribe or resync reply is outstanding.
|
|
67
|
+
_LiveQuery_buffer.set(this, null);
|
|
68
|
+
_LiveQuery_unlisten.set(this, void 0);
|
|
69
|
+
_LiveQuery_unreconnect.set(this, void 0);
|
|
70
|
+
__classPrivateFieldSet(this, _LiveQuery_client, client, "f");
|
|
71
|
+
__classPrivateFieldSet(this, _LiveQuery_uuid, uuid, "f");
|
|
72
|
+
__classPrivateFieldSet(this, _LiveQuery_open, open, "f");
|
|
73
|
+
__classPrivateFieldSet(this, _LiveQuery_onResult, onResult, "f");
|
|
74
|
+
__classPrivateFieldSet(this, _LiveQuery_unlisten, client.onQueryUpdate(update => __classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_receive).call(this, update)), "f");
|
|
75
|
+
__classPrivateFieldSet(this, _LiveQuery_unreconnect, client.onReconnect(() => {
|
|
76
|
+
this.start().catch(e => console.error('Error re-opening live query after reconnect:', e));
|
|
77
|
+
}), "f");
|
|
78
|
+
}
|
|
79
|
+
get id() { return __classPrivateFieldGet(this, _LiveQuery_id, "f"); }
|
|
80
|
+
get result() { return __classPrivateFieldGet(this, _LiveQuery_result, "f"); }
|
|
81
|
+
/** Open the subscription (again) and return its initial result. A start
|
|
82
|
+
* that a newer one overtakes resolves with the newer one's result. */
|
|
83
|
+
start() {
|
|
84
|
+
var _a;
|
|
85
|
+
__classPrivateFieldSet(this, _LiveQuery_latest, __classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_start).call(this, __classPrivateFieldSet(this, _LiveQuery_generation, (_a = __classPrivateFieldGet(this, _LiveQuery_generation, "f"), ++_a), "f")), "f");
|
|
86
|
+
return __classPrivateFieldGet(this, _LiveQuery_latest, "f");
|
|
87
|
+
}
|
|
88
|
+
dispose() {
|
|
89
|
+
var _a;
|
|
90
|
+
__classPrivateFieldSet(this, _LiveQuery_disposed, true, "f");
|
|
91
|
+
__classPrivateFieldSet(this, _LiveQuery_generation, (_a = __classPrivateFieldGet(this, _LiveQuery_generation, "f"), _a++, _a), "f");
|
|
92
|
+
__classPrivateFieldGet(this, _LiveQuery_unlisten, "f").call(this);
|
|
93
|
+
__classPrivateFieldGet(this, _LiveQuery_unreconnect, "f").call(this);
|
|
94
|
+
if (__classPrivateFieldGet(this, _LiveQuery_id, "f"))
|
|
95
|
+
__classPrivateFieldGet(this, _LiveQuery_client, "f").disposeQuerySubscription(__classPrivateFieldGet(this, _LiveQuery_uuid, "f"), __classPrivateFieldGet(this, _LiveQuery_id, "f")).catch(() => { });
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
_LiveQuery_client = new WeakMap(), _LiveQuery_uuid = new WeakMap(), _LiveQuery_open = new WeakMap(), _LiveQuery_onResult = new WeakMap(), _LiveQuery_id = new WeakMap(), _LiveQuery_revision = new WeakMap(), _LiveQuery_result = new WeakMap(), _LiveQuery_started = new WeakMap(), _LiveQuery_disposed = new WeakMap(), _LiveQuery_generation = new WeakMap(), _LiveQuery_latest = new WeakMap(), _LiveQuery_buffer = new WeakMap(), _LiveQuery_unlisten = new WeakMap(), _LiveQuery_unreconnect = new WeakMap(), _LiveQuery_instances = new WeakSet(), _LiveQuery_start = async function _LiveQuery_start(generation) {
|
|
99
|
+
__classPrivateFieldSet(this, _LiveQuery_buffer, [], "f");
|
|
100
|
+
let subscribed;
|
|
101
|
+
try {
|
|
102
|
+
subscribed = await __classPrivateFieldGet(this, _LiveQuery_open, "f").call(this);
|
|
103
|
+
}
|
|
104
|
+
catch (e) {
|
|
105
|
+
if (generation === __classPrivateFieldGet(this, _LiveQuery_generation, "f"))
|
|
106
|
+
__classPrivateFieldSet(this, _LiveQuery_buffer, null, "f");
|
|
107
|
+
throw e;
|
|
108
|
+
}
|
|
109
|
+
if (__classPrivateFieldGet(this, _LiveQuery_disposed, "f") || generation !== __classPrivateFieldGet(this, _LiveQuery_generation, "f")) {
|
|
110
|
+
__classPrivateFieldGet(this, _LiveQuery_client, "f").disposeQuerySubscription(__classPrivateFieldGet(this, _LiveQuery_uuid, "f"), subscribed.subscriptionId).catch(() => { });
|
|
111
|
+
// Disposed while opening (e.g. a newer subscribe() on the same
|
|
112
|
+
// builder): the caller still gets the snapshot that was read.
|
|
113
|
+
return __classPrivateFieldGet(this, _LiveQuery_disposed, "f") ? (__classPrivateFieldGet(this, _LiveQuery_result, "f") ?? subscribed.result) : __classPrivateFieldGet(this, _LiveQuery_latest, "f");
|
|
114
|
+
}
|
|
115
|
+
__classPrivateFieldSet(this, _LiveQuery_id, subscribed.subscriptionId, "f");
|
|
116
|
+
__classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_replace).call(this, subscribed.revision, subscribed.result);
|
|
117
|
+
return __classPrivateFieldGet(this, _LiveQuery_result, "f");
|
|
118
|
+
}, _LiveQuery_replace = function _LiveQuery_replace(revision, result) {
|
|
119
|
+
__classPrivateFieldSet(this, _LiveQuery_revision, revision, "f");
|
|
120
|
+
__classPrivateFieldSet(this, _LiveQuery_result, result, "f");
|
|
121
|
+
const buffered = __classPrivateFieldGet(this, _LiveQuery_buffer, "f") ?? [];
|
|
122
|
+
__classPrivateFieldSet(this, _LiveQuery_buffer, null, "f");
|
|
123
|
+
if (__classPrivateFieldGet(this, _LiveQuery_started, "f"))
|
|
124
|
+
__classPrivateFieldGet(this, _LiveQuery_onResult, "f").call(this, result);
|
|
125
|
+
__classPrivateFieldSet(this, _LiveQuery_started, true, "f");
|
|
126
|
+
for (const update of buffered)
|
|
127
|
+
__classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_receive).call(this, update);
|
|
128
|
+
}, _LiveQuery_receive = function _LiveQuery_receive(update) {
|
|
129
|
+
if (__classPrivateFieldGet(this, _LiveQuery_buffer, "f")) {
|
|
130
|
+
__classPrivateFieldGet(this, _LiveQuery_buffer, "f").push(update);
|
|
131
|
+
return;
|
|
132
|
+
}
|
|
133
|
+
if ('lagged' in update) {
|
|
134
|
+
if (__classPrivateFieldGet(this, _LiveQuery_id, "f"))
|
|
135
|
+
__classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_resync).call(this);
|
|
136
|
+
return;
|
|
137
|
+
}
|
|
138
|
+
if (update.subscriptionId !== __classPrivateFieldGet(this, _LiveQuery_id, "f") || update.revision <= __classPrivateFieldGet(this, _LiveQuery_revision, "f"))
|
|
139
|
+
return;
|
|
140
|
+
if (update.revision !== __classPrivateFieldGet(this, _LiveQuery_revision, "f") + 1) {
|
|
141
|
+
__classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_resync).call(this);
|
|
142
|
+
return;
|
|
143
|
+
}
|
|
144
|
+
let result;
|
|
145
|
+
try {
|
|
146
|
+
result = applyUpdate(__classPrivateFieldGet(this, _LiveQuery_result, "f"), update);
|
|
147
|
+
}
|
|
148
|
+
catch {
|
|
149
|
+
__classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_resync).call(this);
|
|
150
|
+
return;
|
|
151
|
+
}
|
|
152
|
+
__classPrivateFieldSet(this, _LiveQuery_revision, update.revision, "f");
|
|
153
|
+
__classPrivateFieldSet(this, _LiveQuery_result, result, "f");
|
|
154
|
+
__classPrivateFieldGet(this, _LiveQuery_onResult, "f").call(this, __classPrivateFieldGet(this, _LiveQuery_result, "f"));
|
|
155
|
+
}, _LiveQuery_resync = function _LiveQuery_resync() {
|
|
156
|
+
const generation = __classPrivateFieldGet(this, _LiveQuery_generation, "f");
|
|
157
|
+
const id = __classPrivateFieldGet(this, _LiveQuery_id, "f");
|
|
158
|
+
__classPrivateFieldSet(this, _LiveQuery_buffer, [], "f");
|
|
159
|
+
__classPrivateFieldGet(this, _LiveQuery_client, "f").resyncSubscription(__classPrivateFieldGet(this, _LiveQuery_uuid, "f"), id).then(({ revision, result }) => {
|
|
160
|
+
if (!__classPrivateFieldGet(this, _LiveQuery_disposed, "f") && generation === __classPrivateFieldGet(this, _LiveQuery_generation, "f"))
|
|
161
|
+
__classPrivateFieldGet(this, _LiveQuery_instances, "m", _LiveQuery_replace).call(this, revision, result);
|
|
162
|
+
}, () => {
|
|
163
|
+
// Replace the subscription with a new one.
|
|
164
|
+
if (!__classPrivateFieldGet(this, _LiveQuery_disposed, "f") && generation === __classPrivateFieldGet(this, _LiveQuery_generation, "f")) {
|
|
165
|
+
__classPrivateFieldGet(this, _LiveQuery_client, "f").disposeQuerySubscription(__classPrivateFieldGet(this, _LiveQuery_uuid, "f"), id).catch(() => { });
|
|
166
|
+
this.start().catch(e => console.error('Error re-opening live query:', e));
|
|
167
|
+
}
|
|
168
|
+
});
|
|
169
|
+
};
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { Link, LinkExpression, LinkExpressionInput, LinkInput } from "../links/Links";
|
|
2
2
|
import { LinkQuery } from "./LinkQuery";
|
|
3
|
+
import type { DecoratedPerspective } from "../generated/api/DecoratedPerspective";
|
|
4
|
+
import type { Perspective as WirePerspective } from "../generated/api/Perspective";
|
|
5
|
+
import type { PerspectiveExpression as WirePerspectiveExpression } from "../generated/api/PerspectiveExpression";
|
|
3
6
|
/** A Perspective represents subjective meaning, encoded through
|
|
4
7
|
* associations between expressions, a.k.a. Links, that is a graph
|
|
5
8
|
* over the objective Expressions of any subset of Languages.
|
|
@@ -16,6 +19,9 @@ export declare class Perspective {
|
|
|
16
19
|
/** The content of the perspective, a list/graph of links */
|
|
17
20
|
links: LinkExpression[];
|
|
18
21
|
constructor(links?: LinkExpression[]);
|
|
22
|
+
/** Build a Perspective (with its query helpers) from the executor's wire shape. */
|
|
23
|
+
static fromWire(wire: DecoratedPerspective | null): Perspective;
|
|
24
|
+
static toWire(perspective: Perspective): WirePerspective;
|
|
19
25
|
/** Convenience function for filtering links just like with PerspectiveProxy */
|
|
20
26
|
get(query: LinkQuery): LinkExpression[];
|
|
21
27
|
/** Convenience function to get the target of the first link that matches the given query
|
|
@@ -32,7 +38,8 @@ export declare class PerspectiveUnsignedInput {
|
|
|
32
38
|
constructor(links?: LinkInput[]);
|
|
33
39
|
static fromLink(link: Link): PerspectiveUnsignedInput;
|
|
34
40
|
}
|
|
35
|
-
declare const PerspectiveExpression_base:
|
|
41
|
+
declare const PerspectiveExpression_base: abstract new (author?: string, timestamp?: string, data?: Perspective, proof?: import("../expression/Expression").ExpressionProof) => import("../expression/Expression").ExpressionShape<Perspective, import("../expression/Expression").ExpressionProof>;
|
|
36
42
|
export declare class PerspectiveExpression extends PerspectiveExpression_base {
|
|
43
|
+
static fromWire(wire: WirePerspectiveExpression): PerspectiveExpression;
|
|
37
44
|
}
|
|
38
45
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ExpressionGeneric } from "../expression/Expression";
|
|
2
|
+
import { LinkExpression, linkExpressionToWire } from "../links/Links";
|
|
2
3
|
/** A Perspective represents subjective meaning, encoded through
|
|
3
4
|
* associations between expressions, a.k.a. Links, that is a graph
|
|
4
5
|
* over the objective Expressions of any subset of Languages.
|
|
@@ -20,6 +21,13 @@ export class Perspective {
|
|
|
20
21
|
this.links = [];
|
|
21
22
|
}
|
|
22
23
|
}
|
|
24
|
+
/** Build a Perspective (with its query helpers) from the executor's wire shape. */
|
|
25
|
+
static fromWire(wire) {
|
|
26
|
+
return new Perspective((wire?.links ?? []).map(LinkExpression.fromWire));
|
|
27
|
+
}
|
|
28
|
+
static toWire(perspective) {
|
|
29
|
+
return { links: perspective.links.map(linkExpressionToWire) };
|
|
30
|
+
}
|
|
23
31
|
/** Convenience function for filtering links just like with PerspectiveProxy */
|
|
24
32
|
get(query) {
|
|
25
33
|
if (!query || !query.source && !query.predicate && !query.target) {
|
|
@@ -98,5 +106,8 @@ export class PerspectiveUnsignedInput {
|
|
|
98
106
|
}
|
|
99
107
|
}
|
|
100
108
|
export class PerspectiveExpression extends ExpressionGeneric(Perspective) {
|
|
109
|
+
static fromWire(wire) {
|
|
110
|
+
return new PerspectiveExpression(wire.author, wire.timestamp, Perspective.fromWire(wire.data), wire.proof);
|
|
111
|
+
}
|
|
101
112
|
}
|
|
102
113
|
;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { ApiClient, CallOptions } from
|
|
1
|
+
import { ApiClient, CallOptions, EventFilter } from '../apiClient';
|
|
2
|
+
import type { EventMap, EventName } from '../generated/api/Events';
|
|
2
3
|
import { ExpressionRendered } from "../expression/Expression";
|
|
3
4
|
import { ExpressionClient } from "../expression/ExpressionClient";
|
|
4
5
|
import { Link, LinkExpressionInput, LinkExpression, LinkMutations, LinkExpressionMutations } from "../links/Links";
|
|
@@ -6,20 +7,16 @@ import { NeighbourhoodClient } from "../neighbourhood/NeighbourhoodClient";
|
|
|
6
7
|
import { NeighbourhoodProxy } from "../neighbourhood/NeighbourhoodProxy";
|
|
7
8
|
import { LinkQuery } from "./LinkQuery";
|
|
8
9
|
import { Perspective } from "./Perspective";
|
|
9
|
-
import { PerspectiveHandle, PerspectiveState } from "./PerspectiveHandle";
|
|
10
10
|
import { LinkStatus, PerspectiveProxy } from './PerspectiveProxy';
|
|
11
11
|
import { AIClient } from "../ai/AIClient";
|
|
12
|
-
import {
|
|
12
|
+
import type { QueryLagged, QueryUpdate, Subscribed } from "./LiveQuery";
|
|
13
13
|
import type { TranscriptTurn } from "../generated/api";
|
|
14
|
-
import type {
|
|
15
|
-
import type {
|
|
16
|
-
|
|
17
|
-
export type UuidCallback = (uuid: string) => null;
|
|
18
|
-
export type LinkCallback = (link: LinkExpression) => null;
|
|
19
|
-
export type SyncStateChangeCallback = (state: PerspectiveState) => null;
|
|
14
|
+
import type { JsonValue } from "../generated/api/serde_json/JsonValue";
|
|
15
|
+
import type { AddAutoProcessorConfig, InterpretationOverlayInfo, RawScope, RunInterpretationObserveOptions } from "./AutoProcessor";
|
|
16
|
+
import type { FlowFireOutcome, FlowMintedReceipt, FlowOutputRef, FlowProposeResult, FlowReceiptVerdict, FlowStateEntry, FlowValidOutput } from "./FlowInstance";
|
|
20
17
|
export declare class PerspectiveClient {
|
|
21
18
|
#private;
|
|
22
|
-
constructor(baseUrl: string, token?: string,
|
|
19
|
+
constructor(baseUrl: string, token?: string, sharedApiClient?: ApiClient);
|
|
23
20
|
setExpressionClient(client: ExpressionClient): void;
|
|
24
21
|
setNeighbourhoodClient(client: NeighbourhoodClient): void;
|
|
25
22
|
setAIClient(client: AIClient): void;
|
|
@@ -31,22 +28,24 @@ export declare class PerspectiveClient {
|
|
|
31
28
|
queryLinks(uuid: string, query: LinkQuery, options?: CallOptions): Promise<LinkExpression[]>;
|
|
32
29
|
queryProlog(uuid: string, query: string, options?: CallOptions): Promise<unknown>;
|
|
33
30
|
querySparql<T = any>(uuid: string, query: string, options?: CallOptions): Promise<T>;
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
31
|
+
/** Open a live SPARQL query. Updates arrive through {@link onQueryUpdate}. */
|
|
32
|
+
subscribeQuery(uuid: string, query: string): Promise<Subscribed>;
|
|
33
|
+
/** Every `query-subscription-update` event on this client's socket. */
|
|
34
|
+
onQueryUpdate(cb: (update: QueryUpdate | QueryLagged) => void): () => void;
|
|
35
|
+
/** The current result and revision of a live query, after a revision gap. */
|
|
36
|
+
resyncSubscription(uuid: string, subscriptionId: string): Promise<{
|
|
37
|
+
revision: number;
|
|
38
|
+
result: any;
|
|
37
39
|
}>;
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
subscribeToQueryUpdates(subscriptionId: string, onData: (result: AllInstancesResult) => void): () => void;
|
|
41
|
-
keepAliveQuery(uuid: string, subscriptionId: string): Promise<boolean>;
|
|
40
|
+
/** Ends the subscription on the executor. The caller releases its local listener
|
|
41
|
+
* with the function {@link onQueryUpdate} returned. */
|
|
42
42
|
disposeQuerySubscription(uuid: string, subscriptionId: string): Promise<boolean>;
|
|
43
|
-
|
|
43
|
+
/** `className` may name several classes: one query over their union (#1238). */
|
|
44
|
+
modelQuery(uuid: string, className: string | string[], queryJson: string, options?: CallOptions): Promise<any>;
|
|
44
45
|
subjectClassesOf(uuid: string, uris: string[]): Promise<Record<string, string[]>>;
|
|
45
46
|
evaluateGetters(uuid: string, className: string, instanceIds: string[], propertyNames?: string[]): Promise<Record<string, Record<string, any>>>;
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
result: any;
|
|
49
|
-
}>;
|
|
47
|
+
/** Open a live model query over one class or several. Updates arrive through {@link onQueryUpdate}. */
|
|
48
|
+
modelSubscribe(uuid: string, className: string | string[], queryJson: string): Promise<Subscribed>;
|
|
50
49
|
add(name: string): Promise<PerspectiveProxy>;
|
|
51
50
|
update(uuid: string, name: string): Promise<PerspectiveProxy>;
|
|
52
51
|
remove(uuid: string): Promise<{
|
|
@@ -64,8 +63,7 @@ export declare class PerspectiveClient {
|
|
|
64
63
|
*
|
|
65
64
|
* The server-side call prompts an LLM (up to `INTERPRETATION_MAX_ATTEMPTS`
|
|
66
65
|
* retries on parse failure), so it can legitimately take minutes on slower
|
|
67
|
-
* or CPU-only models
|
|
68
|
-
* (matches the CI `--timeout 1200000` for the interpretation tests).
|
|
66
|
+
* or CPU-only models, so it defaults to {@link LONG_TIMEOUT_MS}.
|
|
69
67
|
*
|
|
70
68
|
* `existingScope` and `mintScope` match the AutoProcessor semantics:
|
|
71
69
|
* `existingScope` constrains the dedup lookup to instances under a
|
|
@@ -73,7 +71,7 @@ export declare class PerspectiveClient {
|
|
|
73
71
|
* `mintScope.id` via its predicate (upserts of pre-existing instances
|
|
74
72
|
* are NOT re-parented — same rule as the watcher).
|
|
75
73
|
*/
|
|
76
|
-
runInterpretation(uuid: string, transcript: TranscriptTurn[], basePrefix: string, classes?: string[], existingScope?: RawScope, mintScope?: RawScope, observe?: RunInterpretationObserveOptions): Promise<string[]>;
|
|
74
|
+
runInterpretation(uuid: string, transcript: TranscriptTurn[], basePrefix: string, classes?: string[], existingScope?: RawScope, mintScope?: RawScope, observe?: RunInterpretationObserveOptions, options?: CallOptions): Promise<string[]>;
|
|
77
75
|
/**
|
|
78
76
|
* Tool-calling counterpart to {@link runInterpretation}. The LLM sees a
|
|
79
77
|
* live per-class tool surface (`{Class}_query`, `{Class}_propose_create`,
|
|
@@ -85,17 +83,15 @@ export declare class PerspectiveClient {
|
|
|
85
83
|
* the harness to a no-op final-answer step; use {@link runInterpretation}
|
|
86
84
|
* for the classic single-shot path.
|
|
87
85
|
*
|
|
88
|
-
*
|
|
89
|
-
* that calls several tools can legitimately take longer than one plain
|
|
90
|
-
* generation.
|
|
86
|
+
* Defaults to {@link LONG_TIMEOUT_MS}, like the single-shot path.
|
|
91
87
|
*/
|
|
92
|
-
runInterpretationWithHarness(uuid: string, transcript: TranscriptTurn[], basePrefix: string, maxToolCalls: number, classes?: string[], modelOverride?: string, existingScope?: RawScope, observationId?: string, emitDebugEvents?: boolean): Promise<string[]>;
|
|
88
|
+
runInterpretationWithHarness(uuid: string, transcript: TranscriptTurn[], basePrefix: string, maxToolCalls: number, classes?: string[], modelOverride?: string, existingScope?: RawScope, observationId?: string, emitDebugEvents?: boolean, options?: CallOptions): Promise<string[]>;
|
|
93
89
|
/**
|
|
94
90
|
* Register a neighbourhood auto-processor on this perspective. The executor's
|
|
95
91
|
* watch loop then runs interpretation automatically over new source items
|
|
96
92
|
* (like Flux per channel), coordinating which peer processes each batch via
|
|
97
93
|
* the shared-graph ProcessingClaim, and emits step signals on the events
|
|
98
|
-
* WebSocket (subscribe
|
|
94
|
+
* WebSocket (subscribe with `on('auto-processor-event', …, { perspective })`).
|
|
99
95
|
* Returns the processor id.
|
|
100
96
|
*/
|
|
101
97
|
addAutoProcessor(uuid: string, config: AddAutoProcessorConfig): Promise<string>;
|
|
@@ -118,34 +114,20 @@ export declare class PerspectiveClient {
|
|
|
118
114
|
*/
|
|
119
115
|
rejectFlowProposal(uuid: string, proposalUri: string): Promise<number>;
|
|
120
116
|
/** Re-decide a flow receipt under this perspective's own flow catalogue. */
|
|
121
|
-
verifyFlowReceipt(uuid: string, receipt:
|
|
117
|
+
verifyFlowReceipt(uuid: string, receipt: JsonValue): Promise<FlowReceiptVerdict>;
|
|
122
118
|
/** The instances that are, as they stand, valid outputs of `flow`
|
|
123
119
|
* (optionally: of runs settled into terminal state `state`). */
|
|
124
120
|
flowValidOutputs(uuid: string, flow: string, state?: string): Promise<FlowValidOutput[]>;
|
|
121
|
+
/** The calling agent's recorded state of each flow instance it has
|
|
122
|
+
* derived, optionally narrowed to `instances`. */
|
|
123
|
+
flowStates(uuid: string, instances?: string[]): Promise<FlowStateEntry[]>;
|
|
124
|
+
/** The proposals of `instance` the calling agent's replica recorded as
|
|
125
|
+
* fired, sorted. */
|
|
126
|
+
flowFired(uuid: string, instance: string): Promise<string[]>;
|
|
125
127
|
/** Mint and store the receipt for a completed flow run. Fails while the
|
|
126
128
|
* run has not settled into a terminal state, and when an output's
|
|
127
129
|
* content no longer matches what the quorum committed to. */
|
|
128
130
|
mintFlowReceipt(uuid: string, instanceUri: string): Promise<FlowMintedReceipt>;
|
|
129
|
-
/**
|
|
130
|
-
* Subscribe to auto-processor step signals. `cb` fires for every
|
|
131
|
-
* `auto-processor-event` on `uuid` (BatchReady → Claimed/BackedOff/… →
|
|
132
|
-
* Processed), letting a UI show progress and await the next batch.
|
|
133
|
-
*
|
|
134
|
-
* Registered on the per-uuid `#linkUnsubscribers` map so
|
|
135
|
-
* `PerspectiveProxy.dispose()` → `removeAllListeners(uuid)` cleans the
|
|
136
|
-
* subscription up; using the global `#unsubscribers` array would leak
|
|
137
|
-
* callbacks across repeated view lifecycles (CodeRabbit #881 review).
|
|
138
|
-
*/
|
|
139
|
-
addAutoProcessorEventListener(uuid: String, cb: (event: AutoProcessorEvent) => void): Promise<void>;
|
|
140
|
-
/**
|
|
141
|
-
* Subscribe to neighbourhood-state events on a perspective. `cb` fires
|
|
142
|
-
* when THIS executor claims / finishes / abandons a batch for any
|
|
143
|
-
* processor on `uuid` — perspective-scoped observability so a UI can
|
|
144
|
-
* render "someone is auto-processing this" without receiving the batch
|
|
145
|
-
* payload or LLM I/O. Registered on the per-uuid `#linkUnsubscribers`
|
|
146
|
-
* map so `PerspectiveProxy.dispose()` sweeps it up.
|
|
147
|
-
*/
|
|
148
|
-
addAutoProcessorNeighbourhoodStateListener(uuid: String, cb: (event: AutoProcessorNeighbourhoodStateEvent) => void): Promise<void>;
|
|
149
131
|
addLinkExpression(uuid: string, link: LinkExpression, status?: LinkStatus, batchId?: string): Promise<LinkExpression>;
|
|
150
132
|
updateLink(uuid: string, oldLink: LinkExpressionInput, newLink: Link, batchId?: string): Promise<LinkExpression>;
|
|
151
133
|
removeLink(uuid: string, link: LinkExpressionInput, batchId?: string): Promise<boolean>;
|
|
@@ -158,6 +140,9 @@ export declare class PerspectiveClient {
|
|
|
158
140
|
}[]): Promise<boolean[]>;
|
|
159
141
|
executeCommands(uuid: string, commands: string, expression: string, parameters: string, batchId?: string): Promise<boolean>;
|
|
160
142
|
createSubject(uuid: string, subjectClass: string, expressionAddress: string, initialValues?: string, batchId?: string): Promise<boolean>;
|
|
143
|
+
/** Through an abstract class (#1435), the executor writes to the record's own classes. */
|
|
144
|
+
updateSubject(uuid: string, subjectClass: string, expressionAddress: string, values: string, batchId?: string): Promise<boolean>;
|
|
145
|
+
removeSubject(uuid: string, subjectClass: string, expressionAddress: string, batchId?: string): Promise<boolean>;
|
|
161
146
|
getSubjectData(uuid: string, subjectClass: string, expressionAddress: string): Promise<string>;
|
|
162
147
|
/** List the names of every SHACL shape stored in a perspective (one RPC call). */
|
|
163
148
|
getShaclNames(uuid: string): Promise<string[]>;
|
|
@@ -200,20 +185,8 @@ export declare class PerspectiveClient {
|
|
|
200
185
|
}>>;
|
|
201
186
|
getExpression(expressionURI: string): Promise<ExpressionRendered>;
|
|
202
187
|
createExpression(content: unknown, languageAddress: string): Promise<string>;
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
addPerspectiveUpdatedListener(cb: PerspectiveHandleCallback): void;
|
|
206
|
-
subscribePerspectiveUpdated(): void;
|
|
207
|
-
addPerspectiveSyncedListener(cb: SyncStateChangeCallback): void;
|
|
208
|
-
addPerspectiveSyncStateChangeListener(uuid: String, cb: SyncStateChangeCallback[]): Promise<void>;
|
|
209
|
-
addPerspectiveRemovedListener(cb: UuidCallback): void;
|
|
210
|
-
subscribePerspectiveRemoved(): void;
|
|
211
|
-
addPerspectiveLinkAddedListener(uuid: String, cb: LinkCallback[]): Promise<void>;
|
|
212
|
-
addPerspectiveLinkRemovedListener(uuid: String, cb: LinkCallback[]): Promise<void>;
|
|
213
|
-
addPerspectiveLinkUpdatedListener(uuid: String, cb: LinkCallback[]): Promise<void>;
|
|
214
|
-
/** Unsubscribe all link/sync-state listeners registered for the given perspective UUID.
|
|
215
|
-
* Called by PerspectiveProxy.dispose() to prevent subscription leaks. */
|
|
216
|
-
removeAllListeners(uuid: string): void;
|
|
188
|
+
/** The client's event bus; see {@link ApiClient.on}. */
|
|
189
|
+
on<K extends EventName>(type: K, handler: (event: EventMap[K]) => void, filter?: EventFilter): () => void;
|
|
217
190
|
getNeighbourhoodProxy(uuid: string): NeighbourhoodProxy;
|
|
218
191
|
createBatch(uuid: string): Promise<string>;
|
|
219
192
|
commitBatch(uuid: string, batchId: string): Promise<LinkExpressionMutations>;
|