Glean 拾遗
日刊 /2026-09-15 / 把知识写下来:一位 CTO 的文档优先实践

把知识写下来:一位 CTO 的文档优先实践

原文 vadimkravcenko.com 收录 2026-09-15 06:00 阅读 11 min
AI 解读

一位创业公司 CTO 复盘自己推行“文档优先”的整套做法:用一页纸代替半小时站会、把文档工时显式写进排期、给每个 feature 合并时附一段“为什么选 X 不选 Y”。他也承认过度文档会反噬(过时页面比没有更糟),因此只记录能活过一个季度的 80% 内容,并用一条轻量 CI 检查强制新埋点必须配 wiki 条目。文中给出 ADR、incident post-mortem、Diátaxis、docs gardener 等具体机制,适合正在搭建工程规范的中小团队负责人与一线工程师参考。

原文 11 分钟
原文 vadimkravcenko.com ↗
§ 1

I have an irrational love for documentation. Give me a quiet hour, a mug of half-cold espresso, and a blank Confluence page and I’m happy. It feels boring only until you watch someone unblock themselves in 30 seconds because of a paragraph you wrote last month—those moments pay back the effort a hundredfold (well, that’s my rough estimate, I haven’t actually timed it).

我对文档有一种毫无道理的热爱。给我一小时安静时间、一杯放凉了一半的 espresso,再加一个空白的 Confluence 页面,我就心满意足了。它看上去无聊,直到你亲眼看到有人因为你上个月写的那段话,在 30 秒内自己解了困——这样的时刻,回报是投入的百倍(好吧,这只是粗略估计,我并没有真的掐表算过)。

§ 2

If you’re wearing the CTO hat, good docs are the stealth tool in your belt—the bit nobody brags about at demo day, yet somehow everything falls apart when it’s missing. Less guesswork, fewer déjà-vu bugs, faster onboarding. Think of OpenBSD: seasoned users learn that the man pages answer most of questions faster than Google. That same dynamic is possible inside a company if you write things down properly.

如果你戴着 CTO 这顶帽子,好文档就是你腰间的隐形武器——没人会在 demo day 上炫耀它,可一旦缺了它,一切都会莫名其妙地散架。少些猜测,少些似曾相识的 bug,新人上手更快。想想 OpenBSD:老用户都知道,翻 man page 比 Google 更快找到答案。只要把事情老老实实写下来,公司内部也能有同样的效果。

§ 3

Don't be like this.

别做这种人。

§ 4

Quick thought experiment:

Ping a teammate, break their focus, ask how the billing micro-service resolves currency rounding.

Open the doc, skim for sixty seconds, and move on.

The second option wins every time (unless the doc is missing—then you’re back to option one with an apology).

来做个快速的思想实验:

戳一下同事,打断他的专注,问他计费微服务是怎么处理货币舍入的。

打开文档,扫六十秒,然后继续干活。

第二种每次都赢(除非文档根本不存在——那你就得回到第一种,外加一句道歉)。

§ 5

Bare bones first. You’re a technical co-founder at a young startup, juggling deployments with investor calls, and something breaks at 2 a.m. You fix it, swear you’ll write a post-mortem, and then sprint to the next fire. I’ve done that loop more times than I care to admit. The only sustainable escape route I’ve found is to extract knowledge from my head into text before the memory fades.

先说最基本的。你是一家年轻创业公司的技术联合创始人,一边做部署一边接投资人电话,然后凌晨两点出了故障。你修好了,发誓要写复盘,接着又冲向下一场火。这个循环我重复过的次数多到自己都不愿承认。我找到的唯一可持续的出路,是在记忆消退之前,把脑子里的知识倒进文字里。

§ 6

That said, more pages do not automatically mean more clarity. Excess or stale docs can be worse than none at all—people stop trusting the handbook once they hit the third outdated snippet. I try to calibrate the effort the same way we write tests: prototype code gets a short README, production code gets the full treatment. Anything beyond that risks turning into archaeological sediment.

Everything you keep only in your head is a future bottleneck—but I could be overstating it. Small, rapidly changing details sometimes change faster than we can document them. I aim for the 80 % that survives a quarter and ignore the rest.

话虽如此,页面多并不自动等于更清晰。多余的、过期的文档可能比完全没有还糟——一旦连着撞见三段过时内容,人们就不再信任这本手册了。我会像写测试那样校准投入:原型代码配一份简短 README,生产代码才做全套。再往上加,就有变成考古沉积层的风险。

