@hashgraphonline/conversational-agent
Version:
Hashgraph Online conversational AI agent implementing HCS-10 communication, HCS-2 registries, and content inscription on Hedera
21 lines (19 loc) • 625 B
text/typescript
import { BaseAgent, type HederaAgentConfiguration } from './base-agent';
import { LangChainAgent } from './langchain-agent';
export function createAgent(
config: HederaAgentConfiguration & {
framework?: 'langchain' | 'vercel' | 'baml';
}
): BaseAgent {
const framework = config.framework || 'langchain';
switch (framework) {
case 'langchain':
return new LangChainAgent(config);
case 'vercel':
throw new Error('Vercel AI SDK support coming soon');
case 'baml':
throw new Error('BAML support coming soon');
default:
throw new Error(`Unknown framework: ${framework}`);
}
}