Files
deepseek-harness/packages/fs
Dudu-0223 d612ebaef1 fix: address codex review round 3
Record the freshness token observed AFTER the read (re-stat post-read, falling
back to the routing stat if the file vanished) so the version returned/recorded
matches the bytes returned — a writer racing between the routing stat and the
read can no longer make a follow-up edit spuriously stale. Stream reads when the
backend reports no size, so a size-less backend never buffers a large file
whole. Update the cordis-catalog link map to the current filesystem API symbols
(FileContextExec/FileReadRequest/FileReadOutcome/FsInfo/FsWriteExpectation).
2026-06-26 18:14:30 +08:00
..

fs/ - filesystem capability family

The filesystem stack: a provider seam (text IO + guarded mutation), a local implementation, a policy layer (read windowing + write/edit freshness), and the model-facing file tools. All product packages.

Package Role ctx key
fs/ Provider seam: text IO + guarded mutation primitives ctx.fs
fs-local/ Local-filesystem FileSystem implementation (registers ctx.fs)
file-context/ Policy layer: observed-state, read windowing, write/edit freshness ctx.fileContext
tool-fs/ Model-facing read/write/edit tool schemas (registers on ctx.tools)

The interface lives at fs/fs/. A sandboxed, remote, or project-scoped filesystem backend can replace fs-local without touching the seam, the policy layer, or the model-facing tool schemas. The policy layer (file-context/) is a concrete service, not a swappable seam — it owns the model-facing observation policy that does not belong on a provider backend.