Skip to content

feat(chat): configurable interactive answer timeout - #362

Draft
FlowerRealm wants to merge 3 commits into
Stack-Cairn:mainfrom
FlowerRealm:feat/configurable-ask-timeout
Draft

feat(chat): configurable interactive answer timeout#362
FlowerRealm wants to merge 3 commits into
Stack-Cairn:mainfrom
FlowerRealm:feat/configurable-ask-timeout

Conversation

@FlowerRealm

@FlowerRealm FlowerRealm commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

What

Allow configuring the answer window shared by the AskUserQuestion card and the tool approval barsettings.system.interactiveTimeoutMinutes (minutes, default 3, preserving current behavior). A very large value (e.g. 99999) ≈ never time out.

Addresses the timeout-configuration part of #354. Notifications / taskbar flashing are out of scope (tracked separately).

How

  • New interactiveTimeoutMinutes field in SystemSettings, synced to the gateway WebUI; input added to the mirrored System Tools settings section.
  • Desktop injects the window (minutes → ms) into both tools at runtime via module-level config (setAskUserQuestionTimeoutMs / setToolApprovalTimeoutMs) — avoids threading through the 6+ tool-preview call sites.
  • Because "never" is just a large number, every deadline stays a finite timestamp: the tools always set a timer and the countdown logic is unchanged — ToolApprovalBar.tsx and gatewayToolPreview.ts end up with zero diff.
  • The tool description sent to the model is generated from the actual configured window.
image

Verification

  • agent-gui frontend: 1418 pass
  • agent-gateway web: 493 pass
  • both tsc --noEmit clean
  • mirror consistency (scripts/check-mirror.mjs): 119 files byte-identical

Make the answer window shared by the AskUserQuestion card and the tool
approval bar configurable via settings.system.interactiveTimeoutMinutes
(minutes, default 3, preserving current behavior). A very large value
(e.g. 99999) approximates never timing out. The window is injected into
both tools at runtime; every deadline stays a finite timestamp, so the
countdown logic needs no special never-handling.

Refs Stack-Cairn#354 (timeout configurability).
@github-actions

github-actions Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

PR governance checks failed — this PR has been converted to draft.

  • No linked issue: the PR body must contain Closes #123 / Fixes #123 / Resolves #123. This project requires an issue before a PR — see the contribution guidelines.
  • UI change without screenshots: this PR modifies frontend code. Please add before/after screenshots or a recording under "Screenshots / preview" in the PR body.

Fix the items above, then click Ready for review to re-run the checks.

@StackCairn
StackCairn marked this pull request as draft August 2, 2026 08:16
… a fine-grained slider

Move the interactive answer timeout off its standalone input card and into
the AskUserQuestion tool row, replacing the fixed read-only 'allow' label
with a stop-based slider. The stop table keeps 1-60 minutes fine-grained
(1,2,3,4,5,6,8,10,12,15,20,25,30,40,50,60) and jumps straight to 99999
past one hour, so the slider reads as a plain duration without exposing
any internal 'never' semantics. The tool detail copy no longer hardcodes
'3 minutes'; it now points at the adjustable slider.
Keep a single one-line comment on the stop table and drop the duplicate
block inside the render body; both mirrored files stay byte-identical.
@devil233-ui

Copy link
Copy Markdown

麻烦再检查下了
image

@FlowerRealm

Copy link
Copy Markdown
Contributor Author

太努力了, draft的pr还review

@FlowerRealm

Copy link
Copy Markdown
Contributor Author

感谢佬的review

@devil233-ui

Copy link
Copy Markdown

啊不好意思我看两天没动静以为是整得差不多了就拉下来测了下....之前没参与过和人协作,draft这些啥的也没概念
因为个人觉得这个pr基本是当前版本最紧急要优化的功能了,我本来想帮着改一下的,但是工作量非常大,只改了一部分,可惜再也等不到tibo出手了...
话说这个称呼方式难道是l站佬?(

@devil233-ui

Copy link
Copy Markdown

放个花絮
image

@FlowerRealm

Copy link
Copy Markdown
Contributor Author

我最近有事没空处理这个, 佬可以把我的分支拉下来自己干

@devil233-ui

devil233-ui commented Aug 6, 2026 via email

Copy link
Copy Markdown

@devil233-ui

Copy link
Copy Markdown
image 让ds先把当前进度确认了

@FlowerRealm

Copy link
Copy Markdown
Contributor Author

没办法接着往下, 得开个新的pr

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants