← All writing

The working area of the Agent era needs "the only upstream"

<!doctype html>

The working area of the Agent era needs "the only upstream" | Roy.Tong

Machine-assisted translation. Read the Chinese original.

← Back to the article

The working area of the Agent era needs "the only upstream"

Copying is a debt, and mounting is an asset. The real source should be versionized, the derivative should be reconstructible, and the temporary state should have TTL.

2026-09-21 I take stock~/Documents/AI app/, du reported 28G; by the end of the second round of cleaning on 10-02, the same directory 22G. The 6G saved is the least important number. The inventory made me see another thing clearly: the three AI terminals (codex, ZCode, deepseek-harness) work in the same workspace. The file generation mechanism is completely different from the era when people write code, and the structure of my workspace has never been designed for this purpose. This article records six types of symptoms, two rounds of control, and the final principle: each asset allows only one upstream. 28G to 22G are just by-products.

Three ends, three sets of garbage production lines

Each of the three ends has its own landing point: codex use~/.codexAddAI app/codex, ZCode use~/.agentsAddAI app/glm, dsh has its own harness catalog. Session, venv, node_modules, skill copies, each produce their own, and no one knows what the other party has produced. I used the inventory of 9-21duAndfindAfter a category-by-category, the symptoms are concentrated in six categories:

Symptom Actual measurement numbers How was it measured?
A BP 24 consecutive rounds of iteration, the historical version is fully tiled About 40M 9-21 Inventory, check the iterative records document by file
A customer deck project 20 versions × html/pdf/pptx three formats 60+ files are tiled in the root directory of the project 9-21 inventory ls statistics
Node_modules scattered 15 places, a total of 1.34G find -name node_modulesLater one by one du
The same Reddit collection script was copied into 7 projects 7 copies, md5 is different Md5 compare one by one
Temporary workspace (candidate.pptx / .inspect.ndjson / render directory) Cumulative 330M, never recycled 9-21 inventory du
The cache of the resident browser profile Continue to grow back to 2G+ After clearing, observe and retest for a few days.

I almost had an accident when cleaning up: the two paths of the transcription database pointed to the same batch of inode (hard links), and either side of the deletion followed by the other side. After that, the suspected duplicate file was first compared with the inode number and then compared with the content hash, and the two confirmations were deleted - md5 only indicates that the content is the same, not that it is the same entity on the disk.

The most worth stopping in this table is the md5 line. The 7 collection scripts are from the same source, but they have been modified separately in their respective projects, and the md5 is already different. The bug fixes in any copy have not flowed back to the other 6 copies - the same bug needs to be fixed in different copies.

The shape of garbage has changed.

There is also garbage in the era of people writing code, but the form is old: temporary scripts are forgotten to be deleted, downloadable directories are full, and old projects are reluctant to clear. The quantity and nature of the extra things in the agent era have changed, and I classify them into three categories.

The first category is the intermediate version. 24 rounds of BP iterations, 20 versions of deck, each round of agent will produce a complete product. "A new file" is the most natural way for the agent to save the results. People don't work like this - people change the same file in the editor. So the "copy folder" has degenerated into version management, and the directory tree is full of history that should be managed by git. Each version of the deck project has three formats of html, pdf and pptx at the same time. Three files are iterated in a round, and 60+ files are rolled out in this way; the real amount of information is "what has been changed", and the format expansion is purely the inertia of export habits.

The second category is dependent on copies. 15 node_modules with a total of 1.34G (about 90M per place on average), each corresponding to a small script "install an environment first and run". Agent executesnpm installThere is no psychological burden. One order will drop a directory starting from tens of megabytes, and people will at least think about "will this thing be needed in the future" before installing it?

The third category is tool fork. The 7 collection scripts are the most typical: at the methodological level, I have long written experience as skill, and there are rules to follow to change prompts, add protocols, and change models; but engineering assets - scripts, pipelines, and templates - are still wandering in the whole catalog. Every time a new project is opened, the agent faithfully implements the "copy and change", and changes to become 7 parallel universes.The methodology has been skilled, but the engineering assets have not yet.

What did the two rounds of governance do?

9-21 The first round, 10-02 The second round, 28G cleared to 22G. The specific action is divided into four parts according to the target.

Version chain: the finalization area is separated from the historical archive.The BP and deck projects have been changed to a two-layer structure: only the current representative version is placed in the final draft area, and the historical version is moved in as a whole.归档/, only the representative milestone version is left in the archive, and the round of pure format fine-tuning will be deleted directly. The 40M BP tile converges into a final draft with a small number of representative versions, and the deck is filed according to the same rules.

Tool Center: an entity with three-end mounting.A unified tool center catalog has been built, with 10 skills and 7 pipelines as the only entity, and the three ends are mounted into their respective work paths with symbolic links. Repeated skill first do the content diff, and re-merge after confirming that there is no substantial difference; the 7 forked collection scripts are merged back to one, and the differentiated configuration of each project is changed to parameter input. After that, the repair of any place will benefit from the three ends at the same time. The action of the newly opened project has also changed: hang a link to the tool center, change the parameters, and no longer copy any whole directory.

