Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow the user to send context with approval or rejection #638

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

napter
Copy link

@napter napter commented Jan 29, 2025

Description

If there is text in the text box when approving or rejecting an action - send it to the agent as context.

Often when Roo makes an edit you may want to save it - but let the agent know that a small thing needs to be changed. Or perhaps when it is reading a file you want to allow it but give it context. It is extremely helpful to be able to approve with context. This PR lets you approve (or reject) with context.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Checklist:

  • My code follows the patterns of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation

Additional context

Related Issues

Reviewers


Important

Enhance Cline.ts to allow sending user-provided context with approval or rejection actions, with new response formatting in responses.ts.

  • Behavior:
    • askApproval in Cline.ts now handles user-provided text when approving or rejecting actions, sending it as feedback or context.
    • Supports both yesButtonClicked and noButtonClicked responses with text input.
  • Responses:
    • Adds toolApprovedWithFeedback to responses.ts to format approval messages with user context.
  • Misc:
    • Minor refactoring in Cline.ts to streamline feedback handling.

This description was created by Ellipsis for 87c7ee0. It will automatically update as commits are pushed.

Copy link

changeset-bot bot commented Jan 29, 2025

⚠️ No Changeset found

Latest commit: fe82500

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@napter napter force-pushed the approval-feedback branch from 8f611a2 to fe82500 Compare January 29, 2025 20:29
Copy link
Collaborator

@mrubens mrubens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, looks good! Do you have time to add a test for the new functionality?

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