I wanted to run one full unmanned loop end to end. If I kept interrupting, the flow broke, and I wanted to see how far “just handle it” would go. When it finished, wiki bodies were living in Postgres columns.
I thought I had said it. Markdown files like second. Folders you can read and search. Opening the unmanned result, document bodies were buried in the DB. Maybe the agent misunderstood “files.” Maybe I never pinned it hard enough. Both are possible. What matters is you cannot catch this without mid-flight checks.
I said something similar in I only saw the mountain of fixes after shipping unmanned. That piece was about review pile-up and context. This one is storage. Same habit, different face. I still wanted to try unmanned “once.” That once taught me unmanned without checkpoints does not work.
The direction was second from the start
When I started myWiki, the picture in my head was the second wiki I actually use. Source text piles up in a source layer. The wiki layer keeps cleaned md. Git keeps history. If AI is going to manage a personal wiki whole, that wiki has to be a folder. Bodies in a DB column mean the agent cannot read and search a tree, git undo is awkward, and the mental picture splits from second. That was the starting point of AD-15.
Inside the unmanned loop, “save document” drifted into Postgres because it was convenient. Meta in DB, body in DB. Say it and it ships. Spec and implementation can diverge forever if no human looks midstream. Finish without checks and you keep the misunderstanding.
So I flipped it. Document bodies are file and git as the source of truth. DB keeps meta, chat meta, metering, job queues. Drop columns like bodyMarkdown. A file store reads and writes files. Once that direction lands, a chain follows. If only bodies go to files and chat/uploads stay in DB, the same question returns. Where is the source? Isn’t it frustrating when you cannot see it?
Source layer and wiki, two layers
A session title still holds the line: 「로우 파일도 관리하게 해야하나 아예안보이니까 좀 답답하네」. If only wiki is files and chat/uploads evaporate or stay inside the DB, sources disappear. So AD-18 moved conversation and uploads to source files too. Session md is owned by files. Message content is not kept as DB body of record. Load fills from files. Save is file-side.
Folder shape came with it. 「폴더구조는 좀 바꾸자 깃여러개인건 좀 아닌거 같아서 raw 안에 여러 공간이 있고… wiki 폴에 깃 하나로」. I once thought each space might have its own git. Moving a document across spaces then becomes a cross-repo transplant and history breaks. AD-19 made wiki a single git repo per user, with moves as git mv. Multi upload landed under 「흠 파일 업로드 멀티로 되어야 할거 같음~」 in the same stretch.
Target layout is roughly this:
data/users/{userId}/
raw/{spaceId}/
chats/
uploads/
index/
structured/
wiki-map/
wiki/ # single git per user
{spaceId}/{docId}.md
second is a single-user local wiki. myWiki is a multi-user service, so every path is isolated under users/{userId}/. Aside from that, source · classify map · wiki can speak the same language as second. How many classify layers, which file is the “wiki TOC,” still confused us later. Questions like 「아하 인덱스는 db에서 관리한다고?」 showed up and got sorted toward AD-20·21. That is not this post’s deep dive. Here the point is why the floor became files.
Why we flipped it, in one line
If bodies live in the DB, AI cannot treat the wiki as a folder. Search, undo, and handoffs to file tools like Obsidian all get weaker. To move a way of working already proven in second into a product, storage has to match first. The unmanned full loop exposed the mismatch, and once exposed we tore out the Postgres body path.
I do not need to list AD-15 through 20 one by one. The flow is one. Body as files → chat/uploads as source files → single wiki git → classify map on top. Implementation series names and smoke counts matter less than the scene: “I thought I had asked for a file wiki, and it was in the DB.”
Cost, classify, and when to run organize come later on this floor. Less how, more why we flipped once. I only learned it after going unmanned all the way. Without checks, misunderstandings settle into the product, and fixing them means changing the floor.