Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RAGAS] fix: Metric parameter validation and metric descriptors #555

Merged
merged 4 commits into from
Mar 8, 2024

Conversation

julian-risch
Copy link
Member

@julian-risch julian-risch commented Mar 7, 2024

fixes #528

  • Extends metric param validation, so that it is done by our integration framework and not Ragas

@github-actions github-actions bot added the type:documentation Improvements or additions to documentation label Mar 7, 2024
@julian-risch
Copy link
Member Author

@shadeMe now we don't distinguish required and optional parameters. name is used only for ASPECT_CRITIQUE, where it is needed.

Note that the implementation of def _init_metric(self): in deepeval and now in ragas checks that all metric init parameters provided by the user are in the list of expected metric init parameters. In addition, it checks that if the metric expects any init parameters then the user must provide at least one of those. It doesn’t check that all of them are provided by the user. So it’s not fully checking required parameters but also not checking only allowed parameters.

Here is the part of code that I am referring to: https://github.com/deepset-ai/haystack-core-integrations/pull/555/files#diff-c0c023551bfa22d8d23e1e3f6cefcae07b3819de9b9811e313126f6bae1c5a53R81

@julian-risch julian-risch marked this pull request as ready for review March 7, 2024 23:46
@julian-risch julian-risch requested a review from a team as a code owner March 7, 2024 23:46
@julian-risch julian-risch requested review from vblagoje and shadeMe and removed request for a team and vblagoje March 7, 2024 23:46
@shadeMe shadeMe merged commit 5e1d8b0 into main Mar 8, 2024
10 checks passed
@shadeMe shadeMe deleted the ragas-param-validation branch March 8, 2024 10:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integration:ragas type:documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[RAGAS] Update metric parameter validation and metric descriptors
2 participants