[PR #3081] [MERGED] warn when json format is expected but not mentioned in prompt #36930

Closed
opened 2026-04-22 21:34:38 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/3081
Author: @BruceMacD
Created: 3/12/2024
Status: Merged
Merged: 3/12/2024
Merged by: @BruceMacD

Base: mainHead: brucemacd/warn-json


📝 Commits (1)

  • 2a4cae6 warn when json format is expected but not mentioned in prompt

📊 Changes

1 file changed (+3 additions, -0 deletions)

View changed files

📝 llm/dyn_ext_server.go (+3 -0)

📄 Description

This is a complimentary PR to #3080

If format: json is specified but the prompt makes no mention of JSON log a warning. This is a lenient, rather than rejecting the request.


🔄 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/3081 **Author:** [@BruceMacD](https://github.com/BruceMacD) **Created:** 3/12/2024 **Status:** ✅ Merged **Merged:** 3/12/2024 **Merged by:** [@BruceMacD](https://github.com/BruceMacD) **Base:** `main` ← **Head:** `brucemacd/warn-json` --- ### 📝 Commits (1) - [`2a4cae6`](https://github.com/ollama/ollama/commit/2a4cae6de010b362665e0e6005409a7155865288) warn when json format is expected but not mentioned in prompt ### 📊 Changes **1 file changed** (+3 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `llm/dyn_ext_server.go` (+3 -0) </details> ### 📄 Description This is a complimentary PR to #3080 If `format: json` is specified but the prompt makes no mention of JSON log a warning. This is a lenient, rather than rejecting the request. --- <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-22 21:34:38 -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#36930