Git Is the Best Memory an Agent Can Have
The API your agent learned last week, it relearns this week — every service is a cold start. My answer is not a vector database. It is a helpers directory plus git history.

Everyone building agent tooling has met the same embarrassment: your agent learned to call the Linear API last week — read the docs, trial-and-errored, got it working — and this week, facing Linear again, it starts from zero. No muscle memory. Every new service is a cold start.
The industry's standard answer is to bolt on a vector database and embed "experience" as vectors. Building my open-source project graft, I took a different road, based on one plain observation:
The way engineers have always accumulated experience is by writing code and committing it to git.
Why should agents be the exception?
So graft's memory design has exactly two layers: a helpers directory — code files the agent writes and revises as it works, one per service — plus git history. This combination delivers things no vector database can:
- Readable — a human can open it anytime and see what the agent learned; mistakes surface on sight;
- Editable — the agent refactors its own experience, and humans can patch it directly;
- Revertible — learned something wrong? git revert;
- Shareable — push to a pure-git community registry and other people's agents reuse it, no central server required.
Behind this sits what the Browser-Use team called the Bitter Lesson of agent harnesses: don't teach the agent how to work — give it a plot of land it maintains itself. Models get stronger every year; the teaching logic you hard-code will rot fast. A mechanism that lets the agent accumulate and revise on its own will not.
graft adds one more radical discipline: core code carries a CI-enforced line budget, and a bug fix must not add lines — if fixing a bug requires more code, you probably haven't found the root cause. LOC is not a cost metric; it is a thermometer for design quality.
Putting memory in git has one hidden benefit: it forces experience to be written down. Embeddings in a vector store are a black box nobody can review. An 80-line helper file can be reviewed, tested and trusted — by humans and agents alike.
Trust is not fed; it is audited. True for people. Equally true for agents.