kairon
kairon copied to clipboard
Multiple parameters/collections in prompt action.
- Gave prompt-specific hyperparameters, collection top_results, and similarity_threshold.
- Added unit and integration test cases.
- Fixed test cases.
Summary by CodeRabbit
-
New Features
- Enhanced the handling of prompts and parameters for the GPT model, including similarity and query prompts.
- Introduced new fields in the API models for improved configuration and validation of prompts.
-
Improvements
- Adjusted validation logic for various fields to ensure better data integrity and user input handling.
- Improved prompt action retrieval based on collection names, enhancing the user's ability to organize and manage prompts.
- Refined the control flow and logic for processing query and similarity prompts to deliver more accurate responses.
-
Bug Fixes
- Resolved issues with prompt validation checks, ensuring that prompts with empty collections raise appropriate exceptions.
-
Documentation
- Updated HTTP request and response structures in integration tests to reflect new and removed fields.
- Aligned unit test assertions with the latest changes in prompt action configuration and validation logic.