@retrivora-ai/rag-engine 2.4.6 → 2.4.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.
- package/dist/{BatchProcessor-BGslIR5l.d.mts → BatchProcessor-BZhwvT6o.d.mts} +2 -2
- package/dist/{BatchProcessor-C3gY6kZ0.d.ts → BatchProcessor-DlAkfGbv.d.ts} +2 -2
- package/dist/{ILLMProvider-Y6aL5N8J.d.mts → ILLMProvider-BYQd0Nys.d.mts} +1 -1
- package/dist/{ILLMProvider-Y6aL5N8J.d.ts → ILLMProvider-BYQd0Nys.d.ts} +1 -1
- package/dist/handlers/index.d.mts +2 -2
- package/dist/handlers/index.d.ts +2 -2
- package/dist/handlers/index.js +1 -1
- package/dist/handlers/index.mjs +1 -1
- package/dist/{index-59CHg0V3.d.mts → index-BTLsJ0da.d.mts} +1 -1
- package/dist/{index-BgKRInpa.d.ts → index-DtDY4Dwa.d.ts} +1 -1
- package/dist/index.css +46 -0
- package/dist/index.d.mts +74 -6
- package/dist/index.d.ts +74 -6
- package/dist/index.js +583 -318
- package/dist/index.min.css +1 -1
- package/dist/index.mjs +546 -284
- package/dist/server.d.mts +6 -6
- package/dist/server.d.ts +6 -6
- package/dist/server.js +1 -1
- package/dist/server.mjs +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CSSProperties, MouseEvent, ReactNode, ElementType } from 'react';
|
|
2
|
-
import { W as WidgetPosition,
|
|
2
|
+
import { W as WidgetPosition, P as Product, u as UIConfig, c as ProjectChatSettings, q as RagMessage, y as VectorMatch, L as LLMConfig, f as EmbeddingConfig, V as VectorDBConfig, U as UITransformationResponse, p as RagConfig, I as ILLMProvider, h as IngestDocument, C as ChatMessage, e as ChatResponse, _ as RetrievalResult, v as UniversalRagConfig } from './ILLMProvider-BYQd0Nys.mjs';
|
|
3
3
|
|
|
4
4
|
interface ArchitectureCardProps {
|
|
5
5
|
icon: ReactNode;
|
|
@@ -831,4 +831,4 @@ declare class BatchProcessor {
|
|
|
831
831
|
static processConcurrent<T, R>(items: T[], processor: (item: T) => Promise<R>, concurrency?: number, options?: BatchOptions): Promise<BatchResult<R>>;
|
|
832
832
|
}
|
|
833
833
|
|
|
834
|
-
export { type RenderSectionDecision as $, AuthenticationException as A, type BatchOptions as B, type ChatWidgetProps as C, type DocumentUploadProps as D, EmbeddingFailedException as E, type
|
|
834
|
+
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 };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CSSProperties, MouseEvent, ReactNode, ElementType } from 'react';
|
|
2
|
-
import { W as WidgetPosition,
|
|
2
|
+
import { W as WidgetPosition, P as Product, u as UIConfig, c as ProjectChatSettings, q as RagMessage, y as VectorMatch, L as LLMConfig, f as EmbeddingConfig, V as VectorDBConfig, U as UITransformationResponse, p as RagConfig, I as ILLMProvider, h as IngestDocument, C as ChatMessage, e as ChatResponse, _ as RetrievalResult, v as UniversalRagConfig } from './ILLMProvider-BYQd0Nys.js';
|
|
3
3
|
|
|
4
4
|
interface ArchitectureCardProps {
|
|
5
5
|
icon: ReactNode;
|
|
@@ -831,4 +831,4 @@ declare class BatchProcessor {
|
|
|
831
831
|
static processConcurrent<T, R>(items: T[], processor: (item: T) => Promise<R>, concurrency?: number, options?: BatchOptions): Promise<BatchResult<R>>;
|
|
832
832
|
}
|
|
833
833
|
|
|
834
|
-
export { type RenderSectionDecision as $, AuthenticationException as A, type BatchOptions as B, type ChatWidgetProps as C, type DocumentUploadProps as D, EmbeddingFailedException as E, type
|
|
834
|
+
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 };
|
|
@@ -679,4 +679,4 @@ interface ILLMProvider {
|
|
|
679
679
|
ping(): Promise<boolean>;
|
|
680
680
|
}
|
|
681
681
|
|
|
682
|
-
export { type RetrivoraChunkMetadata as $, type AuthMode as A,
|
|
682
|
+
export { type RetrivoraChunkMetadata as $, type AuthMode as A, createDefaultProjectSettings as B, type ChatMessage as C, normalizeProjectSettings as D, type EmbedOptions as E, projectSettingsToUiConfig as F, type GraphDBConfig as G, type GraphNode as H, type ILLMProvider as I, type Edge as J, type GraphSearchResult as K, type LLMConfig as L, type BarChartData as M, type CarouselProduct as N, type ObservabilityTrace as O, type Product as P, type IRetriever as Q, type RAGConfig as R, type LineChartDataPoint as S, type ThemeMode as T, type UITransformationResponse as U, type VectorDBConfig as V, type WidgetPosition as W, type MessageRole as X, type MetricCardData as Y, type PieChartData as Z, type RetrievalResult as _, type UseRagChatOptions as a, type RetrivoraIngestedDocument as a0, type ScatterPlotDataPoint as a1, type SuggestionsResponse as a2, type TableData as a3, type VisualizationType as a4, type UseRagChatReturn as b, type ProjectChatSettings as c, type ChatOptions as d, type ChatResponse as e, type EmbeddingConfig as f, type EmbeddingProvider as g, type IngestDocument as h, type LLMProvider as i, type LatencyBreakdown as j, type ProjectAiSettings as k, type ProjectAuthSettings as l, type ProjectBrandingSettings as m, type ProjectTelemetrySettings as n, type ProjectWidgetSettings as o, type RagConfig as p, type RagMessage as q, type RetrievalConfig as r, type RetrievedChunk as s, type TokenUsage as t, type UIConfig as u, type UniversalRagConfig as v, type UpsertDocument as w, type VectorDBProvider as x, type VectorMatch as y, type WorkflowConfig as z };
|
|
@@ -679,4 +679,4 @@ interface ILLMProvider {
|
|
|
679
679
|
ping(): Promise<boolean>;
|
|
680
680
|
}
|
|
681
681
|
|
|
682
|
-
export { type RetrivoraChunkMetadata as $, type AuthMode as A,
|
|
682
|
+
export { type RetrivoraChunkMetadata as $, type AuthMode as A, createDefaultProjectSettings as B, type ChatMessage as C, normalizeProjectSettings as D, type EmbedOptions as E, projectSettingsToUiConfig as F, type GraphDBConfig as G, type GraphNode as H, type ILLMProvider as I, type Edge as J, type GraphSearchResult as K, type LLMConfig as L, type BarChartData as M, type CarouselProduct as N, type ObservabilityTrace as O, type Product as P, type IRetriever as Q, type RAGConfig as R, type LineChartDataPoint as S, type ThemeMode as T, type UITransformationResponse as U, type VectorDBConfig as V, type WidgetPosition as W, type MessageRole as X, type MetricCardData as Y, type PieChartData as Z, type RetrievalResult as _, type UseRagChatOptions as a, type RetrivoraIngestedDocument as a0, type ScatterPlotDataPoint as a1, type SuggestionsResponse as a2, type TableData as a3, type VisualizationType as a4, type UseRagChatReturn as b, type ProjectChatSettings as c, type ChatOptions as d, type ChatResponse as e, type EmbeddingConfig as f, type EmbeddingProvider as g, type IngestDocument as h, type LLMProvider as i, type LatencyBreakdown as j, type ProjectAiSettings as k, type ProjectAuthSettings as l, type ProjectBrandingSettings as m, type ProjectTelemetrySettings as n, type ProjectWidgetSettings as o, type RagConfig as p, type RagMessage as q, type RetrievalConfig as r, type RetrievedChunk as s, type TokenUsage as t, type UIConfig as u, type UniversalRagConfig as v, type UpsertDocument as w, type VectorDBProvider as x, type VectorMatch as y, type WorkflowConfig as z };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import 'next/server';
|
|
2
|
-
export { b as HandlerOptions, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, p as createLicenseHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, q as createSuggestionsHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, r as sseObservabilityFrame, o as sseTextFrame, t as sseUIFrame } from '../index-
|
|
3
|
-
import '../ILLMProvider-
|
|
2
|
+
export { b as HandlerOptions, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, p as createLicenseHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, q as createSuggestionsHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, r as sseObservabilityFrame, o as sseTextFrame, t as sseUIFrame } from '../index-BTLsJ0da.mjs';
|
|
3
|
+
import '../ILLMProvider-BYQd0Nys.mjs';
|
package/dist/handlers/index.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import 'next/server';
|
|
2
|
-
export { b as HandlerOptions, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, p as createLicenseHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, q as createSuggestionsHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, r as sseObservabilityFrame, o as sseTextFrame, t as sseUIFrame } from '../index-
|
|
3
|
-
import '../ILLMProvider-
|
|
2
|
+
export { b as HandlerOptions, d as createChatHandler, e as createFeedbackHandler, f as createHealthHandler, g as createHistoryHandler, h as createIngestHandler, p as createLicenseHandler, i as createRagHandler, j as createSessionsHandler, k as createStreamHandler, q as createSuggestionsHandler, l as createUploadHandler, s as sseErrorFrame, m as sseFrame, n as sseMetaFrame, r as sseObservabilityFrame, o as sseTextFrame, t as sseUIFrame } from '../index-DtDY4Dwa.js';
|
|
3
|
+
import '../ILLMProvider-BYQd0Nys.js';
|
package/dist/handlers/index.js
CHANGED
|
@@ -318,7 +318,7 @@ var init_package = __esm({
|
|
|
318
318
|
"package.json"() {
|
|
319
319
|
package_default = {
|
|
320
320
|
name: "@retrivora-ai/rag-engine",
|
|
321
|
-
version: "2.4.
|
|
321
|
+
version: "2.4.7",
|
|
322
322
|
description: "Retrivora AI is a plug-and-play AI engine for RAG chat experiences \u2014 generic vector DB + LLM provider, embeddable or standalone.",
|
|
323
323
|
author: "Abhinav Alkuchi",
|
|
324
324
|
license: "UNLICENSED",
|
package/dist/handlers/index.mjs
CHANGED
|
@@ -312,7 +312,7 @@ var init_package = __esm({
|
|
|
312
312
|
"package.json"() {
|
|
313
313
|
package_default = {
|
|
314
314
|
name: "@retrivora-ai/rag-engine",
|
|
315
|
-
version: "2.4.
|
|
315
|
+
version: "2.4.7",
|
|
316
316
|
description: "Retrivora AI is a plug-and-play AI engine for RAG chat experiences \u2014 generic vector DB + LLM provider, embeddable or standalone.",
|
|
317
317
|
author: "Abhinav Alkuchi",
|
|
318
318
|
license: "UNLICENSED",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { NextRequest } from 'next/server';
|
|
2
|
-
import {
|
|
2
|
+
import { p as RagConfig, I as ILLMProvider, C as ChatMessage, e as ChatResponse, h as IngestDocument } from './ILLMProvider-BYQd0Nys.mjs';
|
|
3
3
|
|
|
4
4
|
interface ValidationError {
|
|
5
5
|
field: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { NextRequest } from 'next/server';
|
|
2
|
-
import {
|
|
2
|
+
import { p as RagConfig, I as ILLMProvider, C as ChatMessage, e as ChatResponse, h as IngestDocument } from './ILLMProvider-BYQd0Nys.js';
|
|
3
3
|
|
|
4
4
|
interface ValidationError {
|
|
5
5
|
field: string;
|
package/dist/index.css
CHANGED
|
@@ -630,6 +630,9 @@
|
|
|
630
630
|
.h-9 {
|
|
631
631
|
height: calc(var(--spacing) * 9);
|
|
632
632
|
}
|
|
633
|
+
.h-10 {
|
|
634
|
+
height: calc(var(--spacing) * 10);
|
|
635
|
+
}
|
|
633
636
|
.h-12 {
|
|
634
637
|
height: calc(var(--spacing) * 12);
|
|
635
638
|
}
|
|
@@ -1519,6 +1522,9 @@
|
|
|
1519
1522
|
.p-4 {
|
|
1520
1523
|
padding: calc(var(--spacing) * 4);
|
|
1521
1524
|
}
|
|
1525
|
+
.p-5 {
|
|
1526
|
+
padding: calc(var(--spacing) * 5);
|
|
1527
|
+
}
|
|
1522
1528
|
.p-6 {
|
|
1523
1529
|
padding: calc(var(--spacing) * 6);
|
|
1524
1530
|
}
|
|
@@ -2074,6 +2080,14 @@
|
|
|
2074
2080
|
.\[animation-delay\:300ms\] {
|
|
2075
2081
|
animation-delay: 300ms;
|
|
2076
2082
|
}
|
|
2083
|
+
.group-hover\:translate-x-0\.5 {
|
|
2084
|
+
&:is(:where(.group):hover *) {
|
|
2085
|
+
@media (hover: hover) {
|
|
2086
|
+
--tw-translate-x: calc(var(--spacing) * 0.5);
|
|
2087
|
+
translate: var(--tw-translate-x) var(--tw-translate-y);
|
|
2088
|
+
}
|
|
2089
|
+
}
|
|
2090
|
+
}
|
|
2077
2091
|
.group-hover\:scale-100 {
|
|
2078
2092
|
&:is(:where(.group):hover *) {
|
|
2079
2093
|
@media (hover: hover) {
|
|
@@ -2375,6 +2389,13 @@
|
|
|
2375
2389
|
}
|
|
2376
2390
|
}
|
|
2377
2391
|
}
|
|
2392
|
+
.hover\:opacity-95 {
|
|
2393
|
+
&:hover {
|
|
2394
|
+
@media (hover: hover) {
|
|
2395
|
+
opacity: 95%;
|
|
2396
|
+
}
|
|
2397
|
+
}
|
|
2398
|
+
}
|
|
2378
2399
|
.hover\:shadow-lg {
|
|
2379
2400
|
&:hover {
|
|
2380
2401
|
@media (hover: hover) {
|
|
@@ -2396,11 +2417,28 @@
|
|
|
2396
2417
|
border-color: var(--color-emerald-500);
|
|
2397
2418
|
}
|
|
2398
2419
|
}
|
|
2420
|
+
.focus\:ring-1 {
|
|
2421
|
+
&:focus {
|
|
2422
|
+
--tw-ring-shadow: var(--tw-ring-inset,) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color, currentcolor);
|
|
2423
|
+
box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
|
|
2424
|
+
}
|
|
2425
|
+
}
|
|
2399
2426
|
.focus\:ring-blue-500 {
|
|
2400
2427
|
&:focus {
|
|
2401
2428
|
--tw-ring-color: var(--color-blue-500);
|
|
2402
2429
|
}
|
|
2403
2430
|
}
|
|
2431
|
+
.focus\:ring-indigo-500 {
|
|
2432
|
+
&:focus {
|
|
2433
|
+
--tw-ring-color: var(--color-indigo-500);
|
|
2434
|
+
}
|
|
2435
|
+
}
|
|
2436
|
+
.focus\:outline-none {
|
|
2437
|
+
&:focus {
|
|
2438
|
+
--tw-outline-style: none;
|
|
2439
|
+
outline-style: none;
|
|
2440
|
+
}
|
|
2441
|
+
}
|
|
2404
2442
|
.active\:scale-95 {
|
|
2405
2443
|
&:active {
|
|
2406
2444
|
--tw-scale-x: 95%;
|
|
@@ -2882,6 +2920,14 @@
|
|
|
2882
2920
|
}
|
|
2883
2921
|
}
|
|
2884
2922
|
}
|
|
2923
|
+
.dark\:bg-emerald-950\/20 {
|
|
2924
|
+
@media (prefers-color-scheme: dark) {
|
|
2925
|
+
background-color: color-mix(in srgb, oklch(26.2% 0.051 172.552) 20%, transparent);
|
|
2926
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
2927
|
+
background-color: color-mix(in oklab, var(--color-emerald-950) 20%, transparent);
|
|
2928
|
+
}
|
|
2929
|
+
}
|
|
2930
|
+
}
|
|
2885
2931
|
.dark\:bg-emerald-950\/40 {
|
|
2886
2932
|
@media (prefers-color-scheme: dark) {
|
|
2887
2933
|
background-color: color-mix(in srgb, oklch(26.2% 0.051 172.552) 40%, transparent);
|
package/dist/index.d.mts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
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, R as RemoteConfig } from './BatchProcessor-
|
|
3
|
-
export { A as AuthenticationException, B as BatchOptions,
|
|
4
|
-
import { O as ObservabilityTrace, U as
|
|
5
|
-
export { A as AuthMode, C as ChatMessage,
|
|
6
|
-
import '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 './BatchProcessor-BZhwvT6o.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 './BatchProcessor-BZhwvT6o.mjs';
|
|
4
|
+
import { O as ObservabilityTrace, P as Product, U as UITransformationResponse, a as UseRagChatOptions, b as UseRagChatReturn, c as ProjectChatSettings } from './ILLMProvider-BYQd0Nys.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-BYQd0Nys.mjs';
|
|
6
|
+
import React from 'react';
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* ChatWidget — Floating Action Button (FAB) that toggles the chat window.
|
|
@@ -76,6 +76,74 @@ declare function ProductCard({ product, primaryColor, onAddToCart }: ProductCard
|
|
|
76
76
|
|
|
77
77
|
declare function ProductCarousel({ products, primaryColor, onAddToCart }: ProductCarouselProps): react_jsx_runtime.JSX.Element | null;
|
|
78
78
|
|
|
79
|
+
declare function UIDispatcher({ rawContent, primaryColor, accentColor, isStreaming, onAddToCart, viewportSize }: {
|
|
80
|
+
rawContent: string;
|
|
81
|
+
primaryColor?: string;
|
|
82
|
+
accentColor?: string;
|
|
83
|
+
isStreaming?: boolean;
|
|
84
|
+
onAddToCart?: (product: Product) => void;
|
|
85
|
+
viewportSize?: ChatViewportSize;
|
|
86
|
+
}): react_jsx_runtime.JSX.Element | null;
|
|
87
|
+
|
|
88
|
+
interface VisualizationRendererProps {
|
|
89
|
+
data: UITransformationResponse;
|
|
90
|
+
className?: string;
|
|
91
|
+
primaryColor?: string;
|
|
92
|
+
onAddToCart?: (product: Product) => void;
|
|
93
|
+
isStreaming?: boolean;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* VisualizationRenderer — Renders UI transformations as React components.
|
|
97
|
+
*
|
|
98
|
+
* Dynamically selects the appropriate visualization component based on the
|
|
99
|
+
* transformation type returned by UITransformer. All charts are rendered via
|
|
100
|
+
* Recharts (chart.js has been removed).
|
|
101
|
+
*
|
|
102
|
+
* Supported types: bar_chart · line_chart · pie_chart · table · product_carousel · text
|
|
103
|
+
*
|
|
104
|
+
* @example
|
|
105
|
+
* const transformation = await UITransformer.analyzeAndDecide(query, sources, llm);
|
|
106
|
+
* return <VisualizationRenderer data={transformation} />;
|
|
107
|
+
*/
|
|
108
|
+
declare function VisualizationRenderer({ data, className, primaryColor, onAddToCart, isStreaming, }: VisualizationRendererProps): react_jsx_runtime.JSX.Element;
|
|
109
|
+
|
|
110
|
+
interface UIBlock {
|
|
111
|
+
view: 'carousel' | 'table' | 'chart' | 'form' | 'actions' | string;
|
|
112
|
+
title?: string;
|
|
113
|
+
description?: string;
|
|
114
|
+
data?: any;
|
|
115
|
+
columns?: string[];
|
|
116
|
+
chartType?: 'bar' | 'line' | 'pie' | 'scatter';
|
|
117
|
+
xAxisKey?: string;
|
|
118
|
+
dataKeys?: string[];
|
|
119
|
+
colors?: string[];
|
|
120
|
+
fields?: Array<{
|
|
121
|
+
name: string;
|
|
122
|
+
type: 'text' | 'email' | 'number' | 'textarea' | 'checkbox';
|
|
123
|
+
label: string;
|
|
124
|
+
required?: boolean;
|
|
125
|
+
placeholder?: string;
|
|
126
|
+
}>;
|
|
127
|
+
submitText?: string;
|
|
128
|
+
buttons?: Array<{
|
|
129
|
+
label: string;
|
|
130
|
+
action: 'trigger_workflow' | 'open_url' | 'send_message' | string;
|
|
131
|
+
payload?: Record<string, any>;
|
|
132
|
+
}>;
|
|
133
|
+
[key: string]: any;
|
|
134
|
+
}
|
|
135
|
+
interface UIBlockRendererProps {
|
|
136
|
+
block: UIBlock | unknown;
|
|
137
|
+
customRenderers?: Record<string, (data: any) => React.ReactNode>;
|
|
138
|
+
primaryColor?: string;
|
|
139
|
+
accentColor?: string;
|
|
140
|
+
onAddToCart?: (product: Product) => void;
|
|
141
|
+
onActionTriggered?: (action: string, payload: any) => void;
|
|
142
|
+
onFormSubmit?: (formData: Record<string, any>) => void | Promise<void>;
|
|
143
|
+
isStreaming?: boolean;
|
|
144
|
+
}
|
|
145
|
+
declare function UIBlockRenderer({ block, customRenderers, primaryColor, accentColor, onAddToCart, onActionTriggered, onFormSubmit, isStreaming, }: UIBlockRendererProps): react_jsx_runtime.JSX.Element | null;
|
|
146
|
+
|
|
79
147
|
declare function useRagChat(projectId: string, options?: UseRagChatOptions): UseRagChatReturn;
|
|
80
148
|
|
|
81
149
|
interface UseProjectSettingsOptions {
|
|
@@ -98,4 +166,4 @@ declare function useProjectSettings(projectId: string, options?: UseProjectSetti
|
|
|
98
166
|
*/
|
|
99
167
|
declare function addSynonyms(customSynonyms: Record<string, string[]>): void;
|
|
100
168
|
|
|
101
|
-
export { ChatWidget, ChatWidgetProps, ChatWindow, ChatWindowProps, ClientConfig, CodeViewer, ConfigProvider, DocumentUpload, DocumentUploadProps, MessageBubble, MessageBubbleProps, ObservabilityPanel, ObservabilityTrace, ProductCard, ProductCardProps, ProductCarousel, ProductCarouselProps, ProjectChatSettings, RemoteConfig, SourceCard, SourceCardProps, type UseProjectSettingsOptions, type UseProjectSettingsReturn, UseRagChatOptions, UseRagChatReturn, addSynonyms, useConfig, useProjectSettings, useRagChat };
|
|
169
|
+
export { ChatWidget, ChatWidgetProps, ChatWindow, ChatWindowProps, ClientConfig, CodeViewer, ConfigProvider, DocumentUpload, DocumentUploadProps, MessageBubble, MessageBubbleProps, ObservabilityPanel, ObservabilityTrace, ProductCard, ProductCardProps, ProductCarousel, ProductCarouselProps, ProjectChatSettings, RemoteConfig, SourceCard, SourceCardProps, type UIBlock, UIBlockRenderer, UIDispatcher, type UseProjectSettingsOptions, type UseProjectSettingsReturn, UseRagChatOptions, UseRagChatReturn, VisualizationRenderer, addSynonyms, useConfig, useProjectSettings, useRagChat };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
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, R as RemoteConfig } from './BatchProcessor-
|
|
3
|
-
export { A as AuthenticationException, B as BatchOptions,
|
|
4
|
-
import { O as ObservabilityTrace, U as
|
|
5
|
-
export { A as AuthMode, C as ChatMessage,
|
|
6
|
-
import '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 './BatchProcessor-DlAkfGbv.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 './BatchProcessor-DlAkfGbv.js';
|
|
4
|
+
import { O as ObservabilityTrace, P as Product, U as UITransformationResponse, a as UseRagChatOptions, b as UseRagChatReturn, c as ProjectChatSettings } from './ILLMProvider-BYQd0Nys.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-BYQd0Nys.js';
|
|
6
|
+
import React from 'react';
|
|
7
7
|
|
|
8
8
|
/**
|
|
9
9
|
* ChatWidget — Floating Action Button (FAB) that toggles the chat window.
|
|
@@ -76,6 +76,74 @@ declare function ProductCard({ product, primaryColor, onAddToCart }: ProductCard
|
|
|
76
76
|
|
|
77
77
|
declare function ProductCarousel({ products, primaryColor, onAddToCart }: ProductCarouselProps): react_jsx_runtime.JSX.Element | null;
|
|
78
78
|
|
|
79
|
+
declare function UIDispatcher({ rawContent, primaryColor, accentColor, isStreaming, onAddToCart, viewportSize }: {
|
|
80
|
+
rawContent: string;
|
|
81
|
+
primaryColor?: string;
|
|
82
|
+
accentColor?: string;
|
|
83
|
+
isStreaming?: boolean;
|
|
84
|
+
onAddToCart?: (product: Product) => void;
|
|
85
|
+
viewportSize?: ChatViewportSize;
|
|
86
|
+
}): react_jsx_runtime.JSX.Element | null;
|
|
87
|
+
|
|
88
|
+
interface VisualizationRendererProps {
|
|
89
|
+
data: UITransformationResponse;
|
|
90
|
+
className?: string;
|
|
91
|
+
primaryColor?: string;
|
|
92
|
+
onAddToCart?: (product: Product) => void;
|
|
93
|
+
isStreaming?: boolean;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* VisualizationRenderer — Renders UI transformations as React components.
|
|
97
|
+
*
|
|
98
|
+
* Dynamically selects the appropriate visualization component based on the
|
|
99
|
+
* transformation type returned by UITransformer. All charts are rendered via
|
|
100
|
+
* Recharts (chart.js has been removed).
|
|
101
|
+
*
|
|
102
|
+
* Supported types: bar_chart · line_chart · pie_chart · table · product_carousel · text
|
|
103
|
+
*
|
|
104
|
+
* @example
|
|
105
|
+
* const transformation = await UITransformer.analyzeAndDecide(query, sources, llm);
|
|
106
|
+
* return <VisualizationRenderer data={transformation} />;
|
|
107
|
+
*/
|
|
108
|
+
declare function VisualizationRenderer({ data, className, primaryColor, onAddToCart, isStreaming, }: VisualizationRendererProps): react_jsx_runtime.JSX.Element;
|
|
109
|
+
|
|
110
|
+
interface UIBlock {
|
|
111
|
+
view: 'carousel' | 'table' | 'chart' | 'form' | 'actions' | string;
|
|
112
|
+
title?: string;
|
|
113
|
+
description?: string;
|
|
114
|
+
data?: any;
|
|
115
|
+
columns?: string[];
|
|
116
|
+
chartType?: 'bar' | 'line' | 'pie' | 'scatter';
|
|
117
|
+
xAxisKey?: string;
|
|
118
|
+
dataKeys?: string[];
|
|
119
|
+
colors?: string[];
|
|
120
|
+
fields?: Array<{
|
|
121
|
+
name: string;
|
|
122
|
+
type: 'text' | 'email' | 'number' | 'textarea' | 'checkbox';
|
|
123
|
+
label: string;
|
|
124
|
+
required?: boolean;
|
|
125
|
+
placeholder?: string;
|
|
126
|
+
}>;
|
|
127
|
+
submitText?: string;
|
|
128
|
+
buttons?: Array<{
|
|
129
|
+
label: string;
|
|
130
|
+
action: 'trigger_workflow' | 'open_url' | 'send_message' | string;
|
|
131
|
+
payload?: Record<string, any>;
|
|
132
|
+
}>;
|
|
133
|
+
[key: string]: any;
|
|
134
|
+
}
|
|
135
|
+
interface UIBlockRendererProps {
|
|
136
|
+
block: UIBlock | unknown;
|
|
137
|
+
customRenderers?: Record<string, (data: any) => React.ReactNode>;
|
|
138
|
+
primaryColor?: string;
|
|
139
|
+
accentColor?: string;
|
|
140
|
+
onAddToCart?: (product: Product) => void;
|
|
141
|
+
onActionTriggered?: (action: string, payload: any) => void;
|
|
142
|
+
onFormSubmit?: (formData: Record<string, any>) => void | Promise<void>;
|
|
143
|
+
isStreaming?: boolean;
|
|
144
|
+
}
|
|
145
|
+
declare function UIBlockRenderer({ block, customRenderers, primaryColor, accentColor, onAddToCart, onActionTriggered, onFormSubmit, isStreaming, }: UIBlockRendererProps): react_jsx_runtime.JSX.Element | null;
|
|
146
|
+
|
|
79
147
|
declare function useRagChat(projectId: string, options?: UseRagChatOptions): UseRagChatReturn;
|
|
80
148
|
|
|
81
149
|
interface UseProjectSettingsOptions {
|
|
@@ -98,4 +166,4 @@ declare function useProjectSettings(projectId: string, options?: UseProjectSetti
|
|
|
98
166
|
*/
|
|
99
167
|
declare function addSynonyms(customSynonyms: Record<string, string[]>): void;
|
|
100
168
|
|
|
101
|
-
export { ChatWidget, ChatWidgetProps, ChatWindow, ChatWindowProps, ClientConfig, CodeViewer, ConfigProvider, DocumentUpload, DocumentUploadProps, MessageBubble, MessageBubbleProps, ObservabilityPanel, ObservabilityTrace, ProductCard, ProductCardProps, ProductCarousel, ProductCarouselProps, ProjectChatSettings, RemoteConfig, SourceCard, SourceCardProps, type UseProjectSettingsOptions, type UseProjectSettingsReturn, UseRagChatOptions, UseRagChatReturn, addSynonyms, useConfig, useProjectSettings, useRagChat };
|
|
169
|
+
export { ChatWidget, ChatWidgetProps, ChatWindow, ChatWindowProps, ClientConfig, CodeViewer, ConfigProvider, DocumentUpload, DocumentUploadProps, MessageBubble, MessageBubbleProps, ObservabilityPanel, ObservabilityTrace, ProductCard, ProductCardProps, ProductCarousel, ProductCarouselProps, ProjectChatSettings, RemoteConfig, SourceCard, SourceCardProps, type UIBlock, UIBlockRenderer, UIDispatcher, type UseProjectSettingsOptions, type UseProjectSettingsReturn, UseRagChatOptions, UseRagChatReturn, VisualizationRenderer, addSynonyms, useConfig, useProjectSettings, useRagChat };
|