How to work with context in Cursor
claude-3.5-sonnet
when it’s not given enough context.claude-3.7-sonnet
) can go quite far with this strategy, and providing the right initial context will determine the trajectory.Symbol | Example | Use case | Drawback |
---|---|---|---|
@code | @LRUCachedFunction | You know which function, constant or symbol is relevant to the output you’re generating | Requires a lot of knowledge of codebase |
@file | cache.ts | You know which file should be read or edited, but not exactly where in the file | Might include a lot of irrelevant context for the task at hand depending on file size |
@folder | utils/ | Everything or majority of files in a folder is relevant | Might include a lot of irrelevant context for the task at hand |
/Generate Cursor Rules
. If you’ve had a long back and forth conversation with lots of prompting, there’s probably some useful directives or general rules that you might want to reuse later.