diff --git a/src/agent/create.ts b/src/agent/create.ts index a592a66..bda36d9 100644 --- a/src/agent/create.ts +++ b/src/agent/create.ts @@ -2,11 +2,11 @@ * Utilities for creating an agent on the Letta API backend **/ +import type { AgentType } from "@letta-ai/letta-client/resources/agents/agents"; import type { - AgentType, - Block, + BlockResponse, CreateBlock, -} from "@letta-ai/letta-client/resources/agents/agents"; +} from "@letta-ai/letta-client/resources/blocks/blocks"; import { settingsManager } from "../settings-manager"; import { getToolNames } from "../tools/manager"; import { getClient } from "./client"; @@ -61,7 +61,7 @@ export async function createAgent( const localSharedBlockIds = projectSettings.localSharedBlockIds; // Retrieve existing blocks (both global and local) and match them with defaults - const existingBlocks = new Map(); + const existingBlocks = new Map(); // Load global blocks (persona, human) for (const [label, blockId] of Object.entries(globalSharedBlockIds)) { diff --git a/src/agent/memory.ts b/src/agent/memory.ts index 7b67fe4..225a4dd 100644 --- a/src/agent/memory.ts +++ b/src/agent/memory.ts @@ -3,7 +3,7 @@ * Loads memory blocks from .mdx files in src/agent/prompts */ -import type { CreateBlock } from "@letta-ai/letta-client/resources/agents/agents"; +import type { CreateBlock } from "@letta-ai/letta-client/resources/blocks/blocks"; import { MEMORY_PROMPTS } from "./promptAssets"; /** diff --git a/src/cli/App.tsx b/src/cli/App.tsx index 3afd3d5..3f2d3d2 100644 --- a/src/cli/App.tsx +++ b/src/cli/App.tsx @@ -1,6 +1,9 @@ // src/cli/App.tsx -import type { MessageCreate } from "@letta-ai/letta-client/resources/agents/agents"; +import type { + AgentState, + MessageCreate, +} from "@letta-ai/letta-client/resources/agents/agents"; import type { ApprovalCreate, LettaMessageUnion, @@ -86,7 +89,7 @@ type StaticItem = id: string; snapshot: { continueSession: boolean; - agentState?: Letta.AgentState | null; + agentState?: AgentState | null; terminalWidth: number; }; } @@ -102,7 +105,7 @@ export default function App({ tokenStreaming = true, }: { agentId: string; - agentState?: Letta.AgentState | null; + agentState?: AgentState | null; loadingState?: | "assembling" | "upserting" @@ -1055,7 +1058,7 @@ export default function App({ try { // Find the selected model from models.json first (for loading message) - const { models } = await import("../model"); + const { models } = await import("../agent/model"); const selectedModel = models.find((m) => m.id === modelId); if (!selectedModel) {