feat: Add UnifiedDiffSimpleCoder with simpler prompt for code edits

This commit is contained in:
Paul Gauthier (aider) 2025-04-20 11:31:55 -07:00
parent 8c3f167e8c
commit 3ca3f39f1d

View file

@ -0,0 +1,16 @@
from .udiff_coder import UnifiedDiffCoder
class UnifiedDiffSimpleCoder(UnifiedDiffCoder):
"""
A coder that uses unified diff format for code modifications.
This variant uses a simpler prompt that doesn't mention specific
diff rules like using `@@ ... @@` lines or avoiding line numbers.
"""
edit_format = "udiff-simple"
# We can inherit the prompts if they are suitable or override them here
# For now, let's assume the base UnifiedDiffPrompts are sufficient
# If specific prompts are needed for the "simple" version, they would be defined here.
# gpt_prompts = UnifiedDiffSimplePrompts()