I occasionally use the Agent to do refactoring. First times I tried it, it hallucinated and introduced new bugs (on features that used to work). It took some time to recover and in some cases I had to bring back a complete older version of the code base. Lately I tried a different approach, I told the Agent to copy the files it planned to refactor to a subdirectory (which it has access to) and then do the refactoring (only one refactor at the time). Now, if there is a regression, the Agent can look the working code and figure. I am not really sure but it at least “feels” like it worked better.
Related topics
Topic | Replies | Views | Activity | |
---|---|---|---|---|
Refactor mode for Agent | 5 | 330 | March 8, 2025 | |
Automated Move to file Refactoring | 2 | 767 | September 20, 2024 | |
Agent The agent mode sometimes doesn't work well | 0 | 53 | January 17, 2025 | |
Refactoring with Composer | 1 | 126 | February 1, 2025 | |
Refactoring workflow for 200-300 lines of code | 1 | 1531 | April 1, 2024 |