@retrivora-ai/rag-engine 2.6.0 → 2.6.3

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 (58) hide show
  1. package/README.md +8 -6
  2. package/dist/ChromaDBProvider-NDA2IBOH.mjs +8 -0
  3. package/dist/{ILLMProvider-DUCL1r75.d.mts → ILLMProvider-CzXcTA6d.d.mts} +21 -3
  4. package/dist/{ILLMProvider-DUCL1r75.d.ts → ILLMProvider-CzXcTA6d.d.ts} +21 -3
  5. package/dist/MilvusProvider-H6GGL5FQ.mjs +8 -0
  6. package/dist/MongoDBProvider-KC3GF3FH.mjs +8 -0
  7. package/dist/MultiTablePostgresProvider-6LJBFZL2.mjs +9 -0
  8. package/dist/PineconeProvider-22RF2QPF.mjs +10 -0
  9. package/dist/PineconeProvider-HBBIXLT3.mjs +10 -0
  10. package/dist/PostgreSQLProvider-VWFL4OIP.mjs +8 -0
  11. package/dist/QdrantProvider-UU7RGXBI.mjs +8 -0
  12. package/dist/RedisProvider-MIIPSAAE.mjs +8 -0
  13. package/dist/SimpleGraphProvider-HJIS4S7Y.mjs +70 -0
  14. package/dist/UniversalVectorProvider-NO3L255G.mjs +9 -0
  15. package/dist/WeaviateProvider-YRZDZFAC.mjs +8 -0
  16. package/dist/chunk-23PFNEBF.mjs +107 -0
  17. package/dist/chunk-3E4GZGDX.mjs +10851 -0
  18. package/dist/chunk-3SQ4DODU.mjs +238 -0
  19. package/dist/chunk-AHMMUZ4W.mjs +152 -0
  20. package/dist/chunk-ASBNNEVI.mjs +81 -0
  21. package/dist/chunk-AT4TFUQN.mjs +219 -0
  22. package/dist/chunk-BEPLYQBS.mjs +89 -0
  23. package/dist/chunk-G7MJRFCO.mjs +340 -0
  24. package/dist/chunk-IHWKVAUR.mjs +112 -0
  25. package/dist/chunk-IMP6FUCY.mjs +30 -0
  26. package/dist/chunk-LFNV6DEL.mjs +281 -0
  27. package/dist/chunk-MAXMVO7B.mjs +211 -0
  28. package/dist/chunk-MGJ6V2IT.mjs +203 -0
  29. package/dist/chunk-N3TI27LG.mjs +334 -0
  30. package/dist/chunk-NWYE4Q7B.mjs +334 -0
  31. package/dist/chunk-OJMAT4EG.mjs +219 -0
  32. package/dist/chunk-QKZM3RSJ.mjs +10851 -0
  33. package/dist/chunk-QUY3E6HJ.mjs +168 -0
  34. package/dist/chunk-SG6XYLQE.mjs +53 -0
  35. package/dist/chunk-UT6SZZEC.mjs +69 -0
  36. package/dist/chunk-VW3U4MMX.mjs +157 -0
  37. package/dist/chunk-WOJCOTXI.mjs +281 -0
  38. package/dist/chunk-XP6NJMX4.mjs +168 -0
  39. package/dist/chunk-XYBKDJDW.mjs +696 -0
  40. package/dist/handlers/index.d.mts +2 -2
  41. package/dist/handlers/index.d.ts +2 -2
  42. package/dist/handlers/index.js +9736 -9354
  43. package/dist/handlers/index.mjs +24 -13686
  44. package/dist/{index-CsBcqng1.d.ts → index-BBbt5A2y.d.mts} +61 -47
  45. package/dist/{index-BVSHblli.d.mts → index-BST9Gzsv.d.mts} +8 -7
  46. package/dist/{index-D6Oq2zyc.d.mts → index-BZ_rR6V8.d.ts} +61 -47
  47. package/dist/{index-DGW0NNmR.d.ts → index-qLvtMUr-.d.ts} +8 -7
  48. package/dist/index.css +23 -0
  49. package/dist/index.d.mts +4 -4
  50. package/dist/index.d.ts +4 -4
  51. package/dist/index.js +278 -190
  52. package/dist/index.min.css +1 -1
  53. package/dist/index.mjs +218 -1558
  54. package/dist/server.d.mts +58 -12
  55. package/dist/server.d.ts +58 -12
  56. package/dist/server.js +968 -577
  57. package/dist/server.mjs +395 -14244
  58. package/package.json +1 -1
@@ -1,5 +1,30 @@
1
1
  import { NextRequest } from 'next/server';
2
- import { p as RagConfig, I as ILLMProvider, C as ChatMessage, e as ChatResponse, h as IngestDocument } from './ILLMProvider-DUCL1r75.js';
2
+ import { b as RagConfig, I as ILLMProvider, C as ChatMessage, d as ChatResponse, c as IngestDocument } from './ILLMProvider-CzXcTA6d.mjs';
3
+
4
+ /**
5
+ * Shared options accepted by every handler factory.
6
+ *
7
+ * Pass `onAuthorize` to plug in per-request auth rules; the callback is
8
+ * called before rate-limiting, license enforcement, or any business logic
9
+ * runs. Return `true` or the resolved promise `true` to allow, `false`
10
+ * to get a 401, or return a `Response` to fully control the denial (for
11
+ * example redirecting an OAuth-style flow to a login page).
12
+ */
13
+ interface HandlerOptions {
14
+ /** Optional synchronous or asynchronous authorization gate. */
15
+ onAuthorize?: (req: NextRequest) => boolean | Response | Promise<boolean | Response>;
16
+ /**
17
+ * Optional scope resolver for multi-tenant deployments.
18
+ *
19
+ * Returns an allow-list of project ids that the caller is authorized to
20
+ * access on the `sessions`, `history`, and `feedback` endpoints. When
21
+ * the callback returns a non-empty array, server-side filtering is
22
+ * applied to every `listSessions`, `getHistory`, `clearHistory`,
23
+ * `listFeedback`, and `getFeedback` call so the caller can never leak
24
+ * another tenant's data even when client-side filters are tampered with.
25
+ */
26
+ onResolveScope?: (req: NextRequest) => string[] | undefined | Promise<string[] | undefined>;
27
+ }
3
28
 
