Closed ogabrielluiz closed 3 days ago
Comparing fix-imports-model-constants
(6ddf55a) with main
(9450f85)
⚡ 2
improvements
✅ 13
untouched benchmarks
Benchmark | main |
fix-imports-model-constants |
Change | |
---|---|---|---|---|
⚡ | test_successful_run_with_input_type_any |
324.1 ms | 232.9 ms | +39.13% |
⚡ | test_successful_run_with_input_type_text |
322.1 ms | 231.3 ms | +39.22% |
This fixes an issue when trying to import anything from langflow-base. Since we were importing packages that are not installed in langflow-base it would raise an exception.
This pull request refactors the model input constants to manage missing imports more gracefully. It introduces error handling for ImportError exceptions in the initialization of various model components, including OpenAI, Azure OpenAI, Groq, Anthropic, NVIDIA, and Amazon Bedrock. This ensures that informative error messages are provided when required packages are not installed, improving the user experience and debugging process.