Skip to content

Conversation

thiagohora
Copy link
Contributor

Implements the ability to restore previous prompt versions by creating new versions with content from selected versions.

Backend changes:

  • Add restorePromptVersion method to PromptService
  • Add POST /prompts/{promptId}/versions/{versionId}/restore endpoint
  • Add comprehensive integration test for restore functionality

Frontend changes:

  • Add useRestorePromptVersionMutation API hook
  • Add restore button with Undo-2 icon to CommitHistory component
  • Add confirmation modal for restore action
  • Add tooltip with 'Restore this version' message

Implements issue-2232: Add revert to previous version feature for prompts

Details

Change checklist

  • User facing
  • Documentation update

Issues

  • Resolves #
  • OPIK-

Testing

Documentation

Implements the ability to restore previous prompt versions by creating new versions with content from selected versions.

Backend changes:
- Add restorePromptVersion method to PromptService
- Add POST /prompts/{promptId}/versions/{versionId}/restore endpoint
- Add comprehensive integration test for restore functionality

Frontend changes:
- Add useRestorePromptVersionMutation API hook
- Add restore button with Undo-2 icon to CommitHistory component
- Add confirmation modal for restore action
- Add tooltip with 'Restore this version' message

Implements issue-2232: Add revert to previous version feature for prompts
Copy link
Contributor

📋 PR Linter Failed

Incomplete Details Section. The ## Details section cannot be empty.


Incomplete Issues Section. You must reference at least one GitHub issue (#xxxx) or Jira ticket (OPIK-xxxx) under the ## Issues section.

Copy link
Contributor

Backend Tests Results

4 642 tests   4 638 ✅  38m 48s ⏱️
  197 suites      4 💤
  197 files        0 ❌

Results for commit d08e40c.

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.

1 participant