RAGApi class

Logical RAG service contract. Native file pickers, sandbox handles, browser File System Access handles, and backend execution remain adapter-owned; C++ consumes only serialized configuration/request/result/state/event messages.

Constructors

RAGApi(RpcClient _client)

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

clear_(ClientContext? ctx, RAGServiceState request) Future<RAGServiceState>
Clear the current logical index and return the post-clear state.
create_(ClientContext? ctx, RAGConfiguration request) Future<RAGServiceState>
Create or reconfigure the logical RAG session from registered model ids and index settings. Commons resolves model ids → on-disk paths via the global model registry; SDK callers MUST register their embedding / LLM / reranker models before invoking Create.
ingest(ClientContext? ctx, RAGIngestRequest request) Future<RAGIngestResult>
Ingest caller-provided documents into the current logical index.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
query(ClientContext? ctx, RAGQueryRequest request) Future<RAGResult>
Retrieval-augmented generation returning grounded answer text, chunks, and timing/token metrics.
Retrieval-only search. The returned RAGResult carries retrieved_chunks and request/timing fields; answer/context fields may be empty.
stats(ClientContext? ctx, RAGServiceState request) Future<RAGStatistics>
Snapshot current index statistics from the logical service state.
stream(ClientContext? ctx, RAGQueryRequest request) Future<RAGStreamEvent>
Server-streaming query events: retrieval start, chunks, context readiness, token deltas, terminal completion, and errors.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited