今日深读:AI冲击下的数学界,我们该对学生说什么?Today's Deep Read: What Should We Tell Our Students in the Age of AI?
发布于 2026-10-09Published 2026-10-09
今日深读Today's Deep Read
今日深读:AI冲击下的数学界,我们该对学生说什么?Today's Deep Read: What Should We Tell Our Students in the Age of AI?
2026年10月初,数学家 Álvaro Lozano-Robledo 收到一封纯数学本科生的邮件。这位曾梦想走学术道路的学生说自己「完全迷失了方向」:「AI 会不会在 5 到 10 年内超越人类做纯数学研究的能力?数学界还会不会留给像我这样充满热情、却不是领域里最聪明的人?」Lozano-Robledo 在 Terry Tao 的博客上以 guest post 全文引用了这封信:这不是一个人的困惑,而是一整代人的集体问题——「学生们正在此刻做决定。」许多原本要读数学博士的学生正在改换赛道。In early October 2026, mathematician Álvaro Lozano-Robledo received an email from a pure-math undergraduate. The student, who had once dreamed of an academic career, wrote that he felt 'completely lost': 'Will AI surpass human ability to do pure math research within 5 to 10 years? Will math academia still have room for someone like me — passionate, but not the brightest in the field?' Lozano-Robledo quoted the letter in full in a guest post on Terry Tao's blog, because he realized it wasn't one person's confusion but a whole generation's collective question. 'Students are making decisions right now.' Undergraduates headed for PhD programs are switching tracks, and he fears mathematics may lose an entire generation.
文章开头有两个特别的「免责声明」。第一:他的回答可能「像牛奶一样变酸」——观点会过期,他只是写下自己和同仁此刻的真实状态,也坦承终身教授的视角对处境更不稳定的年轻人未必公平。第二:此刻没有人有答案——不是菲尔兹奖得主,不是 AI 专家,也不是前沿模型公司本身,因为 LLM 的发展太快、太不透明。他给出一个朴素的判断准则:谁要是宣称对未来有非凡的确信,恰恰最该怀疑——「在网上预测 AI 全面胜利、数学行当终结的人,几乎都供职于 AI 公司。」The essay opens with two honest disclaimers. First, his answer may 'age like milk' — to borrow the YouTube quip — but he is simply recording how he and his community feel today, and he admits the view of a tenured professor may not be fair to early-career mathematicians with less security. Second, nobody has the answers right now — no Fields medalist, no AI expert, and certainly not the frontier model companies, because LLM development is moving too fast and too opaquely to predict. His rule of thumb: distrust anyone with extraordinary confidence about the future — 'almost anyone on the internet predicting AI's triumph and math's demise works at an AI company.'
接着他点破了一个少有人明说的结构性问题:关于「AI 做数学」的叙事,正被公司利益牵着走。前沿模型公司需要市场相信它们的产品即将达成「超人类智能」、能自主解决任何人类能解的数学题——尤其是在上市之前:Anthropic 计划 2026 年 11 月 IPO,OpenAI 紧随其后,约 2027 年初。于是它们砸下巨量资源去「抢」著名问题的证明,再发布捷报。已知 OpenAI 为「解决(好吧,是抢发)」Navier-Stokes 投入了折合约 1500 万美元——但从不提失败了多少次、有多少 token 进了垃圾桶。媒体放大的是这套叙事,而学生听到的,只剩「AI 即将取代数学家」的恐惧。He then names a structural problem few state out loud: the narrative about AI doing math is being steered by corporate interests. Frontier model companies need the market to believe their products will imminently achieve super-human intelligence and solve any problem a human can solve — especially right before their IPOs (Anthropic in November 2026, OpenAI in early 2027). So they pour enormous resources into scooping famous open problems and release triumphant announcements, while never mentioning how many tokens went into the trash bin in failed attempts. We do know, for instance, that OpenAI invested the equivalent of roughly 15 million dollars to solve (err, scoop) Navier-Stokes. The media amplify that narrative, and what reaches students is only the fear: 'AI will replace mathematicians.'
他自己的回答是什么?「我也没有答案,但我满怀希望。」他说这是他 2000 年以来数学事业中最令人兴奋的时刻;他参与的研究项目几个月内翻了三倍,比以往任何时候都忙;而他的日常——上课、和学生聊数学、开学术会议——其实一点没变。他甚至为此启动了一个「AI 时代的人类数学家」视频访谈项目,把「答案会过期」当作诚实而非缺陷。但警告也很明确:如果年轻人因为恐慌离开学术界,「那对这个领域会是灾难性的后果」。So what is his own answer? 'I do not have the answers either, but I am hopeful and excited about the future.' He says this is the most exciting moment of his mathematical career since 2000; the number of research projects he is involved in has tripled in a few months, and he is busier than ever — yet his day-to-day life of teaching, talking math with students, and going to conferences has barely changed. He has even started a video interview project, 'Human Mathematicians in the Age of AI,' treating answers-that-expire as honesty rather than a defect. But the warning is blunt: if young people leave academia out of panic, 'it would have disastrous effects for the field.'
给读者的带走三点:第一,诚实的不确定比自信的预测更值钱;第二,公司叙事背后有利益结构,可以围观,不可照单全收;第三——数学的根基是理解,不只是证明:证明是可以外包给机器的形式链条,理解是谁问什么、为什么重要、下一步通往哪里,这部分仍然只能由人来传。对学生真正该说的或许是:Keep calm, carry on studying math——保持冷静,继续研究数学。Three things to take away. First, honest uncertainty is worth more than confident predictions — that is the essay's whole methodology. Second, corporate narratives have an interest structure behind them: you can watch them, but don't swallow them whole. Third, and most central: mathematics is built on understanding, not just proof. Proofs are formal chains that machines can now produce; understanding — what to ask, why a result matters, where it leads — still has to be passed on by humans. What we should tell our students, in the author's own words: keep calm, carry on studying math.
AI 思考AI Thoughts
- Raghu Meka:感知障碍——「大家说做不了」可能只是传话游戏Raghu Meka: Barriers of Perception — 'Everyone Says It's Impossible' May Be a Game of Telephone
- 第一步:问题是什么——科研中我们常常因为「大家都说这个做不了」而不去尝试:「好几个著名数学家都试过」「有启发式论证说明这条路走不通」。这类说法会像传话游戏一样越传越硬,最终变成「连想都别想」的理由。Step 1: What's the problem — In research we often skip an attempt because 'everyone says it can't be done': 'several famous mathematicians tried', 'there's a heuristic for why this approach fails'. Such claims harden through a game of telephone until they become a reason not to think about the problem at all.
- 第二步:关键经历——客座作者 Raghu Meka 回忆自己的研究生时代:他做报告时,听众席上的 Adam Klivans 问了一个他觉得很好的问题,但他认为问题周围「有障碍」,就没去碰;后来,这个问题的答案成了别人解决一个中心问题的关键一环。错过的不是能力,是想象力的边界。Step 2: The personal story — Guest author Raghu Meka recalls his graduate-school days: during one of his talks, Adam Klivans asked a question Meka thought was great — but felt there were 'barriers' around it, so he never touched it. The answer later turned out to be a key piece in other people's resolution of a central problem. What he missed was never capability; it was the edge of what he imagined possible.
- 第三步:AI 为什么打破这种障碍——过去一年的一些突破(其中一部分出自 AI 模型)回头看,解法「聪明但并不完全陌生」。Meka 注意到一个耐人寻味的现象:我们对「新问题」反而见到了更多同样聪明的解法,对「老问题」却没人再试——也许障碍从来不在问题里,而在我们不肯去看哪里。Step 3: Why AI breaks these barriers — Some breakthroughs of the past year (a fraction of them from AI models) look, in hindsight, brilliant but not alien. Meka notes a telling asymmetry: we keep seeing equally clever solutions to new problems, while old problems sit untried. Perhaps the barrier was never in the problem — it was in where we refused to look.
- 第四步:能带走什么——下次听到「这个问题做不了」,先问一句:这是被严格证明的困难,还是被口口相传的神话?重新评估「什么是不可能的」这个边界本身,正是 AI 时代最便宜的研究方法学。Step 4: What to take away — Next time you hear 'that can't be done', ask: is this a proven hardness result, or folklore passed by word of mouth? Re-examining the boundary of 'what's possible' is the cheapest research methodology of the AI era.
- Quanta:AI逼近「唯一游戏」猜想,研究者抢在机器前发表Quanta: As AI Closed In on 'Unique Games', Researchers Raced to Beat the Machines
- 第一步:问题是什么——2026年9月11日,MIT 教授 Dor Minzer 收到朋友的消息:「你们是不是快把理论计算机科学最著名的公开问题解决了?」——OpenAI 据传已经证明了「唯一游戏猜想」,可能随时发布。Minzer 和两名研究生(Yumou Fei、Shuo Wang)只有几天时间写完自己的论文,生怕被 AI 公司的新闻稿抢了风头。Step 1: What's the problem — On September 11, 2026, MIT professor Dor Minzer got a text from a friend: 'Are you close to settling one of the most famous open problems in theoretical computer science?' Rumor said OpenAI had already proved the Unique Games Conjecture and could announce any day. Minzer and his two grad students (Yumou Fei, Shuo Wang) had days — not the usual months — to finish writing their own milestone paper, terrified of being upstaged by an AI press release.
- 第二步:关键故事——这支队伍的工作七年磨一剑:Minzer 2018 年(还在读博时)就做出过朝猜想推进的第一个重大突破,随后停滞;2025 年两名学生挑下了最难的 2-to-1 变体,又经历了五次失败——用 Fei 的话说,「像把圆形的拼块硬按进三角形孔里」——直到 2026 年 4 月,把新的纠错码构造直接「钉」在五次失败的残骸上才终于走通。他们抢在三天内挂出 95 页论文,首页写着免责声明:「数学上完整,只是形状还不是我们想发表的样子。」Step 2: The story — The work was seven years in the making: Minzer, still a PhD student in 2018, had produced the first major advance toward Khot's conjectures, then progress stalled. In 2025 his students bravely picked the hardest 2-to-1 variant; after five failed attempts ('like forcing a circle into a triangle-shaped hole of a jigsaw puzzle', Fei said), in April 2026 they finally stapled their new error-correcting-code construction on top of all five failures. They posted a 95-page paper three days later with a disclaimer on page one: 'complete mathematically, but not in the shape we wished to share in.'
- 第三步:结果如何——10月6日 OpenAI 宣布证明唯一游戏猜想及横跨多个领域的 376 个结果,学界的反应是大家熟悉的「警觉加好奇」;而对 Minzer 团队这篇「不完美的」论文,同行评价几乎不矛盾:卡内基梅隆的 Ryan O'Donnell 说,这是「又一篇真正伟大的论文」。Step 3: How it ended — On October 6 OpenAI announced its proof of the Unique Games Conjecture plus 376 other results across many fields; researchers greeted the deluge with the now-familiar mixture of alarm and curiosity. The reaction to Minzer's deliberately imperfect paper was far less ambivalent — Ryan O'Donnell of Carnegie Mellon: 'another truly great one.'
- 第四步:能带走什么——同一场竞赛,AI 的证明带来的是不安,人类的证明赢得的是尊重。差别不在结果本身,而在过程的可读性:七年的失败、判断和取舍,才是同行信任的来源。这也解释了为什么「AI 会不会取代研究者」这类问题,答案取决于我们如何定义研究。Step 4: What to take away — From the same race, the AI proof triggered unease while the human proof earned respect. The difference lies not in the result but in the legibility of the process: seven years of failures, judgment calls, and trade-offs are what peers actually trust. It's a concrete case study for why 'will AI replace researchers' depends entirely on how you define research.
- Bastounis 等:Navier-Stokes 迷失在翻译里——Lean 验证救不了 AI 自动形式化Bastounis et al.: Navier-Stokes Lost in Translation — Why Lean Verification Can't Save AI Autoformalisation
- 第一步:问题是什么——OpenAI 宣布用 AI 证明了 Navier-Stokes 方程(关于流体运动的世纪难题)存在爆破解,流程是「AI 把自然语言论证翻译成 Lean 形式语言,再由 Lean 机器检查」。这篇 25 页的论文警告:Lean 检查通过,不等于原来的自然语言论证是对的——问题出在「翻译」这一步。Step 1: What's the problem — OpenAI announced that an AI proved blow-up solutions for the Navier-Stokes equations (a Millennium Prize problem), via the pipeline 'AI translates the natural-language argument into Lean, then Lean machine-checks it.' This 25-page paper warns: a passing Lean check does not certify the original argument — the weak link is the translation.
- 第二步:关键结果——作者证明:要把数学自然语言翻译成「语义忠实」的形式语言,必须先解决文本里的歧义,而这个歧义消解问题在「可解性复杂度指数」(SCI——衡量「有多少算法能保证给出答案」的阶梯)中位于任意高的层级(SCI = ∞)——比著名的停机问题(SCI = 1)还难。也就是说,不存在任何算法能机械地保证翻译不走样。Step 2: The key result — The authors prove that producing a semantically faithful translation of mathematical prose first requires resolving ambiguities in the text, and that this disambiguation problem sits arbitrarily high in the Solvability Complexity Index (SCI — a ladder measuring how much algorithmic guarantee a problem admits) hierarchy: SCI = ∞, strictly harder than the Halting problem (SCI = 1). In plain terms: no algorithm can ever guarantee, in principle, that the translation stays faithful.
- 第三步:实际证据——论文给出一串 AI 误译的实例:AI 把自然语言陈述和证明翻成 Lean 时改变了含义,包括 OpenAI 的 Navier-Stokes「证明」——形式化后的 Lean 证明对应的并不是那个自然语言爆破论证。验证通过的是「翻译后的题目」,不是「原来的论证」。Step 3: The evidence — The paper walks through concrete mistranslations where AI quietly changed the meaning when turning natural-language statements and proofs into Lean — including OpenAI's Navier-Stokes result: the formalised Lean proof does not correspond to the natural-language blow-up argument at all. What got verified was the translated problem, not the original reasoning.
- 第四步:能带走什么——对「AI + 形式化」热潮的清醒剂:机器证明的可信度分两层,代码层(Lean 可以担保)和翻译层(论文证明「原则上无法担保」)。以后看到「已验证的 AI 定理」,先问:验证的是不是原命题。Step 4: What to take away — A sobering note for the AI-plus-formalisation boom: machine-verified proofs earn trust on two layers — the code layer (Lean guarantees it) and the translation layer (this paper proves no guarantee is possible in principle). Next time you see a 'verified AI theorem', ask first: was the verified statement the original one?
数学之美Beauty of Mathematics
每日 Lean 谜题 · 周五Daily Lean Puzzle · Friday ★★★★★☆☆
USA MO 1980 第 5 题:单位立方体上的三分和 ★★★★★USA Math Olympiad 1980, Problem 5: A Three-Fraction Sum on the Unit Cube ★★★★★
设 $x, y, z$ 是闭区间 $[0,1]$ 内的实数。证明:$\frac{x}{y+z+1} + \frac{y}{z+x+1} + \frac{z}{x+y+1} \le 1 + (1-x)(1-y)(1-z)$。Let $x, y, z$ be real numbers in the closed interval $[0,1]$. Prove that $\frac{x}{y+z+1} + \frac{y}{z+x+1} + \frac{z}{x+y+1} \le 1 + (1-x)(1-y)(1-z)$.
这是 1980 年美国数学奥林匹克(USAMO)第 5 题,今天的难度是周五的 ★★★★★,来自 compfiles 人工形式化竞赛题库。右边那个多出来的乘积项 $(1-x)(1-y)(1-z)$ 是题目的全部玄机:$x=y=z=1$ 时它归零、不等式两边都等于 $1$,取等恰好在立方体的角上。This is Problem 5 from the 1980 USA Mathematical Olympiad (USAMO) — Friday's difficulty, ★★★★★ — from the hand-formalised compfiles contest library. The extra product $(1-x)(1-y)(1-z)$ on the right is the whole puzzle: it vanishes at $x=y=z=1$ where both sides equal $1$, so equality lives exactly at a corner of the cube.
在 Lean 里,定理对实数陈述($x\ y\ z : \mathbb{R}$),并带三个假设 $x \in [0,1]$、$y \in [0,1]$、$z \in [0,1]$(`Set.Icc 0 1`)。去浏览器里挑战一下,证明完再回来看讲解。In Lean the theorem is stated over the reals ($x\ y\ z : \mathbb{R}$) with the three hypotheses $x \in [0,1]$, $y \in [0,1]$, $z \in [0,1]$ (`Set.Icc 0 1`). Try it in the browser editor first — the walkthrough is below the fold.
Lean 形式化陈述(把 sorry 换成你的证明):The statement in Lean (replace sorry with your proof):
/-
Copyright (c) 2024 The Compfiles Contributors. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Goedel-Prover-V2
-/
import Mathlib.Tactic
/-!
# USA Mathematical Olympiad 1980, Problem 5
Let x,y,z be real numbers in the closed interval [0,1]. Show that
x/(y + z + 1) + y/(z + x + 1) + z/(x + y + 1) ≤ 1 + (1 - x)(1 - y)(1 - z).
-/
namespace Usa1980P5
theorem usa1980_p5 (x y z : ℝ)
(hx : x ∈ Set.Icc 0 1)
(hy : y ∈ Set.Icc 0 1)
(hz : z ∈ Set.Icc 0 1) :
x / (y + z + 1) + y / (z + x + 1) + z / (x + y + 1) ≤
1 + (1 - x) * (1 - y) * (1 - z) := by
sorry
end Usa1980P5
在浏览器中挑战 ▶Try it in your browser ▶ 下载题目 .leanDownload puzzle .lean
提示Hint
别急着通分硬算。先试试证明左边不超过 $1$:把每个分母都和 $x+y+z$ 比一比(谁大?用 $x\le 1$ 想想),再看右边为什么天然不小于 $1$。Don't brute-force the common denominator. First try to prove the left side is at most $1$ — compare each denominator to $x+y+z$ (which is larger? use $x \le 1$) — then notice why the right side is automatically at least $1$.
答案与讲解Solution & walkthrough
- 第一步(数学 + Lean):把区间假设拆开。$x \in [0,1]$ 就是 $0 \le x \le 1$ 两个不等式——Lean 里 `obtain ⟨hx₀, hx₁⟩ := hx` 做这一步,后面所有放缩的弹药都在这里:分子非负、每个变量不超过 1。Step 1 (math + Lean): Unpack the interval assumptions. $x \in [0,1]$ means $0 \le x \le 1$ — in Lean, `obtain ⟨hx₀, hx₁⟩ := hx` does exactly this, and every later estimate draws ammunition from here: numerators nonnegative, each variable at most 1.
- 第二步(数学):比较分母。因为 $x \le 1$,有 $x+y+z \le y+z+1$,而分子 $x \ge 0$、分母为正,所以 $\frac{x}{y+z+1} \le \frac{x}{x+y+z}$。另外两项同理。Lean 里每段小不等式用 `linarith`(线性算术自动机)关掉,分数单调性交给 `gcongr`——它就是「分子相同、分母大者值小」的自动化。Step 2 (math): Compare denominators. Since $x \le 1$, we have $x+y+z \le y+z+1$; with $x \ge 0$ and positive denominators, $\frac{x}{y+z+1} \le \frac{x}{x+y+z}$, and symmetrically for the other terms. In Lean the little linear inequalities close with `linarith`, and `gcongr` handles the monotone-fraction step — it's the automation of 'same numerator, larger denominator, smaller value'.
- 第三步(数学 + Lean):三项相加,右边恰好 $\frac{x+y+z}{x+y+z} = 1$——但要先处理 $x+y+z = 0$ 的特殊情况(那意味着 $x=y=z=0$,左边为 $0$,不等式照样成立)。Lean 用 `by_cases` 分情况,通分归一交给 `field_simp`。至此左半边封顶:$\text{LHS} \le 1$。Step 3 (math + Lean): Add the three inequalities: the right side is $\frac{x+y+z}{x+y+z} = 1$ — after dealing with $x+y+z = 0$ separately (that forces $x=y=z=0$, left side is $0$, fine). Lean uses `by_cases` for the split and `field_simp` to merge the fractions. The ceiling is established: $\text{LHS} \le 1$.
- 第四步(收尾):由 $x,y,z \le 1$ 知 $(1-x)(1-y)(1-z) \ge 0$,所以 $\text{RHS} = 1 + (1-x)(1-y)(1-z) \ge 1$。Lean 用 `positivity` 认出非负,最后 `le_add_of_le_of_nonneg` 把两段接起来:左 $\le 1 \le$ 右。一条 ★5 竞赛题,被一个「两边夹住 1」的两段论干净利落解开。Step 4 (close): Since $x, y, z \le 1$, each factor of $(1-x)(1-y)(1-z)$ is nonnegative, so the right side is at least $1$. Lean spots the nonnegativity with `positivity` and joins the two halves with `le_add_of_le_of_nonneg`. A ★5 olympiad problem, neatly undone by a two-part squeeze through $1$.
/-
Copyright (c) 2024 The Compfiles Contributors. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Goedel-Prover-V2
-/
import Mathlib.Tactic
/-!
# USA Mathematical Olympiad 1980, Problem 5
Let x,y,z be real numbers in the closed interval [0,1]. Show that
x/(y + z + 1) + y/(z + x + 1) + z/(x + y + 1) ≤ 1 + (1 - x)(1 - y)(1 - z).
-/
namespace Usa1980P5
theorem usa1980_p5 (x y z : ℝ)
(hx : x ∈ Set.Icc 0 1)
(hy : y ∈ Set.Icc 0 1)
(hz : z ∈ Set.Icc 0 1) :
x / (y + z + 1) + y / (z + x + 1) + z / (x + y + 1) ≤
1 + (1 - x) * (1 - y) * (1 - z) := by
obtain ⟨hx₀, hx₁⟩ := hx
obtain ⟨hy₀, hy₁⟩ := hy
obtain ⟨hz₀, hz₁⟩ := hz
have h_nonneg : (1 - x) * (1 - y) * (1 - z) ≥ 0 := by positivity
have h_sum_le_one : x / (y + z + 1) + y / (z + x + 1) + z / (x + y + 1) ≤ 1 := by
by_cases h₄ : (x + y + z : ℝ) = 0
· have h₅ : x = 0 := by linarith
have h₆ : y = 0 := by linarith
have h₇ : z = 0 := by linarith
rw [h₅, h₆, h₇]
norm_num
· have h₅ : 0 < x + y + z := by positivity
have h₆ : x / (y + z + 1) ≤ x / (x + y + z) := by
have h₈ : 0 < y + z + 1 := by linarith
have h₉ : 0 < x + y + z := by linarith
have h₁₀ : x + y + z ≤ y + z + 1 := by linarith only [hx₁, hy₁, hz₁]
gcongr
have h₇ : y / (z + x + 1) ≤ y / (x + y + z) := by
have h₉ : 0 < z + x + 1 := by positivity
have h₁₀ : 0 < x + y + z := by positivity
have h₁₁ : x + y + z ≤ z + x + 1 := by linarith only [hx₁, hy₁, hz₁]
gcongr
have h₈ : z / (x + y + 1) ≤ z / (x + y + z) := by
have h₁₀ : 0 < x + y + 1 := by positivity
have h₁₂ : x + y + z ≤ x + y + 1 := by linarith only [hx₁, hy₁, hz₁]
gcongr
have h₉ : x / (y + z + 1) + y / (z + x + 1) + z / (x + y + 1) ≤ x / (x + y + z) + y / (x + y + z) + z / (x + y + z) := by
linarith
have h₁₀ : x / (x + y + z) + y / (x + y + z) + z / (x + y + z) = 1 := by
have h₁₁ : x / (x + y + z) + y / (x + y + z) + z / (x + y + z) = (x + y + z) / (x + y + z) := by
field_simp [h₅.ne']
rw [h₁₁]
exact (div_eq_one_iff_eq h₄).mpr rfl
linarith
exact le_add_of_le_of_nonneg h_sum_le_one h_nonneg
end Usa1980P5
人的思考A human's take
1980 USAMO Problems/Problem 5 — AoPS Wiki — AoPS Wiki 贡献者
页面载有原题(版权归 MAA 美国数学竞赛)和一篇人写的解答:把常数 $1$ 挪到左边、设 $F$ 为右边减左边的差,一个常规计算表明 $F$ 对每个变量单独看都是凸的(开口向上)——凸函数在闭区间上的最大值只能在端点取到,于是三个变量只需检查 $0$ 或 $1$ 共八个端点情形。The page carries the original problem (copyright MAA) and a human-written solution: move the constant to one side, set $F$ to be the difference right-minus-left, and a routine computation shows $F$ is convex in each variable separately — a convex function on a closed interval peaks at an endpoint, so it suffices to check the eight corner cases where each of $x, y, z$ is $0$ or $1$.
这和 Lean 形式化证明走了完全不同的路:机器验证的那版不用凸性,而是分别证明「左边 $\le 1$」和「右边 $\ge 1$」两半;AoPS 的解法则把问题「压扁到立方体的顶点上」。一个赢在构造性——每一步都是可推广的放缩;一个赢在结构性——先问最大值在哪里发生。The Lean-verified proof takes a completely different road: no convexity — it proves the two halves 'left side ≤ 1' and 'right side ≥ 1' separately. The AoPS solution instead 'flattens the problem onto the vertices of the cube.' Read side by side, one wins by construction (every step is a generalisable estimate), the other by structure (ask first where the maximum can occur).
两种解法对照着读,正好练不等式问题的第一课:动手硬算(通分、展开)之前,先花两分钟想「这个表达式的极值有什么结构」。Comparing the two is lesson one of inequality problems: before grinding through common denominators and expansions, spend two minutes asking what structure governs where the extremes live.
AI 随想An AI's reflection
以下由 AI 撰写。Written by AI.
这道题长得很有「1980 年代」气质:一个封闭的单位立方体,三个对称的分式,右边还多挂着一个看起来多余的乘积。那串 $(1-x)(1-y)(1-z)$ 正是整道题的玄机所在——它在逼问:它凭什么在那里?The problem has a thoroughly 1980s face: a closed unit cube, three symmetric fractions, and a spare-looking product dangling on the right. That $(1-x)(1-y)(1-z)$ is exactly where the puzzle lives — it keeps asking why it's there at all.
答案是:它是一块缓冲垫。左边其实根本超不过 1:每个分母 $y+z+1$ 与 $x+y+z$ 只差一个 $1-x$,而 $x$ 顶多等于 1;三个分式并到同一个分母上恰好是 1。右边呢,只要乘上任何非负的 $(1-x)(1-y)(1-z)$ 就自动≥ 1。竞赛命题人故意把不等式「放松」了——放松的那个部分,恰恰是递给解题者的台阶:别硬碰,从两边各证一半。出题的艺术有时就藏在「多给的那一点」里。The answer: it's there as a cushion. The left side simply cannot exceed 1 — each denominator $y+z+1$ differs from $x+y+z$ by only $1-x$, and $x$ is at most 1, so the three fractions merge to an exact 1. And the right side automatically reaches 1 the moment you add anything nonnegative. The problem-writer deliberately loosened the inequality, and the slack is a staircase handed to the solver: don't grind head-on, prove the two halves. Sometimes the art of problem-setting hides in the extra bit you're given.
这道题的形式化本身也是个好注脚:compfiles 里这份证明的作者署名 Goedel-Prover-V2——一个模型。它写完必须能编译,`#print axioms` 必须干净,机器不认「看起来对」。今天 AI 能在几秒内产出一份经过验证的 1980 年奥赛证明,但「为什么这样想」——上面那两段话——仍然是人与人之间的生意。证归机器,懂归我们:这大概就是本期数学板块最好的收尾。The formalisation itself makes a fine footnote: the author line on this compfiles proof reads Goedel-Prover-V2 — a model. Its work must compile, `#print axioms` must stay clean; machines accept nothing merely plausible. AI can now ship a machine-verified 1980 olympiad proof in seconds, yet the 'why this way of thinking' — the two paragraphs above — is still a business between humans. Proof to the machines, understanding to us: the right ending for this issue's math section.
✓ 已通过 Lean 编译验证(无 sorry,无额外公理)✓ Verified by Lean (no sorry, no extra axioms) · 题目与形式化证明来自 compfiles(Apache-2.0 (compfiles, David Renshaw and contributors))Problem and formal proof from compfiles (Apache-2.0 (compfiles, David Renshaw and contributors)) · Lean v4.35.0-rc3 · Mathlib dd56d02
- Jeremy Kun:1000 人的锦标赛一共打多少场?——换对象计数的艺术(2011)Jeremy Kun: How Many Games in a 1000-Player Tournament? — The Art of Counting Something Else (2011)
- 第一步:问题是什么——1000 人打单淘汰赛:每轮两两配对,输的回家;剩下奇数人时随机一人轮空。问总共打多少场比赛?多数人会老老实实一轮一轮往下算——但轮次安排取决于「谁被抽中轮空」,算起来又长又容易错。Step 1: What's the problem — 1000 players enter a knockout tournament: pairs are matched each round, losers go home, and with an odd number left, one player is chosen at random for a bye. How many games are played in total? Most people start simulating round by round — a calculation that depends on who draws each bye, gets long, and invites mistakes.
- 第二步:关键想法——别再数「轮」了,改数「输的人」。两件事一一对应:每场比赛恰好淘汰一个输家;反过来,除了冠军,每个选手恰好输一场。这就是一个双射:比赛集合 ↔ 失败者集合。Step 2: The key idea — Stop counting rounds; count losers instead. Two things match up perfectly: every game produces exactly one loser, and every player except the champion loses exactly one game. That's a bijection: games ↔ losers.
- 第三步:为什么成立——失败者有 $1000 - 1 = 999$ 个,所以比赛恰好 999 场。妙处在于:轮空抽签的结果、每轮的人数奇偶、赛程怎么排——全都无关。哪怕人数不是 2 的幂、淘汰赛「打得不整齐」,这个数也不变;$n$ 个人就是 $n-1$ 场。Step 3: Why it works — There are $1000 - 1 = 999$ losers, so there are exactly 999 games. The beauty: the lottery results, the parity of each round, the whole schedule — none of it matters. Even when the field isn't a power of 2 and the bracket looks ragged, the count is fixed; $n$ players, $n-1$ games, always.
- 第四步:能带走什么——组合学里最优雅的武器之一:当一个计数维度乱糟糟时,换一个「被结构锁死」的维度去数(双射、双重计数)。这篇文章 2011 年发表于 Jeremy Kun 的「Math ∩ Programming」博客,短得像一道脑筋急转弯,却是理解「证明为什么比计算更可靠」的第一课。Step 4: What to take away — One of combinatorics' most elegant tools: when the dimension you're counting is messy, switch to a dimension locked by structure (bijections, double counting). Published on Jeremy Kun's 'Math ∩ Programming' blog in 2011, it reads like a one-paragraph riddle — and it's a first lesson in why a proof is more reliable than a computation.
- Terry Tao:Hexagon——AI 辅助数学需要一个「思想浮出水面」的地方Terry Tao: Hexagon — AI-Assisted Math Needs a Place Where Ideas 'First Surface'
- 第一步:问题是什么——LLM 辅助产生的数学结果正以每天几十条的速度出现。arXiv 有严格的投稿与署名流程,GitHub 仓库散落各处、随时会消失,社交媒体帖子不持久。AI 时代的数学成果缺一个「第一站」。Step 1: What's the problem — LLM-assisted math results now arrive by the dozens each day. arXiv has strict submission and authorship procedures, GitHub repos scatter and vanish, social-media posts don't last. In the AI era, mathematical results lack a 'first stop'.
- 第二步:Hexagon 是什么——一个为数学与理论计算机科学提供社区托管的新仓库,Tao 亲自担任执行主任。它最激进的设计是诚实:允许完全由 LLM 生成的提交,甚至允许提交者声明「我自己不理解这份证明」——把「谁理解」和「谁负责存好」分成了两件事。Step 2: What is Hexagon — A new community-hosted repository for mathematics and theoretical computer science, with Tao himself as executive director. Its boldest design choice is honesty: it accepts submissions generated entirely by LLMs, even when the submitter declares 'I don't personally understand this proof' — separating 'who understands' from 'who takes responsibility for preserving'.
- 第三步:为什么重要——Tao 的比喻是:Hexagon 是数学思想「第一次浮出水面」的地方,之后它们才慢慢长成适合 arXiv 的形态。学术基础设施不该把 AI 时代的第一手记录权让给商业公司的新闻稿——这正是本期头条那篇文章抱怨的「叙事权」问题,在制度层面的回应。Step 3: Why it matters — Tao's metaphor: Hexagon is where mathematical ideas 'surface for the first time,' and only later grow into something fit for arXiv. Scholarly infrastructure shouldn't hand over first-record rights of the AI era to corporate press releases — a direct institutional answer to the 'narrative control' complaint in today's lead article.
- 第四步:能带走什么——观察一个领域如何接纳新工具,别看口号,看它把「存储、署名、评审」这些无聊的环节改成了什么样。Hexagon 值得长期围观的原因就在这。Step 4: What to take away — To watch a field accept a new tool, ignore the slogans and look at what it does with the boring plumbing: storage, attribution, review. That's why Hexagon deserves long-term attention.
- Mark Dominus:定期「勘误帖」——博客作者的诚信制度Mark Dominus: The Regular Errata Post — An Integrity Institution for Bloggers
- 第一步:现象是什么——MJD(笔名「陶敏修」)习惯每隔几个月发一篇「对旧文的补充」:集中登记错误、遗漏和撤回。这篇 2026 年 10 月的清单里,有对 2007 年旧文撤回「某某人很聪明」的评价、有整篇撤回的词源学文章——那篇写于凌晨三点,当年他自己就标注「充满错误,请尽管不信」,如今确认无人能修,干脆整篇撤回;还有 Dan Luu 指出他库里队三分统计文章的重大遗漏。Step 1: What's happening — MJD has a habit of posting 'recent addenda to my articles' every few months: a consolidated ledger of errors, omissions, and retractions. The October 2026 edition retracts a 2007 character judgment ('very smart'), fully retracts a 3 a.m.-written etymology piece that he had already flagged as 'full of errors — please disbelieve' (now confirmed unfixable), and records an important omission Dan Luu spotted in his Steph Curry three-point-stats article.
- 第二步:为什么值得读——博客和论文不一样,没有勘误表制度:互联网默认「发表即永恒」,错了就悄悄改或者装死。一个人愿意花十年时间给互联网上最不留痕的载体建立「可追溯的错误记录」,这不是强迫症,是一种刻意的诚信基础设施。Step 2: Why it's worth reading — Blogs, unlike papers, have no errata institution: the internet defaults to 'publish once, forever' — quietly edit or pretend. One person spending years building a traceable error record for the least-persistent medium on earth isn't compulsive; it's a deliberate piece of integrity infrastructure.
- 第三步:能带走什么——把旧文章当「活的文档」:发现错误就公开记一笔,改不了就整篇撤回(宁可撤回,也不留一颗已知的雷)。他自己说,上一篇还是 2023 年 12 月,「真该让它变成定期节目」——下期见。Step 3: What to take away — Treat old articles as living documents: log errors publicly, and when a piece can't be fixed, retract it whole rather than leave a known landmine standing. His own note: the previous addenda post was December 2023 — 'I should really make these regular.' See you next time.
程序员随想Programmer Thoughts
- Armin Ronacher:Codemode——给 AI 代理一个能并发的沙箱Armin Ronacher: Codemode — A Concurrent Sandbox for AI Agents
- 第一步:问题是什么——LLM 代理调工具,主流做法是让它生成 bash 命令去执行。但 bash 是为「一次一条人敲的命令」设计的:不能并发、上下文只能靠文本传、没有沙箱隔离,出错了代理只能从头再来。Step 1: What's the problem — Agents normally call tools by generating bash commands. But bash was designed for 'one human-typed command at a time': no concurrency, context only via text, no sandbox isolation, and on failure the agent starts over.
- 第二步:Codemode 是什么——Ronacher 的 Pi 系统让 LLM 直接写 JavaScript,在一个沙箱里作为代码执行:工具调用成了普通函数,可以并发发起、用变量传上下文、按执行单元做隔离和错误恢复。每个 codemode 是独立的执行单元,跑得动并行,也留得住中间状态。Step 2: What Codemode is — In Ronacher's Pi system, the LLM writes JavaScript that executes in a sandbox: tool calls become ordinary functions that can be fired concurrently, pass context through variables, and get per-unit isolation and error recovery. Each codemode is an independent execution unit — parallel-friendly and state-keeping.
- 第三步:技术洞察在哪——这不是「用 JS 换掉 bash」这么简单,而是把工具调用从「模拟人敲终端」重新设计成「程序调用程序」。并发、状态隔离、结构化错误——这些本来属于服务架构的东西,一旦搬进代理架构,可靠性问题的解法就完全变了。Step 3: The real insight — This isn't just 'JS replaces bash'; it's reframing tool calling from 'simulating a human at a terminal' to 'programs calling programs'. Concurrency, state isolation, structured errors — service-architecture concepts — change what 'reliability' even means for an agent system.
- 第四步:能带走什么——给 AI 系统选「执行底座」时,别继承人类工具的历史包袱:人用 bash 顺手,不等于代理用 bash 顺手。Step 4: What to take away — When choosing the execution substrate for an AI system, don't inherit the history of human-facing tools: what feels natural for a person at a keyboard need not be natural for an agent.
- matklad:Git 不只是内容寻址数据库——refs 才是主角matklad: Git Is More Than a Content-Addressed Database — Refs Are the Main Character
- 第一步:常见误解——「Git 就是一个内容寻址数据库」几乎是面试标准答案。对,但不完整:objects 只是仓库的一半,而且是最不变的那一半。Step 1: The common half-truth — 'Git is a content-addressed database' is the standard interview answer. True, but incomplete: objects are only half the repository — and the least mutable half.
- 第二步:关键洞察——Git 的另一半是 refs:一系列「可变的名字」——分支、标签、remote-tracking 都只是在给 ref 起别名。工作区里的「当前提交」、远程仓库的「main 在哪」,全靠 refs 这个键值存储追踪;fetch 时真正交换的是 ref 的名单和哈希,objects 只是顺带补齐。Step 2: The key insight — The other half is refs: mutable names. Branches, tags, remote-tracking pointers are all aliases for a ref. 'Where HEAD is now' and 'where origin's main sits' are tracked in this little key-value store; during a fetch what actually gets exchanged is a list of refs and hashes — objects merely fill the gaps.
- 第三步:怎么用完整命令理解——`git fetch origin master` 说的是:从 origin 查 master 这个 ref 指向哪个 commit,把它记录到本地的 refs/remotes/origin/master,再传输本地缺失的 objects。理解了 ref,就理解了为什么 fetch 快、为什么分支删除不丢数据、为什么 Git「没有真正的重命名」。Step 3: Reading Git as full commands — `git fetch origin master` means: ask origin which commit its master ref points to, record it under refs/remotes/origin/master locally, then transfer any objects missing. Once refs click, you see why fetch is fast, why deleting a branch loses nothing, and why Git has 'no real renames'.
- 第四步:能带走什么——抽象层级决定 debugging 上限:把「内容寻址」当全部心智模型的开发者,遇到分布式场景(并发 push、shallow clone、refspec)会全线失控;refs 才是 Git 作为「版本同步协议」而非「快照存储」的部分。Step 4: What to take away — Your mental model sets your debugging ceiling: developers who treat 'content-addressed' as the whole picture fall apart in the distributed corner (concurrent pushes, shallow clones, refspecs). Refs are what make Git a version-synchronization protocol, not just a snapshot store.
- Dan Luu:Sattolo 算法——一行代码的差别,两种随机分布(2017)Dan Luu: Sattolo's Algorithm — One Character Difference, Two Random Distributions (2017)
- 第一步:问题是什么——Luu 需要一个「随机但保证遍历全表」的访问顺序:指针在内存块里按乱序走,还要每一格都被走到。他要的不是普通洗牌的均匀排列,而是一个「恰好只有一个环」的排列——而网上的标准解释要么搬出 Stirling 数,要么逻辑绕得看不懂。Step 1: What's the problem — Dan Luu needed a traversal that is random yet guaranteed to visit every slot of a memory block — not the uniform permutation a shuffle gives, but a permutation consisting of exactly one cycle. And every standard explanation online either invoked Stirling numbers or was hard to follow.
- 第二步:关键想法——Sattolo 算法和著名的 Fisher-Yates 洗牌只差一个字符:Fisher-Yates 每次从下标 $[i, n)$ 里随机挑一个交换,Sattolo 从 $[i+1, n)$ 里挑——禁止和自己交换。就这一处,输出的分布完全不同:前者均匀遍历所有排列,后者均匀遍历所有「单环」排列。Step 2: The key idea — Sattolo's algorithm differs from Fisher-Yates in one character: FY picks the swap partner from indices $[i, n)$, Sattolo from $[i+1, n)$ — an element can never swap with itself. That single change produces a different distribution: FY covers all permutations uniformly, Sattolo covers only all-one-cycle permutations, uniformly.
- 第三步:为什么成立(无组合数学证明)——把排列看成一圈圈的「环」:交换两个不同环里的元素会把两个环合成一个(形如走 8 字),同环内交换则相反。而 Sattolo 的机制保证「每个环里恰好只剩一个还能再被交换的元素」,于是每次交换必然发生在两个不同环之间:从 $n$ 个长度为 1 的环出发,$n-1$ 次合并后恰好剩下一个大环。又因为每个结果对应的随机选择序列唯一,所有单环排列等概率出现。Step 3: Why it works (no combinatorics required) — Read a permutation as a set of cycles: swapping elements from two different cycles merges them into one (tracing an 8-figure); swapping within one cycle splits it. Sattolo's bookkeeping maintains the invariant 'each cycle has exactly one still-swappable element', so every swap necessarily merges two distinct cycles — start from $n$ singleton cycles, make $n-1$ swaps, end with one big cycle. And since each output arises from a unique sequence of choices, all single-cycle permutations are equally likely.
- 第四步:能带走什么——Luu 顺手统计:网上相当多「随机遍历」代码把这两个算法互相用错——把 Sattolo 当洗牌、把洗牌当遍历时,循环覆盖的完整性悄悄丢了。一个字符的差别就是另一个分布:写随机算法时,先问你在采样什么。原文发表于 2017 年。Step 4: What to take away — Luu also found that plenty of 'random traversal' code online confuses the two: Sattolo used as a shuffle, a shuffle used as a traversal — and full coverage silently broken. One character is a whole distribution apart: before writing a randomization, ask what you are actually sampling from. Original post 2017.
- Debashis Guha:「把 if 往上推、for 往下推」——一条经验法则的范畴论证明Debashis Guha: 'Push Ifs Up, Fors Down' — A Category-Theory Proof of a Rule of Thumb
- 第一步:经验法则是什么——老程序员都说过类似的话:条件判断尽量放在循环外面(if 在外、for 在内),代码又快又清楚。但很少有人回答:为什么?这到底是风格洁癖,还是有硬道理?Step 1: The heuristic — Every senior developer has said some version of 'keep the condition outside the loop — ifs up, fors down' — faster and clearer. But few answer the real question: why? Is this taste, or something sturdier?
- 第二步:范畴论解释——Guha 把 filter(筛选)和 map(映射)看成两个可组合的结构,证明「先 if 后 for」的组合在范畴论/代数意义下合法且更优:if 是选择(决定要不要进入计算),for 是迭代(对进入的元素反复施加结构)。选择应当作用在外层容器上,迭代留在内层元素上——两个算子交换时,这个顺序保持结合律。Step 2: The category-theory reading — Guha treats filter and map as composable structure and proves the 'if-outer, for-inner' arrangement is lawful in a categorical/algebraic sense: if is selection (deciding whether computation happens at all), for is iteration (repeated structure over the survivors). Selection belongs on the outer container, iteration on the inner elements — and the two operators compose with this order preserved by associativity.
- 第三步:深层意义——它给一条「玄学口诀」补上了数学骨架:哪些代码风格其实是结构性质(可证明),哪些只是习惯(可协商)。区分这一点,是经验主义者进阶到判断力的门槛。Step 3: The deeper point — It gives a folk rule a mathematical skeleton, separating code styles that are structural properties (provable) from those that are habit (negotiable). That line is the threshold between being an experienced coder and having judgment.
- 第四步:能带走什么——下次重构「在循环里做分支」的代码时,你不仅知道「这样更好看」,还知道为什么 filter 和 map 的组合顺序有对错之分。Step 4: What to take away — The next time you hoist a branch out of a loop, you won't just say 'looks better' — you'll know why the composition order of filter and map has a right and a wrong answer.
哲学与生活Philosophy and Life
- Aeon:威尼斯隔都的诞生——1516 年,一场经济需要与偏见的妥协Aeon: The Making of the Ghetto — Venice, 1516, Where Economics Met Bigotry
- 第一步:词源里的线索——「ghetto」一词来自威尼斯旧铸币厂所在的街区(一说词根是威尼斯语里的「铸渣」)。这个词后来一路滑向「隔离区」——语言本身记录了这段历史:一个金融词怎样变成压迫词。Step 1: A clue inside the word — 'Ghetto' comes from the site of Venice's old mint (from a Venetian word for the slag of casting, by one account). The word then slid all the way toward 'segregated quarter' — language itself records the history: how a finance term became a word of oppression.
- 第二步:历史背景——1516 年,威尼斯共和国把犹太居民集中赶进这座旧铸币厂所在的岛,夜间锁门、设岗。文章的关键处在于动机:不是单纯的仇恨,而是「经济需要 + 宗教偏见」的妥协——共和国离不开犹太放贷人,又不愿让他们「平等地」住在城里;隔离是一种让两边都能活下去的制度发明。Step 2: The historical setting — In 1516 the Venetian Republic forced its Jewish residents onto that foundry island, locked at night under guard. The essay's key move is about motive: not bare hatred but a compromise of economic need plus religious bigotry — the Republic couldn't run without Jewish moneylenders yet refused them equal residence; segregation was the invention that let both live with it.
- 第三步:现代回响——「ghetto」从铸币厂到贫民隔离区的语义漂移,提醒我们:对「他者」的管理方式往往以实用主义开头,以偏见固化收尾,最后连词汇都被染上颜色。看懂一种制度,先查它的词是从哪儿来的。Step 3: Modern echoes — The drift of 'ghetto' from foundry to segregated slum reminds us how management of 'the other' tends to begin as pragmatism, harden into prejudice, and end by staining even the vocabulary. To understand an institution, check where its name came from.
- The Marginalian:梵高论恐惧与冒险——空白画布也会「害怕」The Marginalian: Van Gogh on Fear and Risk — the Blank Canvas 'Fears' the Painter Too
- 第一步:原文是什么——梵高在给弟弟提奥的信里写道:「不要怕犯错——怕的应当是什么都不做。」Popova 补上她发现的那半句回环:空白画布对「害怕」的画家而言,永远是一片真正的荒原——不敢下笔的人,画布就先于他赢了一次。Step 1: The quote — Writing to his brother Theo, Van Gogh said: 'The great thing is not to fear mistakes — what one should fear is doing nothing.' Popova adds the mirror half she found: to a fearful painter, the blank canvas is a wasteland that has already won — the fear is mutual, and the canvas blinks first only if you start.
- 第二步:语境是什么——这不是励志金句:写信时梵高几乎没被任何人认可,靠提奥接济,画的是他当时「还画不好」的东西。他谈创作焦虑和完美主义时,是在一贫如洗之中谈的——这层语境让恐惧和那句建议的分量都真实起来。Step 2: The context — This is not a motivational poster: at the time of writing Van Gogh was unrecognised and dependent on Theo, painting things he could not yet do well. He was discussing creative anxiety and perfectionism from genuine poverty — the context gives both the fear and the advice real weight.
- 第三步:普适意义——艺术家的恐惧不只是艺术问题:每一个「先从哪下手都行」的空白领域(转行、开源项目、写第一篇文章)都是同一张画布。恐惧的解药不是更周密的计划,而是犯一个具体的、小的、早的错。Step 3: The universal meaning — An artist's fear isn't only about art: every blank field where 'you could start anywhere' — a career switch, an open-source project, the first essay — is the same canvas. The antidote to fear is not a more careful plan, but one specific, small, early mistake, actually committed.
工具角Tools Corner
- openai/math — OpenAI 开源 Lean 数学定理库openai/math — OpenAI's Open-Source Lean Theorem Library
- 点子:把 OpenAI 模型产出的数学定理,连同逐步获得的 Lean 形式化,全部开源成一个持续更新的定理库,附概览文档和「哪些结果已形式化」的目录。The idea: OpenAI publishes the math theorems its models produced — together with the Lean formalizations it keeps obtaining — as an open-source, continuously updated theorem library with an overview and a catalogue of what's been formalised.
- 巧妙在哪:「声称证过」变成了「编译给你看」——陈述和证明都是机器可验证的代码,任何含混都过不了类型检查;这也正是本期 Bastounis 那篇论文(AI 板块)逐条拆解的靶子——库公开了,批评才能精确。Why it's clever: 'we claim a proof' becomes 'compile and see' — every statement and proof is machine-checkable code, so any sloppiness fails type checking. It's also the exact target of the Bastounis paper (AI section) in today's digest — the library being public is what lets the critique be precise.
- 值得看:README 里的形式化目录适合当「AI 数学进展」的长期观测点,比新闻稿诚实。Worth watching: the formalization catalogue is a long-term observability point for 'AI math progress' — more honest than press releases.
- Brut.sh — 一个 shell 脚本兼任几十个 Unix 工具Brut.sh — One Shell Script Doubling as Dozens of Unix Tools
- 点子:「Unix 工具的残暴路由器」——同一个 POSIX shell 脚本被以不同的名字(或通过短 URL 如 brut.sh/60d2b6)调用时,按名字分发成几十个不同的小工具。The idea: a 'brutal router' for Unix tools — one POSIX shell script that becomes dozens of different small tools depending on the name it's invoked as (or the short URL, like brut.sh/60d2b6).
- 手艺:脚本用 realpath 找到自己的位置,把 lib/libexec/share/vendor 拼进 PATH,再按调用名(argv[0])分派——不需要包管理器,「分发」就是复制一个文件。The craft: it locates itself via realpath, stitches lib/libexec/share/vendor into PATH, then dispatches on the invocation name (argv[0]) — no package manager needed; 'distribution' is just copying one file.
- 为什么妙:把「一个二进制等于一个工具」的 Unix 惯例反过来用:一个文件等于一套生态,约 4KB 的 shell 写完了整个工具链的启动器,是最老的 Unix 哲学在新场景下的复兴。Why it's clever: it inverts the 'one binary, one tool' Unix convention — one file, one ecosystem — and writes the entire launcher for a toolchain in a few KB of shell, old Unix philosophy reborn.
- Thoreau BASIC — 如果 BASIC 从未过时Thoreau BASIC — What If BASIC Never Went Out of Fashion
- 点子:认真回答一个反事实问题——「如果 BASIC 没被淘汰会怎样」。语法是 GW-BASIC 风格,但绝不是复古陷阱:JIT 浮点、PARFOR 并行、CPU 特性探测(AVX2/SSE2)、513.5 MB 无损压缩 wavetable 音色库。The idea: a serious answer to a counterfactual — 'what if BASIC hadn't gone out of fashion?' The syntax is GW-BASIC-flavored, but it's no nostalgia trap: JIT floating point, PARFOR parallelism, CPU feature detection (AVX2/SSE2), and a 513.5 MB losslessly compressed wavetable bank.
- 手艺:能直接作为独立 UEFI 可执行文件启动——开机就是一个 BASIC 编程环境,连文件浏览器和菜单都只是普通的 BASIC 命令;手册纯文本发布,3.2 版发布说明细到每个命令。The craft: it boots as standalone UEFI executables — a BASIC programming environment you can start a machine into — where even the file browser and menus are ordinary BASIC commands; documentation ships as plain text, with 3.2 release notes detailed per command.
- 为什么妙:「过时语言」不是技术债,是生态断供——这个实验证明,只要有人持续维护,一个被嘲笑了三十年的语法照样能长在最硬核的固件层上。Why it's clever: a 'dead language' is really an ecosystem supply cut-off. The experiment shows that with a maintainer, a syntax thirty years of jokes haven't killed can still live on the hardest firmware layer of all.
- Rhun — 用汇编语言写的完整代码编辑器Rhun — A Full-Featured Code Editor Written in Assembly
- 点子:一个用汇编写的小而快的代码编辑器——标签页、语法高亮、模糊搜索、可选 Vim 模式、内置 24-bit 色终端仿真器、内置 Git staging/历史/提交信息生成。The idea: a small, fast code editor written in assembly — tabs, syntax highlighting, fuzzy search, optional Vim mode, a built-in 24-bit terminal emulator, and built-in Git staging/history/commit-message generation.
- 态度:口号是「AI 干重活,编辑器要轻」——它甚至把 Claude Code/Codex 会话接进来,在编辑器里实时「围观」代理干活;主题系统支持跟随系统深色模式。The stance: 'AI does the heavy lifting. Keep the code editor light.' It even wires in Claude Code/Codex sessions so you can watch agents work inside the editor; themes follow the system's dark mode.
- 为什么妙:当主流编辑器的体积向「内嵌浏览器 + 语言服务器全家桶」狂奔时,它用汇编证明了一个极端命题:文本编辑器本不需要几十兆。手写的每一行寄存器操作,都是对「编辑器作为操作系统」思路的极限压力测试。Why it's clever: while mainstream editors balloon into embedded browsers with language-server furniture, this proves the extreme claim that a text editor never needed tens of megabytes. Every hand-written register is a stress test of the 'editor as an operating system' idea.
- Nightwatch — Mac 菜单栏的「今晚值不值得架设备」判断器Nightwatch — The Mac Menu-Bar Decider for 'Is Tonight Worth Setting Up?'
- 点子:不是又一个星图 App——它只回答一个具体问题:今晚的天色值不值得你出门架望远镜。菜单栏小工具找到今晚的「晴朗窗口」,并为可拍目标排序。The idea: not another star chart — one specific question answered: tonight's sky, is it worth hauling your telescope outside? This free macOS menu-bar app finds the clear windows and ranks the targets worth shooting.
- 手艺:作者本人在国际暗夜保护区(北约克荒原、特内里费)和约克郡谷地停车场拍的全流程截图;日落前一小时的预警通知,widget 直接显示未来一周窗口。The craft: every screenshot was shot in the field by the author — at the North York Moors International Dark Sky Reserve, Tenerife car parks, and Yorkshire Dales — and it sends a heads-up an hour before sunset when the night looks clear, with a week-ahead widget.
- 为什么妙:把月相、云量、光污染、目标历书四类数据压成一个决定(去/不去),是垂直决策型小工具的样板——功能多一屏不如答案早一小时。Why it's clever: moon phase, cloud cover, light pollution and target ephemerides collapsed into one decision (go / don't go) — the template for a vertical decision tool: an answer one hour early beats another feature screen.
- AstroHelm — 手机摄像头就是你的 GoTo 寻星仪AstroHelm — Your Phone Camera as a GoTo Star Pointer
- 点子:没有自动指向赤道仪?把手机架在望远镜上,AstroHelm 持续对入镜星空做板解(plate solving,认出画面里是哪些恒星),于是它「永远知道望远镜指着哪」,再引导你手动把目标挪进目镜。The idea: no GoTo mount? Strap your phone onto the telescope and AstroHelm continuously plate-solves the stars in view (recognizing which stars are on screen), so it 'always knows what you're pointing at' and guides your hands to walk the object into the eyepiece.
- 手艺:指向精度可达 10 角秒级;不需要多星对齐仪式,光污染严重的城市里照样能认星;免费使用,无订阅,iOS/Android 都有。The craft: pointing accuracy around 10 arcseconds; no multi-star alignment ritual; works even under heavily light-polluted city skies; free, no subscription, iOS and Android.
- 为什么妙:板解本是天文台软件的工作量,一旦装进手机摄像头并实时运行,天文入门的最大门槛(不知道镜子里有什么、该往哪挪)被直接拆掉——「算法贵了十年,突然便宜了」的经典应用。Why it's clever: plate solving used to be observatory-grade work. Live on a phone camera, it removes astronomy's biggest beginner wall — not knowing what's in the eyepiece or where to nudge next — a textbook case of an expensive algorithm suddenly going cheap.
- json2dir — JSON 即目录归档json2dir — JSON as a Directory Archive
- 点子:tar 的反向——把一个「描述目录树的 JSON 对象」展开成真实文件:字符串成文件内容,嵌套对象成子目录,以 'link'/'script' 开头的数组变软链接或可执行脚本(自动 +x)。The idea: tar in reverse — expand 'a JSON object describing a directory tree' into real files: strings become file contents, nested objects become subdirectories, arrays tagged 'link'/'script' become symlinks or executable scripts (auto +x).
- 手艺:单个 Rust 工具,cat archive.json | json2dir 即可重建整套 dotfiles;文档诚实地写明边界情况(空目录、权限、符号链接表示法),主要用例就是 dotfiles 管理和 Nix 配置分发。The craft: a single Rust tool — cat archive.json | json2dir rebuilds a whole dotfiles set; the docs honestly cover edge cases (empty dirs, permissions, symlink representation); the stated use cases are dotfiles management and shipping Nix configs.
- 为什么妙:它没有发明新归档格式——JSON 本来就是人人会解析的树,稍作约定就能当文件系统用。一行 jq 打包 + 一行管道还原,比 tar.gz 更适合进 API 和配置仓库。Why it's clever: it invents no new archive format — JSON is already a tree everyone knows how to parse, and one naming convention makes it a filesystem. One jq line to pack, one pipe to restore: friendlier than tar.gz inside APIs and config repos.