| 
1 | 1 | # Auto-edits  | 
2 | 2 | 
 
  | 
3 |  | -<p className="subtitle"> Learn about the auto-edits......</p>  | 
 | 3 | +<p className="subtitle">Auto-edits is a feature that suggests changes while you navigate your codebase. It's the next generation of our Autocomplete feature.</p>  | 
4 | 4 | 
 
  | 
5 | 5 | <Callout type="info">Auto-edits is currently in the ........</Callout>  | 
 | 6 | + | 
 | 7 | +## Capabilities of auto-edits  | 
 | 8 | + | 
 | 9 | +- Can automatically insert and delete text  | 
 | 10 | + | 
 | 11 | +- Proposes changes by cursor placement without requiring typing  | 
 | 12 | + | 
 | 13 | +- Can modify code before and after the cursor position  | 
 | 14 | + | 
 | 15 | +- Can handle complex refactoring operations like adding parameters and unpacking functions  | 
 | 16 | + | 
 | 17 | +- Works with repetitive tasks, especially in test files  | 
 | 18 | + | 
 | 19 | +- Can propose similar changes across multiple locations based on recent edits  | 
 | 20 | + | 
 | 21 | +## Enable auto-edits  | 
 | 22 | + | 
 | 23 | +**TBD**  | 
 | 24 | + | 
 | 25 | +### Auto-edits access for Enterprise customers  | 
 | 26 | + | 
 | 27 | +Configure auto-edits on an Enterprise Sourcegraph instance...  | 
 | 28 | + | 
 | 29 | +<Callout type="note">Users with admin access can only configure auto-edits settings.</Callout>  | 
 | 30 | + | 
 | 31 | +**TBD**  | 
 | 32 | + | 
 | 33 | +It's also recommended to read the [Enabling Cody on Sourcegraph Enterprise](/cody/clients/enable-cody-enterprise) docs.  | 
 | 34 | + | 
 | 35 | +## How do auto-edits work?  | 
 | 36 | + | 
 | 37 | +The system detects potential changes based on:  | 
 | 38 | + | 
 | 39 | +- Cursor placement in the code  | 
 | 40 | + | 
 | 41 | +- Recent changes made in similar contexts  | 
 | 42 | + | 
 | 43 | +- Function usage patterns  | 
 | 44 | + | 
 | 45 | +- Common refactoring patterns  | 
 | 46 | + | 
 | 47 | +## Auto-edits vs. Autocomplete  | 
 | 48 | + | 
 | 49 | +Autocomplete:  | 
 | 50 | + | 
 | 51 | +- Requires typing to trigger suggestions  | 
 | 52 | + | 
 | 53 | +- Can only insert text, not delete  | 
 | 54 | + | 
 | 55 | +- Only proposes content after the cursor position  | 
 | 56 | + | 
 | 57 | +- Suggests on every character typed  | 
 | 58 | + | 
 | 59 | +Auto-edits:  | 
 | 60 | + | 
 | 61 | +- Works by cursor placement alone, no typing needed  | 
 | 62 | + | 
 | 63 | +- Can both insert and delete text  | 
 | 64 | + | 
 | 65 | +- Can modify code before and after the cursor position  | 
 | 66 | + | 
 | 67 | +- Proposes changes based on context and recent edits  | 
 | 68 | + | 
 | 69 | +## Auto-edits use cases  | 
 | 70 | + | 
 | 71 | +1. Function signature refactoring (adding error returns)  | 
 | 72 | + | 
 | 73 | +2. Updating function call sites after signature changes  | 
 | 74 | + | 
 | 75 | +3. Repetitive modifications in test files  | 
 | 76 | + | 
 | 77 | +4. Parameter additions and function unpacking  | 
 | 78 | + | 
 | 79 | +5. Type system updates across multiple locations  | 
 | 80 | + | 
 | 81 | +## Known limitations  | 
 | 82 | + | 
 | 83 | +- Sometimes doesn't propose all necessary changes  | 
 | 84 | + | 
 | 85 | +- May require manual deletion in some cases  | 
 | 86 | + | 
 | 87 | +- Certain changes may need to be applied manually  | 
 | 88 | + | 
 | 89 | +- Sometimes, auto-edits fail to accept completions when a user has Vim installed and is currently in Vim’s normal mode  | 
0 commit comments