-
Notifications
You must be signed in to change notification settings - Fork 1
Comparing changes
Open a pull request
base repository: openlayer-ai/openlayer-python
base: main
head repository: openlayer-ai/openlayer-python
compare: vini/adds-oracle-oci-tracer
- 12 commits
- 5 files changed
- 1 contributor
Commits on Aug 5, 2025
-
feat(tracing): add OCI Generative AI LLM tracing integration
- Introduced a new module `oci_tracer.py` that provides methods to trace Oracle OCI Generative AI LLMs. - Implemented tracing for both streaming and non-streaming chat completions, capturing metrics such as latency, token usage, and model parameters. - Added detailed logging for error handling and tracing steps to enhance observability. - Included comprehensive type annotations and Google-style docstrings for all functions to ensure clarity and maintainability.
Configuration menu - View commit details
-
Copy full SHA for 1e79185 - Browse repository at this point
Copy the full SHA 1e79185View commit details -
feat(tracing): add OCI Generative AI tracing examples and documentation
- Introduced a comprehensive Jupyter notebook `oci_genai_tracing.ipynb` demonstrating the integration of Oracle OCI Generative AI with Openlayer tracing, covering non-streaming and streaming chat completions, advanced parameter configurations, and error handling. - Added a simple Python script `simple_oci_example.py` for quick testing of the OCI Generative AI tracer with Openlayer integration. - Created a README file to provide an overview, prerequisites, usage instructions, and supported models for the OCI tracing examples. - Enhanced the `__init__.py` file to include the new `trace_oci_genai` function for easier access to the OCI tracing functionality. - Ensured all new files adhere to coding standards with comprehensive type annotations and Google-style docstrings for clarity and maintainability.
Configuration menu - View commit details
-
Copy full SHA for e193b76 - Browse repository at this point
Copy the full SHA e193b76View commit details -
feat(tracing): enhance OCI Generative AI tracing notebook and integra…
…tion - Updated the `oci_genai_tracing.ipynb` notebook to include new prerequisites for Openlayer setup, emphasizing the need for an Openlayer account and API key. - Improved the configuration section with detailed instructions for setting up Openlayer environment variables. - Refined the tracing logic in the `oci_tracer.py` module to handle streaming and non-streaming chat completions more effectively, including enhanced error handling and metadata extraction. - Added comprehensive logging for better observability of token usage and response metadata. - Ensured all changes adhere to coding standards with thorough type annotations and Google-style docstrings for maintainability.
Configuration menu - View commit details
-
Copy full SHA for 7eade55 - Browse repository at this point
Copy the full SHA 7eade55View commit details -
feat(tracing): enhance OCI tracing with timing and token estimation
- Added timing measurements around the OCI client chat method to capture latency for both streaming and non-streaming chat completions. - Introduced a new function `estimate_prompt_tokens_from_chat_details` to estimate prompt tokens when usage information is not provided by OCI. - Updated `handle_streaming_chat`, `handle_non_streaming_chat`, and `stream_chunks` functions to utilize the new timing parameters for improved performance tracking. - Ensured all changes are compliant with coding standards, including comprehensive type annotations and Google-style docstrings for maintainability.
Configuration menu - View commit details
-
Copy full SHA for 4794e15 - Browse repository at this point
Copy the full SHA 4794e15View commit details -
refactor(tracing): improve code formatting and consistency in oci_tra…
…cer.py - Enhanced code readability by standardizing spacing and formatting throughout the `oci_tracer.py` module. - Ensured consistent use of double quotes for string literals and improved alignment of code blocks. - Updated comments and docstrings for clarity and adherence to Google-style guidelines. - Maintained comprehensive type annotations and logging practices to support maintainability and observability.
Configuration menu - View commit details
-
Copy full SHA for a744e62 - Browse repository at this point
Copy the full SHA a744e62View commit details -
refactor(tracing): optimize chunk streaming and content extraction in…
… oci_tracer.py - Simplified the streaming statistics tracking by reducing the number of metrics and focusing on essential timing information. - Enhanced performance by introducing a new `_extract_chunk_content` function for fast content extraction from OCI chunks, minimizing overhead during processing. - Removed redundant code related to raw output handling and chunk sampling, streamlining the overall logic for better readability and maintainability. - Updated comments and docstrings to reflect the changes and ensure compliance with Google-style guidelines. - Maintained comprehensive type annotations and logging practices to support ongoing maintainability and observability.
Configuration menu - View commit details
-
Copy full SHA for 4df156a - Browse repository at this point
Copy the full SHA 4df156aView commit details -
test(integration): enhance integration tests for conditional imports
- Added support for the new `oci_tracer` in the `INTEGRATION_DEPENDENCIES` dictionary to ensure comprehensive testing of all integration modules. - Improved code formatting for better readability, including consistent use of double quotes and alignment of code blocks. - Streamlined the `run_integration_test` function by consolidating command construction for executing test scripts. - Updated print statements for clarity in test output, ensuring a more informative summary of test results. - Ensured compliance with Google-style docstrings and maintained comprehensive type annotations throughout the test suite.
Configuration menu - View commit details
-
Copy full SHA for 4e29de5 - Browse repository at this point
Copy the full SHA 4e29de5View commit details -
feat(tracing): update OCI Generative AI tracing notebook and remove e…
…xamples - Refactored the `oci_genai_tracing.ipynb` notebook to enhance clarity and organization, including a new setup section for Openlayer API key and inference pipeline ID. - Removed the `README.md` and `simple_oci_example.py` files as they are no longer needed, consolidating documentation within the notebook. - Improved the structure of the notebook by replacing raw cells with markdown cells for better readability and user experience. - Ensured all changes comply with coding standards, including comprehensive type annotations and Google-style docstrings for maintainability.
Configuration menu - View commit details
-
Copy full SHA for acb6412 - Browse repository at this point
Copy the full SHA acb6412View commit details
Commits on Aug 6, 2025
-
feat(tracing): enhance OCI tracing functionality with token estimatio…
…n options - Updated the `trace_oci_genai` function to include an optional `estimate_tokens` parameter, allowing users to control token estimation behavior when not provided by OCI responses. - Enhanced the `oci_genai_tracing.ipynb` notebook to document the new parameter and its implications for token estimation, improving user understanding and experience. - Modified the `extract_tokens_info` function to handle token estimation more robustly, returning None for token fields when estimation is disabled. - Ensured all changes comply with coding standards, including comprehensive type annotations and Google-style docstrings for maintainability.
Configuration menu - View commit details
-
Copy full SHA for cd08b3c - Browse repository at this point
Copy the full SHA cd08b3cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6a8d0e3 - Browse repository at this point
Copy the full SHA 6a8d0e3View commit details -
refactor(tracing): streamline input extraction in OCI tracer
- Updated the `extract_inputs_from_chat_details` function to convert message roles to lowercase for consistency with OpenAI format. - Removed commented-out code related to system message extraction to enhance code clarity and maintainability.
Configuration menu - View commit details
-
Copy full SHA for 9563e88 - Browse repository at this point
Copy the full SHA 9563e88View commit details -
feat(tracing): add OCI GenAI tracing function
- Updated the `__init__.py` file to include the new tracing function in the module's exports, improving accessibility for users.
Configuration menu - View commit details
-
Copy full SHA for e4a0620 - Browse repository at this point
Copy the full SHA e4a0620View commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff main...vini/adds-oracle-oci-tracer