Create response_scoring.py
Browse files- response_scoring.py +7 -0
response_scoring.py
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
def score_response(ai_response, scenario):
|
| 2 |
+
return {
|
| 3 |
+
'accuracy': 1.0 if ai_response == scenario.expected else 0.5,
|
| 4 |
+
'tone': 1.0,
|
| 5 |
+
'quality': 1.0,
|
| 6 |
+
'cost': 0.01
|
| 7 |
+
}
|