DeepSeek Harness Spill Files: Disk Budget and Cleanup
Spill files are not temporary junk; they are the official home for full results that model context cannot hold. DeepSeek Harness spills content beyond the visible limit and returns a locator (source). That is why cleanup must check references before deleting.
DeepSeek Harness: Three producers
Spill usually appears in three places, each with a different growth curve. Compare (source):
| Producer | Trigger | Capacity pattern |
|---|---|---|
| Tool output over limit | One result exceeds the visible cap | Tied to result size |
| Large subprocess output | Command output exceeds buffer or context | Tied to log volume |
| Session reference truncation | Referenced content exceeds budget | Tied to history and reference count |
The first is most common. A glob or grep result over the cap writes the full list to spill, while the model sees a locator and summary.
The second follows long jobs. Build logs, test output, and debug logs can be huge; putting all of it in context would crowd out useful information.
The third follows session references. When referenced content is truncated, the full content may live in spill; deleting it breaks later reads.
The common point is “the full content matters, but not all of it belongs in context.” Spill keeps the operable part visible and the full text on disk.
DeepSeek Harness: Where files live
The location belongs to the storage backend, not the project directory. Common deployments put it under the Harness home; exact paths depend on config and backend. (source)
Three ways to find it:
- Read the locator — it usually contains a backend id and content id.
- Read the config — the spill backend and path live in the profile or bundle.
- Compare disk growth — project versus home growth often identifies the disk.
Do not treat spill as a build artifact. It is not part of the workspace; cleaning the project does not clean it, and deleting the project should not break its references.
Remote or object-storage backends may keep files off the machine. Confirm the backend before using a local rm.
DeepSeek Harness: Retention ownership
Retention is a deployment responsibility, not a default guarantee. The docs describe the save and locator contract; how long content stays and when it is reclaimed depends on the backend and config (source).
Three owners:
- Backend — where files live, compression, remote storage.
- Session/tool — whether a locator is still referenced or can be regenerated.
- Deployment — retention days, capacity caps, cleanup jobs.
Mixing them produces “I thought it cleaned itself, now the disk is full” or “the cleanup script deleted a live result.”
A practical move: give spill its own capacity budget and monitoring. Do not share an unbounded partition with session logs and plugin caches.
DeepSeek Harness: What deleting costs
Deleting a spill file can make a successful result unreadable. Three costs (source):
- Tool result unreadable — the locator remains, the file is gone, later reads fail.
- Session reference broken — truncated references depend on spill; the full text is lost.
- Diagnostics gone — the complete output you need for debugging has been removed.
The first is most common. The model sees a summary and a locator; the user opens details and finds nothing. The task did not fail, but the result is unusable.
The second is subtler: references may read spill only on demand, so nothing errors until a user cites them.
The third is operational: delete too early and you have no full log; delete too late and the disk fills. Balance with a retention policy.
DeepSeek Harness: Cleanup order
Clean in four steps: confirm references, mark, delete, verify. Do not start with rm -rf. (source)
- Confirm references — list locators still used by sessions, tool results, or references.
- Mark candidates — choose by age, size, and reference status.
- Delete in batches — start with unreferenced and oldest content; keep a rollback window.
- Verify sessions — open affected sessions and confirm key results still read.
The first step matters most. Without a reference list, deletion is a gamble; with one, the impact is bounded.
If references cannot be confirmed, keep recent spill and delete older content. Recent sessions are more likely to still use it.
Make the cleanup script idempotent, dry-runnable, and log which locators it deleted. Logs beat memory when something breaks.
DeepSeek Harness: Verify capacity and cleanup
Use four observations. Four steps (source):
- Produce — run a huge-output tool; confirm a spill file and a readable locator.
- Reference — cite the result in a session; confirm the full text reads.
- Clean — delete an unreferenced file; the session is unaffected.
- Retain — trigger or wait for cleanup; capacity returns to budget.
All four mean production, reference, cleanup, and retention agree. Passing only the first often hides broken references; passing the first three often hides continuing growth.
The existing develop-spill-store-contract covers the save and locator contract, develop-token-meter-and-spill covers metering and spilling, and fix-subprocess-spill-short-write covers short writes; this article covers the disk budget and cleanup order. Confirm references before deleting.
FAQ
DeepSeek Harness spills when tool output, subprocess output, or session reference content exceeds the model-visible limit; the full content is stored and a locator is returned.
Retention depends on the DeepSeek Harness storage backend and deployment config. Do not assume automatic reclamation; set a budget or a cleanup policy explicitly.
In DeepSeek Harness, the locator still exists but the content cannot be read, so a result that looked successful becomes unavailable. Confirm references before deleting.
DeepSeek Harness does not work that way. A lower limit pushes more content into spill and can increase disk use. Control usage with retention, cleanup, and tool result size, not by shrinking the visible limit.
Related Terms
- spill storage
- Spill storage is the DeepSeek Harness layer that keeps full content exceeding the model-visible limit and returns a locator for later reads.— DeepSeek Harness reference - Spill storage
- locator
- A locator is a DeepSeek Harness reference to spilled content; tools and sessions use it to read the full result without placing it in model context.— DeepSeek Harness reference - Spill storage
- retention policy
- A retention policy decides how long spilled DeepSeek Harness content is kept and when it may be cleaned; it depends on the backend and deployment.— DeepSeek Harness reference - Spill storage
- disk budget
- A disk budget sets a capacity limit and cleanup cadence for DeepSeek Harness spill files so intermediate content does not grow without bound.— DeepSeek Harness reference - Spill storage
Sources
- DeepSeek Harness reference - Spill storage· deepseek-harness
- DeepSeek Harness reference - Token metering· deepseek-harness