Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inefficient file deletion #3071

Open
NikitaKurpas opened this issue Jan 30, 2025 · 0 comments
Open

Inefficient file deletion #3071

NikitaKurpas opened this issue Jan 30, 2025 · 0 comments

Comments

@NikitaKurpas
Copy link

Issue

Hey!
First of all, amazing tool—I love using it! Thank you!

During a major refactor, I noticed some inefficient behavior in the model. When moving a large chunk of logic from a file (e.g., ai.py) to other files, it then attempted to delete ai.py. However, instead of simply generating an rm command (or something similar) with the filename, it output an entire search-replace block, where the SEARCH section contained the file’s full contents, and the REPLACE section was empty.

Since the file itself was large, this approach seemed unnecessarily wasteful just to delete it.

<<<<<<< SEARCH
3k tokens worth of code
=======
>>>>>>> REPLACE

Version and model info

Aider v0.72.3
Main model: claude-3-5-sonnet-20241022 with diff edit format, prompt cache, infinite output
Weak model: claude-3-5-haiku-20241022
Git repo: .git with 8 files
Repo-map: using 4096 tokens, files refresh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant