Skip to content

AgentRunOptions

type AgentRunOptions = {
actions: Record<string, Tool>;
client: OpenAI;
itemTypes?: ItemTypeRegistry;
logger?: Logger;
model: string;
prompts: Prompt[];
systemPrompt: string;
userId?: string;
};

Defined in: agent/src/agent/agent.run.ts:35

Everything a single AgentRun needs: the model and OpenAI client to call, the system prompt, the transcript so far (prompts), the actions the model may invoke, and the services/registries used while executing them.

actions: Record<string, Tool>;

Defined in: agent/src/agent/agent.run.ts:40


client: OpenAI;

Defined in: agent/src/agent/agent.run.ts:37


optional itemTypes?: ItemTypeRegistry;

Defined in: agent/src/agent/agent.run.ts:41


optional logger?: Logger;

Defined in: agent/src/agent/agent.run.ts:43


model: string;

Defined in: agent/src/agent/agent.run.ts:38


prompts: Prompt[];

Defined in: agent/src/agent/agent.run.ts:39


systemPrompt: string;

Defined in: agent/src/agent/agent.run.ts:36


optional userId?: string;

Defined in: agent/src/agent/agent.run.ts:42