4
29
  interface ValidationError {
5
30
  field: string;
@@ -66,7 +91,9 @@ declare class VectorPlugin {
66
91
  private config;
67
92
  private pipeline;
68
93
  private validationPromise;
69
- constructor(hostConfig?: Partial<RagConfig>);
94
+ constructor(hostConfig?: Partial<RagConfig>, options?: {
95
+ skipLicenseCheck?: boolean;
96
+ });
70
97
  /**
71
98
  * Get the current resolved configuration.
72
99
  */
@@ -111,45 +138,6 @@ declare class VectorPlugin {
111
138
  getSuggestions(query: string, namespace?: string): Promise<string[]>;
112
139
  }
113
140
 
114
- /**
115
- * Shared options accepted by every handler factory.
116
- *
117
- * Pass `onAuthorize` to plug in per-request auth rules; the callback is
118
- * called before rate-limiting, license enforcement, or any business logic
119
- * runs. Return `true` or the resolved promise `true` to allow, `false`
120
- * to get a 401, or return a `Response` to fully control the denial (for
121
- * example redirecting an OAuth-style flow to a login page).
122
- */
123
- interface HandlerOptions {
124
- /** Optional synchronous or asynchronous authorization gate. */
125
- onAuthorize?: (req: NextRequest) => boolean | Response | Promise<boolean | Response>;
126
- /**
127
- * Optional scope resolver for multi-tenant deployments.
128
- *
129
- * Returns an allow-list of project ids that the caller is authorized to
130
- * access on the `sessions`, `history`, and `feedback` endpoints. When
131
- * the callback returns a non-empty array, server-side filtering is
132
- * applied to every `listSessions`, `getHistory`, `clearHistory`,
133
- * `listFeedback`, and `getFeedback` call so the caller can never leak
134
- * another tenant's data even when client-side filters are tampered with.
135
- */
136
- onResolveScope?: (req: NextRequest) => string[] | undefined | Promise<string[] | undefined>;
137
- }
138
- /**
139
- * Encode a payload as a Server-Sent Events frame.
140
- * data: <json>\n\n
141
- */
142
- declare function sseFrame(payload: unknown): string;
143
- /** Encode a plain text chunk as an SSE frame. */
144
- declare function sseTextFrame(text: string): string;
145
- /** Encode the retrieval metadata with UI transformation as an SSE frame. */
146
- declare function sseMetaFrame(meta: unknown): string;
147
- /** Encode the UI transformation result as an SSE frame. */
148
- declare function sseUIFrame(uiTransformation: unknown): string;
149
- /** Encode the observability trace as an SSE frame. */
150
- declare function sseObservabilityFrame(trace: unknown): string;
151
- /** Encode a stream error as an SSE frame. */
152
- declare function sseErrorFrame(message: string): string;
153
141
  /**
154
142
  * Build a Next.js App Router POST handler for **synchronous** RAG chat.
155
143
  *
@@ -176,6 +164,7 @@ declare function sseErrorFrame(message: string): string;
176
164
  * export of a Next.js route file.
177
165
  */
178
166
  declare function createChatHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
167
+
179
168
  /**
180
169
  * Build a Next.js App Router POST handler for **streaming** RAG chat via SSE.
181
170
  *
@@ -184,15 +173,15 @@ declare function createChatHandler(configOrPlugin?: Partial<RagConfig> | VectorP
184
173
  * Event frame. The stream contains frames for `text`, `thinking`,
185
174
  * `metadata`, `ui_transformation`, `observability`, and a terminal `done`.
186
175
  *
187
- * Multipart upload short-circuit: When the request `Content-Type` is
188
- * `multipart/form-data` the request is transparently delegated to
189
- * `createUploadHandler` (which also runs its own `enforceLicense()` gate).
176
+ * NOTE: This handler expects a JSON body. File uploads (`multipart/form-data`)
177
+ * must go to `createUploadHandler` (or `createRagHandler`, which sniffs the
178
+ * content type) — sending form-data here returns `400 INVALID_JSON`.
190
179
  *
191
180
  * Pipeline (in execution order):
192
181
  * 1. `options.onAuthorize` — custom authorization gate (optional)
193
182
  * 2. In-memory IP rate limiter (30 req / 60 s sliding window)
194
- * 3. JSON body parse (or form-data upload delegation)
195
- * 4. `enforceLicense()` RSA signature validation — 403 if missing / terminated
183
+ * 3. JSON body parse
184
+ * 4. `enforceLicense()` server-backed validation — 401/403 if missing / terminated
196
185
  * 5. Input sanitization + length / toxicity / PII / prompt-injection heuristics
197
186
  * 6. User-message persistence via `DatabaseStorage`
198
187
  * 7. Streaming RAG retrieval via `plugin.chat({ stream: true })`
@@ -203,6 +192,7 @@ declare function createChatHandler(configOrPlugin?: Partial<RagConfig> | VectorP
203
192
  * @returns Async `POST(req, ctx)` function for `app/.../route.ts`.
204
193
  */
205
194
  declare function createStreamHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
195
+
206
196
  /**
207
197
  * Build a POST handler that ingests raw pre-parsed documents into the vector DB.
208
198
  *
@@ -219,6 +209,7 @@ declare function createStreamHandler(configOrPlugin?: Partial<RagConfig> | Vecto
219
209
  * @returns Async POST handler.
220
210
  */
221
211
  declare function createIngestHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
212
+
222
213
  /**
223
214
  * Build a GET handler that returns health / readiness status.
224
215
  *
@@ -244,6 +235,7 @@ declare function createIngestHandler(configOrPlugin?: Partial<RagConfig> | Vecto
244
235
  * @returns Async GET handler.
245
236
  */
246
237
  declare function createHealthHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req?: any, context?: any) => Promise<any>;
238
+
247
239
  /**
248
240
  * Build a POST handler for the SDK-facing `/v1/license/validate` endpoint.
249
241
  *
@@ -260,6 +252,7 @@ declare function createHealthHandler(configOrPlugin?: Partial<RagConfig> | Vecto
260
252
  * @returns Async POST handler returning `LicenseValidationResponse` JSON.
261
253
  */
262
254
  declare function createLicenseHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
255
+
263
256
  /**
264
257
  * Build a POST handler that accepts `multipart/form-data` file uploads.
265
258
  *
@@ -278,6 +271,7 @@ declare function createLicenseHandler(configOrPlugin?: Partial<RagConfig> | Vect
278
271
  * @returns Async POST handler.
279
272
  */
280
273
  declare function createUploadHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
274
+
281
275
  /**
282
276
  * Build a GET/POST handler for auto-suggestions (used by ChatWidget prompt chips).
283
277
  *
@@ -296,6 +290,7 @@ declare function createUploadHandler(configOrPlugin?: Partial<RagConfig> | Vecto
296
290
  * @returns Async handler accepting both GET and POST methods.
297
291
  */
298
292
  declare function createSuggestionsHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
293
+
299
294
  /**
300
295
  * Build a handler for chat-history listing and clearing.
301
296
  *
@@ -312,6 +307,7 @@ declare function createSuggestionsHandler(configOrPlugin?: Partial<RagConfig> |
312
307
  * @returns Async handler accepting GET (list) or POST (clear) methods.
313
308
  */
314
309
  declare function createHistoryHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
310
+
315
311
  /**
316
312
  * Build a POST handler for collecting thumbs-up / thumbs-down user feedback.
317
313
  *
@@ -326,6 +322,7 @@ declare function createHistoryHandler(configOrPlugin?: Partial<RagConfig> | Vect
326
322
  * @returns Async POST handler.
327
323
  */
328
324
  declare function createFeedbackHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
325
+
329
326
  /**
330
327
  * Build a GET handler that lists the set of chat sessions.
331
328
  *
@@ -340,6 +337,7 @@ declare function createFeedbackHandler(configOrPlugin?: Partial<RagConfig> | Vec
340
337
  * @returns Async GET handler returning a session listing.
341
338
  */
342
339
  declare function createSessionsHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req?: any, context?: any) => Promise<any>;
