I’ve been thinking about this too, and because I don’t want to write my own database, I’ve been exploring Git as a generic lazy CAS. Modern features get you really close, and for data that isn’t deeply nested the performance is well within an order of magnitude of other databases.
build seems to be an area ripe for total disruption in this space. imagine a Bazel-like where all components are distributed, mesh-based global caching, worktree oriented, agentic integration - that would've been an intimidating years long buildout. now it seems approachable for a small team