[OPIK-6465] [SDK] refactor(runner): retire config patterns, add prompt-usage detection in snapshot#6801
Draft
petrotiurin wants to merge 2 commits into
Draft
Conversation
…t-usage detection in snapshot Drop _CONFIGURATION_PATTERNS and the legacy `instrumentation.configuration` flag from the runner checklist, and replace them with _PROMPT_PATTERNS plus a new `instrumentation.prompts` flag. The prompt-library API (get_prompt/create_prompt and the TS getPrompt/createPrompt method calls) is now the signal we surface to the downstream consumer, matching the migration away from opik.Config-based prompt fields. Implements OPIK-6465: Migrate OllieConfig prompts and instrumentation skill to Prompt library.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Details
Replace the legacy
_CONFIGURATION_PATTERNSdetection in the runner checklist with a new prompt-library detector. The runner now surfacesinstrumentation.prompts(true when the scanned code calls.get_prompt(/.create_prompt(in Python or.getPrompt(/.createPrompt(in TS) instead of the now-unusedinstrumentation.configurationflag, matching the broader move offopik.Config-with-prompt-fields toward the Prompt library._CONFIGURATION_PATTERNSand theinstrumentation.configurationkey removed from the checklist payload._PROMPT_PATTERNSadded;instrumentation.promptsemitted in the same shape astracing/entrypoint.Change checklist
Issues
AI-WATERMARK
AI-WATERMARK: yes
Testing
cd sdks/python && python -m pytest tests/unit/runner/test_snapshot.py -x -q→ 6 passedmake precommit-sdks→ ruff/ruff-format/mypy all pass on the changed filesDocumentation
N/A — internal runner snapshot signal; downstream consumer is already provisioned for the new
promptsflag.