@indexnetwork/protocol 14.3.2-rc.477.1 → 17.0.0-rc.479.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +141 -0
- package/IMPLEMENTATION.md +50 -52
- package/STABILITY.md +3 -3
- package/dist/chat/chat.agent.js +2 -3
- package/dist/chat/chat.graph.d.ts +41 -1
- package/dist/chat/chat.graph.js +108 -127
- package/dist/chat/negotiator.persona.d.ts +1 -1
- package/dist/chat/negotiator.persona.js +1 -4
- package/dist/chat/negotiator.prompt.js +1 -2
- package/dist/chat/onboarding.persona.js +0 -1
- package/dist/chat/reporter.persona.js +0 -1
- package/dist/chat/signal.persona.js +0 -1
- package/dist/contacts/application/contact.tools.d.ts +6 -9
- package/dist/contacts/application/contact.tools.js +11 -92
- package/dist/contacts/application/index.d.ts +2 -14
- package/dist/contacts/application/index.js +2 -13
- package/dist/contacts/domain/contact.types.d.ts +0 -23
- package/dist/contacts/domain/index.d.ts +2 -6
- package/dist/contacts/index.d.ts +1 -1
- package/dist/contacts/index.js +1 -1
- package/dist/contacts/ports/contact.repository.port.d.ts +5 -12
- package/dist/contacts/ports/contact.repository.port.js +4 -6
- package/dist/contacts/ports/contact.tools.port.d.ts +1 -3
- package/dist/contacts/ports/contact.tools.port.js +1 -2
- package/dist/contacts/ports/index.d.ts +1 -1
- package/dist/contacts/ports/index.js +1 -1
- package/dist/discovery/hyde.frame.d.ts +4 -4
- package/dist/discovery/hyde.graph.d.ts +71 -12
- package/dist/discovery/hyde.graph.js +337 -335
- package/dist/discovery/lens.inferrer.d.ts +6 -6
- package/dist/enrichment/enrichment.graph.d.ts +127 -9
- package/dist/enrichment/enrichment.graph.js +633 -655
- package/dist/enrichment/enrichment.state.d.ts +1 -1
- package/dist/enrichment/enrichment.tools.context-read.d.ts +10 -0
- package/dist/enrichment/enrichment.tools.context-read.js +353 -0
- package/dist/enrichment/enrichment.tools.context-write.d.ts +9 -0
- package/dist/enrichment/enrichment.tools.context-write.js +417 -0
- package/dist/enrichment/enrichment.tools.d.ts +11 -1
- package/dist/enrichment/enrichment.tools.helpers.d.ts +139 -0
- package/dist/enrichment/enrichment.tools.helpers.js +234 -0
- package/dist/enrichment/enrichment.tools.js +16 -975
- package/dist/index.d.ts +27 -50
- package/dist/index.js +17 -28
- package/dist/intents/application/intent.graph.d.ts +71 -67
- package/dist/intents/application/intent.graph.execute.d.ts +59 -0
- package/dist/intents/application/intent.graph.execute.js +301 -0
- package/dist/intents/application/intent.graph.infer.d.ts +44 -0
- package/dist/intents/application/intent.graph.infer.js +97 -0
- package/dist/intents/application/intent.graph.js +96 -888
- package/dist/intents/application/intent.graph.reconcile.d.ts +71 -0
- package/dist/intents/application/intent.graph.reconcile.js +274 -0
- package/dist/intents/application/intent.graph.shared.d.ts +70 -0
- package/dist/intents/application/intent.graph.shared.js +153 -0
- package/dist/intents/domain/intent.state.d.ts +1 -1
- package/dist/maintenance/maintenance.graph.d.ts +66 -3
- package/dist/maintenance/maintenance.graph.js +155 -156
- package/dist/mcp/mcp.authorization-policy.d.ts +24 -28
- package/dist/mcp/mcp.authorization-policy.js +14 -34
- package/dist/mcp/mcp.server.d.ts +3 -3
- package/dist/mcp/mcp.server.js +14 -20
- package/dist/negotiations/application/negotiation.candidates.d.ts +83 -0
- package/dist/negotiations/application/negotiation.candidates.js +162 -0
- package/dist/negotiations/application/negotiation.graph.d.ts +91 -157
- package/dist/negotiations/application/negotiation.graph.finalize.d.ts +5 -0
- package/dist/negotiations/application/negotiation.graph.finalize.js +280 -0
- package/dist/negotiations/application/negotiation.graph.init.d.ts +54 -0
- package/dist/negotiations/application/negotiation.graph.init.js +227 -0
- package/dist/negotiations/application/negotiation.graph.js +69 -1388
- package/dist/negotiations/application/negotiation.graph.screen.d.ts +23 -0
- package/dist/negotiations/application/negotiation.graph.screen.js +108 -0
- package/dist/negotiations/application/negotiation.graph.shared.d.ts +75 -0
- package/dist/negotiations/application/negotiation.graph.shared.js +125 -0
- package/dist/negotiations/application/negotiation.graph.turn.d.ts +105 -0
- package/dist/negotiations/application/negotiation.graph.turn.js +484 -0
- package/dist/negotiations/domain/negotiation.state.d.ts +1 -1
- package/dist/negotiations/domain/negotiation.state.js +0 -1
- package/dist/networks/application/indexer.graph.d.ts +165 -7
- package/dist/networks/application/indexer.graph.js +339 -388
- package/dist/networks/application/indexer.state.d.ts +1 -1
- package/dist/networks/application/membership.graph.d.ts +83 -5
- package/dist/networks/application/membership.graph.js +177 -207
- package/dist/networks/application/network.graph.d.ts +148 -5
- package/dist/networks/application/network.graph.js +249 -278
- package/dist/networks/domain/membership.state.d.ts +1 -1
- package/dist/networks/domain/network.state.d.ts +1 -1
- package/dist/opportunities/application/delivery-card.cache.d.ts +1 -1
- package/dist/opportunities/application/delivery-card.cache.js +2 -2
- package/dist/opportunities/application/index.d.ts +2 -2
- package/dist/opportunities/application/index.js +2 -2
- package/dist/opportunities/application/opportunity.evaluator.js +1 -1
- package/dist/opportunities/application/opportunity.graph.d.ts +686 -473
- package/dist/opportunities/application/opportunity.graph.discovery-strategies.d.ts +109 -0
- package/dist/opportunities/application/opportunity.graph.discovery-strategies.js +451 -0
- package/dist/opportunities/application/opportunity.graph.discovery.d.ts +69 -0
- package/dist/opportunities/application/opportunity.graph.discovery.js +397 -0
- package/dist/opportunities/application/opportunity.graph.evaluation.d.ts +82 -0
- package/dist/opportunities/application/opportunity.graph.evaluation.js +608 -0
- package/dist/opportunities/application/opportunity.graph.js +120 -3690
- package/dist/opportunities/application/opportunity.graph.modes.d.ts +538 -0
- package/dist/opportunities/application/opportunity.graph.modes.js +538 -0
- package/dist/opportunities/application/opportunity.graph.negotiate.d.ts +109 -0
- package/dist/opportunities/application/opportunity.graph.negotiate.js +392 -0
- package/dist/opportunities/application/opportunity.graph.persist-node.d.ts +93 -0
- package/dist/opportunities/application/opportunity.graph.persist-node.js +765 -0
- package/dist/opportunities/application/opportunity.graph.prep.d.ts +150 -0
- package/dist/opportunities/application/opportunity.graph.prep.js +381 -0
- package/dist/opportunities/application/opportunity.graph.shared.d.ts +173 -0
- package/dist/opportunities/application/opportunity.graph.shared.js +199 -0
- package/dist/opportunities/application/opportunity.presentation.d.ts +399 -0
- package/dist/opportunities/application/{opportunity.presenter.js → opportunity.presentation.js} +735 -9
- package/dist/opportunities/application/opportunity.tools.cards.d.ts +152 -0
- package/dist/opportunities/application/opportunity.tools.cards.js +235 -0
- package/dist/opportunities/application/opportunity.tools.d.ts +8 -114
- package/dist/opportunities/application/opportunity.tools.js +28 -711
- package/dist/opportunities/application/opportunity.tools.list.d.ts +10 -0
- package/dist/opportunities/application/opportunity.tools.list.js +493 -0
- package/dist/opportunities/domain/index.d.ts +3 -3
- package/dist/opportunities/domain/index.js +3 -3
- package/dist/opportunities/domain/opportunity.state.d.ts +19 -19
- package/dist/opportunities/index.d.ts +6 -6
- package/dist/opportunities/index.js +4 -4
- package/dist/opportunities/ports/opportunity.tools.port.d.ts +1 -1
- package/dist/opportunities/radar/radar.graph.d.ts +57 -13
- package/dist/opportunities/radar/radar.graph.js +470 -471
- package/dist/premises/premise.graph.d.ts +88 -20
- package/dist/premises/premise.graph.js +207 -218
- package/dist/questions/domain/question.schema.d.ts +40 -40
- package/dist/shared/agent/tool.factory.js +0 -8
- package/dist/shared/agent/tool.helpers.d.ts +21 -45
- package/dist/shared/agent/tool.helpers.js +1 -2
- package/dist/shared/agent/tool.registry.d.ts +4 -3
- package/dist/shared/agent/tool.registry.js +2 -4
- package/dist/shared/agent/tool.runtime.js +0 -2
- package/dist/shared/agent/utility.tools.js +9 -13
- package/dist/shared/interfaces/database.capabilities.d.ts +100 -0
- package/dist/shared/interfaces/database.capabilities.js +7 -0
- package/dist/shared/interfaces/database.entities.d.ts +533 -0
- package/dist/shared/interfaces/database.entities.js +10 -0
- package/dist/shared/interfaces/database.identity-queries.d.ts +294 -0
- package/dist/shared/interfaces/database.identity-queries.js +4 -0
- package/dist/shared/interfaces/database.interface.d.ts +15 -2277
- package/dist/shared/interfaces/database.interface.js +8 -0
- package/dist/shared/interfaces/database.member-queries.d.ts +221 -0
- package/dist/shared/interfaces/database.member-queries.js +4 -0
- package/dist/shared/interfaces/database.negotiation.d.ts +305 -0
- package/dist/shared/interfaces/database.negotiation.js +26 -0
- package/dist/shared/interfaces/database.network-queries.d.ts +277 -0
- package/dist/shared/interfaces/database.network-queries.js +4 -0
- package/dist/shared/interfaces/database.opportunity-queries.d.ts +285 -0
- package/dist/shared/interfaces/database.opportunity-queries.js +4 -0
- package/dist/shared/interfaces/database.port.d.ts +322 -0
- package/dist/shared/interfaces/database.port.js +29 -0
- package/dist/shared/schemas/discovery-question.schema.d.ts +14 -14
- package/dist/shared/schemas/negotiation-digest.schema.d.ts +2 -2
- package/package.json +2 -15
- package/dist/contacts/application/contact.inviter.d.ts +0 -49
- package/dist/contacts/application/contact.inviter.js +0 -64
- package/dist/integrations/application/index.d.ts +0 -14
- package/dist/integrations/application/index.js +0 -14
- package/dist/integrations/application/integration.tools.d.ts +0 -27
- package/dist/integrations/application/integration.tools.js +0 -98
- package/dist/integrations/domain/index.d.ts +0 -16
- package/dist/integrations/domain/index.js +0 -1
- package/dist/integrations/domain/integration.types.d.ts +0 -51
- package/dist/integrations/domain/integration.types.js +0 -9
- package/dist/integrations/index.d.ts +0 -10
- package/dist/integrations/index.js +0 -8
- package/dist/integrations/ports/index.d.ts +0 -25
- package/dist/integrations/ports/index.js +0 -23
- package/dist/integrations/ports/integration.adapter.port.d.ts +0 -62
- package/dist/integrations/ports/integration.adapter.port.js +0 -15
- package/dist/integrations/ports/integration.importer.port.d.ts +0 -31
- package/dist/integrations/ports/integration.importer.port.js +0 -15
- package/dist/integrations/ports/integration.tools.port.d.ts +0 -25
- package/dist/integrations/ports/integration.tools.port.js +0 -18
- package/dist/opportunities/application/opportunity.card-presentation.d.ts +0 -44
- package/dist/opportunities/application/opportunity.card-presentation.js +0 -93
- package/dist/opportunities/application/opportunity.presenter.d.ts +0 -156
- package/dist/opportunities/domain/opportunity.presentation-cache.d.ts +0 -5
- package/dist/opportunities/domain/opportunity.presentation-cache.js +0 -11
- package/dist/opportunities/domain/opportunity.presentation.d.ts +0 -76
- package/dist/opportunities/domain/opportunity.presentation.js +0 -516
- package/dist/opportunities/domain/opportunity.safe-presentation.d.ts +0 -104
- package/dist/opportunities/domain/opportunity.safe-presentation.js +0 -102
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { IntentNetworkGraphDatabase } from "../ports/index.js";
|
|
2
2
|
import type { DebugMetaAgent } from "../../agents/index.js";
|
|
3
3
|
import type { IntentIndexer } from "../ports/index.js";
|
|
4
|
-
import { type AssignmentResult } from "./indexer.state.js";
|
|
4
|
+
import { IntentNetworkGraphState, type AssignmentResult } from "./indexer.state.js";
|
|
5
5
|
/**
|
|
6
6
|
* Factory class to build and compile the Intent–Network (indexer) Graph.
|
|
7
7
|
*
|
|
@@ -44,15 +44,22 @@ import { type AssignmentResult } from "./indexer.state.js";
|
|
|
44
44
|
* IND-546: canonical home — previously network/indexer/indexer.graph.ts.
|
|
45
45
|
* Signals dependency consumed via capabilities/signals.facade.ts (through ports).
|
|
46
46
|
*/
|
|
47
|
+
/** The graph's channel state, as every node sees it. */
|
|
48
|
+
export type IntentNetworkState = typeof IntentNetworkGraphState.State;
|
|
49
|
+
/** Everything the intent-network nodes reach for. */
|
|
50
|
+
export interface IntentNetworkGraphDeps {
|
|
51
|
+
database: IntentNetworkGraphDatabase;
|
|
52
|
+
intentNetworker: IntentIndexer;
|
|
53
|
+
}
|
|
47
54
|
export declare class IntentNetworkGraphFactory {
|
|
48
|
-
|
|
49
|
-
|
|
55
|
+
/** Resolved dependency bag shared by every node. */
|
|
56
|
+
readonly deps: IntentNetworkGraphDeps;
|
|
50
57
|
constructor(database: IntentNetworkGraphDatabase, intentNetworker: IntentIndexer);
|
|
51
58
|
createGraph(): import("@langchain/langgraph").CompiledStateGraph<{
|
|
52
59
|
userId: string;
|
|
53
60
|
networkId: string | undefined;
|
|
54
61
|
intentId: string | undefined;
|
|
55
|
-
operationMode: "
|
|
62
|
+
operationMode: "create" | "delete" | "read";
|
|
56
63
|
skipEvaluation: boolean;
|
|
57
64
|
intent: import("./indexer.state.js").IntentForIndexing | null;
|
|
58
65
|
indexContext: import("./indexer.state.js").IndexMemberContext | null;
|
|
@@ -91,7 +98,7 @@ export declare class IntentNetworkGraphFactory {
|
|
|
91
98
|
userId?: string | undefined;
|
|
92
99
|
networkId?: string | import("@langchain/langgraph").OverwriteValue<string | undefined> | undefined;
|
|
93
100
|
intentId?: string | import("@langchain/langgraph").OverwriteValue<string | undefined> | undefined;
|
|
94
|
-
operationMode?: "
|
|
101
|
+
operationMode?: "create" | "delete" | "read" | import("@langchain/langgraph").OverwriteValue<"create" | "delete" | "read"> | undefined;
|
|
95
102
|
skipEvaluation?: boolean | import("@langchain/langgraph").OverwriteValue<boolean> | undefined;
|
|
96
103
|
intent?: import("./indexer.state.js").IntentForIndexing | import("@langchain/langgraph").OverwriteValue<import("./indexer.state.js").IntentForIndexing | null> | null | undefined;
|
|
97
104
|
indexContext?: import("./indexer.state.js").IndexMemberContext | import("@langchain/langgraph").OverwriteValue<import("./indexer.state.js").IndexMemberContext | null> | null | undefined;
|
|
@@ -156,7 +163,7 @@ export declare class IntentNetworkGraphFactory {
|
|
|
156
163
|
};
|
|
157
164
|
networkId: import("@langchain/langgraph").BaseChannel<string | undefined, string | import("@langchain/langgraph").OverwriteValue<string | undefined> | undefined, unknown>;
|
|
158
165
|
intentId: import("@langchain/langgraph").BaseChannel<string | undefined, string | import("@langchain/langgraph").OverwriteValue<string | undefined> | undefined, unknown>;
|
|
159
|
-
operationMode: import("@langchain/langgraph").BaseChannel<"
|
|
166
|
+
operationMode: import("@langchain/langgraph").BaseChannel<"create" | "delete" | "read", "create" | "delete" | "read" | import("@langchain/langgraph").OverwriteValue<"create" | "delete" | "read">, unknown>;
|
|
160
167
|
skipEvaluation: import("@langchain/langgraph").BaseChannel<boolean, boolean | import("@langchain/langgraph").OverwriteValue<boolean>, unknown>;
|
|
161
168
|
intent: import("@langchain/langgraph").BaseChannel<import("./indexer.state.js").IntentForIndexing | null, import("./indexer.state.js").IntentForIndexing | import("@langchain/langgraph").OverwriteValue<import("./indexer.state.js").IntentForIndexing | null> | null, unknown>;
|
|
162
169
|
indexContext: import("@langchain/langgraph").BaseChannel<import("./indexer.state.js").IndexMemberContext | null, import("./indexer.state.js").IndexMemberContext | import("@langchain/langgraph").OverwriteValue<import("./indexer.state.js").IndexMemberContext | null> | null, unknown>;
|
|
@@ -243,7 +250,7 @@ export declare class IntentNetworkGraphFactory {
|
|
|
243
250
|
};
|
|
244
251
|
networkId: import("@langchain/langgraph").BaseChannel<string | undefined, string | import("@langchain/langgraph").OverwriteValue<string | undefined> | undefined, unknown>;
|
|
245
252
|
intentId: import("@langchain/langgraph").BaseChannel<string | undefined, string | import("@langchain/langgraph").OverwriteValue<string | undefined> | undefined, unknown>;
|
|
246
|
-
operationMode: import("@langchain/langgraph").BaseChannel<"
|
|
253
|
+
operationMode: import("@langchain/langgraph").BaseChannel<"create" | "delete" | "read", "create" | "delete" | "read" | import("@langchain/langgraph").OverwriteValue<"create" | "delete" | "read">, unknown>;
|
|
247
254
|
skipEvaluation: import("@langchain/langgraph").BaseChannel<boolean, boolean | import("@langchain/langgraph").OverwriteValue<boolean>, unknown>;
|
|
248
255
|
intent: import("@langchain/langgraph").BaseChannel<import("./indexer.state.js").IntentForIndexing | null, import("./indexer.state.js").IntentForIndexing | import("@langchain/langgraph").OverwriteValue<import("./indexer.state.js").IntentForIndexing | null> | null, unknown>;
|
|
249
256
|
indexContext: import("@langchain/langgraph").BaseChannel<import("./indexer.state.js").IndexMemberContext | null, import("./indexer.state.js").IndexMemberContext | import("@langchain/langgraph").OverwriteValue<import("./indexer.state.js").IndexMemberContext | null> | null, unknown>;
|
|
@@ -444,3 +451,154 @@ export declare class IntentNetworkGraphFactory {
|
|
|
444
451
|
};
|
|
445
452
|
}, unknown, unknown, []>;
|
|
446
453
|
}
|
|
454
|
+
/**
|
|
455
|
+
* Persist an intent→network assignment, honouring membership, and shape the tool result.
|
|
456
|
+
*/
|
|
457
|
+
export declare function finalizeAssignment(deps: IntentNetworkGraphDeps, userId: string, intentId: string, networkId: string, score: number, metadata: Parameters<IntentNetworkGraphDatabase['assignIntentToNetworkIfMember']>[4], successMessage: string): Promise<{
|
|
458
|
+
assignmentResult: AssignmentResult;
|
|
459
|
+
mutationResult: {
|
|
460
|
+
success: boolean;
|
|
461
|
+
message: string;
|
|
462
|
+
error?: undefined;
|
|
463
|
+
};
|
|
464
|
+
} | {
|
|
465
|
+
assignmentResult: AssignmentResult;
|
|
466
|
+
mutationResult: {
|
|
467
|
+
success: boolean;
|
|
468
|
+
error: string;
|
|
469
|
+
message?: undefined;
|
|
470
|
+
};
|
|
471
|
+
}>;
|
|
472
|
+
export declare function assignNode(state: IntentNetworkState, deps: IntentNetworkGraphDeps): Promise<{
|
|
473
|
+
agentTimings: DebugMetaAgent[];
|
|
474
|
+
mutationResult: {
|
|
475
|
+
success: boolean;
|
|
476
|
+
error: string;
|
|
477
|
+
message?: undefined;
|
|
478
|
+
};
|
|
479
|
+
evaluation?: undefined;
|
|
480
|
+
shouldAssign?: undefined;
|
|
481
|
+
finalScore?: undefined;
|
|
482
|
+
} | {
|
|
483
|
+
agentTimings: DebugMetaAgent[];
|
|
484
|
+
mutationResult: {
|
|
485
|
+
success: boolean;
|
|
486
|
+
message: string;
|
|
487
|
+
error?: undefined;
|
|
488
|
+
};
|
|
489
|
+
evaluation?: undefined;
|
|
490
|
+
shouldAssign?: undefined;
|
|
491
|
+
finalScore?: undefined;
|
|
492
|
+
} | {
|
|
493
|
+
assignmentResult: AssignmentResult;
|
|
494
|
+
mutationResult: {
|
|
495
|
+
success: boolean;
|
|
496
|
+
message: string;
|
|
497
|
+
error?: undefined;
|
|
498
|
+
};
|
|
499
|
+
agentTimings: DebugMetaAgent[];
|
|
500
|
+
evaluation?: undefined;
|
|
501
|
+
shouldAssign?: undefined;
|
|
502
|
+
finalScore?: undefined;
|
|
503
|
+
} | {
|
|
504
|
+
assignmentResult: AssignmentResult;
|
|
505
|
+
mutationResult: {
|
|
506
|
+
success: boolean;
|
|
507
|
+
error: string;
|
|
508
|
+
message?: undefined;
|
|
509
|
+
};
|
|
510
|
+
agentTimings: DebugMetaAgent[];
|
|
511
|
+
evaluation?: undefined;
|
|
512
|
+
shouldAssign?: undefined;
|
|
513
|
+
finalScore?: undefined;
|
|
514
|
+
} | {
|
|
515
|
+
agentTimings: DebugMetaAgent[];
|
|
516
|
+
evaluation: null;
|
|
517
|
+
shouldAssign: boolean;
|
|
518
|
+
finalScore: number;
|
|
519
|
+
mutationResult: {
|
|
520
|
+
success: boolean;
|
|
521
|
+
error: string;
|
|
522
|
+
message?: undefined;
|
|
523
|
+
};
|
|
524
|
+
} | {
|
|
525
|
+
assignmentResult: AssignmentResult;
|
|
526
|
+
mutationResult: {
|
|
527
|
+
success: boolean;
|
|
528
|
+
message: string;
|
|
529
|
+
error?: undefined;
|
|
530
|
+
};
|
|
531
|
+
agentTimings: DebugMetaAgent[];
|
|
532
|
+
evaluation: {
|
|
533
|
+
reasoning: string;
|
|
534
|
+
indexScore: number;
|
|
535
|
+
memberScore: number;
|
|
536
|
+
};
|
|
537
|
+
shouldAssign: boolean;
|
|
538
|
+
finalScore: number;
|
|
539
|
+
} | {
|
|
540
|
+
assignmentResult: AssignmentResult;
|
|
541
|
+
mutationResult: {
|
|
542
|
+
success: boolean;
|
|
543
|
+
error: string;
|
|
544
|
+
message?: undefined;
|
|
545
|
+
};
|
|
546
|
+
agentTimings: DebugMetaAgent[];
|
|
547
|
+
evaluation: {
|
|
548
|
+
reasoning: string;
|
|
549
|
+
indexScore: number;
|
|
550
|
+
memberScore: number;
|
|
551
|
+
};
|
|
552
|
+
shouldAssign: boolean;
|
|
553
|
+
finalScore: number;
|
|
554
|
+
}>;
|
|
555
|
+
/**
|
|
556
|
+
* Read Node: Query intent–network relationships.
|
|
557
|
+
*
|
|
558
|
+
* Three modes (selected by which inputs are provided):
|
|
559
|
+
* - Both intentId + networkId: check if the specific link exists (owner only).
|
|
560
|
+
* - intentId only: list all networks the intent is linked to (owner only).
|
|
561
|
+
* - networkId only: list intents in the network (member only, up to 50).
|
|
562
|
+
* Add `queryUserId` to filter to one member's intents.
|
|
563
|
+
*/
|
|
564
|
+
export declare function readNode(state: IntentNetworkState, deps: IntentNetworkGraphDeps): Promise<{
|
|
565
|
+
readResult: {
|
|
566
|
+
links: never[];
|
|
567
|
+
count: number;
|
|
568
|
+
mode: string;
|
|
569
|
+
note?: undefined;
|
|
570
|
+
};
|
|
571
|
+
error: string;
|
|
572
|
+
} | {
|
|
573
|
+
readResult: {
|
|
574
|
+
links: {
|
|
575
|
+
intentId: string;
|
|
576
|
+
networkId: string;
|
|
577
|
+
}[];
|
|
578
|
+
count: number;
|
|
579
|
+
mode: string;
|
|
580
|
+
note: string;
|
|
581
|
+
};
|
|
582
|
+
error?: undefined;
|
|
583
|
+
} | {
|
|
584
|
+
error: string;
|
|
585
|
+
readResult?: undefined;
|
|
586
|
+
}>;
|
|
587
|
+
/**
|
|
588
|
+
* Unassign Node: Remove an intent from a network.
|
|
589
|
+
* Only the intent owner may unassign, and only if they are a member/owner of the network.
|
|
590
|
+
*/
|
|
591
|
+
export declare function unassignNode(state: IntentNetworkState, deps: IntentNetworkGraphDeps): Promise<{
|
|
592
|
+
mutationResult: {
|
|
593
|
+
success: boolean;
|
|
594
|
+
error: string;
|
|
595
|
+
message?: undefined;
|
|
596
|
+
};
|
|
597
|
+
} | {
|
|
598
|
+
mutationResult: {
|
|
599
|
+
success: boolean;
|
|
600
|
+
message: string;
|
|
601
|
+
error?: undefined;
|
|
602
|
+
};
|
|
603
|
+
}>;
|
|
604
|
+
export declare function routeByMode(state: IntentNetworkState): string;
|