Skip to content

Conversation

@Saravanakumar26
Copy link
Contributor

PR Description:
This PR fixes an issue in the Retrieval page where the "Only Need Context" and "Only Need Prompt" checkboxes could both be selected at the same time, leading to incorrect or confusing response behavior.

Changes Made
• Updated checkbox logic in QuerySettings:
o Selecting "Only Need Context" automatically disables "Only Need Prompt".
o Selecting "Only Need Prompt" automatically disables "Only Need Context".
• Removed redundant onCheckedChange handlers and consolidated into a single handler for each checkbox.
• Ensured consistent response behavior:
o Only Need Context → returns only the context.
o Only Need Prompt → returns prompt with context included, without separating context.

Impact
• Prevents conflicting selections on the Retrieval page.
• Simplifies user interaction with clear and predictable behavior.
• Fixes previously confusing responses when both checkboxes were active.

Checklist
• Changes tested locally
• Code reviewed

@danielaskdd danielaskdd merged commit f9b69ac into HKUDS:main Sep 19, 2025
@danielaskdd
Copy link
Collaborator

Thanks for sharing.

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