{"version":"2.1.334","anchor":"compaction-now-tracks-files-it-named-and-renames-them-again","canonical_anchor":"compaction-now-tracks-files-it-named-and-renames-them-again","heading":"Compaction now names files by path and tracks them afterwards","tier":"notice","area":"Compaction","scope":"individual","heads_up":true,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.334\/e\/compaction-now-tracks-files-it-named-and-renames-them-again","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.334","markdown":"### Compaction now names files by path and tracks them afterwards\n\nAfter compaction Claude Code can point to files by path instead of re-reading them, and tracks those files to avoid stale-edit errors\n\n**What**\n\nCompaction is when Claude Code summarises a long conversation to free up room, for example with `\/compact`. Claude Code has changed what it does with files the conversation had open:\n\n- When a check is on, compaction now refers to files by path only (`pathOnly`, `namesFile`) instead of re-reading them up to a token limit and attaching their content. Files that were already named are named again, and large files are marked as content not in the model's context (`contentNotInModelContext`).\n\n- The record of which files Claude has read now keeps a list of files named by compaction (`namedByCompactionPathList`, `namedByCompaction`) and a set of files to name again (`nameAgain`, `takeFilesToNameAgain`). These survive a clear of that record when other entries are kept, and are carried over when it is copied. Before, only files named elsewhere were carried over.\n\n- Reads made before compaction can be kept for comparison only (`readsBeforeCompactionToCompareOnly`). Before, there was a single list of reads from before compaction.\n\n- The check that stops Claude writing to a file it has not fully read now takes compaction-named files into account through `mayWriteWithoutFullRead`.\n\n**Why**\n\nAfter compaction, the model may see a file's path instead of its content, so it reads less back in. Claude may also hit fewer spurious \"file changed\" errors, and may not need a full re-read before editing a file the summary names.\n\n- Area: Compaction\n- Tier: You'll notice\n- Useful: 3\/5\n- Signal: 2\/5\n- Scope: individual\n- Heads-up: yes"}