mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-30 17:24:59 +00:00
feat: Add all_fences list to base_coder.py
This commit is contained in:
parent
f064820f06
commit
f8a1db5318
1 changed files with 11 additions and 8 deletions
|
@ -51,6 +51,16 @@ def wrap_fence(name):
|
|||
return f"<{name}>", f"</{name}>"
|
||||
|
||||
|
||||
all_fences = [
|
||||
("``" + "`", "``" + "`"),
|
||||
wrap_fence("source"),
|
||||
wrap_fence("code"),
|
||||
wrap_fence("pre"),
|
||||
wrap_fence("codeblock"),
|
||||
wrap_fence("sourcecode"),
|
||||
]
|
||||
|
||||
|
||||
@dataclass
|
||||
class ChatChunks:
|
||||
system: List = field(default_factory=list)
|
||||
|
@ -503,14 +513,7 @@ class Coder:
|
|||
self.abs_root_path_cache[key] = res
|
||||
return res
|
||||
|
||||
fences = [
|
||||
("``" + "`", "``" + "`"),
|
||||
wrap_fence("source"),
|
||||
wrap_fence("code"),
|
||||
wrap_fence("pre"),
|
||||
wrap_fence("codeblock"),
|
||||
wrap_fence("sourcecode"),
|
||||
]
|
||||
fences = all_fences
|
||||
fence = fences[0]
|
||||
|
||||
def show_pretty(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue