[PR #10872] [MERGED] tools: relax JSON parse constraints for tool calling #60087

Closed
opened 2026-04-29 15:00:35 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/10872
Author: @ParthSareen
Created: 5/27/2025
Status: Merged
Merged: 5/27/2025
Merged by: @ParthSareen

Base: mainHead: parth/tools-relax-tool-parsing-json


📝 Commits (2)

  • 79ee279 tools: relax tool constraints for tool calling
  • ab5f9c4 tools: add flush test case

📊 Changes

2 files changed (+54 additions, -35 deletions)

View changed files

📝 tools/tools.go (+18 -28)
📝 tools/tools_test.go (+36 -7)

📄 Description

Enables capturing JSON tools for regardless of where the model outputs the JSON to enter the tool calling mode.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ollama/ollama/pull/10872 **Author:** [@ParthSareen](https://github.com/ParthSareen) **Created:** 5/27/2025 **Status:** ✅ Merged **Merged:** 5/27/2025 **Merged by:** [@ParthSareen](https://github.com/ParthSareen) **Base:** `main` ← **Head:** `parth/tools-relax-tool-parsing-json` --- ### 📝 Commits (2) - [`79ee279`](https://github.com/ollama/ollama/commit/79ee2799b791a55cac27d3712a1eb55f2b4eabc5) tools: relax tool constraints for tool calling - [`ab5f9c4`](https://github.com/ollama/ollama/commit/ab5f9c4b84afa8e4e16beeddfa39c34be68f56fe) tools: add flush test case ### 📊 Changes **2 files changed** (+54 additions, -35 deletions) <details> <summary>View changed files</summary> 📝 `tools/tools.go` (+18 -28) 📝 `tools/tools_test.go` (+36 -7) </details> ### 📄 Description Enables capturing JSON tools for regardless of where the model outputs the JSON to enter the tool calling mode. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-29 15:00:35 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#60087