
poteto@poteto
挺有意思的,好多人回复我说可维护性和整洁代码依然很重要。我倒觉得这已经不成立了,大家都该更新一下先验,重新想想 2026 年的“好代码”到底意味着什么。 整洁代码一直都是有代价的——性能。各种间接层、让代码对人类可读可理解,这些都不是免费的,往往要以更差的性能为代价。我们过去能接受这一点,是因为有摩尔定律,而且大部分代码都不在热路径上。 这些原则也来自人类维护代码的年代。那时候为人类优化是合理的,但现在代理已经在写所有代码了,这就没那么合理了。我们其实很可能会发现、提出新的原则:对代理友好的架构原则(我打算很快多写点这方面的想法)
it's very interesting how many replies i've gotten about maintainability and clean code being still important. i would argue that that is no longer true and we all need to update our priors on what Good Code really means in 2026.
clean code has always come at a cost - performance. indirection and making code readable/understandable for a human is not free, it often comes at the cost of worse performance. we have historically been okay with this because of Moore's Law and the fact that most code is not on the hot path.
these principles also came from a time where humans maintained code. it made sense to optimize for humans then, but it makes less sense now when agents are already writing all the code. we will in fact probably discover and come up with new principles: principles of agent friendly architecture (i plan to write more thoughts about this soon)