340
+
343
341
  /**
344
342
  * Build a Next.js catch-all route that dispatches to every sub-handler by path.
345
343
  *
@@ -377,4 +375,20 @@ declare function createRagHandler(configOrPlugin?: Partial<RagConfig> | VectorPl
377
375
  POST: (req: any, context?: any) => Promise<any>;
378
376
  };
379
377
 
380
- export { ConfigValidator as C, type HealthCheckResult as H, type IProviderValidator as I, type ValidationError as V, type IProviderHealthChecker as a, type HandlerOptions as b, VectorPlugin as c, createChatHandler as d, createFeedbackHandler as e, createHealthHandler as f, createHistoryHandler as g, createIngestHandler as h, createRagHandler as i, createSessionsHandler as j, createStreamHandler as k, createUploadHandler as l, sseFrame as m, sseMetaFrame as n, sseTextFrame as o, createLicenseHandler as p, createSuggestionsHandler as q, sseObservabilityFrame as r, sseErrorFrame as s, sseUIFrame as t };
378
+ /**
379
+ * Encode a payload as a Server-Sent Events frame.
380
+ * data: <json>\n\n
381
+ */
382
+ declare function sseFrame(payload: unknown): string;
383
+ /** Encode a plain text chunk as an SSE frame. */
384
+ declare function sseTextFrame(text: string): string;
385
+ /** Encode the retrieval metadata with UI transformation as an SSE frame. */
386
+ declare function sseMetaFrame(meta: unknown): string;
387
+ /** Encode the UI transformation result as an SSE frame. */
388
+ declare function sseUIFrame(uiTransformation: unknown): string;
389
+ /** Encode the observability trace as an SSE frame. */
390
+ declare function sseObservabilityFrame(trace: unknown): string;
391
+ /** Encode a stream error as an SSE frame. */
392
+ declare function sseErrorFrame(message: string): string;
393
+
394
+ export { ConfigValidator as C, type HealthCheckResult as H, type IProviderValidator as I, type ValidationError as V, type IProviderHealthChecker as a, type HandlerOptions as b, VectorPlugin as c, createChatHandler as d, createFeedbackHandler as e, createHealthHandler as f, createHistoryHandler as g, createIngestHandler as h, createLicenseHandler as i, createRagHandler as j, createSessionsHandler as k, createStreamHandler as l, createSuggestionsHandler as m, createUploadHandler as n, sseFrame as o, sseMetaFrame as p, sseObservabilityFrame as q, sseTextFrame as r, sseErrorFrame as s, sseUIFrame as t };
@@ -1,5 +1,5 @@
1
1
  import { CSSProperties, MouseEvent, ReactNode, ElementType } from 'react';
2
- import { W as WidgetPosition, P as Product, u as UIConfig, c as ProjectChatSettings, q as RagMessage, y as VectorMatch, p as RagConfig, I as ILLMProvider, h as IngestDocument, C as ChatMessage, e as ChatResponse, _ as RetrievalResult, v as UniversalRagConfig, U as UITransformationResponse, L as LLMConfig, f as EmbeddingConfig, V as VectorDBConfig } from './ILLMProvider-DUCL1r75.mjs';
2
+ import { W as WidgetPosition, P as Product, U as UIConfig, a as ProjectChatSettings, R as RagMessage, V as VectorMatch, b as RagConfig, I as ILLMProvider, c as IngestDocument, C as ChatMessage, d as ChatResponse, e as RetrievalResult, f as UniversalRagConfig, g as UITransformationResponse, L as LLMConfig, E as EmbeddingConfig, h as VectorDBConfig } from './ILLMProvider-CzXcTA6d.mjs';
3
3
 
