@lucern/graph-sync 0.3.0-alpha.10

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.
@@ -0,0 +1,1327 @@
1
+ import { v } from 'convex/values';
2
+ import { permissiveReturn } from '@lucern/contracts/schema-helpers/validators';
3
+ import { componentsGeneric, actionGeneric } from 'convex/server';
4
+
5
+ // src/neo4jQueries.ts
6
+ componentsGeneric();
7
+ var action = actionGeneric;
8
+
9
+ // src/neo4jQueries.ts
10
+ function toInt(value, defaultValue) {
11
+ if (value === void 0 || value === null) {
12
+ return defaultValue;
13
+ }
14
+ const parsed = Number(value);
15
+ return Number.isFinite(parsed) ? Math.floor(parsed) : defaultValue;
16
+ }
17
+ function isAllowedProxyUrl(urlString) {
18
+ try {
19
+ const url = new URL(urlString);
20
+ const isLocalhost = url.hostname === "localhost" || url.hostname === "127.0.0.1";
21
+ if (!isLocalhost && url.protocol !== "https:") {
22
+ return false;
23
+ }
24
+ if (url.username || url.password) {
25
+ return false;
26
+ }
27
+ const configuredHosts = (process.env.LUCERN_GRAPH_SYNC_ALLOWED_PROXY_HOSTS || "").split(",").map((host) => host.trim().toLowerCase()).filter(Boolean);
28
+ if (configuredHosts.length === 0) {
29
+ return true;
30
+ }
31
+ const hostname = url.hostname.toLowerCase();
32
+ return configuredHosts.some(
33
+ (host) => host.startsWith(".") ? hostname.endsWith(host) : hostname === host
34
+ );
35
+ } catch {
36
+ console.warn("[Neo4j Queries] Rejected malformed proxy URL", urlString);
37
+ return false;
38
+ }
39
+ }
40
+ function createNeo4jQueryTransportSuccess(data) {
41
+ return { success: true, data };
42
+ }
43
+ function createNeo4jQueryTransportFailure(error) {
44
+ return { success: false, error };
45
+ }
46
+ function resolveProxyBaseUrl(apiBaseUrl) {
47
+ const resolved = apiBaseUrl || process.env.LUCERN_GRAPH_SYNC_QUERY_BASE_URL || process.env.NEXT_PUBLIC_APP_URL;
48
+ const normalized = resolved?.trim();
49
+ return normalized ? normalized.replace(/\/+$/u, "") : null;
50
+ }
51
+ function buildProxyEndpoint(proxyBaseUrl) {
52
+ const endpoint = new URL(proxyBaseUrl);
53
+ if (!endpoint.pathname.endsWith("/api/neo4j-query")) {
54
+ endpoint.pathname = `${endpoint.pathname.replace(/\/+$/u, "")}/api/neo4j-query`;
55
+ }
56
+ return endpoint.toString();
57
+ }
58
+ async function callNeo4jQuery(queryName, params, apiBaseUrl) {
59
+ const proxyUrl = resolveProxyBaseUrl(apiBaseUrl);
60
+ if (!proxyUrl) {
61
+ return createNeo4jQueryTransportFailure(
62
+ "Neo4j query proxy URL not configured"
63
+ );
64
+ }
65
+ if (!isAllowedProxyUrl(proxyUrl)) {
66
+ console.error(
67
+ "[Neo4j Queries] Blocked request to disallowed URL:",
68
+ proxyUrl
69
+ );
70
+ return createNeo4jQueryTransportFailure("Invalid proxy URL");
71
+ }
72
+ const syncSecret = process.env.NEO4J_SYNC_SECRET;
73
+ if (!syncSecret) {
74
+ console.error("[Neo4j Queries] NEO4J_SYNC_SECRET not configured");
75
+ return createNeo4jQueryTransportFailure(
76
+ "Neo4j sync secret not configured"
77
+ );
78
+ }
79
+ try {
80
+ const explicitTenant = typeof params.tenantId === "string" ? params.tenantId.trim() : "";
81
+ const scopedTopic = typeof params.topicId === "string" ? params.topicId.trim() : "";
82
+ const legacyProject = typeof params.projectId === "string" ? params.projectId.trim() : "";
83
+ const scopedTopicId = scopedTopic || legacyProject;
84
+ const projectTenant = scopedTopicId ? `project:${scopedTopicId}` : "";
85
+ const defaultTenant = process.env.LUCERN_DEFAULT_TENANT_ID?.trim() || "";
86
+ const tenantId = explicitTenant || projectTenant || defaultTenant;
87
+ if (!tenantId) {
88
+ return createNeo4jQueryTransportFailure(
89
+ "Missing required tenant context (tenantId or topicId)"
90
+ );
91
+ }
92
+ const scopedParams = { ...params, tenantId };
93
+ const headers = {
94
+ "Content-Type": "application/json",
95
+ Authorization: `Bearer ${syncSecret}`
96
+ };
97
+ const bypassSecret = process.env.VERCEL_AUTOMATION_BYPASS_SECRET;
98
+ if (bypassSecret && apiBaseUrl) {
99
+ headers["x-vercel-protection-bypass"] = bypassSecret;
100
+ }
101
+ const controller = new AbortController();
102
+ const timeoutId = setTimeout(() => controller.abort(), 1e4);
103
+ try {
104
+ const response = await fetch(buildProxyEndpoint(proxyUrl), {
105
+ method: "POST",
106
+ headers,
107
+ body: JSON.stringify({ queryName, params: scopedParams }),
108
+ signal: controller.signal
109
+ });
110
+ clearTimeout(timeoutId);
111
+ const result = await response.json();
112
+ if (!response.ok) {
113
+ return createNeo4jQueryTransportFailure(result.error || "Query failed");
114
+ }
115
+ return createNeo4jQueryTransportSuccess(result.data || []);
116
+ } catch (fetchError) {
117
+ clearTimeout(timeoutId);
118
+ if (fetchError instanceof Error && fetchError.name === "AbortError") {
119
+ console.warn("[Neo4j Queries] Request timed out for:", queryName);
120
+ return createNeo4jQueryTransportFailure("Query timed out (10s)");
121
+ }
122
+ throw fetchError;
123
+ }
124
+ } catch (error) {
125
+ console.error("[Neo4j Queries] Error in callNeo4jQuery:", queryName, error);
126
+ return createNeo4jQueryTransportFailure(
127
+ error instanceof Error ? error.message : "Network error connecting to query proxy"
128
+ );
129
+ }
130
+ }
131
+ function withTopicScope(args, params) {
132
+ return args.topicId ? { ...params, topicId: args.topicId } : params;
133
+ }
134
+ var getNodeLineageGraph = action({
135
+ args: {
136
+ globalId: v.string(),
137
+ apiBaseUrl: v.optional(v.string()),
138
+ topicId: v.optional(v.string())
139
+ },
140
+ returns: permissiveReturn,
141
+ handler: async (_ctx, args) => {
142
+ const result = await callNeo4jQuery(
143
+ "nodeLineage",
144
+ withTopicScope(args, {
145
+ globalId: args.globalId
146
+ }),
147
+ args.apiBaseUrl
148
+ );
149
+ if (!result.success) {
150
+ console.error("[Neo4j] Lineage query failed:", result.error);
151
+ return { lineage: [], error: result.error };
152
+ }
153
+ const lineage = result.data?.[0]?.lineage || [];
154
+ return { lineage };
155
+ }
156
+ });
157
+ var getConnectedNodesGraph = action({
158
+ args: {
159
+ globalId: v.string(),
160
+ maxHops: v.optional(v.number()),
161
+ limit: v.optional(v.number()),
162
+ apiBaseUrl: v.optional(v.string()),
163
+ topicId: v.optional(v.string())
164
+ },
165
+ returns: permissiveReturn,
166
+ handler: async (_ctx, args) => {
167
+ const maxHops = Math.min(toInt(args.maxHops, 2), 5);
168
+ const limit = toInt(args.limit, 50);
169
+ const result = await callNeo4jQuery(
170
+ "connectedNodes",
171
+ withTopicScope(args, {
172
+ globalId: args.globalId,
173
+ maxHops,
174
+ limit
175
+ }),
176
+ args.apiBaseUrl
177
+ );
178
+ if (!result.success) {
179
+ console.error("[Neo4j] Connected nodes query failed:", result.error);
180
+ return { nodes: [], error: result.error };
181
+ }
182
+ return { nodes: result.data || [] };
183
+ }
184
+ });
185
+ var getThemeBeliefsGraph = action({
186
+ args: {
187
+ themeGlobalId: v.string()
188
+ },
189
+ returns: permissiveReturn,
190
+ handler: async (_ctx, args) => {
191
+ const result = await callNeo4jQuery("themeBeliefs", {
192
+ themeGlobalId: args.themeGlobalId
193
+ });
194
+ if (!result.success) {
195
+ return { beliefs: [], error: result.error };
196
+ }
197
+ return {
198
+ beliefs: result.data?.map((r) => r.belief) || []
199
+ };
200
+ }
201
+ });
202
+ var getBeliefEvidenceGraph = action({
203
+ args: {
204
+ beliefGlobalId: v.string(),
205
+ apiBaseUrl: v.optional(v.string()),
206
+ topicId: v.optional(v.string())
207
+ },
208
+ returns: permissiveReturn,
209
+ handler: async (_ctx, args) => {
210
+ const result = await callNeo4jQuery(
211
+ "beliefEvidence",
212
+ withTopicScope(args, {
213
+ beliefGlobalId: args.beliefGlobalId
214
+ }),
215
+ args.apiBaseUrl
216
+ );
217
+ if (!result.success) {
218
+ return { evidence: [], error: result.error };
219
+ }
220
+ return {
221
+ evidence: result.data?.map((r) => r.evidence) || []
222
+ };
223
+ }
224
+ });
225
+ var getCrossThemeBeliefs = action({
226
+ args: {
227
+ limit: v.optional(v.number()),
228
+ apiBaseUrl: v.optional(v.string()),
229
+ topicId: v.optional(v.string())
230
+ },
231
+ returns: permissiveReturn,
232
+ handler: async (_ctx, args) => {
233
+ const result = await callNeo4jQuery(
234
+ "crossThemeBeliefs",
235
+ withTopicScope(args, {
236
+ limit: toInt(args.limit, 20)
237
+ }),
238
+ args.apiBaseUrl
239
+ );
240
+ if (!result.success) {
241
+ return { beliefs: [], error: result.error };
242
+ }
243
+ return {
244
+ beliefs: result.data?.map((r) => r.belief) || []
245
+ };
246
+ }
247
+ });
248
+ var findPotentialContradictions = action({
249
+ args: {
250
+ limit: v.optional(v.number()),
251
+ apiBaseUrl: v.optional(v.string()),
252
+ topicId: v.optional(v.string())
253
+ },
254
+ returns: permissiveReturn,
255
+ handler: async (_ctx, args) => {
256
+ const result = await callNeo4jQuery(
257
+ "potentialContradictions",
258
+ withTopicScope(args, {
259
+ limit: toInt(args.limit, 10)
260
+ }),
261
+ args.apiBaseUrl
262
+ );
263
+ if (!result.success) {
264
+ return { contradictions: [], error: result.error };
265
+ }
266
+ return {
267
+ contradictions: result.data?.map(
268
+ (r) => r.contradiction
269
+ ) || []
270
+ };
271
+ }
272
+ });
273
+ var getThemeSubgraph = action({
274
+ args: {
275
+ themeGlobalId: v.string(),
276
+ apiBaseUrl: v.optional(v.string()),
277
+ topicId: v.optional(v.string())
278
+ },
279
+ returns: permissiveReturn,
280
+ handler: async (_ctx, args) => {
281
+ const result = await callNeo4jQuery(
282
+ "themeSubgraph",
283
+ withTopicScope(args, {
284
+ themeGlobalId: args.themeGlobalId
285
+ }),
286
+ args.apiBaseUrl
287
+ );
288
+ if (!result.success) {
289
+ return { subgraph: null, error: result.error };
290
+ }
291
+ return {
292
+ subgraph: result.data?.[0]?.subgraph || null
293
+ };
294
+ }
295
+ });
296
+ var getEvidenceToBeliefPath = action({
297
+ args: {
298
+ evidenceGlobalId: v.string(),
299
+ beliefGlobalId: v.string(),
300
+ apiBaseUrl: v.optional(v.string()),
301
+ topicId: v.optional(v.string())
302
+ },
303
+ returns: permissiveReturn,
304
+ handler: async (_ctx, args) => {
305
+ const result = await callNeo4jQuery(
306
+ "evidenceToBeliefPath",
307
+ withTopicScope(args, {
308
+ evidenceGlobalId: args.evidenceGlobalId,
309
+ beliefGlobalId: args.beliefGlobalId
310
+ }),
311
+ args.apiBaseUrl
312
+ );
313
+ if (!result.success) {
314
+ return { path: null, error: result.error };
315
+ }
316
+ const pathResult = result.data?.[0];
317
+ if (!pathResult?.pathResult) {
318
+ return { path: null, error: "No path found between evidence and belief" };
319
+ }
320
+ return {
321
+ path: {
322
+ nodes: pathResult.pathResult.nodes || [],
323
+ relationships: pathResult.pathResult.relationships || [],
324
+ length: pathResult.pathResult.length || 0
325
+ }
326
+ };
327
+ }
328
+ });
329
+ var getThemeStats = action({
330
+ args: {
331
+ themeGlobalId: v.string()
332
+ },
333
+ returns: permissiveReturn,
334
+ handler: async (_ctx, args) => {
335
+ const result = await callNeo4jQuery("themeStats", {
336
+ themeGlobalId: args.themeGlobalId
337
+ });
338
+ if (!result.success) {
339
+ return { stats: null, error: result.error };
340
+ }
341
+ return { stats: result.data?.[0]?.stats || null };
342
+ }
343
+ });
344
+ var getThemeValueChainCandidates = action({
345
+ args: {
346
+ limit: v.optional(v.number()),
347
+ apiBaseUrl: v.optional(v.string()),
348
+ topicId: v.optional(v.string())
349
+ },
350
+ returns: permissiveReturn,
351
+ handler: async (_ctx, args) => {
352
+ const result = await callNeo4jQuery(
353
+ "themeValueChainCandidates",
354
+ withTopicScope(args, {
355
+ limit: toInt(args.limit, 100)
356
+ }),
357
+ args.apiBaseUrl
358
+ );
359
+ if (!result.success) {
360
+ return { candidates: [], error: result.error };
361
+ }
362
+ return {
363
+ candidates: result.data?.map((r) => r.candidate) || []
364
+ };
365
+ }
366
+ });
367
+ var getThemesImpactingCompany = action({
368
+ args: {
369
+ companyName: v.string(),
370
+ limit: v.optional(v.number())
371
+ },
372
+ returns: permissiveReturn,
373
+ handler: async (_ctx, args) => {
374
+ const result = await callNeo4jQuery("themesImpactingCompany", {
375
+ companyName: args.companyName,
376
+ limit: toInt(args.limit, 20)
377
+ });
378
+ if (!result.success) {
379
+ return { results: [], error: result.error };
380
+ }
381
+ return { results: result.data || [] };
382
+ }
383
+ });
384
+ var getCompaniesByTheme = action({
385
+ args: {
386
+ themeName: v.string(),
387
+ limit: v.optional(v.number())
388
+ },
389
+ returns: permissiveReturn,
390
+ handler: async (_ctx, args) => {
391
+ const result = await callNeo4jQuery("companiesByTheme", {
392
+ themeName: args.themeName,
393
+ limit: toInt(args.limit, 50)
394
+ });
395
+ if (!result.success) {
396
+ return { results: [], error: result.error };
397
+ }
398
+ return { results: result.data || [] };
399
+ }
400
+ });
401
+ var getQuestionsByValueChain = action({
402
+ args: {
403
+ valueChainName: v.string(),
404
+ limit: v.optional(v.number())
405
+ },
406
+ returns: permissiveReturn,
407
+ handler: async (_ctx, args) => {
408
+ const result = await callNeo4jQuery("questionsByValueChain", {
409
+ valueChainName: args.valueChainName,
410
+ limit: toInt(args.limit, 50)
411
+ });
412
+ if (!result.success) {
413
+ return { results: [], error: result.error };
414
+ }
415
+ return { results: result.data || [] };
416
+ }
417
+ });
418
+ var getQuestionsByTheme = action({
419
+ args: {
420
+ themeName: v.string(),
421
+ limit: v.optional(v.number())
422
+ },
423
+ returns: permissiveReturn,
424
+ handler: async (_ctx, args) => {
425
+ const result = await callNeo4jQuery("questionsByTheme", {
426
+ themeName: args.themeName,
427
+ limit: toInt(args.limit, 50)
428
+ });
429
+ if (!result.success) {
430
+ return { results: [], error: result.error };
431
+ }
432
+ return { results: result.data || [] };
433
+ }
434
+ });
435
+ var getPeopleByTheme = action({
436
+ args: {
437
+ themeName: v.string(),
438
+ limit: v.optional(v.number())
439
+ },
440
+ returns: permissiveReturn,
441
+ handler: async (_ctx, args) => {
442
+ const result = await callNeo4jQuery("peopleByTheme", {
443
+ themeName: args.themeName,
444
+ limit: toInt(args.limit, 50)
445
+ });
446
+ if (!result.success) {
447
+ return { results: [], error: result.error };
448
+ }
449
+ return { results: result.data || [] };
450
+ }
451
+ });
452
+ var getPeopleByCompany = action({
453
+ args: {
454
+ companyName: v.string(),
455
+ limit: v.optional(v.number())
456
+ },
457
+ returns: permissiveReturn,
458
+ handler: async (_ctx, args) => {
459
+ const result = await callNeo4jQuery("peopleByCompany", {
460
+ companyName: args.companyName,
461
+ limit: toInt(args.limit, 50)
462
+ });
463
+ if (!result.success) {
464
+ return { results: [], error: result.error };
465
+ }
466
+ return { results: result.data || [] };
467
+ }
468
+ });
469
+ var getValueChainsByTheme = action({
470
+ args: {
471
+ themeName: v.string(),
472
+ limit: v.optional(v.number())
473
+ },
474
+ returns: permissiveReturn,
475
+ handler: async (_ctx, args) => {
476
+ const result = await callNeo4jQuery("valueChainsByTheme", {
477
+ themeName: args.themeName,
478
+ limit: toInt(args.limit, 20)
479
+ });
480
+ if (!result.success) {
481
+ return { results: [], error: result.error };
482
+ }
483
+ return { results: result.data || [] };
484
+ }
485
+ });
486
+ var getFunctionsByValueChain = action({
487
+ args: {
488
+ valueChainName: v.string(),
489
+ limit: v.optional(v.number())
490
+ },
491
+ returns: permissiveReturn,
492
+ handler: async (_ctx, args) => {
493
+ const result = await callNeo4jQuery("functionsByValueChain", {
494
+ valueChainName: args.valueChainName,
495
+ limit: toInt(args.limit, 50)
496
+ });
497
+ if (!result.success) {
498
+ return { results: [], error: result.error };
499
+ }
500
+ return { results: result.data || [] };
501
+ }
502
+ });
503
+ var getBeliefsByCompany = action({
504
+ args: {
505
+ companyName: v.string(),
506
+ limit: v.optional(v.number())
507
+ },
508
+ returns: permissiveReturn,
509
+ handler: async (_ctx, args) => {
510
+ const result = await callNeo4jQuery("beliefsByCompany", {
511
+ companyName: args.companyName,
512
+ limit: toInt(args.limit, 30)
513
+ });
514
+ if (!result.success) {
515
+ return { results: [], error: result.error };
516
+ }
517
+ return { results: result.data || [] };
518
+ }
519
+ });
520
+ var getEvidenceByCompany = action({
521
+ args: {
522
+ companyName: v.string(),
523
+ limit: v.optional(v.number())
524
+ },
525
+ returns: permissiveReturn,
526
+ handler: async (_ctx, args) => {
527
+ const result = await callNeo4jQuery("evidenceByCompany", {
528
+ companyName: args.companyName,
529
+ limit: toInt(args.limit, 50)
530
+ });
531
+ if (!result.success) {
532
+ return { results: [], error: result.error };
533
+ }
534
+ return { results: result.data || [] };
535
+ }
536
+ });
537
+ var searchAllNodes = action({
538
+ args: {
539
+ searchText: v.string(),
540
+ limit: v.optional(v.number())
541
+ },
542
+ returns: permissiveReturn,
543
+ handler: async (_ctx, args) => {
544
+ const result = await callNeo4jQuery("searchAllNodes", {
545
+ searchText: args.searchText,
546
+ limit: toInt(args.limit, 50)
547
+ });
548
+ if (!result.success) {
549
+ return { results: [], error: result.error };
550
+ }
551
+ return { results: result.data || [] };
552
+ }
553
+ });
554
+ var getNodeRelationships = action({
555
+ args: {
556
+ globalId: v.optional(v.string()),
557
+ searchText: v.optional(v.string()),
558
+ limit: v.optional(v.number())
559
+ },
560
+ returns: permissiveReturn,
561
+ handler: async (_ctx, args) => {
562
+ const result = await callNeo4jQuery("nodeRelationships", {
563
+ globalId: args.globalId || "",
564
+ searchText: args.searchText || "",
565
+ limit: toInt(args.limit, 50)
566
+ });
567
+ if (!result.success) {
568
+ return { results: [], error: result.error };
569
+ }
570
+ return { results: result.data || [] };
571
+ }
572
+ });
573
+ var getGraphStats = action({
574
+ args: {},
575
+ returns: permissiveReturn,
576
+ handler: async () => {
577
+ const result = await callNeo4jQuery("graphStats", {});
578
+ if (!result.success) {
579
+ return { stats: [], error: result.error };
580
+ }
581
+ return { stats: result.data || [] };
582
+ }
583
+ });
584
+ var queryGraph = action({
585
+ args: {
586
+ queryType: v.union(
587
+ v.literal("themesImpactingCompany"),
588
+ v.literal("companiesByTheme"),
589
+ v.literal("questionsByValueChain"),
590
+ v.literal("questionsByTheme"),
591
+ v.literal("peopleByTheme"),
592
+ v.literal("peopleByCompany"),
593
+ v.literal("valueChainsByTheme"),
594
+ v.literal("functionsByValueChain"),
595
+ v.literal("beliefsByCompany"),
596
+ v.literal("evidenceByCompany"),
597
+ v.literal("searchAllNodes"),
598
+ v.literal("nodeRelationships"),
599
+ v.literal("graphStats")
600
+ ),
601
+ params: v.object({
602
+ companyName: v.optional(v.string()),
603
+ themeName: v.optional(v.string()),
604
+ valueChainName: v.optional(v.string()),
605
+ searchText: v.optional(v.string()),
606
+ globalId: v.optional(v.string()),
607
+ limit: v.optional(v.number())
608
+ }),
609
+ apiBaseUrl: v.optional(v.string()),
610
+ topicId: v.optional(v.string())
611
+ },
612
+ returns: permissiveReturn,
613
+ handler: async (_ctx, args) => {
614
+ const limit = toInt(args.params.limit, 30);
615
+ const themeRequiredQueries = [
616
+ "questionsByTheme",
617
+ "peopleByTheme",
618
+ "companiesByTheme",
619
+ "valueChainsByTheme"
620
+ ];
621
+ const companyRequiredQueries = [
622
+ "themesImpactingCompany",
623
+ "peopleByCompany",
624
+ "beliefsByCompany",
625
+ "evidenceByCompany"
626
+ ];
627
+ const valueChainRequiredQueries = [
628
+ "questionsByValueChain",
629
+ "functionsByValueChain"
630
+ ];
631
+ if (themeRequiredQueries.includes(args.queryType) && !args.params.themeName) {
632
+ return {
633
+ results: [],
634
+ error: `Query type '${args.queryType}' requires 'themeName' parameter`
635
+ };
636
+ }
637
+ if (companyRequiredQueries.includes(args.queryType) && !args.params.companyName) {
638
+ return {
639
+ results: [],
640
+ error: `Query type '${args.queryType}' requires 'companyName' parameter`
641
+ };
642
+ }
643
+ if (valueChainRequiredQueries.includes(args.queryType) && !args.params.valueChainName) {
644
+ return {
645
+ results: [],
646
+ error: `Query type '${args.queryType}' requires 'valueChainName' parameter`
647
+ };
648
+ }
649
+ const result = await callNeo4jQuery(
650
+ args.queryType,
651
+ withTopicScope(args, {
652
+ ...args.params,
653
+ limit
654
+ }),
655
+ args.apiBaseUrl
656
+ );
657
+ if (!result.success) {
658
+ return { results: [], error: result.error };
659
+ }
660
+ return { results: result.data || [] };
661
+ }
662
+ });
663
+ var getHighPriorityQuestions = action({
664
+ args: {
665
+ limit: v.optional(v.number()),
666
+ apiBaseUrl: v.optional(v.string()),
667
+ topicId: v.optional(v.string())
668
+ },
669
+ returns: permissiveReturn,
670
+ handler: async (_ctx, args) => {
671
+ const result = await callNeo4jQuery(
672
+ "highPriorityQuestions",
673
+ withTopicScope(args, {
674
+ limit: toInt(args.limit, 50)
675
+ }),
676
+ args.apiBaseUrl
677
+ );
678
+ if (!result.success) {
679
+ return { questions: [], error: result.error };
680
+ }
681
+ return { questions: result.data || [] };
682
+ }
683
+ });
684
+ var getEvidenceByMethodology = action({
685
+ args: {
686
+ methodology: v.string(),
687
+ limit: v.optional(v.number()),
688
+ apiBaseUrl: v.optional(v.string()),
689
+ topicId: v.optional(v.string())
690
+ },
691
+ returns: permissiveReturn,
692
+ handler: async (_ctx, args) => {
693
+ const result = await callNeo4jQuery(
694
+ "evidenceByMethodology",
695
+ withTopicScope(args, {
696
+ methodology: args.methodology,
697
+ limit: toInt(args.limit, 50)
698
+ }),
699
+ args.apiBaseUrl
700
+ );
701
+ if (!result.success) {
702
+ return { evidence: [], error: result.error };
703
+ }
704
+ return { evidence: result.data || [] };
705
+ }
706
+ });
707
+ var getProprietaryEvidence = action({
708
+ args: {
709
+ limit: v.optional(v.number()),
710
+ apiBaseUrl: v.optional(v.string()),
711
+ topicId: v.optional(v.string())
712
+ },
713
+ returns: permissiveReturn,
714
+ handler: async (_ctx, args) => {
715
+ const result = await callNeo4jQuery(
716
+ "proprietaryEvidence",
717
+ withTopicScope(args, {
718
+ limit: toInt(args.limit, 50)
719
+ }),
720
+ args.apiBaseUrl
721
+ );
722
+ if (!result.success) {
723
+ return { evidence: [], error: result.error };
724
+ }
725
+ return { evidence: result.data || [] };
726
+ }
727
+ });
728
+ var getBeliefsByEpistemicStatus = action({
729
+ args: {
730
+ epistemicStatus: v.string(),
731
+ limit: v.optional(v.number()),
732
+ apiBaseUrl: v.optional(v.string()),
733
+ topicId: v.optional(v.string())
734
+ },
735
+ returns: permissiveReturn,
736
+ handler: async (_ctx, args) => {
737
+ const result = await callNeo4jQuery(
738
+ "beliefsByEpistemicStatus",
739
+ withTopicScope(args, {
740
+ epistemicStatus: args.epistemicStatus,
741
+ limit: toInt(args.limit, 50)
742
+ }),
743
+ args.apiBaseUrl
744
+ );
745
+ if (!result.success) {
746
+ return { beliefs: [], error: result.error };
747
+ }
748
+ return { beliefs: result.data || [] };
749
+ }
750
+ });
751
+ var getChallengedBeliefs = action({
752
+ args: {
753
+ limit: v.optional(v.number()),
754
+ apiBaseUrl: v.optional(v.string()),
755
+ topicId: v.optional(v.string())
756
+ },
757
+ returns: permissiveReturn,
758
+ handler: async (_ctx, args) => {
759
+ const result = await callNeo4jQuery(
760
+ "challengedBeliefs",
761
+ withTopicScope(args, {
762
+ limit: toInt(args.limit, 30)
763
+ }),
764
+ args.apiBaseUrl
765
+ );
766
+ if (!result.success) {
767
+ return { beliefs: [], error: result.error };
768
+ }
769
+ return { beliefs: result.data || [] };
770
+ }
771
+ });
772
+ var getPredictions = action({
773
+ args: {
774
+ limit: v.optional(v.number()),
775
+ apiBaseUrl: v.optional(v.string()),
776
+ topicId: v.optional(v.string())
777
+ },
778
+ returns: permissiveReturn,
779
+ handler: async (_ctx, args) => {
780
+ const result = await callNeo4jQuery(
781
+ "predictions",
782
+ withTopicScope(args, {
783
+ limit: toInt(args.limit, 50)
784
+ }),
785
+ args.apiBaseUrl
786
+ );
787
+ if (!result.success) {
788
+ return { predictions: [], error: result.error };
789
+ }
790
+ return { predictions: result.data || [] };
791
+ }
792
+ });
793
+ var getCausalChains = action({
794
+ args: {
795
+ limit: v.optional(v.number()),
796
+ apiBaseUrl: v.optional(v.string()),
797
+ topicId: v.optional(v.string())
798
+ },
799
+ returns: permissiveReturn,
800
+ handler: async (_ctx, args) => {
801
+ const result = await callNeo4jQuery(
802
+ "causalChains",
803
+ withTopicScope(args, {
804
+ limit: toInt(args.limit, 50)
805
+ }),
806
+ args.apiBaseUrl
807
+ );
808
+ if (!result.success) {
809
+ return { chains: [], error: result.error };
810
+ }
811
+ return { chains: result.data || [] };
812
+ }
813
+ });
814
+ var getNecessaryEvidence = action({
815
+ args: {
816
+ limit: v.optional(v.number()),
817
+ apiBaseUrl: v.optional(v.string()),
818
+ topicId: v.optional(v.string())
819
+ },
820
+ returns: permissiveReturn,
821
+ handler: async (_ctx, args) => {
822
+ const result = await callNeo4jQuery(
823
+ "necessaryEvidence",
824
+ withTopicScope(args, {
825
+ limit: toInt(args.limit, 50)
826
+ }),
827
+ args.apiBaseUrl
828
+ );
829
+ if (!result.success) {
830
+ return { results: [], error: result.error };
831
+ }
832
+ return { results: result.data || [] };
833
+ }
834
+ });
835
+ var getFalsificationQuestions = action({
836
+ args: {
837
+ limit: v.optional(v.number()),
838
+ apiBaseUrl: v.optional(v.string()),
839
+ topicId: v.optional(v.string())
840
+ },
841
+ returns: permissiveReturn,
842
+ handler: async (_ctx, args) => {
843
+ const result = await callNeo4jQuery(
844
+ "falsificationQuestions",
845
+ withTopicScope(args, {
846
+ limit: toInt(args.limit, 50)
847
+ }),
848
+ args.apiBaseUrl
849
+ );
850
+ if (!result.success) {
851
+ return { questions: [], error: result.error };
852
+ }
853
+ return { questions: result.data || [] };
854
+ }
855
+ });
856
+ var getConfirmationBiasScore = action({
857
+ args: {
858
+ limit: v.optional(v.number()),
859
+ apiBaseUrl: v.optional(v.string()),
860
+ topicId: v.optional(v.string())
861
+ },
862
+ returns: permissiveReturn,
863
+ handler: async (_ctx, args) => {
864
+ const result = await callNeo4jQuery(
865
+ "confirmationBiasScore",
866
+ {
867
+ ...args.topicId ? { topicId: args.topicId } : {},
868
+ limit: toInt(args.limit, 30)
869
+ },
870
+ args.apiBaseUrl
871
+ );
872
+ if (!result.success) {
873
+ return { results: [], error: result.error };
874
+ }
875
+ return { results: result.data || [] };
876
+ }
877
+ });
878
+ var getAnchoringBiasDetection = action({
879
+ args: {
880
+ limit: v.optional(v.number()),
881
+ apiBaseUrl: v.optional(v.string()),
882
+ topicId: v.optional(v.string())
883
+ },
884
+ returns: permissiveReturn,
885
+ handler: async (_ctx, args) => {
886
+ const result = await callNeo4jQuery(
887
+ "anchoringBiasDetection",
888
+ withTopicScope(args, {
889
+ limit: toInt(args.limit, 30)
890
+ }),
891
+ args.apiBaseUrl
892
+ );
893
+ if (!result.success) {
894
+ return { results: [], error: result.error };
895
+ }
896
+ return { results: result.data || [] };
897
+ }
898
+ });
899
+ var getSourceConcentrationRisk = action({
900
+ args: {
901
+ limit: v.optional(v.number()),
902
+ apiBaseUrl: v.optional(v.string()),
903
+ topicId: v.optional(v.string())
904
+ },
905
+ returns: permissiveReturn,
906
+ handler: async (_ctx, args) => {
907
+ const result = await callNeo4jQuery(
908
+ "sourceConcentrationRisk",
909
+ withTopicScope(args, {
910
+ limit: toInt(args.limit, 30)
911
+ }),
912
+ args.apiBaseUrl
913
+ );
914
+ if (!result.success) {
915
+ return { results: [], error: result.error };
916
+ }
917
+ return { results: result.data || [] };
918
+ }
919
+ });
920
+ var getMinimumFalsificationSet = action({
921
+ args: {
922
+ apiBaseUrl: v.optional(v.string()),
923
+ topicId: v.optional(v.string())
924
+ },
925
+ returns: permissiveReturn,
926
+ handler: async (_ctx, args) => {
927
+ const result = await callNeo4jQuery(
928
+ "minimumFalsificationSet",
929
+ withTopicScope(args, {}),
930
+ args.apiBaseUrl
931
+ );
932
+ if (!result.success) {
933
+ return { result: null, error: result.error };
934
+ }
935
+ const data = result.data;
936
+ return { result: Array.isArray(data) && data.length > 0 ? data[0] : null };
937
+ }
938
+ });
939
+ var getContradictionTensionMap = action({
940
+ args: {
941
+ limit: v.optional(v.number()),
942
+ apiBaseUrl: v.optional(v.string()),
943
+ topicId: v.optional(v.string())
944
+ },
945
+ returns: permissiveReturn,
946
+ handler: async (_ctx, args) => {
947
+ const result = await callNeo4jQuery(
948
+ "contradictionTensionMap",
949
+ withTopicScope(args, {
950
+ limit: toInt(args.limit, 30)
951
+ }),
952
+ args.apiBaseUrl
953
+ );
954
+ if (!result.success) {
955
+ return { results: [], error: result.error };
956
+ }
957
+ return { results: result.data || [] };
958
+ }
959
+ });
960
+ var getReasoningDepthScore = action({
961
+ args: {
962
+ limit: v.optional(v.number()),
963
+ apiBaseUrl: v.optional(v.string()),
964
+ topicId: v.optional(v.string())
965
+ },
966
+ returns: permissiveReturn,
967
+ handler: async (_ctx, args) => {
968
+ const result = await callNeo4jQuery(
969
+ "reasoningDepthScore",
970
+ withTopicScope(args, {
971
+ limit: toInt(args.limit, 50)
972
+ }),
973
+ args.apiBaseUrl
974
+ );
975
+ if (!result.success) {
976
+ return { results: [], error: result.error };
977
+ }
978
+ return { results: result.data || [] };
979
+ }
980
+ });
981
+ var getKnowledgeFrontier = action({
982
+ args: {
983
+ limit: v.optional(v.number()),
984
+ apiBaseUrl: v.optional(v.string()),
985
+ topicId: v.optional(v.string())
986
+ },
987
+ returns: permissiveReturn,
988
+ handler: async (_ctx, args) => {
989
+ const result = await callNeo4jQuery(
990
+ "knowledgeFrontier",
991
+ withTopicScope(args, {
992
+ limit: toInt(args.limit, 30)
993
+ }),
994
+ args.apiBaseUrl
995
+ );
996
+ if (!result.success) {
997
+ return { results: [], error: result.error };
998
+ }
999
+ return { results: result.data || [] };
1000
+ }
1001
+ });
1002
+ var getBeliefHalfLife = action({
1003
+ args: {
1004
+ apiBaseUrl: v.optional(v.string()),
1005
+ topicId: v.optional(v.string())
1006
+ },
1007
+ returns: permissiveReturn,
1008
+ handler: async (_ctx, args) => {
1009
+ const result = await callNeo4jQuery(
1010
+ "beliefHalfLife",
1011
+ withTopicScope(args, {}),
1012
+ args.apiBaseUrl
1013
+ );
1014
+ if (!result.success) {
1015
+ return { result: null, error: result.error };
1016
+ }
1017
+ const data = result.data;
1018
+ return { result: Array.isArray(data) && data.length > 0 ? data[0] : null };
1019
+ }
1020
+ });
1021
+ var getMeetingPrepBrief = action({
1022
+ args: {
1023
+ personGlobalId: v.string(),
1024
+ apiBaseUrl: v.optional(v.string()),
1025
+ topicId: v.optional(v.string())
1026
+ },
1027
+ returns: permissiveReturn,
1028
+ handler: async (_ctx, args) => {
1029
+ const result = await callNeo4jQuery(
1030
+ "meetingPrepBrief",
1031
+ withTopicScope(args, {
1032
+ personGlobalId: args.personGlobalId
1033
+ }),
1034
+ args.apiBaseUrl
1035
+ );
1036
+ if (!result.success) {
1037
+ return { brief: null, error: result.error };
1038
+ }
1039
+ const data = result.data;
1040
+ return { brief: Array.isArray(data) && data.length > 0 ? data[0] : null };
1041
+ }
1042
+ });
1043
+ var getProprietarySignals = action({
1044
+ args: {
1045
+ limit: v.optional(v.number()),
1046
+ apiBaseUrl: v.optional(v.string()),
1047
+ topicId: v.optional(v.string())
1048
+ },
1049
+ returns: permissiveReturn,
1050
+ handler: async (_ctx, args) => {
1051
+ const result = await callNeo4jQuery(
1052
+ "proprietarySignals",
1053
+ withTopicScope(args, {
1054
+ limit: toInt(args.limit, 30)
1055
+ }),
1056
+ args.apiBaseUrl
1057
+ );
1058
+ if (!result.success) {
1059
+ return { results: [], error: result.error };
1060
+ }
1061
+ return { results: result.data || [] };
1062
+ }
1063
+ });
1064
+ var getPortfolioConviction = action({
1065
+ args: {
1066
+ limit: v.optional(v.number()),
1067
+ apiBaseUrl: v.optional(v.string()),
1068
+ topicId: v.optional(v.string())
1069
+ },
1070
+ returns: permissiveReturn,
1071
+ handler: async (_ctx, args) => {
1072
+ const result = await callNeo4jQuery(
1073
+ "portfolioConviction",
1074
+ withTopicScope(args, {
1075
+ limit: toInt(args.limit, 50)
1076
+ }),
1077
+ args.apiBaseUrl
1078
+ );
1079
+ if (!result.success) {
1080
+ return { portfolio: [], error: result.error };
1081
+ }
1082
+ return { portfolio: result.data || [] };
1083
+ }
1084
+ });
1085
+ var getStaleThemes = action({
1086
+ args: {
1087
+ limit: v.optional(v.number()),
1088
+ apiBaseUrl: v.optional(v.string()),
1089
+ topicId: v.optional(v.string())
1090
+ },
1091
+ returns: permissiveReturn,
1092
+ handler: async (_ctx, args) => {
1093
+ const result = await callNeo4jQuery(
1094
+ "staleThemes",
1095
+ withTopicScope(args, {
1096
+ limit: toInt(args.limit, 30)
1097
+ }),
1098
+ args.apiBaseUrl
1099
+ );
1100
+ if (!result.success) {
1101
+ return { themes: [], error: result.error };
1102
+ }
1103
+ return { themes: result.data || [] };
1104
+ }
1105
+ });
1106
+ var getMissingQuestionDetection = action({
1107
+ args: {
1108
+ limit: v.optional(v.number()),
1109
+ apiBaseUrl: v.optional(v.string()),
1110
+ topicId: v.optional(v.string())
1111
+ },
1112
+ returns: permissiveReturn,
1113
+ handler: async (_ctx, args) => {
1114
+ const result = await callNeo4jQuery(
1115
+ "missingQuestionDetection",
1116
+ withTopicScope(args, {
1117
+ limit: toInt(args.limit, 30)
1118
+ }),
1119
+ args.apiBaseUrl
1120
+ );
1121
+ if (!result.success) {
1122
+ return { results: [], error: result.error };
1123
+ }
1124
+ return { results: result.data || [] };
1125
+ }
1126
+ });
1127
+ var getSurpriseDetection = action({
1128
+ args: {
1129
+ limit: v.optional(v.number()),
1130
+ apiBaseUrl: v.optional(v.string()),
1131
+ topicId: v.optional(v.string())
1132
+ },
1133
+ returns: permissiveReturn,
1134
+ handler: async (_ctx, args) => {
1135
+ const result = await callNeo4jQuery(
1136
+ "surpriseDetection",
1137
+ withTopicScope(args, {
1138
+ limit: toInt(args.limit, 30)
1139
+ }),
1140
+ args.apiBaseUrl
1141
+ );
1142
+ if (!result.success) {
1143
+ return { results: [], error: result.error };
1144
+ }
1145
+ return { results: result.data || [] };
1146
+ }
1147
+ });
1148
+ var getNonConsensusBeliefs = action({
1149
+ args: {
1150
+ limit: v.optional(v.number()),
1151
+ apiBaseUrl: v.optional(v.string()),
1152
+ topicId: v.optional(v.string())
1153
+ },
1154
+ returns: permissiveReturn,
1155
+ handler: async (_ctx, args) => {
1156
+ const result = await callNeo4jQuery(
1157
+ "nonConsensusBeliefs",
1158
+ withTopicScope(args, {
1159
+ limit: toInt(args.limit, 30)
1160
+ }),
1161
+ args.apiBaseUrl
1162
+ );
1163
+ if (!result.success) {
1164
+ return { results: [], error: result.error };
1165
+ }
1166
+ return { results: result.data || [] };
1167
+ }
1168
+ });
1169
+ var EMBEDDING_DIMENSIONS = 1024;
1170
+ var VALID_INDEX_NAMES = /* @__PURE__ */ new Set([
1171
+ "belief_embedding_index",
1172
+ "question_embedding_index",
1173
+ "evidence_embedding_index",
1174
+ "theme_embedding_index",
1175
+ "source_embedding_index",
1176
+ "synthesis_embedding_index"
1177
+ ]);
1178
+ function clamp(value, min, max) {
1179
+ return Math.max(min, Math.min(max, value));
1180
+ }
1181
+ var semanticSearch = action({
1182
+ args: {
1183
+ embedding: v.array(v.float64()),
1184
+ indexName: v.optional(v.string()),
1185
+ topK: v.optional(v.number()),
1186
+ minScore: v.optional(v.number()),
1187
+ apiBaseUrl: v.optional(v.string()),
1188
+ topicId: v.optional(v.string())
1189
+ },
1190
+ returns: permissiveReturn,
1191
+ handler: async (_ctx, args) => {
1192
+ if (args.embedding.length !== EMBEDDING_DIMENSIONS) {
1193
+ return {
1194
+ results: [],
1195
+ error: `Embedding must be ${EMBEDDING_DIMENSIONS} dimensions, got ${args.embedding.length}`
1196
+ };
1197
+ }
1198
+ const indexName = args.indexName || "belief_embedding_index";
1199
+ if (!VALID_INDEX_NAMES.has(indexName)) {
1200
+ return { results: [], error: `Invalid index name: ${indexName}` };
1201
+ }
1202
+ const result = await callNeo4jQuery(
1203
+ "semanticSearch",
1204
+ {
1205
+ embedding: args.embedding,
1206
+ indexName,
1207
+ topK: toInt(args.topK, 10),
1208
+ minScore: clamp(args.minScore ?? 0.5, 0, 1)
1209
+ },
1210
+ args.apiBaseUrl
1211
+ );
1212
+ if (!result.success) {
1213
+ return { results: [], error: result.error };
1214
+ }
1215
+ return { results: result.data || [] };
1216
+ }
1217
+ });
1218
+ var getSemanticOrphans = action({
1219
+ args: {
1220
+ threshold: v.optional(v.number()),
1221
+ limit: v.optional(v.number()),
1222
+ apiBaseUrl: v.optional(v.string()),
1223
+ topicId: v.optional(v.string())
1224
+ },
1225
+ returns: permissiveReturn,
1226
+ handler: async (_ctx, args) => {
1227
+ const result = await callNeo4jQuery(
1228
+ "semanticOrphans",
1229
+ withTopicScope(args, {
1230
+ threshold: clamp(args.threshold ?? 0.4, 0, 1),
1231
+ limit: toInt(args.limit, 20)
1232
+ }),
1233
+ args.apiBaseUrl
1234
+ );
1235
+ if (!result.success) {
1236
+ return { results: [], error: result.error };
1237
+ }
1238
+ return { results: result.data || [] };
1239
+ }
1240
+ });
1241
+ var getSoftContradictions = action({
1242
+ args: {
1243
+ similarityThreshold: v.optional(v.number()),
1244
+ limit: v.optional(v.number()),
1245
+ apiBaseUrl: v.optional(v.string()),
1246
+ topicId: v.optional(v.string())
1247
+ },
1248
+ returns: permissiveReturn,
1249
+ handler: async (_ctx, args) => {
1250
+ const result = await callNeo4jQuery(
1251
+ "softContradictions",
1252
+ withTopicScope(args, {
1253
+ similarityThreshold: clamp(args.similarityThreshold ?? 0.7, 0, 1),
1254
+ limit: toInt(args.limit, 20)
1255
+ }),
1256
+ args.apiBaseUrl
1257
+ );
1258
+ if (!result.success) {
1259
+ return { results: [], error: result.error };
1260
+ }
1261
+ return { results: result.data || [] };
1262
+ }
1263
+ });
1264
+ var getSemanticBridges = action({
1265
+ args: {
1266
+ similarityThreshold: v.optional(v.number()),
1267
+ limit: v.optional(v.number()),
1268
+ apiBaseUrl: v.optional(v.string()),
1269
+ topicId: v.optional(v.string())
1270
+ },
1271
+ returns: permissiveReturn,
1272
+ handler: async (_ctx, args) => {
1273
+ const result = await callNeo4jQuery(
1274
+ "semanticBridges",
1275
+ withTopicScope(args, {
1276
+ similarityThreshold: clamp(args.similarityThreshold ?? 0.7, 0, 1),
1277
+ limit: toInt(args.limit, 20)
1278
+ }),
1279
+ args.apiBaseUrl
1280
+ );
1281
+ if (!result.success) {
1282
+ return { results: [], error: result.error };
1283
+ }
1284
+ return { results: result.data || [] };
1285
+ }
1286
+ });
1287
+ var graphAwareSearch = action({
1288
+ args: {
1289
+ embedding: v.array(v.float64()),
1290
+ indexName: v.optional(v.string()),
1291
+ topK: v.optional(v.number()),
1292
+ minScore: v.optional(v.number()),
1293
+ apiBaseUrl: v.optional(v.string()),
1294
+ topicId: v.optional(v.string())
1295
+ },
1296
+ returns: permissiveReturn,
1297
+ handler: async (_ctx, args) => {
1298
+ if (args.embedding.length !== EMBEDDING_DIMENSIONS) {
1299
+ return {
1300
+ results: [],
1301
+ error: `Embedding must be ${EMBEDDING_DIMENSIONS} dimensions, got ${args.embedding.length}`
1302
+ };
1303
+ }
1304
+ const indexName = args.indexName || "belief_embedding_index";
1305
+ if (!VALID_INDEX_NAMES.has(indexName)) {
1306
+ return { results: [], error: `Invalid index name: ${indexName}` };
1307
+ }
1308
+ const result = await callNeo4jQuery(
1309
+ "graphAwareSearch",
1310
+ withTopicScope(args, {
1311
+ embedding: args.embedding,
1312
+ indexName,
1313
+ topK: toInt(args.topK, 10),
1314
+ minScore: clamp(args.minScore ?? 0.5, 0, 1)
1315
+ }),
1316
+ args.apiBaseUrl
1317
+ );
1318
+ if (!result.success) {
1319
+ return { results: [], error: result.error };
1320
+ }
1321
+ return { results: result.data || [] };
1322
+ }
1323
+ });
1324
+
1325
+ export { findPotentialContradictions, getAnchoringBiasDetection, getBeliefEvidenceGraph, getBeliefHalfLife, getBeliefsByCompany, getBeliefsByEpistemicStatus, getCausalChains, getChallengedBeliefs, getCompaniesByTheme, getConfirmationBiasScore, getConnectedNodesGraph, getContradictionTensionMap, getCrossThemeBeliefs, getEvidenceByCompany, getEvidenceByMethodology, getEvidenceToBeliefPath, getFalsificationQuestions, getFunctionsByValueChain, getGraphStats, getHighPriorityQuestions, getKnowledgeFrontier, getMeetingPrepBrief, getMinimumFalsificationSet, getMissingQuestionDetection, getNecessaryEvidence, getNodeLineageGraph, getNodeRelationships, getNonConsensusBeliefs, getPeopleByCompany, getPeopleByTheme, getPortfolioConviction, getPredictions, getProprietaryEvidence, getProprietarySignals, getQuestionsByTheme, getQuestionsByValueChain, getReasoningDepthScore, getSemanticBridges, getSemanticOrphans, getSoftContradictions, getSourceConcentrationRisk, getStaleThemes, getSurpriseDetection, getThemeBeliefsGraph, getThemeStats, getThemeSubgraph, getThemeValueChainCandidates, getThemesImpactingCompany, getValueChainsByTheme, graphAwareSearch, queryGraph, searchAllNodes, semanticSearch };
1326
+ //# sourceMappingURL=neo4jQueries.js.map
1327
+ //# sourceMappingURL=neo4jQueries.js.map