chore: Clean up system prompts directory [LET-7937] (#1378)
This commit is contained in:
@@ -3,8 +3,8 @@ import { getClient } from "../../agent/client";
|
||||
import { createAgent } from "../../agent/create";
|
||||
import { updateAgentSystemPromptMemfs } from "../../agent/modify";
|
||||
import {
|
||||
SYSTEM_PROMPT_BLOCKS_ADDON,
|
||||
SYSTEM_PROMPT_MEMFS_ADDON,
|
||||
SYSTEM_PROMPT_MEMORY_ADDON,
|
||||
} from "../../agent/promptAssets";
|
||||
|
||||
const describeIntegration = process.env.LETTA_API_KEY
|
||||
@@ -72,7 +72,7 @@ describeIntegration("memory prompt integration", () => {
|
||||
false,
|
||||
);
|
||||
expect(disable.success).toBe(true);
|
||||
const expectedStandard = expectedPrompt(base, SYSTEM_PROMPT_MEMORY_ADDON);
|
||||
const expectedStandard = expectedPrompt(base, SYSTEM_PROMPT_BLOCKS_ADDON);
|
||||
fetched = await client.agents.retrieve(created.agent.id);
|
||||
expect(fetched.system).toBe(expectedStandard);
|
||||
expect(fetched.system).not.toContain("## Memory layout");
|
||||
|
||||
@@ -3,8 +3,8 @@ import { describe, expect, test } from "bun:test";
|
||||
import {
|
||||
buildSystemPrompt,
|
||||
isKnownPreset,
|
||||
SYSTEM_PROMPT_BLOCKS_ADDON,
|
||||
SYSTEM_PROMPT_MEMFS_ADDON,
|
||||
SYSTEM_PROMPT_MEMORY_ADDON,
|
||||
shouldRecommendDefaultPrompt,
|
||||
swapMemoryAddon,
|
||||
} from "../../agent/promptAssets";
|
||||
@@ -69,7 +69,7 @@ describe("buildSystemPrompt", () => {
|
||||
describe("swapMemoryAddon", () => {
|
||||
test("swaps standard to memfs", () => {
|
||||
const base = "You are a test agent.";
|
||||
const standard = `${base}\n\n${SYSTEM_PROMPT_MEMORY_ADDON.trimStart()}`;
|
||||
const standard = `${base}\n\n${SYSTEM_PROMPT_BLOCKS_ADDON.trimStart()}`;
|
||||
|
||||
const result = swapMemoryAddon(standard, "memfs");
|
||||
|
||||
@@ -96,7 +96,7 @@ describe("swapMemoryAddon", () => {
|
||||
|
||||
test("handles duplicate addons", () => {
|
||||
const base = "You are a test agent.";
|
||||
const doubled = `${base}\n\n${SYSTEM_PROMPT_MEMORY_ADDON}\n\n${SYSTEM_PROMPT_MEMORY_ADDON}`;
|
||||
const doubled = `${base}\n\n${SYSTEM_PROMPT_BLOCKS_ADDON}\n\n${SYSTEM_PROMPT_BLOCKS_ADDON}`;
|
||||
|
||||
const result = swapMemoryAddon(doubled, "memfs");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user