Skip to content

AI Agent: tool call answers are cleared upon app close #47404

@Malix-Labs

Description

@Malix-Labs

Reproduction

  1. Install a MCP Server Extension (in my case, mcp-server-github)
  2. Go to Zed's AI Agent window
  3. Make sure you are using a profile in which a MCP server extension is enabled (in my case, write)
  4. Send a message requesting to use a MCP server tool (in my case, mcp-server-github/issue_read, using the prompt : "From MCP Server mcp-server-github, use the tool issue_read to read https://github.com/zed-industries/zed/issues/47111, and describe what you see")
  5. Assess that the MCP tool answer is visible when expanding them
    Image
  6. Close Zed
  7. Open Zed again
  8. Go back to the original thread
  9. Assess that the MCP tool answer is now broken
    Image

Behavior

Current

AI Agent tool call answers are cleared upon app close

However, I'm not sure if new messages sent after zed has been reopened have access to the MCP tool call answer (I'm guessing not), If so, I also doubt that token count is being recalculated (needs confirmation from someone who knows the internals)

Expected

AI Agent tool call answers remains upon app close

Also making messages sent after zed has been reopened include those tool call answers

Zed version and system specs

Zed: v0.217.4+stable (Zed)
OS: Linux Wayland nixos 25.11
Memory: 13.5 GiB
Architecture: x86_64
GPU: AMD Radeon Graphics (RADV RENOIR) || radv || Mesa 25.2.6

Related

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:ai/mcpModel Context Protocolarea:serializationRestoration of the editor state after a restartfrequency:commonBugs that happen for at least a third of the users across all platforms and kinds of usagemeta:awesomeexemplary issue/PR from the communitypriority:P2Average run-of-the-mill bugsstate:claimed by communitysomeone from the community has a PR in progressstate:reproducibleVerified steps to reproduce included and someone on the team managed to reproduce

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions