@retrivora-ai/rag-engine 2.5.5 → 2.5.7

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.
Files changed (51) hide show
  1. package/dist/ChromaDBProvider-4RPJN7Y3.mjs +8 -0
  2. package/dist/{ILLMProvider-DO5gj-e5.d.mts → ILLMProvider-DwFj0h2u.d.mts} +2 -2
  3. package/dist/{ILLMProvider-DO5gj-e5.d.ts → ILLMProvider-DwFj0h2u.d.ts} +2 -2
  4. package/dist/MilvusProvider-WJLLZ6TW.mjs +8 -0
  5. package/dist/MongoDBProvider-QSERELZX.mjs +8 -0
  6. package/dist/MultiTablePostgresProvider-JF2HEUDZ.mjs +9 -0
  7. package/dist/PineconeProvider-HLZL7HKU.mjs +10 -0
  8. package/dist/PostgreSQLProvider-JQMCNHRO.mjs +8 -0
  9. package/dist/QdrantProvider-6MNFPEVC.mjs +8 -0
  10. package/dist/RedisProvider-ERQL6AEB.mjs +8 -0
  11. package/dist/SimpleGraphProvider-OP3HAJJM.mjs +70 -0
  12. package/dist/UniversalVectorProvider-INM3KH5F.mjs +9 -0
  13. package/dist/WeaviateProvider-VHWWICCC.mjs +8 -0
  14. package/dist/chunk-366EFBZC.mjs +165 -0
  15. package/dist/chunk-6MGVQTU4.mjs +8883 -0
  16. package/dist/chunk-B4AXIUM7.mjs +49 -0
  17. package/dist/chunk-BEPLYQBS.mjs +89 -0
  18. package/dist/chunk-BNOPQCZW.mjs +238 -0
  19. package/dist/chunk-FJ43J4FW.mjs +654 -0
  20. package/dist/chunk-GP2AJQRQ.mjs +107 -0
  21. package/dist/chunk-IMP6FUCY.mjs +30 -0
  22. package/dist/chunk-JRQWSJNF.mjs +202 -0
  23. package/dist/chunk-LYHCKUNF.mjs +112 -0
  24. package/dist/chunk-MFIWWUC7.mjs +152 -0
  25. package/dist/chunk-MWICNCB2.mjs +157 -0
  26. package/dist/chunk-N54YTFBN.mjs +76 -0
  27. package/dist/chunk-POOWU2HR.mjs +211 -0
  28. package/dist/chunk-QGDGPOZH.mjs +217 -0
  29. package/dist/chunk-QI3FTN6G.mjs +281 -0
  30. package/dist/chunk-QJIDGVG6.mjs +334 -0
  31. package/dist/chunk-W2DKVD3G.mjs +81 -0
  32. package/dist/chunk-XHSDHPKI.mjs +336 -0
  33. package/dist/handlers/index.d.mts +2 -2
  34. package/dist/handlers/index.d.ts +2 -2
  35. package/dist/handlers/index.js +191 -27
  36. package/dist/handlers/index.mjs +24 -11888
  37. package/dist/{index-BKOyhayB.d.mts → index-9h_ENWQn.d.mts} +17 -1
  38. package/dist/{index-DkOhRqEc.d.ts → index-Cb0GsT16.d.ts} +1 -1
  39. package/dist/{index-DE8qPWpI.d.mts → index-D1jN8KSF.d.mts} +1 -1
  40. package/dist/{index-8vijDPfT.d.ts → index-Xci6GfpI.d.ts} +17 -1
  41. package/dist/index.css +112 -0
  42. package/dist/index.d.mts +178 -20
  43. package/dist/index.d.ts +178 -20
  44. package/dist/index.js +602 -104
  45. package/dist/index.min.css +1 -1
  46. package/dist/index.mjs +648 -1534
  47. package/dist/server.d.mts +57 -10
  48. package/dist/server.d.ts +57 -10
  49. package/dist/server.js +199 -33
  50. package/dist/server.mjs +376 -12447
  51. package/package.json +2 -2