4
4
  interface ArchitectureCardProps {
5
5
  icon: ReactNode;
@@ -695,8 +695,9 @@ interface LicenseValidationResponse {
695
695
  * 1. Resolve the license key (prop → header → env)
696
696
  * 2. Return any fresh (< 5 min old) successful cached result
697
697
  * 3. POST to `{retrivoraApiBase}/v1/license/validate` for server-side DB-backed status
698
- * 4. On network or HTTP error, fall back to zero-latency local RSA signature
699
- * verification via `LicenseVerifier.verify()`.
698
+ * 4. On network or HTTP error, fall back to `LicenseVerifier.verifyAsync()`
699
+ * (server re-validation with local fail-open only for missing local SDK
700
+ * routes / explicitly allowed fallback).
700
701
  *
701
702
  * Caching policy:
702
703
  * - ONLY successful (valid + ACTIVE + !forceUpgrade) responses are cached
@@ -730,11 +731,11 @@ declare class LicenseValidator {
730
731
  * Primary validation entry-point for UI / hook consumers.
731
732
  *
732
733
  * Resolves the license key, consults the local success cache, performs a
733
- * server POST for authoritative status, and falls back to local RSA
734
- * signature verification if the server can't be reached.
734
+ * server POST for authoritative status, and falls back to `LicenseVerifier.verifyAsync()`
735
+ * if the server can't be reached.
735
736
  *
736
737
  * @throws LicenseValidationError - When no key is provided OR both the
737
- * server call AND the local-RSA fallback report an invalid/expired key.
738
+ * server call AND the fallback report an invalid/expired key.
738
739
  * @throws SDKVersionUnsupportedError - When server reports forceUpgrade=true.
739
740
  * @returns A `LicenseValidationResponse` that the UI can use to enable or
740
741
  * lock the chat widget.
@@ -881,4 +882,4 @@ declare class LicenseValidationError extends RetrivoraError {
881
882
  */
882
883
  declare function wrapError(err: unknown, defaultCode: RetrivoraErrorCode, defaultMessage?: string): RetrivoraError;
883
884
 
884
- export { type RenderSectionDecision as $, AuthenticationException as A, type BatchOptions as B, type ChatWidgetProps as C, type DocumentUploadProps as D, EmbeddingFailedException as E, type RemoteVectorConfig as F, type RenderDecision as G, type RenderType as H, type IRenderRule as I, RetrievalException as J, Retrivora as K, type LicenseTierConfig as L, type MessageBubbleProps as M, RetrivoraError as N, type RetrivoraErrorCode as O, type ProductCardProps as P, SDKVersionUnsupportedError as Q, type RemoteConfig as R, type SourceCardProps as S, SDK_VERSION as T, isTransientError as U, type ArchitectureCardProps as V, DocumentChunker as W, LicenseConfigResolver as X, Pipeline as Y, type PipelineStep as Z, type ProviderPill as _, type ChatWindowProps as a, type Snippet as a0, wrapError as a1, type ConfigProviderProps as b, type ClientConfig as c, type ProductCarouselProps as d, type ChatViewportSize as e, BatchProcessor as f, type BatchResult as g, type ChartType as h, type Chunk as i, type ChunkOptions as j, CircuitBreaker as k, type CircuitBreakerOptions as l, ConfigFetcher as m, ConfigurationException as n, type DecisionContext as o, type IRendererStrategy as p, type IntentCategory as q, LicenseValidationError as r, type LicenseValidationRequest as s, type LicenseValidationResponse as t, LicenseValidator as u, type ProviderCredentials as v, ProviderNotFoundException as w, RateLimitException as x, type RemoteEmbeddingConfig as y, type RemoteLLMConfig as z };
885
+ export { type RenderSectionDecision as $, AuthenticationException as A, type BatchOptions as B, type ChatWidgetProps as C, type DocumentUploadProps as D, EmbeddingFailedException as E, type RemoteVectorConfig as F, type RenderDecision as G, type RenderType as H, type IRenderRule as I, RetrievalException as J, Retrivora as K, type LicenseTierConfig as L, type MessageBubbleProps as M, RetrivoraError as N, type RetrivoraErrorCode as O, type ProductCardProps as P, SDKVersionUnsupportedError as Q, type RemoteConfig as R, type SourceCardProps as S, SDK_VERSION as T, isTransientError as U, Pipeline as V, type ArchitectureCardProps as W, DocumentChunker as X, LicenseConfigResolver as Y, type PipelineStep as Z, type ProviderPill as _, type ChatWindowProps as a, type Snippet as a0, wrapError as a1, type ConfigProviderProps as b, type ClientConfig as c, type ProductCarouselProps as d, type ChatViewportSize as e, BatchProcessor as f, type BatchResult as g, type ChartType as h, type Chunk as i, type ChunkOptions as j, CircuitBreaker as k, type CircuitBreakerOptions as l, ConfigFetcher as m, ConfigurationException as n, type DecisionContext as o, type IRendererStrategy as p, type IntentCategory as q, LicenseValidationError as r, type LicenseValidationRequest as s, type LicenseValidationResponse as t, LicenseValidator as u, type ProviderCredentials as v, ProviderNotFoundException as w, RateLimitException as x, type RemoteEmbeddingConfig as y, type RemoteLLMConfig as z };
@@ -1,5 +1,30 @@
1
1
  import { NextRequest } from 'next/server';
2
- import { p as RagConfig, I as ILLMProvider, C as ChatMessage, e as ChatResponse, h as IngestDocument } from './ILLMProvider-DUCL1r75.mjs';
2
+ import { b as RagConfig, I as ILLMProvider, C as ChatMessage, d as ChatResponse, c as IngestDocument } from './ILLMProvider-CzXcTA6d.js';
3
+
4
+ /**
5
+ * Shared options accepted by every handler factory.
6
+ *
7
+ * Pass `onAuthorize` to plug in per-request auth rules; the callback is
8
+ * called before rate-limiting, license enforcement, or any business logic
9
+ * runs. Return `true` or the resolved promise `true` to allow, `false`
10
+ * to get a 401, or return a `Response` to fully control the denial (for
11
+ * example redirecting an OAuth-style flow to a login page).
12
+ */
13
+ interface HandlerOptions {
14
+ /** Optional synchronous or asynchronous authorization gate. */
15
+ onAuthorize?: (req: NextRequest) => boolean | Response | Promise<boolean | Response>;
16
+ /**
17
+ * Optional scope resolver for multi-tenant deployments.
18
+ *
19
+ * Returns an allow-list of project ids that the caller is authorized to
20
+ * access on the `sessions`, `history`, and `feedback` endpoints. When
21
+ * the callback returns a non-empty array, server-side filtering is
22
+ * applied to every `listSessions`, `getHistory`, `clearHistory`,
23
+ * `listFeedback`, and `getFeedback` call so the caller can never leak
24
+ * another tenant's data even when client-side filters are tampered with.
25
+ */
26
+ onResolveScope?: (req: NextRequest) => string[] | undefined | Promise<string[] | undefined>;
27
+ }
3
28
 
4
29
  interface ValidationError {
5
30
  field: string;
@@ -66,7 +91,9 @@ declare class VectorPlugin {
66
91
  private config;
67
92
  private pipeline;
68
93
  private validationPromise;
69
- constructor(hostConfig?: Partial<RagConfig>);
94
+ constructor(hostConfig?: Partial<RagConfig>, options?: {
95
+ skipLicenseCheck?: boolean;
96
+ });
70
97
  /**
71
98
  * Get the current resolved configuration.
72
99
  */
@@ -111,45 +138,6 @@ declare class VectorPlugin {
111
138
  getSuggestions(query: string, namespace?: string): Promise<string[]>;
112
139
  }
113
140
 
114
- /**
115
- * Shared options accepted by every handler factory.
116
- *
117
- * Pass `onAuthorize` to plug in per-request auth rules; the callback is
118
- * called before rate-limiting, license enforcement, or any business logic
119
- * runs. Return `true` or the resolved promise `true` to allow, `false`
120
- * to get a 401, or return a `Response` to fully control the denial (for
121
- * example redirecting an OAuth-style flow to a login page).
122
- */
123
- interface HandlerOptions {
124
- /** Optional synchronous or asynchronous authorization gate. */
125
- onAuthorize?: (req: NextRequest) => boolean | Response | Promise<boolean | Response>;
126
- /**
127
- * Optional scope resolver for multi-tenant deployments.
128
- *
129
- * Returns an allow-list of project ids that the caller is authorized to
130
- * access on the `sessions`, `history`, and `feedback` endpoints. When
131
- * the callback returns a non-empty array, server-side filtering is
132
- * applied to every `listSessions`, `getHistory`, `clearHistory`,
133
- * `listFeedback`, and `getFeedback` call so the caller can never leak
134
- * another tenant's data even when client-side filters are tampered with.
135
- */
136
- onResolveScope?: (req: NextRequest) => string[] | undefined | Promise<string[] | undefined>;
137
- }
138
- /**
139
- * Encode a payload as a Server-Sent Events frame.
140
- * data: <json>\n\n
141
- */
142
- declare function sseFrame(payload: unknown): string;
143
- /** Encode a plain text chunk as an SSE frame. */
144
- declare function sseTextFrame(text: string): string;
145
- /** Encode the retrieval metadata with UI transformation as an SSE frame. */
146
- declare function sseMetaFrame(meta: unknown): string;
147
- /** Encode the UI transformation result as an SSE frame. */
148
- declare function sseUIFrame(uiTransformation: unknown): string;
149
- /** Encode the observability trace as an SSE frame. */
150
- declare function sseObservabilityFrame(trace: unknown): string;
151
- /** Encode a stream error as an SSE frame. */
152
- declare function sseErrorFrame(message: string): string;
153
141
  /**
154
142
  * Build a Next.js App Router POST handler for **synchronous** RAG chat.
155
143
  *
@@ -176,6 +164,7 @@ declare function sseErrorFrame(message: string): string;
176
164
  * export of a Next.js route file.
177
165
  */
178
166
  declare function createChatHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
167
+
179
168
  /**
180
169
  * Build a Next.js App Router POST handler for **streaming** RAG chat via SSE.
181
170
  *
@@ -184,15 +173,15 @@ declare function createChatHandler(configOrPlugin?: Partial<RagConfig> | VectorP
184
173
  * Event frame. The stream contains frames for `text`, `thinking`,
185
174
  * `metadata`, `ui_transformation`, `observability`, and a terminal `done`.
186
175
  *
187
- * Multipart upload short-circuit: When the request `Content-Type` is
188
- * `multipart/form-data` the request is transparently delegated to
189
- * `createUploadHandler` (which also runs its own `enforceLicense()` gate).
176
+ * NOTE: This handler expects a JSON body. File uploads (`multipart/form-data`)
177
+ * must go to `createUploadHandler` (or `createRagHandler`, which sniffs the
178
+ * content type) — sending form-data here returns `400 INVALID_JSON`.
190
179
  *
191
180
  * Pipeline (in execution order):
192
181
  * 1. `options.onAuthorize` — custom authorization gate (optional)
193
182
  * 2. In-memory IP rate limiter (30 req / 60 s sliding window)
194
- * 3. JSON body parse (or form-data upload delegation)
195
- * 4. `enforceLicense()` RSA signature validation — 403 if missing / terminated
183
+ * 3. JSON body parse
184
+ * 4. `enforceLicense()` server-backed validation — 401/403 if missing / terminated
196
185
  * 5. Input sanitization + length / toxicity / PII / prompt-injection heuristics
197
186
  * 6. User-message persistence via `DatabaseStorage`
198
187
  * 7. Streaming RAG retrieval via `plugin.chat({ stream: true })`
@@ -203,6 +192,7 @@ declare function createChatHandler(configOrPlugin?: Partial<RagConfig> | VectorP
203
192
  * @returns Async `POST(req, ctx)` function for `app/.../route.ts`.
204
193
  */
205
194
  declare function createStreamHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
195
+
206
196
  /**
207
197
  * Build a POST handler that ingests raw pre-parsed documents into the vector DB.
208
198
  *
@@ -219,6 +209,7 @@ declare function createStreamHandler(configOrPlugin?: Partial<RagConfig> | Vecto
219
209
  * @returns Async POST handler.
220
210
  */
221
211
  declare function createIngestHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
212
+
222
213
  /**
223
214
  * Build a GET handler that returns health / readiness status.
224
215
  *
@@ -244,6 +235,7 @@ declare function createIngestHandler(configOrPlugin?: Partial<RagConfig> | Vecto
244
235
  * @returns Async GET handler.
245
236
  */
246
237
  declare function createHealthHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req?: any, context?: any) => Promise<any>;
238
+
247
239
  /**
248
240
  * Build a POST handler for the SDK-facing `/v1/license/validate` endpoint.
249
241
  *
@@ -260,6 +252,7 @@ declare function createHealthHandler(configOrPlugin?: Partial<RagConfig> | Vecto
260
252
  * @returns Async POST handler returning `LicenseValidationResponse` JSON.
261
253
  */
262
254
  declare function createLicenseHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
255
+
263
256
  /**
264
257
  * Build a POST handler that accepts `multipart/form-data` file uploads.
265
258
  *
@@ -278,6 +271,7 @@ declare function createLicenseHandler(configOrPlugin?: Partial<RagConfig> | Vect
278
271
  * @returns Async POST handler.
279
272
  */
280
273
  declare function createUploadHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: any, context?: any) => Promise<any>;
274
+
281
275
  /**
282
276
  * Build a GET/POST handler for auto-suggestions (used by ChatWidget prompt chips).
283
277
  *
@@ -296,6 +290,7 @@ declare function createUploadHandler(configOrPlugin?: Partial<RagConfig> | Vecto
296
290
  * @returns Async handler accepting both GET and POST methods.
297
291
  */
298
292
  declare function createSuggestionsHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
293
+
299
294
  /**
300
295
  * Build a handler for chat-history listing and clearing.
301
296
  *
@@ -312,6 +307,7 @@ declare function createSuggestionsHandler(configOrPlugin?: Partial<RagConfig> |
312
307
  * @returns Async handler accepting GET (list) or POST (clear) methods.
313
308
  */
314
309
  declare function createHistoryHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
310
+
315
311
  /**
316
312
  * Build a POST handler for collecting thumbs-up / thumbs-down user feedback.
317
313
  *
@@ -326,6 +322,7 @@ declare function createHistoryHandler(configOrPlugin?: Partial<RagConfig> | Vect
326
322
  * @returns Async POST handler.
327
323
  */
328
324
  declare function createFeedbackHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req: NextRequest) => Promise<any>;
325
+
329
326
  /**
330
327
  * Build a GET handler that lists the set of chat sessions.
331
328
  *
@@ -340,6 +337,7 @@ declare function createFeedbackHandler(configOrPlugin?: Partial<RagConfig> | Vec
340
337
  * @returns Async GET handler returning a session listing.
341
338
  */
342
339
  declare function createSessionsHandler(configOrPlugin?: Partial<RagConfig> | VectorPlugin, options?: HandlerOptions): (req?: any, context?: any) => Promise<any>;
340
+
343
341
  /**
344
342
  * Build a Next.js catch-all route that dispatches to every sub-handler by path.
345
343
  *
@@ -377,4 +375,20 @@ declare function createRagHandler(configOrPlugin?: Partial<RagConfig> | VectorPl
377
375
  POST: (req: any, context?: any) => Promise<any>;
378
376
  };
379
377
 
380
- export { ConfigValidator as C, type HealthCheckResult as H, type IProviderValidator as I, type ValidationError as V, type IProviderHealthChecker as a, type HandlerOptions as b, VectorPlugin as c, createChatHandler as d, createFeedbackHandler as e, createHealthHandler as f, createHistoryHandler as g, createIngestHandler as h, createRagHandler as i, createSessionsHandler as j, createStreamHandler as k, createUploadHandler as l, sseFrame as m, sseMetaFrame as n, sseTextFrame as o, createLicenseHandler as p, createSuggestionsHandler as q, sseObservabilityFrame as r, sseErrorFrame as s, sseUIFrame as t };
378
+ /**
379
+ * Encode a payload as a Server-Sent Events frame.
380
+ * data: <json>\n\n
381
+ */
382
+ declare function sseFrame(payload: unknown): string;
383
+ /** Encode a plain text chunk as an SSE frame. */
384
+ declare function sseTextFrame(text: string): string;
385
+ /** Encode the retrieval metadata with UI transformation as an SSE frame. */
386
+ declare function sseMetaFrame(meta: unknown): string;
387
+ /** Encode the UI transformation result as an SSE frame. */
388
+ declare function sseUIFrame(uiTransformation: unknown): string;
389
+ /** Encode the observability trace as an SSE frame. */
390
+ declare function sseObservabilityFrame(trace: unknown): string;
391
+ /** Encode a stream error as an SSE frame. */
392
+ declare function sseErrorFrame(message: string): string;
393
+
394
+ export { ConfigValidator as C, type HealthCheckResult as H, type IProviderValidator as I, type ValidationError as V, type IProviderHealthChecker as a, type HandlerOptions as b, VectorPlugin as c, createChatHandler as d, createFeedbackHandler as e, createHealthHandler as f, createHistoryHandler as g, createIngestHandler as h, createLicenseHandler as i, createRagHandler as j, createSessionsHandler as k, createStreamHandler as l, createSuggestionsHandler as m, createUploadHandler as n, sseFrame as o, sseMetaFrame as p, sseObservabilityFrame as q, sseTextFrame as r, sseErrorFrame as s, sseUIFrame as t };
@@ -1,5 +1,5 @@
1
1
  import { CSSProperties, MouseEvent, ReactNode, ElementType } from 'react';
2
- import { W as WidgetPosition, P as Product, u as UIConfig, c as ProjectChatSettings, q as RagMessage, y as VectorMatch, p as RagConfig, I as ILLMProvider, h as IngestDocument, C as ChatMessage, e as ChatResponse, _ as RetrievalResult, v as UniversalRagConfig, U as UITransformationResponse, L as LLMConfig, f as EmbeddingConfig, V as VectorDBConfig } from './ILLMProvider-DUCL1r75.js';
2
+ import { W as WidgetPosition, P as Product, U as UIConfig, a as ProjectChatSettings, R as RagMessage, V as VectorMatch, b as RagConfig, I as ILLMProvider, c as IngestDocument, C as ChatMessage, d as ChatResponse, e as RetrievalResult, f as UniversalRagConfig, g as UITransformationResponse, L as LLMConfig, E as EmbeddingConfig, h as VectorDBConfig } from './ILLMProvider-CzXcTA6d.js';
3
3
 
4
4
  interface ArchitectureCardProps {
5
5
  icon: ReactNode;
@@ -695,8 +695,9 @@ interface LicenseValidationResponse {
695
695
  * 1. Resolve the license key (prop → header → env)
696
696
  * 2. Return any fresh (< 5 min old) successful cached result
697
697
  * 3. POST to `{retrivoraApiBase}/v1/license/validate` for server-side DB-backed status
698
- * 4. On network or HTTP error, fall back to zero-latency local RSA signature
699
- * verification via `LicenseVerifier.verify()`.
698
+ * 4. On network or HTTP error, fall back to `LicenseVerifier.verifyAsync()`
699
+ * (server re-validation with local fail-open only for missing local SDK
700
+ * routes / explicitly allowed fallback).
700
701
  *
701
702
  * Caching policy:
702
703
  * - ONLY successful (valid + ACTIVE + !forceUpgrade) responses are cached
@@ -730,11 +731,11 @@ declare class LicenseValidator {
730
731
  * Primary validation entry-point for UI / hook consumers.
731
732
  *
732
733
  * Resolves the license key, consults the local success cache, performs a
733
- * server POST for authoritative status, and falls back to local RSA
734
- * signature verification if the server can't be reached.
734
+ * server POST for authoritative status, and falls back to `LicenseVerifier.verifyAsync()`
735
+ * if the server can't be reached.
735
736
  *
736
737
  * @throws LicenseValidationError - When no key is provided OR both the
737
- * server call AND the local-RSA fallback report an invalid/expired key.
738
+ * server call AND the fallback report an invalid/expired key.
738
739
  * @throws SDKVersionUnsupportedError - When server reports forceUpgrade=true.
739
740
  * @returns A `LicenseValidationResponse` that the UI can use to enable or
740
741
  * lock the chat widget.
@@ -881,4 +882,4 @@ declare class LicenseValidationError extends RetrivoraError {
881
882
  */
882
883
  declare function wrapError(err: unknown, defaultCode: RetrivoraErrorCode, defaultMessage?: string): RetrivoraError;
883
884
 
884
- export { type RenderSectionDecision as $, AuthenticationException as A, type BatchOptions as B, type ChatWidgetProps as C, type DocumentUploadProps as D, EmbeddingFailedException as E, type RemoteVectorConfig as F, type RenderDecision as G, type RenderType as H, type IRenderRule as I, RetrievalException as J, Retrivora as K, type LicenseTierConfig as L, type MessageBubbleProps as M, RetrivoraError as N, type RetrivoraErrorCode as O, type ProductCardProps as P, SDKVersionUnsupportedError as Q, type RemoteConfig as R, type SourceCardProps as S, SDK_VERSION as T, isTransientError as U, type ArchitectureCardProps as V, DocumentChunker as W, LicenseConfigResolver as X, Pipeline as Y, type PipelineStep as Z, type ProviderPill as _, type ChatWindowProps as a, type Snippet as a0, wrapError as a1, type ConfigProviderProps as b, type ClientConfig as c, type ProductCarouselProps as d, type ChatViewportSize as e, BatchProcessor as f, type BatchResult as g, type ChartType as h, type Chunk as i, type ChunkOptions as j, CircuitBreaker as k, type CircuitBreakerOptions as l, ConfigFetcher as m, ConfigurationException as n, type DecisionContext as o, type IRendererStrategy as p, type IntentCategory as q, LicenseValidationError as r, type LicenseValidationRequest as s, type LicenseValidationResponse as t, LicenseValidator as u, type ProviderCredentials as v, ProviderNotFoundException as w, RateLimitException as x, type RemoteEmbeddingConfig as y, type RemoteLLMConfig as z };
885
+ export { type RenderSectionDecision as $, AuthenticationException as A, type BatchOptions as B, type ChatWidgetProps as C, type DocumentUploadProps as D, EmbeddingFailedException as E, type RemoteVectorConfig as F, type RenderDecision as G, type RenderType as H, type IRenderRule as I, RetrievalException as J, Retrivora as K, type LicenseTierConfig as L, type MessageBubbleProps as M, RetrivoraError as N, type RetrivoraErrorCode as O, type ProductCardProps as P, SDKVersionUnsupportedError as Q, type RemoteConfig as R, type SourceCardProps as S, SDK_VERSION as T, isTransientError as U, Pipeline as V, type ArchitectureCardProps as W, DocumentChunker as X, LicenseConfigResolver as Y, type PipelineStep as Z, type ProviderPill as _, type ChatWindowProps as a, type Snippet as a0, wrapError as a1, type ConfigProviderProps as b, type ClientConfig as c, type ProductCarouselProps as d, type ChatViewportSize as e, BatchProcessor as f, type BatchResult as g, type ChartType as h, type Chunk as i, type ChunkOptions as j, CircuitBreaker as k, type CircuitBreakerOptions as l, ConfigFetcher as m, ConfigurationException as n, type DecisionContext as o, type IRendererStrategy as p, type IntentCategory as q, LicenseValidationError as r, type LicenseValidationRequest as s, type LicenseValidationResponse as t, LicenseValidator as u, type ProviderCredentials as v, ProviderNotFoundException as w, RateLimitException as x, type RemoteEmbeddingConfig as y, type RemoteLLMConfig as z };
package/dist/index.css CHANGED
@@ -335,6 +335,9 @@
335
335
  .static {
336
336
  position: static;
337
337
  }
338
+ .sticky {
339
+ position: sticky;
340
+ }
338
341
  .inset-0 {
339
342
  inset: 0px;
340
343
  }
@@ -380,6 +383,9 @@
380
383
  .-bottom-1\.5 {
381
384
  bottom: calc(var(--spacing) * -1.5);
382
385
  }
386
+ .bottom-3 {
387
+ bottom: calc(var(--spacing) * 3);
388
+ }
383
389
  .bottom-6 {
384
390
  bottom: calc(var(--spacing) * 6);
385
391
  }
@@ -1513,6 +1519,12 @@
1513
1519
  background-color: color-mix(in oklab, var(--color-white) 90%, transparent);
1514
1520
  }
1515
1521
  }
1522
+ .bg-white\/95 {
1523
+ background-color: color-mix(in srgb, #fff 95%, transparent);
1524
+ @supports (color: color-mix(in lab, red, red)) {
1525
+ background-color: color-mix(in oklab, var(--color-white) 95%, transparent);
1526
+ }
1527
+ }
1516
1528
  .bg-gradient-to-br {
1517
1529
  --tw-gradient-position: to bottom right in oklab;
1518
1530
  background-image: linear-gradient(var(--tw-gradient-stops));
@@ -2944,6 +2956,14 @@
2944
2956
  .dark\:bg-slate-800 {
2945
2957
  background-color: var(--color-slate-800);
2946
2958
  }
2959
+ .dark\:bg-slate-800\/95 {
2960
+ background-color: color-mix(in srgb, oklch(27.9% 0.041 260.031) 95%, transparent);
2961
+ }
2962
+ @supports (color: color-mix(in lab, red, red)) {
2963
+ .dark\:bg-slate-800\/95 {
2964
+ background-color: color-mix(in oklab, var(--color-slate-800) 95%, transparent);
2965
+ }
2966
+ }
2947
2967
  .dark\:bg-slate-900 {
2948
2968
  background-color: var(--color-slate-900);
2949
2969
  }
@@ -3320,6 +3340,9 @@
3320
3340
  background-color: color-mix(in oklab, var(--color-rose-900) 40%, transparent);
3321
3341
  }
3322
3342
  }
3343
+ .dark\:hover\:bg-slate-800:hover {
3344
+ background-color: var(--color-slate-800);
3345
+ }
3323
3346
  .dark\:hover\:bg-white\/5:hover {
3324
3347
  background-color: color-mix(in srgb, #fff 5%, transparent);
3325
3348
  }
package/dist/index.d.mts CHANGED
@@ -1,8 +1,8 @@
1
1
  import React$1 from 'react';
2
- import { C as ChatWidgetProps, a as ChatWindowProps, D as DocumentUploadProps, M as MessageBubbleProps, S as SourceCardProps, b as ConfigProviderProps, c as ClientConfig, P as ProductCardProps, d as ProductCarouselProps, e as ChatViewportSize, R as RemoteConfig } from './index-BVSHblli.mjs';
3
- export { A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, i as Chunk, j as ChunkOptions, k as CircuitBreaker, l as CircuitBreakerOptions, m as ConfigFetcher, n as ConfigurationException, o as DecisionContext, E as EmbeddingFailedException, I as IRenderRule, p as IRendererStrategy, q as IntentCategory, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, v as ProviderCredentials, w as ProviderNotFoundException, x as RateLimitException, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, G as RenderDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, U as isTransientError } from './index-BVSHblli.mjs';
4
- import { O as ObservabilityTrace, P as Product, U as UITransformationResponse, a as UseRagChatOptions, b as UseRagChatReturn, c as ProjectChatSettings } from './ILLMProvider-DUCL1r75.mjs';
5
- export { A as AuthMode, C as ChatMessage, d as ChatOptions, e as ChatResponse, E as EmbedOptions, f as EmbeddingConfig, g as EmbeddingProvider, I as ILLMProvider, h as IngestDocument, L as LLMConfig, i as LLMProvider, j as LatencyBreakdown, k as ProjectAiSettings, l as ProjectAuthSettings, m as ProjectBrandingSettings, n as ProjectTelemetrySettings, o as ProjectWidgetSettings, R as RAGConfig, p as RagConfig, q as RagMessage, r as RetrievalConfig, s as RetrievedChunk, T as ThemeMode, t as TokenUsage, u as UIConfig, v as UniversalRagConfig, w as UpsertDocument, V as VectorDBConfig, x as VectorDBProvider, y as VectorMatch, W as WidgetPosition, z as WorkflowConfig, B as createDefaultProjectSettings, D as normalizeProjectSettings, F as projectSettingsToUiConfig } from './ILLMProvider-DUCL1r75.mjs';
2
+ import { C as ChatWidgetProps, a as ChatWindowProps, D as DocumentUploadProps, M as MessageBubbleProps, S as SourceCardProps, b as ConfigProviderProps, c as ClientConfig, P as ProductCardProps, d as ProductCarouselProps, e as ChatViewportSize, R as RemoteConfig } from './index-BST9Gzsv.mjs';
3
+ export { A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, i as Chunk, j as ChunkOptions, k as CircuitBreaker, l as CircuitBreakerOptions, m as ConfigFetcher, n as ConfigurationException, o as DecisionContext, E as EmbeddingFailedException, I as IRenderRule, p as IRendererStrategy, q as IntentCategory, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, v as ProviderCredentials, w as ProviderNotFoundException, x as RateLimitException, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, G as RenderDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, U as isTransientError } from './index-BST9Gzsv.mjs';
4
+ import { O as ObservabilityTrace, P as Product, g as UITransformationResponse, i as UseRagChatOptions, j as UseRagChatReturn, a as ProjectChatSettings } from './ILLMProvider-CzXcTA6d.mjs';
5
+ export { A as AuthMode, C as ChatMessage, k as ChatOptions, d as ChatResponse, l as EmbedOptions, E as EmbeddingConfig, m as EmbeddingProvider, I as ILLMProvider, c as IngestDocument, L as LLMConfig, n as LLMProvider, o as LatencyBreakdown, p as ProjectAiSettings, q as ProjectAuthSettings, r as ProjectBrandingSettings, s as ProjectTelemetrySettings, t as ProjectWidgetSettings, u as RAGConfig, b as RagConfig, R as RagMessage, v as RetrievalConfig, w as RetrievedChunk, T as ThemeMode, x as TokenUsage, U as UIConfig, f as UniversalRagConfig, y as UpsertDocument, h as VectorDBConfig, z as VectorDBProvider, V as VectorMatch, W as WidgetPosition, B as WorkflowConfig, D as createDefaultProjectSettings, F as normalizeProjectSettings, G as projectSettingsToUiConfig } from './ILLMProvider-CzXcTA6d.mjs';
6
6
 
7
7
  /**
8
8
  * ChatWidget — Floating Action Button (FAB) that toggles the chat window.
package/dist/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import React$1 from 'react';
2
- import { C as ChatWidgetProps, a as ChatWindowProps, D as DocumentUploadProps, M as MessageBubbleProps, S as SourceCardProps, b as ConfigProviderProps, c as ClientConfig, P as ProductCardProps, d as ProductCarouselProps, e as ChatViewportSize, R as RemoteConfig } from './index-DGW0NNmR.js';
3
- export { A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, i as Chunk, j as ChunkOptions, k as CircuitBreaker, l as CircuitBreakerOptions, m as ConfigFetcher, n as ConfigurationException, o as DecisionContext, E as EmbeddingFailedException, I as IRenderRule, p as IRendererStrategy, q as IntentCategory, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, v as ProviderCredentials, w as ProviderNotFoundException, x as RateLimitException, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, G as RenderDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, U as isTransientError } from './index-DGW0NNmR.js';
4
- import { O as ObservabilityTrace, P as Product, U as UITransformationResponse, a as UseRagChatOptions, b as UseRagChatReturn, c as ProjectChatSettings } from './ILLMProvider-DUCL1r75.js';
5
- export { A as AuthMode, C as ChatMessage, d as ChatOptions, e as ChatResponse, E as EmbedOptions, f as EmbeddingConfig, g as EmbeddingProvider, I as ILLMProvider, h as IngestDocument, L as LLMConfig, i as LLMProvider, j as LatencyBreakdown, k as ProjectAiSettings, l as ProjectAuthSettings, m as ProjectBrandingSettings, n as ProjectTelemetrySettings, o as ProjectWidgetSettings, R as RAGConfig, p as RagConfig, q as RagMessage, r as RetrievalConfig, s as RetrievedChunk, T as ThemeMode, t as TokenUsage, u as UIConfig, v as UniversalRagConfig, w as UpsertDocument, V as VectorDBConfig, x as VectorDBProvider, y as VectorMatch, W as WidgetPosition, z as WorkflowConfig, B as createDefaultProjectSettings, D as normalizeProjectSettings, F as projectSettingsToUiConfig } from './ILLMProvider-DUCL1r75.js';
2
+ import { C as ChatWidgetProps, a as ChatWindowProps, D as DocumentUploadProps, M as MessageBubbleProps, S as SourceCardProps, b as ConfigProviderProps, c as ClientConfig, P as ProductCardProps, d as ProductCarouselProps, e as ChatViewportSize, R as RemoteConfig } from './index-qLvtMUr-.js';
3
+ export { A as AuthenticationException, B as BatchOptions, f as BatchProcessor, g as BatchResult, h as ChartType, i as Chunk, j as ChunkOptions, k as CircuitBreaker, l as CircuitBreakerOptions, m as ConfigFetcher, n as ConfigurationException, o as DecisionContext, E as EmbeddingFailedException, I as IRenderRule, p as IRendererStrategy, q as IntentCategory, L as LicenseTierConfig, r as LicenseValidationError, s as LicenseValidationRequest, t as LicenseValidationResponse, u as LicenseValidator, v as ProviderCredentials, w as ProviderNotFoundException, x as RateLimitException, y as RemoteEmbeddingConfig, z as RemoteLLMConfig, F as RemoteVectorConfig, G as RenderDecision, H as RenderType, J as RetrievalException, K as Retrivora, N as RetrivoraError, O as RetrivoraErrorCode, Q as SDKVersionUnsupportedError, T as SDK_VERSION, U as isTransientError } from './index-qLvtMUr-.js';
4
+ import { O as ObservabilityTrace, P as Product, g as UITransformationResponse, i as UseRagChatOptions, j as UseRagChatReturn, a as ProjectChatSettings } from './ILLMProvider-CzXcTA6d.js';
5
+ export { A as AuthMode, C as ChatMessage, k as ChatOptions, d as ChatResponse, l as EmbedOptions, E as EmbeddingConfig, m as EmbeddingProvider, I as ILLMProvider, c as IngestDocument, L as LLMConfig, n as LLMProvider, o as LatencyBreakdown, p as ProjectAiSettings, q as ProjectAuthSettings, r as ProjectBrandingSettings, s as ProjectTelemetrySettings, t as ProjectWidgetSettings, u as RAGConfig, b as RagConfig, R as RagMessage, v as RetrievalConfig, w as RetrievedChunk, T as ThemeMode, x as TokenUsage, U as UIConfig, f as UniversalRagConfig, y as UpsertDocument, h as VectorDBConfig, z as VectorDBProvider, V as VectorMatch, W as WidgetPosition, B as WorkflowConfig, D as createDefaultProjectSettings, F as normalizeProjectSettings, G as projectSettingsToUiConfig } from './ILLMProvider-CzXcTA6d.js';
6
6
 
7
7
  /**
8
8
  * ChatWidget — Floating Action Button (FAB) that toggles the chat window.