mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-31 09:44:59 +00:00
style: Apply linter formatting to models.py
This commit is contained in:
parent
c0c960ec2e
commit
3d666d9929
1 changed files with 2 additions and 2 deletions
|
@ -616,13 +616,13 @@ class Model(ModelSettings):
|
|||
# Try to match the complete tag pattern first
|
||||
pattern = f"<{self.remove_reasoning}>.*?</{self.remove_reasoning}>"
|
||||
res = re.sub(pattern, "", res, flags=re.DOTALL).strip()
|
||||
|
||||
|
||||
# If closing tag exists but opening tag might be missing, remove everything before closing tag
|
||||
closing_tag = f"</{self.remove_reasoning}>"
|
||||
if closing_tag in res:
|
||||
parts = res.split(closing_tag, 1)
|
||||
res = parts[1].strip() if len(parts) > 1 else res
|
||||
|
||||
|
||||
return res
|
||||
|
||||
def simple_send_with_retries(self, messages):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue