Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.
Go
refactor(profile): remove tools.md template
Jiayuane571bd591855
diff --git a/src/agent/profile/index.ts b/src/agent/profile/index.tsindex 5f8820153d..dcb2397648 100644--- a/src/agent/profile/index.ts+++ b/src/agent/profile/index.ts@@ -44,7 +44,6 @@ export function createAgentProfile(if (useTemplates) {profile.soul = DEFAULT_TEMPLATES.soul;profile.identity = DEFAULT_TEMPLATES.identity;- profile.tools = DEFAULT_TEMPLATES.tools;profile.memory = DEFAULT_TEMPLATES.memory;profile.bootstrap = DEFAULT_TEMPLATES.bootstrap;@@ -139,10 +138,6 @@ export class ProfileManager {parts.push(profile.soul);}- if (profile.tools) {- parts.push(profile.tools);- }-if (profile.memory) {parts.push(profile.memory);}diff --git a/src/agent/profile/storage.test.ts b/src/agent/profile/storage.test.tsindex dae0dfe099..014454d49c 100644--- a/src/agent/profile/storage.test.ts+++ b/src/agent/profile/storage.test.ts@@ -152,7 +152,6 @@ describe("storage", () => {writeFileSync(join(dir, "SOUL.md"), "Soul content");writeFileSync(join(dir, "IDENTITY.md"), "Identity content");- writeFileSync(join(dir, "TOOLS.md"), "Tools content");writeFileSync(join(dir, "MEMORY.md"), "Memory content");writeFileSync(join(dir, "BOOTSTRAP.md"), "Bootstrap content");@@ -161,7 +160,6 @@ describe("storage", () => {expect(profile.id).toBe(profileId);expect(profile.soul).toBe("Soul content");expect(profile.identity).toBe("Identity content");- expect(profile.tools).toBe("Tools content");expect(profile.memory).toBe("Memory content");expect(profile.bootstrap).toBe("Bootstrap content");});@@ -178,7 +176,6 @@ describe("storage", () => {expect(profile.id).toBe(profileId);expect(profile.soul).toBe("Soul only");expect(profile.identity).toBeUndefined();- expect(profile.tools).toBeUndefined();expect(profile.memory).toBeUndefined();expect(profile.bootstrap).toBeUndefined();});@@ -198,7 +195,6 @@ describe("storage", () => {id: "save-test",soul: "Soul data",identity: "Identity data",- tools: "Tools data",memory: "Memory data",bootstrap: "Bootstrap data",};@@ -208,7 +204,6 @@ describe("storage", () => {const dir = join(testBaseDir, profile.id);expect(readFileSync(join(dir, "SOUL.md"), "utf-8")).toBe("Soul data");expect(readFileSync(join(dir, "IDENTITY.md"), "utf-8")).toBe("Identity data");- expect(readFileSync(join(dir, "TOOLS.md"), "utf-8")).toBe("Tools data");expect(readFileSync(join(dir, "MEMORY.md"), "utf-8")).toBe("Memory data");expect(readFileSync(join(dir, "BOOTSTRAP.md"), "utf-8")).toBe("Bootstrap data");});@@ -218,7 +213,6 @@ describe("storage", () => {id: "partial-save",soul: "Soul only",identity: undefined,- tools: undefined,memory: undefined,bootstrap: undefined,};@@ -228,7 +222,6 @@ describe("storage", () => {const dir = join(testBaseDir, profile.id);expect(existsSync(join(dir, "SOUL.md"))).toBe(true);expect(existsSync(join(dir, "IDENTITY.md"))).toBe(false);- expect(existsSync(join(dir, "TOOLS.md"))).toBe(false);});it("should create profile directory if needed", () => {diff --git a/src/agent/profile/storage.ts b/src/agent/profile/storage.tsindex 6507288a10..9400472c5b 100644--- a/src/agent/profile/storage.ts+++ b/src/agent/profile/storage.ts@@ -93,7 +93,6 @@ export function loadProfile(profileId: string, options?: StorageOptions): AgentPid: profileId,soul: readProfileFile(profileId, PROFILE_FILES.soul, options),identity: readProfileFile(profileId, PROFILE_FILES.identity, options),- tools: readProfileFile(profileId, PROFILE_FILES.tools, options),memory: readProfileFile(profileId, PROFILE_FILES.memory, options),bootstrap: readProfileFile(profileId, PROFILE_FILES.bootstrap, options),config: readProfileConfig(profileId, options),@@ -102,7 +101,7 @@ export function loadProfile(profileId: string, options?: StorageOptions): AgentP/** 保存 AgentProfile(只写入非空字段) */export function saveProfile(profile: AgentProfile, options?: StorageOptions): void {- const { id, soul, identity, tools, memory, bootstrap, config } = profile;+ const { id, soul, identity, memory, bootstrap, config } = profile;if (soul !== undefined) {writeProfileFile(id, PROFILE_FILES.soul, soul, options);@@ -110,9 +109,6 @@ export function saveProfile(profile: AgentProfile, options?: StorageOptions): voif (identity !== undefined) {writeProfileFile(id, PROFILE_FILES.identity, identity, options);}- if (tools !== undefined) {- writeProfileFile(id, PROFILE_FILES.tools, tools, options);- }if (memory !== undefined) {writeProfileFile(id, PROFILE_FILES.memory, memory, options);}diff --git a/src/agent/profile/templates.ts b/src/agent/profile/templates.tsindex 5d1377f89e..9e9b59ec36 100644--- a/src/agent/profile/templates.ts+++ b/src/agent/profile/templates.ts@@ -17,40 +17,6 @@ You are a helpful AI assistant. Follow these guidelines:- Name: Assistant- Role: General-purpose AI assistant-`,-- tools: `# Tools--## File Operations-- **read**: Read file contents. Provide the file path.-- **write**: Create or overwrite a file. Use for new files only.-- **edit**: Modify an existing file. Prefer this over write for existing files.-- **glob**: Find files by pattern (e.g., '**/*.ts', 'src/**/*.{js,jsx}'). Returns paths sorted by modification time (newest first). Options: cwd, limit (default 100), ignore patterns.--## Command Execution-- **exec**: Execute shell commands. Auto-backgrounds if command takes >5s (configurable via yieldMs). Returns process ID for long-running commands.-- **process**: Manage background processes (servers, watchers, daemons).- - \`start\`: Launch a process, returns immediately with ID.- - \`status\`: Check if process is running.- - \`output\`: Read stdout/stderr.- - \`stop\`: Terminate a process.- - \`cleanup\`: Remove terminated processes from memory.--## Web Tools-- **web_fetch**: Fetch and extract content from a URL.- - Converts HTML to markdown (default) or plain text.- - Extractors: \`readability\` (smart article extraction) or \`turndown\` (full page).- - Options: extractMode, extractor, maxChars (default 50000).-- **web_search**: Search the web for information.- - Providers: \`brave\` (traditional search results) or \`perplexity\` (AI-synthesized answers with citations).- - Options: query, provider (auto-detected from API keys), count (1-10), country, freshness (brave only: pd/pw/pm/py or date range).--## Guidelines-- Use glob to discover files before reading them.-- Use process for servers (npm run dev, python server.py) instead of exec.-- Check exec output with \`process output <id>\` when auto-backgrounded.-- Use web_fetch to retrieve content from specific URLs.-- Use web_search to find information on the web when you don't know the URL.`,memory: `# Memorydiff --git a/src/agent/profile/types.ts b/src/agent/profile/types.tsindex 81db3cbca8..5dc7a7efa6 100644--- a/src/agent/profile/types.ts+++ b/src/agent/profile/types.ts@@ -8,7 +8,6 @@ import type { ToolsConfig } from "../tools/policy.js";export const PROFILE_FILES = {soul: "soul.md",identity: "identity.md",- tools: "tools.md",memory: "memory.md",bootstrap: "bootstrap.md",config: "config.json",@@ -34,8 +33,6 @@ export interface AgentProfile {soul?: string | undefined;/** Identity information - agent's name and self-awareness */identity?: string | undefined;- /** Custom tool descriptions - additional tool usage instructions */- tools?: string | undefined;/** Persistent memory - long-term knowledge base */memory?: string | undefined;/** Initial context - guidance information for each conversation */