Conversation
…ronment configurations
…e unused test functions
…and consistency in parameter formatting
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.
This pull request introduces significant updates to the handling of LLM (Large Language Model) API integrations, including a shift to using
openai_formatkeys and base URLs, removal of support for certain providers, and enhancements to configuration and testing. The changes streamline the codebase, improve clarity, and ensure proper testing of the updated functionality.Updates to LLM API Integrations:
Replaced
PROMETHEUS_OPENAI_API_KEYwithPROMETHEUS_OPENAI_FORMAT_API_KEYand addedPROMETHEUS_OPENAI_FORMAT_BASE_URLin multiple configuration files (.github/workflows/pytest_and_coverage.yml,docker-compose.yml,docker-compose.win_mac.yml,example.env) to support the new OpenAI integration format. Removed keys foropenrouteranddeepseek. [1] [2] [3] [4]Updated the
LLMServiceclass inprometheus/app/services/llm_service.pyto useopenai_format_api_keyandopenai_format_base_urlinstead of the olderopenai_api_key. Removed support foropenrouteranddeepseekmodels, simplifying theget_modelfunction. [1] [2]Configuration Improvements:
Removed unused superuser credentials (
PROMETHEUS_SUPERUSER_USERNAME,PROMETHEUS_SUPERUSER_PASSWORD,PROMETHEUS_SUPERUSER_EMAIL) from.github/workflows/pytest_and_coverage.ymlandexample.env. [1] [2]Improved organization of environment variables in
docker-compose.ymlanddocker-compose.win_mac.ymlby grouping them under relevant sections (e.g., Logging, Neo4j, Knowledge Graph, LLM model settings). [1] [2]Testing Enhancements:
Added a new script,
prometheus/script/test_llm_service.py, to manually test the LLM service's response for both base and advanced models.Updated unit tests in
tests/app/services/test_llm_service.pyto reflect the newopenai_formatkeys and base URL. Removed tests for deprecated providers (openrouter,deepseek) and unknown model handling. [1] [2] [3] [4]Dependency Updates:
initialize_servicesfunction inprometheus/app/dependencies.pyto pass the newopenai_format_api_keyandopenai_format_base_urlto theLLMService.