Skip to content

Commit d5efccf

Browse files
authored
update LCB prompt, fix newlines (#645)
1 parent 2c3fdf3 commit d5efccf

File tree

1 file changed

+2
-2
lines changed
  • src/lighteval/tasks/extended/lcb

1 file changed

+2
-2
lines changed

src/lighteval/tasks/extended/lcb/main.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,10 @@ def prepare_prompt(line: dict[str, Any]) -> str:
4949
query = "You will be given a question (problem specification) and will generate a correct Python program that matches the specification and passes all tests.\n\n"
5050
query += f"Question: {line['question_content']}\n\n"
5151
if starter_code := line.get("starter_code", None):
52-
query += "You will use the following starter code to write the solution to the problem and enclose your code within delimiters."
52+
query += "You will use the following starter code to write the solution to the problem and enclose your code within delimiters.\n"
5353
query += f"```python\n{starter_code}\n```\n\n"
5454
else:
55-
query += "Read the inputs from stdin solve the problem and write the answer to stdout (do not directly test on the sample inputs). Enclose your code within delimiters as follows."
55+
query += "Read the inputs from stdin solve the problem and write the answer to stdout (do not directly test on the sample inputs). Enclose your code within delimiters as follows. Ensure that when the python program runs, it reads the inputs, runs the algorithm and writes output to STDOUT.\n"
5656
query += "```python\n# YOUR CODE HERE\n```\n\n"
5757
return query
5858

0 commit comments

Comments
 (0)