@hashgraphonline/standards-sdk
Version:
The Hashgraph Online Standards SDK provides a complete implementation of the Hashgraph Consensus Standards (HCS), giving developers all the tools needed to build applications on Hedera.
53 lines • 2.12 kB
TypeScript
import { InboundTopicType, AgentConfiguration, AgentMetadata, AIAgentCapability, SocialPlatform } from './types';
import { FeeConfigBuilderInterface } from '../fees';
import { NetworkType } from '../utils/types';
/**
* AgentBuilder is a builder class for creating agent configurations.
* It provides a fluent interface for setting various properties of the agent.
*
* Example usage:
* ```typescript
* const agentBuilder = new AgentBuilder();
* agentBuilder.setName('My Agent');
* agentBuilder.setDescription('This is my agent');
* agentBuilder.setCapabilities([AIAgentCapability.CREATE_CONTENT]);
* agentBuilder.setModel('gpt-4o');
* agentBuilder.setCreator('John Doe');
* agentBuilder.addSocial('twitter', 'JohnDoe');
* agentBuilder.addProperty('key', 'value');
* const agentConfig = agentBuilder.build();
* ```
*
*/
export declare class AgentBuilder {
private config;
private logger;
constructor();
setName(name: string): this;
setAlias(alias: string): this;
setBio(bio: string): this;
/**
* @deprecated Use setBio instead
*/
setDescription(description: string): this;
setCapabilities(capabilities: AIAgentCapability[]): this;
/**
* @deprecated Use setType instead
*/
setAgentType(type: 'autonomous' | 'manual'): this;
setType(type: 'autonomous' | 'manual'): this;
setModel(model: string): this;
setCreator(creator: string): this;
addSocial(platform: SocialPlatform, handle: string): this;
addProperty(key: string, value: any): this;
setMetadata(metadata: AgentMetadata): this;
setProfilePicture(pfpBuffer: Buffer, pfpFileName: string): this;
setExistingProfilePicture(pfpTopicId: string): this;
setNetwork(network: NetworkType): this;
setInboundTopicType(inboundTopicType: InboundTopicType): this;
setFeeConfig(feeConfigBuilder: FeeConfigBuilderInterface): this;
setConnectionFeeConfig(feeConfigBuilder: FeeConfigBuilderInterface): this;
setExistingAccount(accountId: string, privateKey: string): this;
build(): AgentConfiguration;
}
//# sourceMappingURL=agent-builder.d.ts.map