Skip to content

Commit 024928f

Browse files
committed
docs: add protected file patterns and nudge reminders to README
1 parent dabd7ba commit 024928f

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,35 @@ DCP uses its own config file:
130130

131131
When enabled, turn protection prevents tool outputs from being pruned for a configurable number of message turns. This gives the AI time to reference recent tool outputs before they become prunable. Applies to both `discard` and `extract` tools, as well as automatic strategies.
132132

133+
### Protected File Patterns
134+
135+
`protectedFilePatterns` is a list of glob patterns matched against `tool parameters.filePath` (e.g. `read`/`write`/`edit` calls).
136+
137+
When a tool call matches a protected pattern:
138+
139+
- It will not appear in the `<prunable-tools>` list.
140+
- `discard` / `extract` will reject attempts to prune it.
141+
- Automatic strategies (deduplication, supersede-writes, purge-errors) will not prune it.
142+
143+
Supported glob tokens:
144+
145+
- `*` matches any characters except `/`
146+
- `?` matches a single character except `/`
147+
- `**` matches across `/` (e.g. `**/*.ts`)
148+
149+
Examples:
150+
151+
- `**/*.env` (protect env files)
152+
- `**/.opencode/**` (protect project opencode configs)
153+
- `**/credentials.*` (protect credential files)
154+
155+
### Nudge Reminders
156+
157+
When `tools.settings.nudgeEnabled` is true, DCP injects a short “use prune tools” reminder into the `<prunable-tools>` message:
158+
159+
- Every `tools.settings.nudgeFrequency` tool results.
160+
- Also after a `todowrite` call transitions an existing todo to `status: "completed"`.
161+
133162
### Protected Tools
134163

135164
By default, these tools are always protected from pruning across all strategies:

0 commit comments

Comments
 (0)