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

Enabling Plan Edits in Copilot #1386

Merged
merged 29 commits into from
Jun 12, 2023
Merged

Conversation

teresaqhoang
Copy link
Contributor

@teresaqhoang teresaqhoang commented Jun 8, 2023

Motivation and Context

This PR enables user to edit a plan before approving or rejecting it:

  • User can edit any of the input value fields
  • User can delete step(s) (If SequentialPlanner is enabled). Deletion is disabled when there is only one step.

When plan is returned to the Kernel, the chat message will be updated in the history repository to reflect the new plan state.

Description

This PR also contains optimizations for methods handling user actions on proposed plan and plan schema changes to enable the above.

Chat History will also now reflect any actions the user took on the plan.

Input Edit Mode:
image

Editing Action Plan (inputs only):
UserPlanEdits

Editing SequentialPlanner (inputs and deleting step):
SequentialPlannerEditsExample

Added 'NoOp' Plan state, where proposedPlan becomes unactionable if app state changes before user approves or rejects the plan. Potential reasons for unstable state: required plug-in no longer enabled, access permissions changed, etc.
image

Note: there's some hallucinations with SequentialPlanner, but planner default is Action. SequentialPlanner stabilizations will continue in another PR

Contribution Checklist

@teresaqhoang teresaqhoang added the PR: ready for review All feedback addressed, ready for reviews label Jun 8, 2023
@teresaqhoang teresaqhoang changed the title Enabling Plan Edits Enabling Plan Edits in Copilot Jun 9, 2023
@teresaqhoang teresaqhoang added PR: ready to merge PR has been approved by all reviewers, and is ready to merge. and removed PR: ready for review All feedback addressed, ready for reviews labels Jun 12, 2023
@dehoward dehoward added PR: feedback to address Waiting for PR owner to address comments/questions and removed PR: ready to merge PR has been approved by all reviewers, and is ready to merge. labels Jun 12, 2023
@teresaqhoang teresaqhoang added PR: ready to merge PR has been approved by all reviewers, and is ready to merge. and removed PR: feedback to address Waiting for PR owner to address comments/questions labels Jun 12, 2023
dehoward
dehoward previously approved these changes Jun 12, 2023
@teresaqhoang teresaqhoang dismissed stale reviews from TaoChenOSU and dehoward via e92da76 June 12, 2023 18:52
TaoChenOSU
TaoChenOSU previously approved these changes Jun 12, 2023
@adrianwyatt adrianwyatt enabled auto-merge (squash) June 12, 2023 19:02
@adrianwyatt adrianwyatt merged commit f175d03 into microsoft:main Jun 12, 2023
16 checks passed
@teresaqhoang teresaqhoang deleted the plan-edits branch June 16, 2023 16:54
shawncal pushed a commit to shawncal/semantic-kernel that referenced this pull request Jul 6, 2023
### Motivation and Context
This PR enables user to edit a plan before approving or rejecting it:
- User can edit any of the input value fields
- User can delete step(s) (If SequentialPlanner is enabled). Deletion is
disabled when there is only one step.

When plan is returned to the Kernel, the chat message will be updated in
the history repository to reflect the new plan state.

### Description
This PR also contains optimizations for methods handling user actions on
proposed plan and plan schema changes to enable the above.

Chat History will also now reflect any actions the user took on the
plan.

Input Edit Mode:
<img width="665" alt="image"
src="https://github.com/microsoft/semantic-kernel/assets/125500434/31b7a5b5-9ca0-432a-bde1-3141e0e8e76f">

Editing Action Plan (inputs only):

![UserPlanEdits](https://github.com/microsoft/semantic-kernel/assets/125500434/66b8c022-dcaf-469f-9426-928fafac4742)

Editing SequentialPlanner (inputs and deleting step):

![SequentialPlannerEditsExample](https://github.com/microsoft/semantic-kernel/assets/125500434/0ae757b5-7767-46b0-977c-2f69dae133ba)

Added 'NoOp' Plan state, where proposedPlan becomes unactionable if app
state changes before user approves or rejects the plan. Potential
reasons for unstable state: required plug-in no longer enabled, access
permissions changed, etc.

![image](https://github.com/microsoft/semantic-kernel/assets/125500434/2af07534-4560-4e11-a8fc-4804d85a4717)


> Note: there's some hallucinations with SequentialPlanner, but planner
default is Action. SequentialPlanner stabilizations will continue in
another PR
golden-aries pushed a commit to golden-aries/semantic-kernel that referenced this pull request Oct 10, 2023
### Motivation and Context
This PR enables user to edit a plan before approving or rejecting it:
- User can edit any of the input value fields
- User can delete step(s) (If SequentialPlanner is enabled). Deletion is
disabled when there is only one step.

When plan is returned to the Kernel, the chat message will be updated in
the history repository to reflect the new plan state.

### Description
This PR also contains optimizations for methods handling user actions on
proposed plan and plan schema changes to enable the above.

Chat History will also now reflect any actions the user took on the
plan.

Input Edit Mode:
<img width="665" alt="image"
src="https://github.com/microsoft/semantic-kernel/assets/125500434/31b7a5b5-9ca0-432a-bde1-3141e0e8e76f">

Editing Action Plan (inputs only):

![UserPlanEdits](https://github.com/microsoft/semantic-kernel/assets/125500434/66b8c022-dcaf-469f-9426-928fafac4742)

Editing SequentialPlanner (inputs and deleting step):

![SequentialPlannerEditsExample](https://github.com/microsoft/semantic-kernel/assets/125500434/0ae757b5-7767-46b0-977c-2f69dae133ba)

Added 'NoOp' Plan state, where proposedPlan becomes unactionable if app
state changes before user approves or rejects the plan. Potential
reasons for unstable state: required plug-in no longer enabled, access
permissions changed, etc.

![image](https://github.com/microsoft/semantic-kernel/assets/125500434/2af07534-4560-4e11-a8fc-4804d85a4717)


> Note: there's some hallucinations with SequentialPlanner, but planner
default is Action. SequentialPlanner stabilizations will continue in
another PR
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: ready to merge PR has been approved by all reviewers, and is ready to merge.
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

5 participants