package/dist/server.d.mts CHANGED
@@ -1,9 +1,9 @@
1
- import { p as RagConfig, v as UniversalRagConfig, V as VectorDBConfig, w as UpsertDocument, y as VectorMatch, G as GraphDBConfig, H as GraphNode, J as Edge, K as GraphSearchResult, L as LLMConfig, f as EmbeddingConfig, I as ILLMProvider, x as VectorDBProvider, i as LLMProvider, g as EmbeddingProvider, R as RAGConfig, u as UIConfig, U as UITransformationResponse, C as ChatMessage, d as ChatOptions, E as EmbedOptions, h as IngestDocument, e as ChatResponse } from './ILLMProvider-DO5gj-e5.mjs';
2
- export { A as AuthMode, M as BarChartData, N as CarouselProduct, Q as IRetriever, j as LatencyBreakdown, S as LineChartDataPoint, X as MessageRole, Y as MetricCardData, O as ObservabilityTrace, Z as PieChartData, P as Product, k as ProjectAiSettings, l as ProjectAuthSettings, m as ProjectBrandingSettings, c as ProjectChatSettings, n as ProjectTelemetrySettings, o as ProjectWidgetSettings, q as RagMessage, r as RetrievalConfig, _ as RetrievalResult, s as RetrievedChunk, $ as RetrivoraChunkMetadata, a0 as RetrivoraIngestedDocument, a1 as ScatterPlotDataPoint, a2 as SuggestionsResponse, a3 as TableData, T as ThemeMode, t as TokenUsage, a as UseRagChatOptions, b as UseRagChatReturn, a4 as VisualizationType, W as WidgetPosition, z as WorkflowConfig, B as createDefaultProjectSettings, D as normalizeProjectSettings, F as projectSettingsToUiConfig } from './ILLMProvider-DO5gj-e5.mjs';
3
- import { o as DecisionContext, q as IntentCategory, I as IRenderRule, G as RenderDecision, p as IRendererStrategy } from './index-BKOyhayB.mjs';
4
- export { V as ArchitectureCardProps, A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, e as ChatViewportSize, C as ChatWidgetProps, a as ChatWindowProps, i as Chunk, j as ChunkOptions, c as ClientConfig, m as ConfigFetcher, b as ConfigProviderProps, n as ConfigurationException, W as DocumentChunker, D as DocumentUploadProps, E as EmbeddingFailedException, X as LicenseConfigResolver, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, M as MessageBubbleProps, Y as Pipeline, Z as PipelineStep, P as ProductCardProps, d as ProductCarouselProps, v as ProviderCredentials, w as ProviderNotFoundException, _ as ProviderPill, x as RateLimitException, R as RemoteConfig, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, $ as RenderSectionDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, a0 as Snippet, S as SourceCardProps, a1 as wrapError } from './index-BKOyhayB.mjs';
5
- import { I as IProviderValidator, a as IProviderHealthChecker, H as HealthCheckResult } from './index-DE8qPWpI.mjs';
6
- export { C as ConfigValidator, b as HandlerOptions, V as ValidationError, c as VectorPlugin, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, o as sseTextFrame } from './index-DE8qPWpI.mjs';
1
+ import { p as RagConfig, v as UniversalRagConfig, V as VectorDBConfig, w as UpsertDocument, y as VectorMatch, G as GraphDBConfig, H as GraphNode, J as Edge, K as GraphSearchResult, L as LLMConfig, f as EmbeddingConfig, I as ILLMProvider, x as VectorDBProvider, i as LLMProvider, g as EmbeddingProvider, R as RAGConfig, u as UIConfig, U as UITransformationResponse, C as ChatMessage, d as ChatOptions, E as EmbedOptions, h as IngestDocument, e as ChatResponse } from './ILLMProvider-DwFj0h2u.mjs';
2
+ export { A as AuthMode, M as BarChartData, N as CarouselProduct, Q as IRetriever, j as LatencyBreakdown, S as LineChartDataPoint, X as MessageRole, Y as MetricCardData, O as ObservabilityTrace, Z as PieChartData, P as Product, k as ProjectAiSettings, l as ProjectAuthSettings, m as ProjectBrandingSettings, c as ProjectChatSettings, n as ProjectTelemetrySettings, o as ProjectWidgetSettings, q as RagMessage, r as RetrievalConfig, _ as RetrievalResult, s as RetrievedChunk, $ as RetrivoraChunkMetadata, a0 as RetrivoraIngestedDocument, a1 as ScatterPlotDataPoint, a2 as SuggestionsResponse, a3 as TableData, T as ThemeMode, t as TokenUsage, a as UseRagChatOptions, b as UseRagChatReturn, a4 as VisualizationType, W as WidgetPosition, z as WorkflowConfig, B as createDefaultProjectSettings, D as normalizeProjectSettings, F as projectSettingsToUiConfig } from './ILLMProvider-DwFj0h2u.mjs';
3
+ import { o as DecisionContext, q as IntentCategory, I as IRenderRule, G as RenderDecision, p as IRendererStrategy } from './index-9h_ENWQn.mjs';
4
+ export { V as ArchitectureCardProps, A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, e as ChatViewportSize, C as ChatWidgetProps, a as ChatWindowProps, i as Chunk, j as ChunkOptions, c as ClientConfig, m as ConfigFetcher, b as ConfigProviderProps, n as ConfigurationException, W as DocumentChunker, D as DocumentUploadProps, E as EmbeddingFailedException, X as LicenseConfigResolver, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, M as MessageBubbleProps, Y as Pipeline, Z as PipelineStep, P as ProductCardProps, d as ProductCarouselProps, v as ProviderCredentials, w as ProviderNotFoundException, _ as ProviderPill, x as RateLimitException, R as RemoteConfig, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, $ as RenderSectionDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, a0 as Snippet, S as SourceCardProps, a1 as wrapError } from './index-9h_ENWQn.mjs';
5
+ import { I as IProviderValidator, a as IProviderHealthChecker, H as HealthCheckResult } from './index-D1jN8KSF.mjs';
6
+ export { C as ConfigValidator, b as HandlerOptions, V as ValidationError, c as VectorPlugin, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, o as sseTextFrame } from './index-D1jN8KSF.mjs';
7
7
  import 'react';
