@absolutejs/rag 0.0.2 → 0.0.4
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/dist/ai/client/index.js +12 -49
- package/dist/ai/client/index.js.map +8 -8
- package/dist/ai/client/ui.js +12 -49
- package/dist/ai/client/ui.js.map +5 -5
- package/dist/ai/rag/index.js +90 -173
- package/dist/ai/rag/index.js.map +30 -30
- package/dist/ai/rag/quality.js +12 -49
- package/dist/ai/rag/quality.js.map +5 -5
- package/dist/ai/rag/ui.js +12 -49
- package/dist/ai/rag/ui.js.map +5 -5
- package/dist/angular/ai/index.js.map +8 -8
- package/dist/react/ai/index.js.map +22 -22
- package/dist/svelte/ai/index.js.map +20 -20
- package/dist/vue/ai/index.js.map +20 -20
- package/package.json +103 -80
- package/dist/src/ai/client/createRAGAnswerWorkflow.d.ts +0 -32
- package/dist/src/ai/client/createRAGStream.d.ts +0 -2
- package/dist/src/ai/client/createRAGWorkflow.d.ts +0 -3
- package/dist/src/ai/client/index.d.ts +0 -8
- package/dist/src/ai/client/ragClient.d.ts +0 -349
- package/dist/src/ai/client/ui.d.ts +0 -5
- package/dist/src/ai/rag/accessControl.d.ts +0 -2
- package/dist/src/ai/rag/adapters/filtering.d.ts +0 -2
- package/dist/src/ai/rag/adapters/inMemory.d.ts +0 -8
- package/dist/src/ai/rag/adapters/postgres.d.ts +0 -20
- package/dist/src/ai/rag/adapters/queryPlanning.d.ts +0 -26
- package/dist/src/ai/rag/adapters/sqlite.d.ts +0 -24
- package/dist/src/ai/rag/adapters/utils.d.ts +0 -3
- package/dist/src/ai/rag/chat.d.ts +0 -1773
- package/dist/src/ai/rag/collection.d.ts +0 -15
- package/dist/src/ai/rag/constants.d.ts +0 -9
- package/dist/src/ai/rag/emailProviders.d.ts +0 -34
- package/dist/src/ai/rag/embedding.d.ts +0 -9
- package/dist/src/ai/rag/embeddingProviders.d.ts +0 -50
- package/dist/src/ai/rag/extractorProviders.d.ts +0 -58
- package/dist/src/ai/rag/grounding.d.ts +0 -6
- package/dist/src/ai/rag/htmxConfig.d.ts +0 -3
- package/dist/src/ai/rag/htmxWorkflowRenderers.d.ts +0 -3
- package/dist/src/ai/rag/index.d.ts +0 -31
- package/dist/src/ai/rag/ingestion.d.ts +0 -61
- package/dist/src/ai/rag/jobState.d.ts +0 -2
- package/dist/src/ai/rag/lexical.d.ts +0 -42
- package/dist/src/ai/rag/presentation.d.ts +0 -165
- package/dist/src/ai/rag/quality.d.ts +0 -607
- package/dist/src/ai/rag/queryTransforms.d.ts +0 -17
- package/dist/src/ai/rag/reranking.d.ts +0 -17
- package/dist/src/ai/rag/resolveAbsoluteSQLiteVec.d.ts +0 -3
- package/dist/src/ai/rag/retrievalStrategies.d.ts +0 -6
- package/dist/src/ai/rag/sync.d.ts +0 -37
- package/dist/src/ai/rag/types.d.ts +0 -11
- package/dist/src/ai/rag/ui.d.ts +0 -4
- package/dist/src/ai/rag/workflowState.d.ts +0 -1
- package/dist/src/angular/ai/ai-rag-stream.service.d.ts +0 -32
- package/dist/src/angular/ai/ai-rag-workflow.service.d.ts +0 -33
- package/dist/src/angular/ai/index.d.ts +0 -3
- package/dist/src/angular/ai/rag-client.service.d.ts +0 -243
- package/dist/src/constants.d.ts +0 -60
- package/dist/src/react/ai/index.d.ts +0 -18
- package/dist/src/react/ai/useRAG.d.ts +0 -341
- package/dist/src/react/ai/useRAGChunkPreview.d.ts +0 -20
- package/dist/src/react/ai/useRAGCitations.d.ts +0 -9
- package/dist/src/react/ai/useRAGDocuments.d.ts +0 -10
- package/dist/src/react/ai/useRAGEvaluate.d.ts +0 -28
- package/dist/src/react/ai/useRAGGrounding.d.ts +0 -10
- package/dist/src/react/ai/useRAGIndexAdmin.d.ts +0 -58
- package/dist/src/react/ai/useRAGIngest.d.ts +0 -16
- package/dist/src/react/ai/useRAGOps.d.ts +0 -20
- package/dist/src/react/ai/useRAGSearch.d.ts +0 -17
- package/dist/src/react/ai/useRAGSources.d.ts +0 -13
- package/dist/src/react/ai/useRAGStatus.d.ts +0 -10
- package/dist/src/react/ai/useRAGStream.d.ts +0 -55
- package/dist/src/react/ai/useRAGStreamProgress.d.ts +0 -9
- package/dist/src/react/ai/useRAGWorkflow.d.ts +0 -55
- package/dist/src/svelte/ai/createRAG.d.ts +0 -292
- package/dist/src/svelte/ai/createRAGChunkPreview.d.ts +0 -20
- package/dist/src/svelte/ai/createRAGCitations.d.ts +0 -10
- package/dist/src/svelte/ai/createRAGDocuments.d.ts +0 -10
- package/dist/src/svelte/ai/createRAGEvaluate.d.ts +0 -28
- package/dist/src/svelte/ai/createRAGGrounding.d.ts +0 -11
- package/dist/src/svelte/ai/createRAGIndexAdmin.d.ts +0 -58
- package/dist/src/svelte/ai/createRAGIngest.d.ts +0 -17
- package/dist/src/svelte/ai/createRAGOps.d.ts +0 -20
- package/dist/src/svelte/ai/createRAGSearch.d.ts +0 -15
- package/dist/src/svelte/ai/createRAGSources.d.ts +0 -14
- package/dist/src/svelte/ai/createRAGStatus.d.ts +0 -9
- package/dist/src/svelte/ai/createRAGStream.d.ts +0 -30
- package/dist/src/svelte/ai/createRAGStreamProgress.d.ts +0 -8
- package/dist/src/svelte/ai/createRAGWorkflow.d.ts +0 -30
- package/dist/src/svelte/ai/index.d.ts +0 -17
- package/dist/src/vue/ai/index.d.ts +0 -17
- package/dist/src/vue/ai/useRAG.d.ts +0 -2892
- package/dist/src/vue/ai/useRAGChunkPreview.d.ts +0 -152
- package/dist/src/vue/ai/useRAGCitations.d.ts +0 -10
- package/dist/src/vue/ai/useRAGDocuments.d.ts +0 -94
- package/dist/src/vue/ai/useRAGEvaluate.d.ts +0 -1002
- package/dist/src/vue/ai/useRAGGrounding.d.ts +0 -11
- package/dist/src/vue/ai/useRAGIndexAdmin.d.ts +0 -1104
- package/dist/src/vue/ai/useRAGIngest.d.ts +0 -27
- package/dist/src/vue/ai/useRAGOps.d.ts +0 -220
- package/dist/src/vue/ai/useRAGSearch.d.ts +0 -159
- package/dist/src/vue/ai/useRAGSources.d.ts +0 -14
- package/dist/src/vue/ai/useRAGStatus.d.ts +0 -9
- package/dist/src/vue/ai/useRAGStream.d.ts +0 -35
- package/dist/src/vue/ai/useRAGStreamProgress.d.ts +0 -8
- package/dist/src/vue/ai/useRAGWorkflow.d.ts +0 -35
package/package.json
CHANGED
|
@@ -1,82 +1,105 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
2
|
+
"name": "@absolutejs/rag",
|
|
3
|
+
"version": "0.0.4",
|
|
4
|
+
"description": "Standalone RAG ingestion, sync, retrieval, evaluation, clients, and framework adapters extracted from AbsoluteJS",
|
|
5
|
+
"license": "BSL-1.1",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"main": "./dist/ai/rag/index.js",
|
|
8
|
+
"types": "./dist/src/ai/rag/index.d.ts",
|
|
9
|
+
"files": [
|
|
10
|
+
"dist",
|
|
11
|
+
"README.md"
|
|
12
|
+
],
|
|
13
|
+
"exports": {
|
|
14
|
+
".": {
|
|
15
|
+
"import": "./dist/ai/rag/index.js",
|
|
16
|
+
"types": "./dist/src/ai/rag/index.d.ts"
|
|
17
|
+
},
|
|
18
|
+
"./client": {
|
|
19
|
+
"import": "./dist/ai/client/index.js",
|
|
20
|
+
"types": "./dist/src/ai/client/index.d.ts"
|
|
21
|
+
},
|
|
22
|
+
"./client/ui": {
|
|
23
|
+
"import": "./dist/ai/client/ui.js",
|
|
24
|
+
"types": "./dist/src/ai/client/ui.d.ts"
|
|
25
|
+
},
|
|
26
|
+
"./ui": {
|
|
27
|
+
"import": "./dist/ai/rag/ui.js",
|
|
28
|
+
"types": "./dist/src/ai/rag/ui.d.ts"
|
|
29
|
+
},
|
|
30
|
+
"./quality": {
|
|
31
|
+
"import": "./dist/ai/rag/quality.js",
|
|
32
|
+
"types": "./dist/src/ai/rag/quality.d.ts"
|
|
33
|
+
},
|
|
34
|
+
"./react": {
|
|
35
|
+
"import": "./dist/react/ai/index.js",
|
|
36
|
+
"types": "./dist/src/react/ai/index.d.ts"
|
|
37
|
+
},
|
|
38
|
+
"./vue": {
|
|
39
|
+
"import": "./dist/vue/ai/index.js",
|
|
40
|
+
"types": "./dist/src/vue/ai/index.d.ts"
|
|
41
|
+
},
|
|
42
|
+
"./svelte": {
|
|
43
|
+
"import": "./dist/svelte/ai/index.js",
|
|
44
|
+
"types": "./dist/src/svelte/ai/index.d.ts"
|
|
45
|
+
},
|
|
46
|
+
"./angular": {
|
|
47
|
+
"import": "./dist/angular/ai/index.js",
|
|
48
|
+
"types": "./dist/src/angular/ai/index.d.ts"
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
"dependencies": {
|
|
52
|
+
"@absolutejs/ai": "0.0.4",
|
|
53
|
+
"@absolutejs/linked-providers": "0.0.2"
|
|
54
|
+
},
|
|
55
|
+
"peerDependencies": {
|
|
56
|
+
"@angular/core": "^21.0.0",
|
|
57
|
+
"elysia": "^1.4.18",
|
|
58
|
+
"react": "^19.2.0",
|
|
59
|
+
"svelte": "^5.35.2",
|
|
60
|
+
"vue": "^3.5.27"
|
|
61
|
+
},
|
|
62
|
+
"peerDependenciesMeta": {
|
|
63
|
+
"@angular/core": {
|
|
64
|
+
"optional": true
|
|
65
|
+
},
|
|
66
|
+
"react": {
|
|
67
|
+
"optional": true
|
|
68
|
+
},
|
|
69
|
+
"svelte": {
|
|
70
|
+
"optional": true
|
|
71
|
+
},
|
|
72
|
+
"vue": {
|
|
73
|
+
"optional": true
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
"devDependencies": {
|
|
77
|
+
"@angular/core": "^21.0.0",
|
|
78
|
+
"@types/bun": "1.3.9",
|
|
79
|
+
"@types/react": "19.2.0",
|
|
80
|
+
"elysia": "1.4.18",
|
|
81
|
+
"react": "19.2.1",
|
|
82
|
+
"svelte": "5.55.0",
|
|
83
|
+
"typescript": "^5.9.3",
|
|
84
|
+
"vue": "3.5.27",
|
|
85
|
+
"@eslint/js": "^10.0.1",
|
|
86
|
+
"eslint": "^10.0.3",
|
|
87
|
+
"globals": "^17.4.0",
|
|
88
|
+
"prettier": "^3.5.3",
|
|
89
|
+
"typescript-eslint": "^8.56.1",
|
|
90
|
+
"eslint-plugin-absolute": "^0.2.6",
|
|
91
|
+
"eslint-plugin-promise": "^7.2.1",
|
|
92
|
+
"react-dom": "19.2.1"
|
|
93
|
+
},
|
|
94
|
+
"scripts": {
|
|
95
|
+
"build": "bun run scripts/build.ts",
|
|
96
|
+
"typecheck": "tsc --noEmit --project tsconfig.json",
|
|
97
|
+
"lint": "eslint . --max-warnings 0",
|
|
98
|
+
"format": "prettier --write .",
|
|
99
|
+
"test": "bun test",
|
|
100
|
+
"release": "bun publish --access public"
|
|
101
|
+
},
|
|
102
|
+
"publishConfig": {
|
|
103
|
+
"access": "public"
|
|
104
|
+
}
|
|
82
105
|
}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import type { AIAttachment, RAGAnswerWorkflowState } from '@absolutejs/ai';
|
|
2
|
-
export declare const createRAGAnswerWorkflow: (path: string, conversationId?: string) => {
|
|
3
|
-
state: RAGAnswerWorkflowState;
|
|
4
|
-
latestAssistantMessage: import("@absolutejs/ai").AIMessage | undefined;
|
|
5
|
-
retrieval: import("@absolutejs/ai").RAGRetrievedState | null;
|
|
6
|
-
sources: import("@absolutejs/ai").RAGSource[];
|
|
7
|
-
sourceGroups: import("@absolutejs/ai").RAGSourceGroup[];
|
|
8
|
-
sourceSummaries: import("@absolutejs/ai").RAGSourceSummary[];
|
|
9
|
-
citations: import("@absolutejs/ai").RAGCitation[];
|
|
10
|
-
citationReferenceMap: import("@absolutejs/ai").RAGCitationReferenceMap;
|
|
11
|
-
groundingReferences: import("@absolutejs/ai").RAGGroundingReference[];
|
|
12
|
-
groundedAnswer: import("@absolutejs/ai").RAGGroundedAnswer;
|
|
13
|
-
stage: import("@absolutejs/ai").RAGStreamStage;
|
|
14
|
-
isRunning: boolean;
|
|
15
|
-
isRetrieving: boolean;
|
|
16
|
-
isRetrieved: boolean;
|
|
17
|
-
isAnswerStreaming: boolean;
|
|
18
|
-
isComplete: boolean;
|
|
19
|
-
isError: boolean;
|
|
20
|
-
hasSources: boolean;
|
|
21
|
-
hasRetrieved: boolean;
|
|
22
|
-
query: (content: string, attachments?: AIAttachment[]) => void;
|
|
23
|
-
branch: (messageId: string, content: string) => void;
|
|
24
|
-
cancel: () => void;
|
|
25
|
-
destroy: () => void;
|
|
26
|
-
send: (content: string, attachments?: AIAttachment[]) => void;
|
|
27
|
-
subscribe: (callback: () => void) => () => void;
|
|
28
|
-
error: string | null;
|
|
29
|
-
isStreaming: boolean;
|
|
30
|
-
messages: import("@absolutejs/ai").AIMessage[];
|
|
31
|
-
};
|
|
32
|
-
export type RAGAnswerWorkflow = ReturnType<typeof createRAGAnswerWorkflow>;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export { createRAGAnswerWorkflow as createRAGWorkflow } from './createRAGAnswerWorkflow';
|
|
2
|
-
export type { RAGAnswerWorkflow as CreateRAGWorkflow } from './createRAGAnswerWorkflow';
|
|
3
|
-
export type { RAGAnswerWorkflow as RAGWorkflow } from './createRAGAnswerWorkflow';
|
|
4
|
-
export { createRAGStream } from './createRAGStream';
|
|
5
|
-
export type { CreateRAGStream } from './createRAGStream';
|
|
6
|
-
export { buildRAGMaintenanceOverview, createRAGClient } from './ragClient';
|
|
7
|
-
export type { RAGClient, RAGClientOptions, RAGDetailedSearchResponse, RAGMaintenanceActionDescriptor, RAGMaintenanceOverview, RAGMaintenancePayload } from './ragClient';
|
|
8
|
-
export { buildRAGEvaluationLeaderboard, createRAGEvaluationSuite, runRAGEvaluationSuite } from '../rag/quality';
|
|
@@ -1,349 +0,0 @@
|
|
|
1
|
-
import type { RAGBackendsResponse, RAGBackendMaintenanceRecommendation, RAGBackendMaintenanceSummary, RAGDocumentChunksResponse, RAGEvaluationInput, RAGEvaluationResponse, RAGRetrievalBaselinePromotionFromRunRequest, RAGRetrievalBaselinePromotionRequest, RAGRetrievalBaselineRevertRequest, RAGRetrievalReleaseIncidentAcknowledgeRequest, RAGRetrievalReleaseDecisionActionRequest, RAGRetrievalBaselineResponse, RAGRetrievalLaneHandoffDecisionRequest, RAGRetrievalLaneHandoffDecisionResponse, RAGRetrievalLaneHandoffIncidentStatusResponse, RAGRetrievalLaneHandoffStatusResponse, RAGRetrievalIncidentRemediationDecisionRequest, RAGRetrievalIncidentRemediationBulkExecutionRequest, RAGRetrievalIncidentRemediationExecutionRequest, RAGRetrievalIncidentRemediationExecutionResponse, RAGRetrievalIncidentRemediationStatusResponse, RAGRetrievalReleaseGroupHistoryResponse, RAGRetrievalReleaseIncidentStatusResponse, RAGRetrievalReleaseDriftStatusResponse, RAGRetrievalComparisonRequest, RAGAdaptiveNativePlannerBenchmarkResponse, RAGAdaptiveNativePlannerBenchmarkSnapshotResponse, RAGDocumentIngestInput, RAGDocumentChunk, RAGDocumentsResponse, RAGDocumentUrlIngestInput, RAGDocumentUploadIngestInput, RAGIngestResponse, RAGMutationResponse, RAGOperationsResponse, RAGSearchRequest, RAGSearchResponse, RAGSearchTracePruneResponse, RAGSource, RAGStatusResponse, RAGSyncRunOptions, RAGSyncResponse } from '@absolutejs/ai';
|
|
2
|
-
type FetchLike = typeof fetch;
|
|
3
|
-
export type RAGClientOptions = {
|
|
4
|
-
path: string;
|
|
5
|
-
fetch?: FetchLike;
|
|
6
|
-
};
|
|
7
|
-
export type RAGDetailedSearchResponse = {
|
|
8
|
-
results: RAGSource[];
|
|
9
|
-
trace?: RAGSearchResponse['trace'];
|
|
10
|
-
};
|
|
11
|
-
export type RAGMaintenancePayload = Pick<RAGMutationResponse, 'maintenance' | 'admin' | 'workflowStatus'> | Pick<RAGOperationsResponse, 'maintenance' | 'admin' | 'status'> | Pick<RAGStatusResponse, 'maintenance' | 'admin' | 'status'> | null | undefined;
|
|
12
|
-
export type RAGMaintenanceActionDescriptor = {
|
|
13
|
-
kind: 'analyze_backend' | 'rebuild_native_index';
|
|
14
|
-
label: string;
|
|
15
|
-
available: boolean;
|
|
16
|
-
recommended: boolean;
|
|
17
|
-
reason?: string;
|
|
18
|
-
};
|
|
19
|
-
export type RAGMaintenanceOverview = {
|
|
20
|
-
activeJobCount: number;
|
|
21
|
-
actions: RAGMaintenanceActionDescriptor[];
|
|
22
|
-
availableActions: RAGMaintenanceActionDescriptor[];
|
|
23
|
-
backend?: RAGBackendMaintenanceSummary['backend'];
|
|
24
|
-
blockingRecommendations: RAGBackendMaintenanceRecommendation[];
|
|
25
|
-
criticalCount: number;
|
|
26
|
-
hasBlockingIssue: boolean;
|
|
27
|
-
infoCount: number;
|
|
28
|
-
primaryRecommendation?: RAGBackendMaintenanceRecommendation;
|
|
29
|
-
recentlyCompletedActions: NonNullable<RAGBackendMaintenanceSummary>['recentActions'];
|
|
30
|
-
recommendationCount: number;
|
|
31
|
-
recommendations: RAGBackendMaintenanceRecommendation[];
|
|
32
|
-
recommendedNow: RAGBackendMaintenanceRecommendation[];
|
|
33
|
-
warningCount: number;
|
|
34
|
-
};
|
|
35
|
-
export declare const buildRAGMaintenanceOverview: (payload: RAGMaintenancePayload) => RAGMaintenanceOverview;
|
|
36
|
-
export declare const createRAGClient: (options: RAGClientOptions) => {
|
|
37
|
-
backends(): Promise<RAGBackendsResponse>;
|
|
38
|
-
clearIndex(): Promise<{
|
|
39
|
-
ok: boolean;
|
|
40
|
-
}>;
|
|
41
|
-
createDocument(input: RAGDocumentIngestInput["documents"][number]): Promise<RAGMutationResponse>;
|
|
42
|
-
deleteDocument(id: string): Promise<RAGMutationResponse>;
|
|
43
|
-
documentChunks(id: string): Promise<RAGDocumentChunksResponse>;
|
|
44
|
-
documents(kind?: string): Promise<RAGDocumentsResponse>;
|
|
45
|
-
evaluate(input: RAGEvaluationInput): Promise<RAGEvaluationResponse>;
|
|
46
|
-
compareRetrievals(input: RAGRetrievalComparisonRequest): Promise<import("@absolutejs/ai").RAGRetrievalComparison>;
|
|
47
|
-
retrievalComparisonHistory(input?: {
|
|
48
|
-
limit?: number;
|
|
49
|
-
suiteId?: string;
|
|
50
|
-
label?: string;
|
|
51
|
-
winnerId?: string;
|
|
52
|
-
groupKey?: string;
|
|
53
|
-
tag?: string;
|
|
54
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalComparisonRun[]>;
|
|
55
|
-
retrievalBaselines(input?: {
|
|
56
|
-
groupKey?: string;
|
|
57
|
-
tag?: string;
|
|
58
|
-
limit?: number;
|
|
59
|
-
status?: "active" | "superseded";
|
|
60
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalBaselineRecord[]>;
|
|
61
|
-
promoteRetrievalBaseline(input: RAGRetrievalBaselinePromotionRequest): Promise<import("@absolutejs/ai").RAGRetrievalBaselineRecord>;
|
|
62
|
-
promoteRetrievalBaselineDetailed(input: RAGRetrievalBaselinePromotionRequest): Promise<RAGRetrievalBaselineResponse>;
|
|
63
|
-
promoteRetrievalBaselineToLane(input: RAGRetrievalBaselinePromotionRequest & {
|
|
64
|
-
rolloutLabel: "canary" | "stable" | "rollback_target";
|
|
65
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalBaselineRecord>;
|
|
66
|
-
promoteRetrievalBaselineToLaneDetailed(input: RAGRetrievalBaselinePromotionRequest & {
|
|
67
|
-
rolloutLabel: "canary" | "stable" | "rollback_target";
|
|
68
|
-
}): Promise<RAGRetrievalBaselineResponse>;
|
|
69
|
-
promoteRetrievalBaselineFromRun(input: RAGRetrievalBaselinePromotionFromRunRequest): Promise<import("@absolutejs/ai").RAGRetrievalBaselineRecord>;
|
|
70
|
-
promoteRetrievalBaselineFromRunDetailed(input: RAGRetrievalBaselinePromotionFromRunRequest): Promise<RAGRetrievalBaselineResponse>;
|
|
71
|
-
revertRetrievalBaseline(input: RAGRetrievalBaselineRevertRequest): Promise<import("@absolutejs/ai").RAGRetrievalBaselineRecord>;
|
|
72
|
-
retrievalBaselineDecisions(input?: {
|
|
73
|
-
groupKey?: string;
|
|
74
|
-
limit?: number;
|
|
75
|
-
kind?: "approve" | "promote" | "reject" | "revert";
|
|
76
|
-
freshnessStatus?: "fresh" | "expired" | "not_applicable";
|
|
77
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
78
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseDecisionRecord[]>;
|
|
79
|
-
retrievalReleaseGroupHistory(input: {
|
|
80
|
-
groupKey: string;
|
|
81
|
-
decisionLimit?: number;
|
|
82
|
-
baselineLimit?: number;
|
|
83
|
-
benchmarkLimit?: number;
|
|
84
|
-
runLimit?: number;
|
|
85
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
86
|
-
}): Promise<RAGRetrievalReleaseGroupHistoryResponse>;
|
|
87
|
-
adaptiveNativePlannerBenchmark(input?: {
|
|
88
|
-
limit?: number;
|
|
89
|
-
runLimit?: number;
|
|
90
|
-
label?: string;
|
|
91
|
-
description?: string;
|
|
92
|
-
groupKey?: string;
|
|
93
|
-
corpusGroupKey?: string;
|
|
94
|
-
}): Promise<RAGAdaptiveNativePlannerBenchmarkResponse>;
|
|
95
|
-
runAdaptiveNativePlannerBenchmark(input?: {
|
|
96
|
-
limit?: number;
|
|
97
|
-
runLimit?: number;
|
|
98
|
-
topK?: number;
|
|
99
|
-
label?: string;
|
|
100
|
-
description?: string;
|
|
101
|
-
groupKey?: string;
|
|
102
|
-
corpusGroupKey?: string;
|
|
103
|
-
persistRun?: boolean;
|
|
104
|
-
baselineRetrievalId?: string;
|
|
105
|
-
candidateRetrievalId?: string;
|
|
106
|
-
retrievals?: Array<{
|
|
107
|
-
id: string;
|
|
108
|
-
label?: string;
|
|
109
|
-
retrieval?: Record<string, unknown> | string;
|
|
110
|
-
}>;
|
|
111
|
-
tags?: string[];
|
|
112
|
-
metadata?: Record<string, unknown>;
|
|
113
|
-
}): Promise<RAGAdaptiveNativePlannerBenchmarkResponse>;
|
|
114
|
-
saveAdaptiveNativePlannerBenchmarkSnapshot(input?: {
|
|
115
|
-
limit?: number;
|
|
116
|
-
label?: string;
|
|
117
|
-
description?: string;
|
|
118
|
-
version?: number;
|
|
119
|
-
createdAt?: number;
|
|
120
|
-
metadata?: Record<string, unknown>;
|
|
121
|
-
snapshotMetadata?: Record<string, unknown>;
|
|
122
|
-
}): Promise<RAGAdaptiveNativePlannerBenchmarkSnapshotResponse>;
|
|
123
|
-
nativeBackendComparisonBenchmark(input?: {
|
|
124
|
-
limit?: number;
|
|
125
|
-
runLimit?: number;
|
|
126
|
-
label?: string;
|
|
127
|
-
description?: string;
|
|
128
|
-
groupKey?: string;
|
|
129
|
-
corpusGroupKey?: string;
|
|
130
|
-
}): Promise<RAGAdaptiveNativePlannerBenchmarkResponse>;
|
|
131
|
-
runNativeBackendComparisonBenchmark(input?: {
|
|
132
|
-
limit?: number;
|
|
133
|
-
runLimit?: number;
|
|
134
|
-
topK?: number;
|
|
135
|
-
label?: string;
|
|
136
|
-
description?: string;
|
|
137
|
-
groupKey?: string;
|
|
138
|
-
corpusGroupKey?: string;
|
|
139
|
-
persistRun?: boolean;
|
|
140
|
-
baselineRetrievalId?: string;
|
|
141
|
-
candidateRetrievalId?: string;
|
|
142
|
-
retrievals?: Array<{
|
|
143
|
-
id: string;
|
|
144
|
-
label?: string;
|
|
145
|
-
retrieval?: Record<string, unknown> | string;
|
|
146
|
-
}>;
|
|
147
|
-
tags?: string[];
|
|
148
|
-
metadata?: Record<string, unknown>;
|
|
149
|
-
}): Promise<RAGAdaptiveNativePlannerBenchmarkResponse>;
|
|
150
|
-
saveNativeBackendComparisonBenchmarkSnapshot(input?: {
|
|
151
|
-
limit?: number;
|
|
152
|
-
label?: string;
|
|
153
|
-
description?: string;
|
|
154
|
-
version?: number;
|
|
155
|
-
createdAt?: number;
|
|
156
|
-
metadata?: Record<string, unknown>;
|
|
157
|
-
snapshotMetadata?: Record<string, unknown>;
|
|
158
|
-
}): Promise<RAGAdaptiveNativePlannerBenchmarkSnapshotResponse>;
|
|
159
|
-
retrievalLaneHandoffs(input?: {
|
|
160
|
-
groupKey?: string;
|
|
161
|
-
sourceRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
162
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
163
|
-
limit?: number;
|
|
164
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseLaneHandoffSummary[]>;
|
|
165
|
-
retrievalLaneHandoffDecisions(input?: {
|
|
166
|
-
groupKey?: string;
|
|
167
|
-
sourceRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
168
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
169
|
-
kind?: "approve" | "reject" | "complete";
|
|
170
|
-
limit?: number;
|
|
171
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffDecisionRecord[]>;
|
|
172
|
-
retrievalLaneHandoffIncidents(input?: {
|
|
173
|
-
groupKey?: string;
|
|
174
|
-
limit?: number;
|
|
175
|
-
status?: "open" | "resolved";
|
|
176
|
-
severity?: "warning" | "critical";
|
|
177
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
178
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffIncidentRecord[]>;
|
|
179
|
-
retrievalLaneHandoffIncidentHistory(input?: {
|
|
180
|
-
action?: "opened" | "acknowledged" | "unacknowledged" | "resolved";
|
|
181
|
-
groupKey?: string;
|
|
182
|
-
incidentId?: string;
|
|
183
|
-
limit?: number;
|
|
184
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
185
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffIncidentHistoryRecord[]>;
|
|
186
|
-
retrievalLaneHandoffAutoCompletePolicyHistory(input?: {
|
|
187
|
-
groupKey?: string;
|
|
188
|
-
limit?: number;
|
|
189
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
190
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffAutoCompletePolicyHistoryRecord[]>;
|
|
191
|
-
retrievalReleaseLanePolicyHistory(input?: {
|
|
192
|
-
groupKey?: string;
|
|
193
|
-
limit?: number;
|
|
194
|
-
rolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
195
|
-
scope?: "rollout_label" | "group_rollout_label";
|
|
196
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseLanePolicyHistoryRecord[]>;
|
|
197
|
-
retrievalBaselineGatePolicyHistory(input?: {
|
|
198
|
-
groupKey?: string;
|
|
199
|
-
limit?: number;
|
|
200
|
-
rolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
201
|
-
scope?: "rollout_label" | "group_rollout_label";
|
|
202
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalBaselineGatePolicyHistoryRecord[]>;
|
|
203
|
-
retrievalReleaseLaneEscalationPolicyHistory(input?: {
|
|
204
|
-
groupKey?: string;
|
|
205
|
-
limit?: number;
|
|
206
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
207
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseLaneEscalationPolicyHistoryRecord[]>;
|
|
208
|
-
retrievalReleaseIncidentPolicyHistory(input?: {
|
|
209
|
-
groupKey?: string;
|
|
210
|
-
limit?: number;
|
|
211
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
212
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseLaneEscalationPolicyHistoryRecord[]>;
|
|
213
|
-
retrievalReleaseIncidentStatus(): Promise<RAGRetrievalReleaseIncidentStatusResponse>;
|
|
214
|
-
retrievalIncidentRemediationStatus(): Promise<RAGRetrievalIncidentRemediationStatusResponse>;
|
|
215
|
-
retrievalLaneHandoffIncidentStatus(): Promise<RAGRetrievalLaneHandoffIncidentStatusResponse>;
|
|
216
|
-
acknowledgeRetrievalLaneHandoffIncident(input: RAGRetrievalReleaseIncidentAcknowledgeRequest): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffIncidentRecord[]>;
|
|
217
|
-
unacknowledgeRetrievalLaneHandoffIncident(input: {
|
|
218
|
-
incidentId: string;
|
|
219
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffIncidentRecord[]>;
|
|
220
|
-
resolveRetrievalLaneHandoffIncident(input: {
|
|
221
|
-
incidentId: string;
|
|
222
|
-
resolvedAt?: number;
|
|
223
|
-
resolvedBy?: string;
|
|
224
|
-
resolutionNotes?: string;
|
|
225
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffIncidentRecord[]>;
|
|
226
|
-
decideRetrievalLaneHandoff(input: RAGRetrievalLaneHandoffDecisionRequest): Promise<import("@absolutejs/ai").RAGRetrievalLaneHandoffDecisionRecord>;
|
|
227
|
-
decideRetrievalLaneHandoffDetailed(input: RAGRetrievalLaneHandoffDecisionRequest): Promise<RAGRetrievalLaneHandoffDecisionResponse>;
|
|
228
|
-
retrievalReleaseIncidents(input?: {
|
|
229
|
-
groupKey?: string;
|
|
230
|
-
limit?: number;
|
|
231
|
-
status?: "open" | "resolved";
|
|
232
|
-
severity?: "warning" | "critical";
|
|
233
|
-
kind?: "approval_expired" | "baseline_regression" | "gate_failure" | "handoff_stale";
|
|
234
|
-
acknowledged?: boolean;
|
|
235
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
236
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseIncidentRecord[]>;
|
|
237
|
-
retrievalIncidentRemediationDecisions(input?: {
|
|
238
|
-
groupKey?: string;
|
|
239
|
-
incidentId?: string;
|
|
240
|
-
limit?: number;
|
|
241
|
-
remediationKind?: RAGRetrievalIncidentRemediationDecisionRequest["remediationKind"];
|
|
242
|
-
status?: "planned" | "applied" | "dismissed";
|
|
243
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
244
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalIncidentRemediationDecisionRecord[]>;
|
|
245
|
-
retrievalIncidentRemediationExecutions(input?: {
|
|
246
|
-
groupKey?: string;
|
|
247
|
-
incidentId?: string;
|
|
248
|
-
limit?: number;
|
|
249
|
-
actionKind?: RAGRetrievalIncidentRemediationExecutionRequest["action"]["kind"];
|
|
250
|
-
code?: NonNullable<RAGRetrievalIncidentRemediationExecutionResponse["execution"]>["code"];
|
|
251
|
-
blockedByGuardrail?: boolean;
|
|
252
|
-
idempotentReplay?: boolean;
|
|
253
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
254
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalIncidentRemediationExecutionHistoryRecord[]>;
|
|
255
|
-
recordRetrievalIncidentRemediationDecision(input: RAGRetrievalIncidentRemediationDecisionRequest): Promise<import("@absolutejs/ai").RAGRetrievalIncidentRemediationDecisionRecord[]>;
|
|
256
|
-
executeRetrievalIncidentRemediation(input: RAGRetrievalIncidentRemediationExecutionRequest): Promise<RAGRetrievalIncidentRemediationExecutionResponse>;
|
|
257
|
-
bulkExecuteRetrievalIncidentRemediations(input: RAGRetrievalIncidentRemediationBulkExecutionRequest): Promise<{
|
|
258
|
-
index: number;
|
|
259
|
-
ok: boolean;
|
|
260
|
-
execution?: import("@absolutejs/ai").RAGRetrievalIncidentRemediationExecutionResult;
|
|
261
|
-
record?: import("@absolutejs/ai").RAGRetrievalIncidentRemediationDecisionRecord;
|
|
262
|
-
error?: string;
|
|
263
|
-
}[]>;
|
|
264
|
-
acknowledgeRetrievalReleaseIncident(input: RAGRetrievalReleaseIncidentAcknowledgeRequest): Promise<import("@absolutejs/ai").RAGRetrievalReleaseIncidentRecord[]>;
|
|
265
|
-
unacknowledgeRetrievalReleaseIncident(input: {
|
|
266
|
-
incidentId: string;
|
|
267
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseIncidentRecord[]>;
|
|
268
|
-
resolveRetrievalReleaseIncident(input: {
|
|
269
|
-
incidentId: string;
|
|
270
|
-
resolvedAt?: number;
|
|
271
|
-
resolvedBy?: string;
|
|
272
|
-
resolutionNotes?: string;
|
|
273
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalReleaseIncidentRecord[]>;
|
|
274
|
-
retrievalPromotionCandidates(input?: {
|
|
275
|
-
groupKey?: string;
|
|
276
|
-
limit?: number;
|
|
277
|
-
tag?: string;
|
|
278
|
-
targetRolloutLabel?: "canary" | "stable" | "rollback_target";
|
|
279
|
-
approved?: boolean;
|
|
280
|
-
ready?: boolean;
|
|
281
|
-
blocked?: boolean;
|
|
282
|
-
reviewStatus?: "approved" | "blocked" | "needs_review" | "ready";
|
|
283
|
-
freshnessStatus?: "fresh" | "expired" | "not_applicable";
|
|
284
|
-
sortBy?: "approvalFreshness" | "finishedAt" | "gateSeverity" | "priority";
|
|
285
|
-
sortDirection?: "asc" | "desc";
|
|
286
|
-
}): Promise<import("@absolutejs/ai").RAGRetrievalPromotionCandidate[]>;
|
|
287
|
-
approveRetrievalCandidate(input: RAGRetrievalReleaseDecisionActionRequest): Promise<import("@absolutejs/ai").RAGRetrievalReleaseDecisionRecord[]>;
|
|
288
|
-
rejectRetrievalCandidate(input: RAGRetrievalReleaseDecisionActionRequest): Promise<import("@absolutejs/ai").RAGRetrievalReleaseDecisionRecord[]>;
|
|
289
|
-
ingest(chunks: RAGDocumentChunk[]): Promise<RAGIngestResponse>;
|
|
290
|
-
ingestDocuments(input: RAGDocumentIngestInput): Promise<RAGIngestResponse>;
|
|
291
|
-
ingestUploads(input: RAGDocumentUploadIngestInput): Promise<RAGIngestResponse>;
|
|
292
|
-
ingestUrls(input: RAGDocumentUrlIngestInput): Promise<RAGIngestResponse>;
|
|
293
|
-
analyzeBackend(): Promise<RAGMutationResponse>;
|
|
294
|
-
ops(): Promise<RAGOperationsResponse>;
|
|
295
|
-
searchTraceHistory(input?: {
|
|
296
|
-
query?: string;
|
|
297
|
-
groupKey?: string;
|
|
298
|
-
tag?: string;
|
|
299
|
-
limit?: number;
|
|
300
|
-
}): Promise<import("@absolutejs/ai").RAGSearchTraceHistory>;
|
|
301
|
-
searchTraceGroups(input?: {
|
|
302
|
-
tag?: string;
|
|
303
|
-
limit?: number;
|
|
304
|
-
}): Promise<import("@absolutejs/ai").RAGSearchTraceGroupHistory>;
|
|
305
|
-
searchTraceStats(input?: {
|
|
306
|
-
tag?: string;
|
|
307
|
-
}): Promise<import("@absolutejs/ai").RAGSearchTraceStats>;
|
|
308
|
-
previewSearchTracePrune(input?: {
|
|
309
|
-
maxAgeMs?: number;
|
|
310
|
-
maxRecordsPerQuery?: number;
|
|
311
|
-
maxRecordsPerGroup?: number;
|
|
312
|
-
now?: number;
|
|
313
|
-
tag?: string;
|
|
314
|
-
}): Promise<import("@absolutejs/ai").RAGSearchTracePrunePreview>;
|
|
315
|
-
pruneSearchTraces(input?: {
|
|
316
|
-
maxAgeMs?: number;
|
|
317
|
-
maxRecordsPerQuery?: number;
|
|
318
|
-
maxRecordsPerGroup?: number;
|
|
319
|
-
now?: number;
|
|
320
|
-
tag?: string;
|
|
321
|
-
}): Promise<RAGSearchTracePruneResponse>;
|
|
322
|
-
searchTracePruneHistory(input?: {
|
|
323
|
-
limit?: number;
|
|
324
|
-
trigger?: "manual" | "write" | "schedule";
|
|
325
|
-
}): Promise<import("@absolutejs/ai").RAGSearchTracePruneRun[]>;
|
|
326
|
-
syncSources(): Promise<RAGSyncResponse>;
|
|
327
|
-
syncAllSources(options?: RAGSyncRunOptions): Promise<RAGSyncResponse>;
|
|
328
|
-
syncSource(id: string, options?: RAGSyncRunOptions): Promise<RAGSyncResponse>;
|
|
329
|
-
reindexDocument(id: string): Promise<RAGMutationResponse>;
|
|
330
|
-
reindexSource(source: string): Promise<RAGMutationResponse>;
|
|
331
|
-
reseed(): Promise<RAGMutationResponse>;
|
|
332
|
-
reset(): Promise<RAGMutationResponse>;
|
|
333
|
-
rebuildNativeIndex(): Promise<RAGMutationResponse>;
|
|
334
|
-
search: <IncludeTrace extends boolean | undefined = undefined>(input: RAGSearchRequest & {
|
|
335
|
-
includeTrace?: IncludeTrace;
|
|
336
|
-
}) => Promise<IncludeTrace extends true ? RAGDetailedSearchResponse : RAGSource[]>;
|
|
337
|
-
searchWithTrace(input: RAGSearchRequest): Promise<RAGDetailedSearchResponse>;
|
|
338
|
-
/**
|
|
339
|
-
* @deprecated Use `searchWithTrace` for trace-aware search responses.
|
|
340
|
-
*/
|
|
341
|
-
searchDetailed(input: RAGSearchRequest): Promise<RAGDetailedSearchResponse>;
|
|
342
|
-
status(): Promise<RAGStatusResponse>;
|
|
343
|
-
statusMaintenance(): Promise<RAGStatusResponse>;
|
|
344
|
-
retrievalReleaseStatus(): Promise<import("@absolutejs/ai").RAGRetrievalComparisonRuntime | undefined>;
|
|
345
|
-
retrievalReleaseDriftStatus(): Promise<RAGRetrievalReleaseDriftStatusResponse>;
|
|
346
|
-
retrievalLaneHandoffStatus(): Promise<RAGRetrievalLaneHandoffStatusResponse>;
|
|
347
|
-
};
|
|
348
|
-
export type RAGClient = ReturnType<typeof createRAGClient>;
|
|
349
|
-
export {};
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
export { buildRAGAnswerWorkflowState, buildRAGSourceGroups, buildRAGSourceSummaries, buildRAGStreamProgress, getLatestAssistantMessage, resolveRAGStreamStage } from '../rag/workflowState';
|
|
2
|
-
export { buildRAGStreamProgress as getRAGStreamProgress } from '../rag/workflowState';
|
|
3
|
-
export { buildRAGCitationReferenceMap, buildRAGChunkExcerpts, buildRAGChunkGraphNavigation, buildRAGChunkGraph, buildRAGChunkPreviewGraph, buildRAGChunkPreviewNavigation, buildRAGGroundedAnswer, buildRAGGroundedAnswerSectionSummaries, buildRAGGroundingReferences, buildRAGSectionRetrievalDiagnostics } from '../rag/presentation';
|
|
4
|
-
export type { RAGStreamProgress, RAGStreamProgressState } from '../rag/workflowState';
|
|
5
|
-
export type { RAGAnswerWorkflowState } from '@absolutejs/ai';
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import type { CreateRAGAccessControlOptions, RAGChatPluginConfig } from '@absolutejs/ai';
|
|
2
|
-
export declare const createRAGAccessControl: <TContext = unknown>(options: CreateRAGAccessControlOptions<TContext>) => Pick<RAGChatPluginConfig, "authorizeRAGAction" | "resolveRAGAccessScope">;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { createRAGVector, normalizeVector, querySimilarity } from './utils';
|
|
2
|
-
import type { RAGVectorStore } from '@absolutejs/ai';
|
|
3
|
-
export type InMemoryRAGStoreOptions = {
|
|
4
|
-
dimensions?: number;
|
|
5
|
-
mockEmbedding?: (text: string) => Promise<number[]>;
|
|
6
|
-
};
|
|
7
|
-
export declare const createInMemoryRAGStore: (options?: InMemoryRAGStoreOptions) => RAGVectorStore;
|
|
8
|
-
export { createRAGVector, normalizeVector, querySimilarity };
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import type { RAGVectorStore } from '@absolutejs/ai';
|
|
2
|
-
type BunSQLClient = InstanceType<typeof Bun.SQL>;
|
|
3
|
-
type PostgresDistanceMetric = 'cosine' | 'l2' | 'inner_product';
|
|
4
|
-
type PostgresIndexType = 'none' | 'hnsw' | 'ivfflat';
|
|
5
|
-
export type PostgresRAGStoreOptions = {
|
|
6
|
-
connectionString?: string;
|
|
7
|
-
sql?: BunSQLClient;
|
|
8
|
-
dimensions?: number;
|
|
9
|
-
mockEmbedding?: (text: string) => Promise<number[]>;
|
|
10
|
-
tableName?: string;
|
|
11
|
-
schemaName?: string;
|
|
12
|
-
distanceMetric?: PostgresDistanceMetric;
|
|
13
|
-
queryMultiplier?: number;
|
|
14
|
-
indexType?: PostgresIndexType;
|
|
15
|
-
indexLists?: number;
|
|
16
|
-
hnswM?: number;
|
|
17
|
-
hnswEfConstruction?: number;
|
|
18
|
-
};
|
|
19
|
-
export declare const createPostgresRAGStore: (options?: PostgresRAGStoreOptions) => RAGVectorStore;
|
|
20
|
-
export {};
|