Skip to content

Conversation

CakeCrusher
Copy link
Contributor

@CakeCrusher CakeCrusher commented May 29, 2025

Video showing it (skip the intro):
https://www.youtube.com/watch?v=Bx1oJBlRfTY

Added Mistral OCR instrumentation for the .process method

  • Followed existing mixin patterns to destructure the instrumentation into creating a _ocr_wrapper.py leveraging new extraction functions from _request_attributes_extractor.py and _response_attributes_extractor.py.
  • Added tests verifying the correct span item are extracted from calling .process
  • Added a tutorial showcasing it (with a lot of print statements)
  • Ensured that the new instrumentation is backwards compatible

Note: I am aware its a lot of code, much of it is generated, but its following the current mixin pattern of instrumentation as used elsewhere in the repo. Also I think this feature is pretty horizontal so the added complexity I would not expect to contaminate the rest of the project.

@CakeCrusher CakeCrusher requested a review from a team as a code owner May 29, 2025 04:10
@dosubot dosubot bot added the size:XL This PR changes 500-999 lines, ignoring generated files. label May 29, 2025
@CakeCrusher CakeCrusher force-pushed the mistral_ocr_instrumentation branch from 689aba6 to 90fa7ed Compare May 29, 2025 04:14
@CakeCrusher CakeCrusher force-pushed the mistral_ocr_instrumentation branch from 0c84392 to 365fff2 Compare May 29, 2025 04:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size:XL This PR changes 500-999 lines, ignoring generated files.
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

1 participant