Spaces:
Sleeping
Sleeping
Ahmet Kaan Sever
commited on
Commit
·
d866f01
1
Parent(s):
0f0ed04
F string fix
Browse files
src/deepeval/commonsense_reasoning_task.py
CHANGED
@@ -28,6 +28,8 @@ class CommonsenseReasoningTask(BaseTask):
|
|
28 |
formatted_choices = "\n".join([f"{chr(65+i)}: {choice}" for i, choice in enumerate(choices)])
|
29 |
category = row["difficulty"]
|
30 |
answer = row["answer"]
|
|
|
|
|
31 |
|
32 |
# Prints for debugging
|
33 |
print(f"Choices: {choices}")
|
@@ -51,7 +53,7 @@ class CommonsenseReasoningTask(BaseTask):
|
|
51 |
|
52 |
# Construct the prompt/message
|
53 |
instruction = ""
|
54 |
-
prompt = f"Bağlam:\n{
|
55 |
message = prompt
|
56 |
|
57 |
# Get/format answer of the model
|
|
|
28 |
formatted_choices = "\n".join([f"{chr(65+i)}: {choice}" for i, choice in enumerate(choices)])
|
29 |
category = row["difficulty"]
|
30 |
answer = row["answer"]
|
31 |
+
text = row["text"]
|
32 |
+
context = row["context"]
|
33 |
|
34 |
# Prints for debugging
|
35 |
print(f"Choices: {choices}")
|
|
|
53 |
|
54 |
# Construct the prompt/message
|
55 |
instruction = ""
|
56 |
+
prompt = f"Bağlam:\n{text}\nÖnerme:\n{context}\nSoru:{question}\nSeçenekler:\n{formatted_choices}\n{instruction}\n"
|
57 |
message = prompt
|
58 |
|
59 |
# Get/format answer of the model
|