Skip to content

Commit

Permalink
Fixed typo in parse_code_blobs docstring (#155)
Browse files Browse the repository at this point in the history
Fixed typo in `parse_code_blobs` docstring
  • Loading branch information
chloefeal authored Jan 12, 2025
1 parent 320dd77 commit 5a62304
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/smolagents/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ def parse_json_blob(json_blob: str) -> Dict[str, str]:


def parse_code_blobs(code_blob: str) -> str:
"""Parses the LLM's output to get any code blob inside. Will retrun the code directly if it's code."""
"""Parses the LLM's output to get any code blob inside. Will return the code directly if it's code."""
pattern = r"```(?:py|python)?\n(.*?)\n```"
matches = re.findall(pattern, code_blob, re.DOTALL)
if len(matches) == 0:
Expand Down

0 comments on commit 5a62304

Please sign in to comment.