所有只存在你脑子里的东西,都是未来的瓶颈——不过这话也许说重了。有些细小而快速变化的细节,变得比我们能记录的还快。我瞄准的是那 80% 能撑过一个季度的内容,剩下的就不管了。

§ 7

🚨 Good docs lessen headaches and keep vacations sacred.

Without them, you become the single point of failure. Want to leave town for a week? Too bad—the CI pipeline still depends on that incantation you memorized three releases ago. Write it down once, and the team can rerun it without the ritual Slack ping.

🚨 好文档能减少头疼,也能让假期保持神圣。

没有它们,你就成了单点故障。想离城一周?抱歉——CI 流水线还依赖着你三个版本前记住的那句咒语。写下来一次,团队就能自己重跑,不必再在 Slack 上例行呼叫你。

§ 8

One caveat I’ve learned the hard way: sometimes we document work-arounds that would be better fixed in code. If the handbook spends three paragraphs explaining which magic flag makes the export button behave, maybe the real solution is to ship a sane default. Docs should describe reality, not excuse it.

有一个我踩过坑才明白的提醒:有时候我们记录的权宜之计,其实更该在代码里修掉。如果手册花了三段话解释哪个魔法开关能让导出按钮听话,那真正的解法也许是发一个合理的默认值。文档应该描述现实,而不是替现实找借口。

§ 9

Time in a startup burns faster than money. Meetings are the usual culprits. A half-hour check-in for eight people can consume significant time—roughly the same as a decent pull request review. I still call meetings, but the bar is high: if the agenda fits into a page, I write the page and ask for comments instead.

在创业公司,时间比钱烧得更快,而会议通常是罪魁祸首。八个人的半小时同步会,消耗的时间相当可观——差不多等于一次像样的 pull request 评审。我依然开会,但门槛很高:如果议程能装进一页纸,我就把那一页写出来,请大家在评论里反馈。

§ 10

Important nuance: not every written artifact counts as documentation. A Zoom recording buried in Drive, or a Slack thread with 200 replies, is barely searchable and rarely edited after the fact. Real docs are three things: searchable, up-to-date, and living in a place where anyone can fix a typo on the spot.

一个重要区别:并不是所有写下来的东西都算文档。埋在 Drive 深处的 Zoom 录像,或者两百条回复的 Slack 串,几乎搜不到,事后也很少有人去编辑。真正的文档满足三点:可检索、保持最新,而且待在一个任何人都能随手改掉错字的地方。

§ 11

"But face-to-face sync builds rapport." Absolutely. I still keep one weekly engineering huddle—for morale, quick unblockers, and the odd joke that doesn’t survive markdown. Everything else goes async.

That would be an awesome feature. Source: Twitter

Relatable? Source: CommitStrip

“可是面对面同步能建立信任。”没错。我依然保留每周一次的工程例会——为了士气、快速解困,还有那些写进 markdown 就不好笑的笑话。除此之外,一律异步。

这功能要是真有就太棒了。来源:Twitter

似曾相识?来源:CommitStrip

§ 12

Every unnecessary meeting is an opportunity cost. Sometimes that cost is a missed refactor, sometimes it’s a missed lunch break. Either way, the bill arrives.

Docs also flatten hierarchies. In a live call the loudest voice often wins; on paper the quietest engineer can leave a carefully reasoned comment that changes the course of a decision.

每一场没必要的会议都是机会成本。这成本有时是错过的重构,有时是错过的午休。无论如何,账单总会来。

文档还会把层级拉平。在实时通话里,赢的往往是嗓门最大的那个;落到纸面上,最安静的工程师也能留下一段缜密的评论,改变一个决策的走向。

§ 13

One more practical tip: if you announce something big (say, “We’re sprinkling AI onto every workflow”), publish the rationale the same day. Otherwise the rumor mill fills the vacuum, and you spend the next sprint untangling misunderstandings.

Over time, this trail of written decisions becomes institutional memory—hugely valuable once the founding team’s attention is split across ten initiatives.

Encourage everyone to add one paragraph about why they chose X over Y when they merge a feature. Future-you will thank present-them.

To enforce the habit, we wired a lightweight CI check that fails the build if a new analytics event ships without a matching wiki entry. Annoying at first, but it nudges the team toward completeness (feel free to steal the idea, adjust the strictness).

再给一条实用建议:如果你要宣布一件大事(比如“我们要给每条工作流都撒上 AI”),当天就把理由公开。否则谣言会填满真空,你得用下一个 sprint 去收拾误解。

