-
Notifications
You must be signed in to change notification settings - Fork 1.2k
[OPIK-1896] [SDK] Opik Optimizer CLI and Notebook Formatting Fix #3900
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR improves Rich formatting handling in the Opik optimizer SDK by preserving metadata and formatting when prefixing panels, and enabling proper Jupyter detection for console rendering. The changes ensure hyperlinks and Rich formatting survive in both terminal and notebook environments.
- Replaces capture/replay prefixing mechanism with a Rich-aware wrapper class
- Removes forced
is_jupyter=Falsesetting to respect Jupyter environment detection - Simplifies the console creation logic
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sdks/python/src/opik/configurator/interactive_helpers.py
contains _in_jupter_environment() that returns True/False
|
@vincentkoc I'll test and merge this tonight |
jverre
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.

Details
OPIK-1896): Replace the capture/replay prefixing inreporting_utils.display_messageswith a Rich-aware wrapper so hyperlinks and formatting survive in terminals and notebooks.OPIK-1991): Stop forcingConsole(is_jupyter=False)so Colab/Jupyter render real Rich links for optimizer reporting output.Change checklist
Issues
Testing
See example

Documentation
n.a