8
8
  import 'next/server';
9
9
 
@@ -1140,6 +1140,53 @@ declare class UniversalLLMAdapter implements ILLMProvider {
1140
1140
  ping(): Promise<boolean>;
1141
1141
  }
1142
1142
 
1143
+ interface CustomEmbeddingOptions {
1144
+ /** Base URL of the custom embedding server (e.g., http://localhost:8080/v1 or https://embeddings.mycompany.com) */
1145
+ baseUrl?: string;
1146
+ /** Relative endpoint path for embeddings (default: '/embeddings') */
1147
+ embedPath?: string;
1148
+ /** Endpoint path for health check (default: '/health' or root) */
1149
+ pingPath?: string;
1150
+ /** Prefix to prepend to query texts (e.g., "query: " for BGE/Nomic models) */
1151
+ queryPrefix?: string;
1152
+ /** Prefix to prepend to document texts (e.g., "passage: " or "document: ") */
1153
+ documentPrefix?: string;
1154
+ /** Template string to build custom JSON payload if non-standard (e.g. '{"inputs": {{input}}, "model": "{{model}}"}') */
1155
+ embedPayloadTemplate?: string;
1156
+ /** JSON path to extract embedding float array from response (default: 'data[0].embedding' or 'embedding') */
1157
+ embedExtractPath?: string;
1158
+ /** Custom HTTP headers */
1159
+ headers?: Record<string, string>;
1160
+ /** Timeout in milliseconds (default: 30000) */
1161
+ timeout?: number;
1162
+ }
1163
+ declare class CustomEmbeddingProvider implements ILLMProvider {
1164
+ private readonly http;
1165
+ private readonly model;
1166
+ private readonly baseUrl;
1167
+ private readonly apiKey?;
1168
+ private readonly opts;
1169
+ constructor(config: EmbeddingConfig | LLMConfig);
1170
+ /**
1171
+ * Dummy chat implementation. CustomEmbeddingProvider is dedicated to embedding generation.
1172
+ */
1173
+ chat(_messages: ChatMessage[], _context?: string, _options?: ChatOptions): Promise<string>;
1174
+ /**
1175
+ * Generate vector embedding for a single string.
1176
+ */
1177
+ embed(text: string, options?: EmbedOptions): Promise<number[]>;
1178
+ /**
1179
+ * Batch embedding generation for multiple texts.
1180
+ */
1181
+ batchEmbed(texts: string[], options?: EmbedOptions): Promise<number[][]>;
1182
+ /**
1183
+ * Ping provider endpoint for health check.
1184
+ */
1185
+ ping(): Promise<boolean>;
1186
+ private extractVector;
1187
+ private extractBatchVectors;
1188
+ }
1189
+
1143
1190
  /**
1144
1191
  * LicensedRetrivora — End-user facing SDK that only requires:
1145
1192
  * - License Key (JWT from Retrivora)
@@ -1264,7 +1311,7 @@ interface TelemetryEvent {
1264
1311
  documentName?: string;
1265
1312
  documentSize?: number;
1266
1313
  chunksGenerated?: number;
1267
- queryText?: string;
1314
+ queryLength?: number;
1268
1315
  resultCount?: number;
1269
1316
  errorCode?: string;
1270
1317
  errorMessage?: string;
@@ -1324,10 +1371,10 @@ declare class TelemetryService {
1324
1371
  durationMs: number;
1325
1372
  }): void;
1326
1373
  /**
1327
- * Record query execution event
1374
+ * Record query execution event (PII-safe)
1328
1375
  */