时间久了,这些写下来的决策就形成了组织记忆——当创始团队的注意力被十个项目分散之后,这份记忆价值巨大。

鼓励每个人在合并功能时补上一段话,说明为什么选了 X 而不是 Y。未来的你会感谢现在的你。

为了让这个习惯落地,我们挂了一个轻量的 CI 检查:新的分析事件如果没有对应的 wiki 条目,构建就失败。一开始很烦,但它会推着团队把事做全(欢迎照搬这个点子,严格程度自己调)。

§ 14

Docs-first culture isn’t everyone writing prose all day. It’s everyone believing that written knowledge outlives verbal explanations. Even a small portion of task time spent on docs moves the needle. I budget it explicitly in estimates so people don’t feel guilty.

Your main job as CTO is to model the behaviour. I jot decisions in public pages, even the half-baked ones (with a disclaimer when I’m unsure). Teams copy what they see.

💡 People mirror leadership. If you don't document, nobody will.

文档优先的文化,不是要求人人整天写文章,而是人人都相信:写下来的知识比口头解释活得久。哪怕任务时间里只抽一小部分写文档,也会起作用。我会把它明确算进工时估算,这样大家就不会有负罪感。

作为 CTO,你的主要职责是把这件事做出来给人看。我会把决策记在公开页面上,半成品也记(不确定的地方加一句免责声明)。团队会照搬他们看到的行为。

💡 人们会模仿领导者。你不写文档,就没人会写。

§ 15

Celebrate good docs in stand-ups, drop kudos in Slack, link them in onboarding. The positive feedback loop matters more than any policy.

Tooling helps: Notion, Confluence, GitLab wiki, plain Markdown in the repo—it’s less about the logo, more about friction. Provide templates and style guides so nobody starts from a blank page.

Create checklists, peer reviews, version control. Those aren’t shackles; they’re the linting rules that keep the handbook coherent.

在 stand-up 上表扬好文档,在 Slack 里给人点赞,在 onboarding 里把它们链接进去。正向反馈循环比任何制度都管用。

工具也有帮助:Notion、Confluence、GitLab wiki、仓库里的纯 Markdown——重要的不是用哪个牌子,而是摩擦有多大。提供模板和写作规范,这样没人需要从空白页开始。

建立检查清单、同行评审和版本控制。这些不是镣铐,而是让手册保持一致的那套 lint 规则。

§ 16

As the company grows, consider appointing a single “docs gardener.” Could be part-time. Their mission: trim outdated branches, nudge owners, keep links alive. One diligent person can prevent the whole garden from turning into weeds.

随着公司变大,可以考虑设一名“文档园丁”。可以是兼职。他的任务:剪掉过时的枝条,提醒责任人,让链接保持存活。一个用心的人,就能防止整座花园长满杂草。

§ 17

Pick whatever integrates with your workflow. We run most engineering docs alongside code because pull requests double as review for the words. Marketing prefers Notion. That’s fine—just cross-link aggressively.

Templates matter: architecture decision record (ADR), incident post-mortem, feature spec. Having the skeleton ready lowers the activation energy.

Remote.Com Notion documentation. Inspired by GitLab

挑能接进你工作流的工具就行。我们把大部分工程文档和代码放在一起,因为 pull request 顺便就完成了对文字的评审。市场部更喜欢 Notion。没问题——只要狠狠地互相交叉链接。

模板很重要:架构决策记录(ADR)、事故复盘、功能规格。骨架先备好,启动所需的那点力气就省下来了。

Remote.Com 的 Notion 文档。灵感来自 GitLab

§ 18

Guidelines explain what belongs where. Without them, you end up with duplicate pages titled “README (new)”—we’ve all been there.

💡 Checklists + versions = consistency without micromanagement.

And yes, keep revisiting the system. A perfectly organized wiki from 2021 that no one updates is just a museum exhibit.

指南要说明什么内容该放在哪里。没有它,你迟早会看到一堆标题都叫“README(新)”的重复页面——这事我们都干过。

💡 检查清单 + 版本控制 = 无需微观管理的一致性。

当然,还要不断回头维护这套体系。一个 2021 年整理得完美无缺、却没人更新的 wiki,只是一件博物馆展品。

§ 19

Expect resistance. Engineers worry it’ll slow them down, managers fear another KPI. Listen, adjust, and start small. A two-paragraph how-to that saves someone an hour is hard to argue against.

