Add Tool Call Recurse Limit slider to Chat Completion settings (#5518)

* feat: add Tool Call Recurse Limit slider to Chat/Message Handling settings

Agent-Logs-Url: https://github.com/SillyTavern/SillyTavern/sessions/ecbde89f-8f4d-4e91-9189-a998d12ca76b

Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>

* feat: move tool call recurse limit to openai_settings under Chat Completion settings

Agent-Logs-Url: https://github.com/SillyTavern/SillyTavern/sessions/132e4c28-9564-47cd-92c1-e8ab50d88905

Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>

* refactor: use CSS :has() selector instead of JS toggle for tool_call_recurse_limit_block visibility

Agent-Logs-Url: https://github.com/SillyTavern/SillyTavern/sessions/c562deb5-05ce-4ebf-84a0-9eeea9d24433

Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>

* fix: wrap tool_call_recurse_limit_block in range-block for correct layout

Agent-Logs-Url: https://github.com/SillyTavern/SillyTavern/sessions/4d25a367-ac12-4e54-83b0-1543eb6f370a

Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>

* fix: data-i18n attribute

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Cohee1207 <18619528+Cohee1207@users.noreply.github.com>
This commit is contained in:
Copilot
2026-04-25 21:05:39 +03:00
committed by GitHub
parent 0a493cad89
commit 7948886c1d
4 changed files with 28 additions and 14 deletions
+14
View File
@@ -2011,6 +2011,20 @@
<span data-i18n="enable_functions_desc_3">Can be utilized by various extensions to provide additional functionality.</span>
<strong data-i18n="enable_functions_desc_4">Not supported when Prompt Post-Processing with "no tools" is used!</strong>
</div>
<div id="tool_call_recurse_limit_block" class="range-block wide100p">
<div class="range-block-title">
<small data-i18n="Tool Call Recurse Limit">Tool Call Recurse Limit</small>
<div class="fa-solid fa-circle-info opacity50p margin5" data-i18n="[title]Maximum number of tool call recursion steps per generation." title="Maximum number of tool call recursion steps per generation."></div>
</div>
<div class="range-block-range-and-counter">
<div class="range-block-range">
<input type="range" id="tool_call_recurse_limit" name="tool_call_recurse_limit" min="1" max="50" step="1">
</div>
<div class="range-block-counter">
<input type="number" min="1" max="50" step="1" data-for="tool_call_recurse_limit" id="tool_call_recurse_limit_counter">
</div>
</div>
</div>
</div>
<div class="range-block" data-source="openrouter,custom">
<div class="flex-container flexFlowColumn wide100p textAlignCenter marginTop10">