1329
1376
  recordQueryExecuted(data: {
1330
- queryText: string;
1377
+ queryLength: number;
1331
1378
  resultCount: number;
1332
1379
  durationMs: number;
1333
1380
  operationId?: string;
@@ -1374,4 +1421,4 @@ declare function initializeTelemetryService(projectId: string, licenseKey: strin
1374
1421
  */
1375
1422
  declare function shutdownTelemetryService(): Promise<void>;
1376
1423
 
1377
- export { AnthropicProvider, BaseVectorProvider, CarouselRendererStrategy, ChartRendererStrategy, ChatMessage, ChatOptions, ChatResponse, ChromaDBProvider, ConfigBuilder, ConfigResolver, DecisionContext, DocumentParser, Edge, EmbedOptions, EmbeddingConfig, EmbeddingProvider, EmbeddingStrategy, EmbeddingStrategyResolver, EventType, GraphNode, GraphSearchResult, GroqProvider, HealthCheckResult, ILLMProvider, IProviderHealthChecker, IProviderValidator, IRenderRule, IRendererStrategy, IngestDocument, IntentCategory, IntentClassifier, LLMConfig, LLMFactory, LLMProvider, LLM_PROFILES, type LicensePayload, LicenseVerifier, LicensedRetrivora, type LicensedRetrivoraOptions, MilvusProvider, MixedRendererStrategy, MongoDBProvider, MultiTablePostgresProvider, OllamaProvider, OpenAIProvider, PRESETS, PineconeProvider, PostgreSQLProvider, ProviderHealthCheck, ProviderRegistry, QdrantProvider, QwenProvider, RAGConfig, RagConfig, RedisProvider, RenderDecision, RendererRegistry, Rule1SpecificInfoRule, Rule2ComparisonRule, Rule3ProductDiscoveryRule, Rule4AnalyticalRule, Rule5MixedResponseRule, Rule6SmallResultSetRule, Rule7LargeTableRule, RuleEngine, type RuntimeTierConfig, TableRendererStrategy, type TelemetryEvent, TelemetryService, TextRendererStrategy, UIConfig, UITransformationResponse, UniversalLLMAdapter, UniversalRagConfig, UniversalVectorProvider, UpsertDocument, VECTOR_PROFILES, VectorDBConfig, VectorDBProvider, VectorMatch, VisualizationDecisionEngine, WeaviateProvider, createFromPreset, createRetrivora, decideVisualization, getRagConfig, getRuntimeConfig, getTelemetryService, initializeTelemetryService, injectRuntimeConfig, shutdownTelemetryService };
1424
+ export { AnthropicProvider, BaseVectorProvider, CarouselRendererStrategy, ChartRendererStrategy, ChatMessage, ChatOptions, ChatResponse, ChromaDBProvider, ConfigBuilder, ConfigResolver, type CustomEmbeddingOptions, CustomEmbeddingProvider, DecisionContext, DocumentParser, Edge, EmbedOptions, EmbeddingConfig, EmbeddingProvider, EmbeddingStrategy, EmbeddingStrategyResolver, EventType, GraphNode, GraphSearchResult, GroqProvider, HealthCheckResult, ILLMProvider, IProviderHealthChecker, IProviderValidator, IRenderRule, IRendererStrategy, IngestDocument, IntentCategory, IntentClassifier, LLMConfig, LLMFactory, LLMProvider, LLM_PROFILES, type LicensePayload, LicenseVerifier, LicensedRetrivora, type LicensedRetrivoraOptions, MilvusProvider, MixedRendererStrategy, MongoDBProvider, MultiTablePostgresProvider, OllamaProvider, OpenAIProvider, PRESETS, PineconeProvider, PostgreSQLProvider, ProviderHealthCheck, ProviderRegistry, QdrantProvider, QwenProvider, RAGConfig, RagConfig, RedisProvider, RenderDecision, RendererRegistry, Rule1SpecificInfoRule, Rule2ComparisonRule, Rule3ProductDiscoveryRule, Rule4AnalyticalRule, Rule5MixedResponseRule, Rule6SmallResultSetRule, Rule7LargeTableRule, RuleEngine, type RuntimeTierConfig, TableRendererStrategy, type TelemetryEvent, TelemetryService, TextRendererStrategy, UIConfig, UITransformationResponse, UniversalLLMAdapter, UniversalRagConfig, UniversalVectorProvider, UpsertDocument, VECTOR_PROFILES, VectorDBConfig, VectorDBProvider, VectorMatch, VisualizationDecisionEngine, WeaviateProvider, createFromPreset, createRetrivora, decideVisualization, getRagConfig, getRuntimeConfig, getTelemetryService, initializeTelemetryService, injectRuntimeConfig, shutdownTelemetryService };
package/dist/server.d.ts CHANGED
@@ -1,9 +1,9 @@
1
- import { p as RagConfig, v as UniversalRagConfig, V as VectorDBConfig, w as UpsertDocument, y as VectorMatch, G as GraphDBConfig, H as GraphNode, J as Edge, K as GraphSearchResult, L as LLMConfig, f as EmbeddingConfig, I as ILLMProvider, x as VectorDBProvider, i as LLMProvider, g as EmbeddingProvider, R as RAGConfig, u as UIConfig, U as UITransformationResponse, C as ChatMessage, d as ChatOptions, E as EmbedOptions, h as IngestDocument, e as ChatResponse } from './ILLMProvider-DO5gj-e5.js';
2
- export { A as AuthMode, M as BarChartData, N as CarouselProduct, Q as IRetriever, j as LatencyBreakdown, S as LineChartDataPoint, X as MessageRole, Y as MetricCardData, O as ObservabilityTrace, Z as PieChartData, P as Product, k as ProjectAiSettings, l as ProjectAuthSettings, m as ProjectBrandingSettings, c as ProjectChatSettings, n as ProjectTelemetrySettings, o as ProjectWidgetSettings, q as RagMessage, r as RetrievalConfig, _ as RetrievalResult, s as RetrievedChunk, $ as RetrivoraChunkMetadata, a0 as RetrivoraIngestedDocument, a1 as ScatterPlotDataPoint, a2 as SuggestionsResponse, a3 as TableData, T as ThemeMode, t as TokenUsage, a as UseRagChatOptions, b as UseRagChatReturn, a4 as VisualizationType, W as WidgetPosition, z as WorkflowConfig, B as createDefaultProjectSettings, D as normalizeProjectSettings, F as projectSettingsToUiConfig } from './ILLMProvider-DO5gj-e5.js';
3
- import { o as DecisionContext, q as IntentCategory, I as IRenderRule, G as RenderDecision, p as IRendererStrategy } from './index-8vijDPfT.js';
4
- export { V as ArchitectureCardProps, A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, e as ChatViewportSize, C as ChatWidgetProps, a as ChatWindowProps, i as Chunk, j as ChunkOptions, c as ClientConfig, m as ConfigFetcher, b as ConfigProviderProps, n as ConfigurationException, W as DocumentChunker, D as DocumentUploadProps, E as EmbeddingFailedException, X as LicenseConfigResolver, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, M as MessageBubbleProps, Y as Pipeline, Z as PipelineStep, P as ProductCardProps, d as ProductCarouselProps, v as ProviderCredentials, w as ProviderNotFoundException, _ as ProviderPill, x as RateLimitException, R as RemoteConfig, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, $ as RenderSectionDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, a0 as Snippet, S as SourceCardProps, a1 as wrapError } from './index-8vijDPfT.js';
5
- import { I as IProviderValidator, a as IProviderHealthChecker, H as HealthCheckResult } from './index-DkOhRqEc.js';
6
- export { C as ConfigValidator, b as HandlerOptions, V as ValidationError, c as VectorPlugin, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, o as sseTextFrame } from './index-DkOhRqEc.js';
1
+ import { p as RagConfig, v as UniversalRagConfig, V as VectorDBConfig, w as UpsertDocument, y as VectorMatch, G as GraphDBConfig, H as GraphNode, J as Edge, K as GraphSearchResult, L as LLMConfig, f as EmbeddingConfig, I as ILLMProvider, x as VectorDBProvider, i as LLMProvider, g as EmbeddingProvider, R as RAGConfig, u as UIConfig, U as UITransformationResponse, C as ChatMessage, d as ChatOptions, E as EmbedOptions, h as IngestDocument, e as ChatResponse } from './ILLMProvider-DwFj0h2u.js';
2
+ export { A as AuthMode, M as BarChartData, N as CarouselProduct, Q as IRetriever, j as LatencyBreakdown, S as LineChartDataPoint, X as MessageRole, Y as MetricCardData, O as ObservabilityTrace, Z as PieChartData, P as Product, k as ProjectAiSettings, l as ProjectAuthSettings, m as ProjectBrandingSettings, c as ProjectChatSettings, n as ProjectTelemetrySettings, o as ProjectWidgetSettings, q as RagMessage, r as RetrievalConfig, _ as RetrievalResult, s as RetrievedChunk, $ as RetrivoraChunkMetadata, a0 as RetrivoraIngestedDocument, a1 as ScatterPlotDataPoint, a2 as SuggestionsResponse, a3 as TableData, T as ThemeMode, t as TokenUsage, a as UseRagChatOptions, b as UseRagChatReturn, a4 as VisualizationType, W as WidgetPosition, z as WorkflowConfig, B as createDefaultProjectSettings, D as normalizeProjectSettings, F as projectSettingsToUiConfig } from './ILLMProvider-DwFj0h2u.js';
3
+ import { o as DecisionContext, q as IntentCategory, I as IRenderRule, G as RenderDecision, p as IRendererStrategy } from './index-Xci6GfpI.js';
4
+ export { V as ArchitectureCardProps, A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, e as ChatViewportSize, C as ChatWidgetProps, a as ChatWindowProps, i as Chunk, j as ChunkOptions, c as ClientConfig, m as ConfigFetcher, b as ConfigProviderProps, n as ConfigurationException, W as DocumentChunker, D as DocumentUploadProps, E as EmbeddingFailedException, X as LicenseConfigResolver, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, M as MessageBubbleProps, Y as Pipeline, Z as PipelineStep, P as ProductCardProps, d as ProductCarouselProps, v as ProviderCredentials, w as ProviderNotFoundException, _ as ProviderPill, x as RateLimitException, R as RemoteConfig, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, $ as RenderSectionDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, a0 as Snippet, S as SourceCardProps, a1 as wrapError } from './index-Xci6GfpI.js';
5
+ import { I as IProviderValidator, a as IProviderHealthChecker, H as HealthCheckResult } from './index-Cb0GsT16.js';
6
+ export { C as ConfigValidator, b as HandlerOptions, V as ValidationError, c as VectorPlugin, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, o as sseTextFrame } from './index-Cb0GsT16.js';
7
7
  import 'react';
8
8
  import 'next/server';
9
9
 
@@ -1140,6 +1140,53 @@ declare class UniversalLLMAdapter implements ILLMProvider {
1140
1140
  ping(): Promise<boolean>;
1141
1141
  }
1142
1142
 
1143
+ interface CustomEmbeddingOptions {
1144
+ /** Base URL of the custom embedding server (e.g., http://localhost:8080/v1 or https://embeddings.mycompany.com) */
1145
+ baseUrl?: string;
1146
+ /** Relative endpoint path for embeddings (default: '/embeddings') */
1147
+ embedPath?: string;
1148
+ /** Endpoint path for health check (default: '/health' or root) */
1149
+ pingPath?: string;
1150
+ /** Prefix to prepend to query texts (e.g., "query: " for BGE/Nomic models) */
1151
+ queryPrefix?: string;
1152
+ /** Prefix to prepend to document texts (e.g., "passage: " or "document: ") */
1153
+ documentPrefix?: string;
1154
+ /** Template string to build custom JSON payload if non-standard (e.g. '{"inputs": {{input}}, "model": "{{model}}"}') */
1155
+ embedPayloadTemplate?: string;
1156
+ /** JSON path to extract embedding float array from response (default: 'data[0].embedding' or 'embedding') */
1157
+ embedExtractPath?: string;
1158
+ /** Custom HTTP headers */
1159
+ headers?: Record<string, string>;
1160
+ /** Timeout in milliseconds (default: 30000) */
1161
+ timeout?: number;
1162
+ }
1163
+ declare class CustomEmbeddingProvider implements ILLMProvider {
1164
+ private readonly http;
1165
+ private readonly model;
1166
+ private readonly baseUrl;
1167
+ private readonly apiKey?;
1168
+ private readonly opts;
1169
+ constructor(config: EmbeddingConfig | LLMConfig);
1170
+ /**
1171
+ * Dummy chat implementation. CustomEmbeddingProvider is dedicated to embedding generation.
1172
+ */
1173
+ chat(_messages: ChatMessage[], _context?: string, _options?: ChatOptions): Promise<string>;
1174
+ /**
1175
+ * Generate vector embedding for a single string.
1176
+ */
1177
+ embed(text: string, options?: EmbedOptions): Promise<number[]>;
1178
+ /**
1179
+ * Batch embedding generation for multiple texts.
1180
+ */
1181
+ batchEmbed(texts: string[], options?: EmbedOptions): Promise<number[][]>;
1182
+ /**
1183
+ * Ping provider endpoint for health check.
1184
+ */
1185
+ ping(): Promise<boolean>;
1186
+ private extractVector;
1187
+ private extractBatchVectors;
1188
+ }
1189
+
1143
1190
  /**
1144
1191
  * LicensedRetrivora — End-user facing SDK that only requires:
1145
1192
  * - License Key (JWT from Retrivora)
@@ -1264,7 +1311,7 @@ interface TelemetryEvent {
1264
1311
  documentName?: string;
1265
1312
  documentSize?: number;
1266
1313
  chunksGenerated?: number;
1267
- queryText?: string;
1314
+ queryLength?: number;
1268
1315
  resultCount?: number;
1269
1316
  errorCode?: string;
1270
1317
  errorMessage?: string;
@@ -1324,10 +1371,10 @@ declare class TelemetryService {
1324
1371
  durationMs: number;
1325
1372
  }): void;
1326
1373
  /**
1327
- * Record query execution event
1374
+ * Record query execution event (PII-safe)
1328
1375
  */
1329
1376
  recordQueryExecuted(data: {
1330
- queryText: string;
1377
+ queryLength: number;
1331
1378
  resultCount: number;
1332
1379
  durationMs: number;
1333
1380
  operationId?: string;
@@ -1374,4 +1421,4 @@ declare function initializeTelemetryService(projectId: string, licenseKey: strin
1374
1421
  */
1375
1422
  declare function shutdownTelemetryService(): Promise<void>;
1376
1423
 
1377
- export { AnthropicProvider, BaseVectorProvider, CarouselRendererStrategy, ChartRendererStrategy, ChatMessage, ChatOptions, ChatResponse, ChromaDBProvider, ConfigBuilder, ConfigResolver, DecisionContext, DocumentParser, Edge, EmbedOptions, EmbeddingConfig, EmbeddingProvider, EmbeddingStrategy, EmbeddingStrategyResolver, EventType, GraphNode, GraphSearchResult, GroqProvider, HealthCheckResult, ILLMProvider, IProviderHealthChecker, IProviderValidator, IRenderRule, IRendererStrategy, IngestDocument, IntentCategory, IntentClassifier, LLMConfig, LLMFactory, LLMProvider, LLM_PROFILES, type LicensePayload, LicenseVerifier, LicensedRetrivora, type LicensedRetrivoraOptions, MilvusProvider, MixedRendererStrategy, MongoDBProvider, MultiTablePostgresProvider, OllamaProvider, OpenAIProvider, PRESETS, PineconeProvider, PostgreSQLProvider, ProviderHealthCheck, ProviderRegistry, QdrantProvider, QwenProvider, RAGConfig, RagConfig, RedisProvider, RenderDecision, RendererRegistry, Rule1SpecificInfoRule, Rule2ComparisonRule, Rule3ProductDiscoveryRule, Rule4AnalyticalRule, Rule5MixedResponseRule, Rule6SmallResultSetRule, Rule7LargeTableRule, RuleEngine, type RuntimeTierConfig, TableRendererStrategy, type TelemetryEvent, TelemetryService, TextRendererStrategy, UIConfig, UITransformationResponse, UniversalLLMAdapter, UniversalRagConfig, UniversalVectorProvider, UpsertDocument, VECTOR_PROFILES, VectorDBConfig, VectorDBProvider, VectorMatch, VisualizationDecisionEngine, WeaviateProvider, createFromPreset, createRetrivora, decideVisualization, getRagConfig, getRuntimeConfig, getTelemetryService, initializeTelemetryService, injectRuntimeConfig, shutdownTelemetryService };
1424
+ export { AnthropicProvider, BaseVectorProvider, CarouselRendererStrategy, ChartRendererStrategy, ChatMessage, ChatOptions, ChatResponse, ChromaDBProvider, ConfigBuilder, ConfigResolver, type CustomEmbeddingOptions, CustomEmbeddingProvider, DecisionContext, DocumentParser, Edge, EmbedOptions, EmbeddingConfig, EmbeddingProvider, EmbeddingStrategy, EmbeddingStrategyResolver, EventType, GraphNode, GraphSearchResult, GroqProvider, HealthCheckResult, ILLMProvider, IProviderHealthChecker, IProviderValidator, IRenderRule, IRendererStrategy, IngestDocument, IntentCategory, IntentClassifier, LLMConfig, LLMFactory, LLMProvider, LLM_PROFILES, type LicensePayload, LicenseVerifier, LicensedRetrivora, type LicensedRetrivoraOptions, MilvusProvider, MixedRendererStrategy, MongoDBProvider, MultiTablePostgresProvider, OllamaProvider, OpenAIProvider, PRESETS, PineconeProvider, PostgreSQLProvider, ProviderHealthCheck, ProviderRegistry, QdrantProvider, QwenProvider, RAGConfig, RagConfig, RedisProvider, RenderDecision, RendererRegistry, Rule1SpecificInfoRule, Rule2ComparisonRule, Rule3ProductDiscoveryRule, Rule4AnalyticalRule, Rule5MixedResponseRule, Rule6SmallResultSetRule, Rule7LargeTableRule, RuleEngine, type RuntimeTierConfig, TableRendererStrategy, type TelemetryEvent, TelemetryService, TextRendererStrategy, UIConfig, UITransformationResponse, UniversalLLMAdapter, UniversalRagConfig, UniversalVectorProvider, UpsertDocument, VECTOR_PROFILES, VectorDBConfig, VectorDBProvider, VectorMatch, VisualizationDecisionEngine, WeaviateProvider, createFromPreset, createRetrivora, decideVisualization, getRagConfig, getRuntimeConfig, getTelemetryService, initializeTelemetryService, injectRuntimeConfig, shutdownTelemetryService };