Skip to content

[Ollama] Tool Calls don't work reliably anymore #16969

@xpomul

Description

@xpomul

Bug Description:

I have noticed that in most cases, tool calls from Ollama fail.
It looks like the tool is executed correctly, but when expanding the tool call response, the following JSON is shown:

{
  "kind": "toolCall",
  "_id": "ollama_2026-02-11T09:04:08.338165Z_0",
  "_name": "getFileContent",
  "_arguments": "{\"file\":\"frontend/src\"}",
  "_finished": true,
  "_result": "{\"content\":[{\"type\":\"error\",\"data\":\"Error executing tool 'getFileContent': Tool call content for tool getFileContent not found in the response\"}]}",
  "_confirmed": {},
  "_whenFinished": {}
}

and the model then says the tool call failed and will try again (but will fail again).

Steps to Reproduce:

  1. Configure Ollama with a tool-capable model (e.g. glm-4.7-flash)
  2. Ask the Architect Agent to describe the workspace contents
  3. Inspect the tool calls in the chat by expanding them

Additional Information

  • Operating System: macOS
  • Theia Version: 1.68.200 (maybe earlier, have not tried)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugbugs found in the applicationtheia-aiissues related to TheiaAI

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions