Skip to content

Commit 7f3b1fa

Browse files
Update openjudge/graders/function_grader.py
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
1 parent 0546995 commit 7f3b1fa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

openjudge/graders/function_grader.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ async def aevaluate(self, **kwargs: Any) -> GraderScore | GraderRank:
106106
>>> # Example for pointwise function grader
107107
>>> def accuracy_function(query: str, response: str) -> GraderScore:
108108
... # Simple accuracy function - checks if answer contains key facts
109-
... if "Paris" in answer and "capital" in answer.lower():
109+
... if "Paris" in response and "capital" in response.lower():
110110
... return GraderScore(name=self.name,
111111
... score=1.0,
112112
... reason="Correctly identifies Paris as capital")

0 commit comments

Comments
 (0)