Garbage that will grow back: give it to the scheduled task.If the browser cache is cleared, it will grow back. Manual cleaning is meaningless. Change it to the launchd task of monthly automatic cleaning. The candidate.pptx and render directory of the temporary workspace are agreed to be "deleted at the end of the task", which is written into AGENTS.md at each end.

Project catalog itself: 29 merged into 20.A considerable part of the "project" is actually the wreckage of a one-time task - completed experiments, abandoned plan comparison drafts, archiving or deletion. I stepped on a pit when merging: Python venv tied the absolute path, and all scripts reported errors collectively after the warehouse moved - this kind of thing should be thought about clearly before moving the directory.

Assetization: Skillization is just the first step

The cleaning action is a small matter. What should really be written down is the understanding of the forced cleaning:The assetization of prompt and skill is only the first step; code, script, template, session and product must also be assetized, otherwise it will come back in the form of debt.

What is the asset of the Agent era? I finally fell on the three-point method:

Classification What are you pretending to be? Correspondences in my work area
Canonical (True Source) Prompt, skill, source code, template, raw data, rules 10 skills, acquisition script and 7 pipelines, BP/deck template, transcription database
Derived (Derived) PDF, PPTX, HTML, report exported from the real source BP final draft, deck's html/pdf/pptx
Ephemeral (temporary state) Render, candidate, cache, node_modules, browser profile Candidate.pptx, render directory, 15 node_modules, browser cache

Three sentences of governance rules:The real source should be versioned; the derivative should be reconstructible; the temporary state should have TTL.There is no ready-made seat in the conversation memory in this table. It is disassembled according to its nature: the conclusion that is worth reuse is precipitated back to the true source (written into the skill or document), and the rest is treated as a temporary state, and the total amount is constrained by archiving.

This table also accurately shows the meaning of "the only upstream": each asset has only one canonical source of truth. The only upstream here is not that there can only be one physical copy on the disk, but only one copy has the right to modify and the status of true source, and the other copies must be reconstructible and traceable derivatives. Copying itself is not foul: package release, git clone, CDN cache, backup, build products, container mirroring, all copies, all of which are reasonable, because there is still only one real source, and it can be regenerated at any time after modification. The foul is to let the copy quietly get the right to modify - the problem of 7 forked scripts is that 7 copies are not saved, and 7 copies can be changed. No one is authoritative.

The dividing line between copy culture and asset culture is also here:Copying and changing it is a debt; mounting a reference is an asset.The debt is not reflected on the disk - the 7 forked scripts do not take up much space, which takes up the repair time I spend repeatedly on each copy, and there is no reminder mechanism. I can't always remember the existence of other copies. Looking back, the composition of 6G is the same structure: the big head is the volume of node_modules and temporary areas such as "install and forget". The absolute amount of version tiling is limited, but the categories that occupy less space are more expensive.

According to this table, two rounds of cleaning have been achieved: on the real source side, the skill is collected into the tool center, and the script is merged back to one copy; on the derivative side, the construction product is handed over to the two-layer structure plus git. Conversation memory is a ready-made counterexample: the three terminal formats are incompatible with each other, and the total amount of constraints can only be archived regularly, and the archive itself has a new historical copy. The template and data set have not been upstream yet, so they will be recorded in the account first.

The only upstream: a principle that can be moved away

After two rounds of clearing, the management experience is pressed into a principle:Only one upstream is allowed for each asset.A piece of entity mounting of the tool is its spatial embodiment; the version into git is its temporal embodiment - the history is managed by git, the directory tree is only in the current state, BP is iterated, what has been changed between the two rounds, git diff can be seen on a screen, which cannot be done in the 40M tiled folder, where there are only 24 silent complete versions; temporary products will be deleted after use, which is to admit that such files are not suitable for games at all. If the principle cannot be managed, such as the browser cache, it is admitted that it will return to long, and the peak of 2G indicates that the cache growth rate itself has not decreased.

This principle does not bind my directory structure. The tool center plus symbolic link plus git is just the solution of my three-terminal parallel scene; change to monorepo, internal package source, shared disk, and change the realization form at will. The three rules remain unchanged: is there only one real source, can the derivative be rebuilt, and whether there is TTL in the temporary state. Falling into routine is a self-examination: before any new file is on the market, ask whether it is a real source, a derivative, or a temporary state; before you want to delete any "duplicate" file, confirm that it is a reconstructible derivative, not the only entity of the true source elsewhere.

22G is not a number that can declare victory. Two things in the next round: add integrity verification to the mounting of the tool center to prevent a certain terminal from quietly copying the local copy one day; make the "temporary product list" into a scripted white list, which will be automatically deleted when it expires, and no longer rely on the consciousness of the agent at each end. These two things still follow the same principle: garbage is not cleaned up, but designed.

R
Thank you for reading this.

I will continue to record my observations on AI, products and entrepreneurship.

Support writing♡