A Million Kakapos
A Million Kakapos / 百万只鸮鹦鹉
Agentic coding is the hot new thing. I’ve been doing it since the GPT3 days back in 2021. Everyone doing it has decided that coding is now ‘basically free’. Prior to this you needed great programmers to make great software. Becoming a programmer with good skill takes a lot of work. Now that LLMs can code fairly well, where does that leave Open Source software? This article is about Open Source software and what could happen to it in a world where writing code is no longer scarce.
“智能体编程”(Agentic coding)是当下最热门的话题。自 2021 年 GPT-3 时代起,我就一直在进行相关实践。所有参与其中的人都认为,编程现在已经“基本免费”了。在此之前,你需要优秀的程序员才能开发出优秀的软件,而成为一名技术精湛的程序员需要付出巨大的努力。如今,既然大语言模型(LLM)已经能写出相当不错的代码,开源软件又将何去何从?本文旨在探讨开源软件的现状,以及在一个编写代码不再稀缺的世界里,它可能会发生什么。
Efficiency vs Robustness / 效率与鲁棒性
Darwin is often misread. We are taught “Survival of the fittest” (Herbert Spencer coined that term, not Darwin) and imagine a competitive world where the strongest survive. Evolution is often thought of as some kind of optimization process. What is often misunderstood is time horizons and what is being “optimized”. If an animal is optimized for its environment, it subjects itself to a huge risk: What if the environment changes? The Giant Panda is a creature that is hyper optimized for its environment. It’s diet is about 99% bamboo, and it has evolved a specialized thumb which helps it strip bamboo. However bamboo can go through synchronous flowerings and die-offs which make it difficult for the panda to survive. The Giant Panda was an endangered species for decades and survives now because we help it survive. In other words, evolution over the short term optimized the panda to be fit for a niche environment, but over the long term has created a very fragile creature, unable to adapt to variance in its environment.
达尔文常被误读。我们被教导“适者生存”(这个词是赫伯特·斯宾塞创造的,而非达尔文),并想象出一个强者生存的竞争世界。进化常被视为某种优化过程。但人们往往误解了时间跨度和“被优化”的对象。如果一种动物针对其环境进行了极致优化,它就面临巨大的风险:如果环境改变了怎么办?大熊猫就是一种针对其环境进行超优化的生物。它的饮食中约 99% 是竹子,并进化出了专门的“伪拇指”来帮助剥竹子。然而,竹子会经历同步开花和枯死,这使得大熊猫难以生存。大熊猫曾几十年来一直处于濒危状态,如今之所以能存活,是因为人类的干预。换句话说,短期进化将大熊猫优化得适应了特定生态位,但从长期来看,却造就了一种极其脆弱、无法适应环境变化的生物。
The Kakapo is another creature that became highly optimized for its environment. With no natural land predators, it evolved in New Zealand and optimized for energy conservation. It abandoned expansive flight, grew heavy, and has a long multi-year breeding cycle. Worst of all, it evolved to freeze when startled which make it easy prey for land mammals like rats and cats. It is another species on the endangered list with only 240 left.
鸮鹦鹉(Kakapo)是另一种针对环境高度优化的生物。由于新西兰没有天然的陆地捕食者,它进化出了节能模式。它放弃了长距离飞行,体型变得笨重,并拥有漫长的多年繁殖周期。最糟糕的是,它进化出了受惊时“僵住”的本能,这使其极易成为老鼠和猫等陆地哺乳动物的猎物。它是另一个濒危物种,目前仅存 240 只。
If you look at a narrow time scale where the climate has not shifted much, you get animals that are highly optimized for their regions. However, over a much longer time scale, where variance of the environment is felt, you get animals that can adapt to a variety of environments. Think of animals like cockroaches, which have been around almost 400 million years. Cockroaches can digest almost any organic matter. They can survive weeks without food and water. They are found in a huge variety of environments from tropical rainforests, dry deserts, temperate woodlands, caves, and now human habitats. Think of sharks, which have been around 450 million years. Sharks have an amazing olfactory system and can locate prey from long distances in zero visibility. They have electroreception as well to help them find prey. They occupy a huge assortment of environments like coral reefs, open oceans, abyssal depths, arctic ice sheets, and even fresh water river systems. Their diets are highly flexible and they are able to readily shift their target prey based on the environment.
如果你观察气候变化不大的狭窄时间尺度,你会发现动物们针对其区域进行了高度优化。然而,在更长的时间尺度上,当环境波动显现时,你会发现那些能够适应多种环境的动物存活了下来。想想蟑螂,它们已经存在了近 4 亿年。蟑螂几乎可以消化任何有机物质,在没有食物和水的情况下能存活数周。它们分布在热带雨林、干旱沙漠、温带林地、洞穴以及现在的人类栖息地等各种环境中。再想想鲨鱼,它们已经存在了 4.5 亿年。鲨鱼拥有惊人的嗅觉系统,能在零能见度下远距离定位猎物。它们还拥有电感受器来辅助捕猎。它们占据了珊瑚礁、开阔海洋、深海、北极冰盖甚至淡水河流系统等多种环境。它们的饮食极其灵活,能够根据环境迅速调整捕食目标。
Over long time horizons, evolution selects for adaptive, robust creatures, not highly optimized performant ones. It selects for creatures with redundancies and adaptive systems. Cockroaches for example have a decentralized nervous system. You can take the head off a cockroach and it will stand, walk around, run away, and react to stimuli for weeks until it dies of dehydration. Sharks have redundant rows of teeth. Instead of evolving a single set of highly specialized teeth, which would give it fragility, Sharks have redundant rows of teeth which migrate forward, replacing older ones, throughout their life. To find prey, sharks have redundant sensory systems like their olfactory system, eletroreception, lateral line systems (which help them detect water movement and pressure), and sight. A blind shark could still feed and survive. Systems of redundancy and adaptability are not performant. They cost the animal a lot in terms of energy. The metabolic cost for sharks having to replace thousands of teeth over their lifetime requires constantly creating new ones. Maintaining multiple overlapping sensory systems requires a high amount of ‘standby power’. For cockroaches, their distributed neural system isn’t as efficient as having a centralized brain. Neurons are some of the most energy intensive tissues. In humans the brain consumes 20% of the resting energy.
在漫长的时间跨度下,进化选择的是适应性强、鲁棒性高的生物,而不是高度优化、追求极致性能的生物。它选择的是拥有冗余和适应系统的生物。例如,蟑螂拥有去中心化的神经系统。即使切掉蟑螂的头,它依然能站立、行走、逃跑并对刺激做出反应,直到数周后因脱水而死。鲨鱼拥有多排冗余的牙齿。它们没有进化出一套高度专业化但脆弱的牙齿,而是进化出多排牙齿,这些牙齿在生命周期内不断向前移动,替换旧牙。为了寻找猎物,鲨鱼拥有冗余的感官系统,如嗅觉、电感受器、侧线系统(帮助探测水流和压力)以及视觉。即使是一只失明的鲨鱼也能进食并存活。冗余和适应性系统并不追求“高性能”,它们在能量上消耗巨大。鲨鱼一生中更换数千颗牙齿的代谢成本要求它们不断制造新牙。维持多个重叠的感官系统需要大量的“待机功率”。对于蟑螂来说,其分布式神经系统也不如集中式大脑高效。神经元是能量消耗最大的组织之一,在人类中,大脑消耗了静息能量的 20%。
In other words, Sharks and Cockroaches are not efficient creatures. They burn more energy than animals without these redundancies. However, it is these inefficiencies that allow them to survive over extremely long time horizons as species. Performant animals cannot be robust, and robust animals cannot be performant.
换句话说,鲨鱼和蟑螂并不是“高效”的生物。它们比没有这些冗余的动物消耗更多的能量。然而,正是这些“低效”使它们作为物种能够在极长的时间跨度内生存下来。追求极致性能的动物无法做到鲁棒,而鲁棒的动物也无法做到极致性能。
Scarcity Promotes Cooperation not Competition / 稀缺促进合作而非竞争
There is a widespread misunderstanding about competition. We are taught that competition is about scarcity, innovation, and the efficient allocation of resources. In economics, the playground of competition is the market, traditionally defined as the mechanism to allocate scarce resources. Conventional wisdom holds that competitive markets are the most efficient way to achieve this via the price signal.
关于竞争,存在一种普遍的误解。我们被教导竞争关乎稀缺性、创新和资源的有效配置。在经济学中,竞争的舞台是市场,传统上被定义为配置稀缺资源的机制。传统观点认为,竞争性市场是通过价格信号实现这一目标的最有效方式。
But this is a myopic view. We need to look at it systematically. Markets, like evolutionary niches, are engines for local optimization and short-term performance. Competition is really only possible in environments of abundance, not scarcity!
但这是一种短视的观点。我们需要系统地看待它。市场就像进化的生态位,是局部优化和短期绩效的引擎。竞争实际上只可能存在于资源丰富的环境中,而非稀缺环境中!
Let’s look at ecology for a moment. The ecologists Mark Bertness and Ragan Callaway developed the Stress-Gradient hypothesis. The hypothesis states that as environmental conditions become more severe and resource-scarce, positive non-trophic interactions like facilitation, mutualism, and cooperation systematically replace competition. For example, in lush resource rich grass lands, plants compete with each other to get sunlight and canopy space. However, in salt marshes, alpine tundra, and deserts, plants clump together.
让我们看看生态学。生态学家马克·伯特内斯(Mark Bertness)和雷根·卡拉威(Ragan Callaway)提出了“压力梯度假说”(Stress-Gradient hypothesis)。该假说指出,随着环境条件变得更加严酷和资源稀缺,促进、互利共生和合作等积极的非营养性相互作用会系统性地取代竞争。例如,在资源丰富的茂盛草地上,植物为了争夺阳光和冠层空间而相互竞争。然而,在盐沼、高山苔原和沙漠中,植物却会聚在一起。