Why cursor create duplicate file structure

it creates duplicate file structures when developing a project it can’t identify existing file structure and hierarchy

Hey, have you got a screenshot of what is going wrong here?

I’m having the same issue. Very frustrating

This usually happens when the AI gets confused and outputs incorrectly. Try starting a new composer session which should fix it. If you’re still seeing duplicate files after that, drop another message here

same issue as op, creating new composer only reset the agent or normal ability to create new duplicates. especially with sonnet that seem to lose context as fast as my dead great grandfather. further more normal composer has extremly limited context, for some models, none at all. "This usually happens when the AI gets confused and outputs incorrectly. " This could be funny if the model was not composing over an error and messing up the whole project.

Could you let me know if you’re working on a local machine, or using SSH/dev containers/workspaces? This will help narrow down what’s causing the duplicate file issues

Local mechine

Got it - can you try clearing your codebase index, which should hopefully help with the duplicate file issue.

Click the gear icon (settings), go to AI settings, and hit “Clear Index”. After that’s done, restart Cursor and see if that helps!

Still have a problem

Could you check which AI model you’re using in Settings > AI Settings? Different models can behave differently, and knowing which one you’re working with will help us get to the bottom of this. Also, do you have any specific AI rules or settings configured?

I get this issue too. I got deep into a project with it and have so many duplicate files now that it’s better to start agian from 0. Don’t know what to do and how to avoid it in the future.

Same issue, bad product