@xynehq/jaf
Version:
Juspay Agent Framework - A purely functional agent framework with immutable state and composable tools
41 lines • 1.38 kB
TypeScript
/**
* JAF ADK Layer - LLM Service Bridge
*
* Bridges ADK types to Core ModelProvider interface following functional patterns
*/
import { Agent, Content, Session, FunctionCall } from '../types.js';
export interface AdkLLMServiceConfig {
provider: 'litellm' | 'openai' | 'anthropic' | 'google';
baseUrl?: string;
apiKey?: string;
defaultModel?: string;
}
export interface AdkLLMResponse {
content: Content;
functionCalls: FunctionCall[];
metadata: {
model: string;
tokensUsed?: number;
finishReason?: string;
};
}
export interface AdkLLMStreamChunk {
delta: string;
functionCall?: Partial<FunctionCall>;
isDone: boolean;
}
export type AdkLLMService = {
generateResponse: (agent: Agent, session: Session, message: Content, requestConfig?: {
modelOverride?: string;
temperature?: number;
maxTokens?: number;
}) => Promise<AdkLLMResponse>;
generateStreamingResponse: (agent: Agent, session: Session, message: Content, requestConfig?: {
modelOverride?: string;
temperature?: number;
maxTokens?: number;
}) => AsyncGenerator<AdkLLMStreamChunk>;
};
export declare const createAdkLLMService: (config: AdkLLMServiceConfig) => AdkLLMService;
export declare const createDefaultAdkLLMService: () => AdkLLMService;
//# sourceMappingURL=llm-service.d.ts.map