agentlang
Version:
The easiest way to build the most reliable AI agents - enterprise-grade teams of AI agents that collaborate with each other and humans
21 lines • 1.01 kB
TypeScript
import { AIMessage, BaseMessage, HumanMessage, SystemMessage } from '@langchain/core/messages';
import { ChatPromptTemplate } from '@langchain/core/prompts';
export interface AgentServiceProvider {
invoke(messages: BaseMessage[], externalToolSpecs: any[] | undefined): any;
}
export declare function systemMessage(msg: string): SystemMessage;
export declare function humanMessage(msg: string): HumanMessage;
export declare function assistantMessage(msg: string): AIMessage;
export type AIResponse = {
content: string;
sysMsg: AIMessage;
};
export declare function asAIResponse(aiMsg: AIMessage): AIResponse;
export type MessageRole = 'system' | 'user' | 'assistant' | 'tool';
export type PromptTemplateEntry = {
role: MessageRole;
text: string;
};
export declare function makePromptTemplate(msgs: PromptTemplateEntry[]): ChatPromptTemplate;
export declare function realizePromptTemplate(template: ChatPromptTemplate, values: any): Promise<BaseMessage[]>;
//# sourceMappingURL=provider.d.ts.map