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

Fixes argument order for custom code evaluator #1690

Merged
merged 1 commit into from
May 21, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion agenta-backend/agenta_backend/services/security/sandbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def execute_code_safely(

# Call the evaluation function, extract the result if it exists
# and is a float between 0 and 1
result = environment["evaluate"](app_params, inputs, correct_answer, output)
result = environment["evaluate"](app_params, inputs, output, correct_answer)
if isinstance(result, float) and 0 <= result <= 1:
return result
return None
Loading