@genkit-ai/core
Version:
Genkit AI framework core libraries.
68 lines (64 loc) • 1.92 kB
TypeScript
import { a4 as Registry } from './action-BkZz5LDA.js';
import 'json-schema';
import 'zod';
import './context.js';
import './statusTypes.js';
import 'dotprompt';
import 'ajv';
/**
* Copyright 2024 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
interface ReflectionServerV2Options {
configuredEnvs?: string[];
name?: string;
url: string;
}
declare class ReflectionServerV2 {
private registry;
private options;
private ws;
private url;
private index;
private activeActions;
private reconnectCount;
private isStopped;
private reconnectTimeout;
private baseDelayMs;
private maxDelayMs;
private pendingRequests;
private requestIdCounter;
constructor(registry: Registry, options: ReflectionServerV2Options);
start(): Promise<void>;
private connect;
private scheduleReconnect;
stop(): Promise<void>;
private send;
private sendResponse;
private sendError;
private sendNotification;
private sendRequest;
private register;
get runtimeId(): string;
private handleResponse;
private handleRequest;
private handleListActions;
private handleListValues;
private handleRunAction;
private handleConfigure;
private handleCancelAction;
private handleSendInputStreamChunk;
private handleEndInputStream;
}
export { ReflectionServerV2, type ReflectionServerV2Options };