Also, the first drafts will be rough. That’s fine—treat docs like code: iterate, refactor, delete obsolete bits. The aim is progress, not perfection.

要有心理准备会遇到抵触。工程师担心这会拖慢自己,管理者怕又来一个 KPI。倾听、调整、从小处做起。一篇两段话的操作说明,只要能为谁省下一小时,就很难被反驳。

另外,初稿一定很糙。没关系——把文档当成代码:迭代、重构、删掉过时的部分。目标是进步,不是完美。

§ 20

Celebrate those who dare go into this room to fix things.

Source: Dataedo

Shine a spotlight on improvements and the culture shifts on its own.

为那些敢走进这间屋子修东西的人鼓掌。

来源:Dataedo

把聚光灯打在改进上,文化自己就会转向。

§ 21

Good docs are clear, concise, and—crucially—scannable. If it feels like slogging through a 2 000-word intro to find the command you need, rewrite or split the page.

Use emphasis—callouts, bold text, whatever your tool offers.

If it reads dry, add a diagram or 60-second Loom.

Lean on frameworks like Diátaxis to separate guides from references.

Diátaxis Framework for writing documentation

好文档清晰、简洁,而且——最关键的一点——能扫读。如果为了找到需要的那条命令,得先在两千字的引言里跋涉,那就重写或者拆页。

善用强调:提示框、加粗,你的工具给什么就用什么。

如果读起来干巴巴的,加一张图,或者一段 60 秒的 Loom 视频。

可以借助 Diátaxis 这类框架,把指南和参考分开。

用于文档写作的 Diátaxis 框架

§ 22

Navigation matters: table of contents, backlinks, “next / previous” links. People should land, skim, click, exit enlightened.

Tags and categories help. A half-decent search engine helps more.

Track ownership and “last updated” dates so stale pages surface automatically.

Finally, remember docs are living. Schedule spring-cleaning once a year, or watch entropy win.

导航很重要:目录、反向链接、“上一页 / 下一页”。人应该能落地、扫一眼、点一下,然后带着答案离开。

标签和分类有用,一个还算过得去的搜索引擎更有用。

记录归属人和“最后更新”日期,这样过期的页面会自动浮出来。

最后,别忘了文档是活的。每年安排一次春季大扫除,否则就等着熵增赢下这一局。

§ 23

Need inspiration? Browse these open-source handbooks:

Basecamp employee handbook

GitLab handbook—thousands of pages, version-controlled.

Strapi handbook

Remote.com handbook

需要灵感?看看这些开源手册:

Basecamp 员工手册

GitLab 手册——数千页,纳入版本控制。

Strapi 手册

Remote.com 手册

§ 24

I’m bullish on documentation, but it’s not a panacea. It can’t replace hallway chats, and it certainly won’t fix a toxic culture. It’s a tool—and like any tool, misused it can hurt. Over-document and you drown the team in noise; under-document and you’re back to tribal knowledge.

Writing good docs takes time. I factor that into roadmaps; otherwise it gets squeezed out. And yes, pages get outdated the moment they ship—so build maintenance into your process, or accept that half-life.

🚨 Remember those recipe blogs with 20 paragraphs before the ingredient list? Don’t let your handbook turn into that.

Stay vigilant, prune regularly, and your docs will stay useful instead of fossilising.

我看好文档,但它不是万能药。它替代不了走廊里的闲聊,更治不好有毒的文化。它是一个工具——而任何工具用错了都会伤人。写得太多,团队的注意力会被噪音淹没;写得太少,又回到口口相传的老路。

写好文档要花时间。我会把它算进路线图,否则它一定会被挤掉。而且页面一发布就可能过时——所以要么把维护做进流程,要么接受它的半衰期。

🚨 还记得那些在配料表之前先写二十段人生故事的菜谱博客吗?别让你的手册变成那样。

保持警觉,定期修剪,你的文档就会一直有用,而不是变成化石。

§ 25

If you take one idea from this rant, make it: “Document to empower, document to grow.” Start small—today, not next quarter. Add a README, jot an ADR, capture the why behind a refactor. The compound interest kicks in faster than you think.

And if you catch me shipping code without notes, call me out—I’m still learning too.

如果这篇碎碎念里你只带走一个想法,那就带走这句:“为赋能而写,为成长而写。”从小处开始——今天就做,别等下个季度。加一份 README,记一条 ADR,把一次重构背后的原因写下来。复利来得比你想象中快。

如果你发现我又不写说明就提交代码,直接骂我——我也还在学。

打开原文 ↗