Bend – A language that blocks AI mistakes via proof, on CPU and GPU
Bend, a new programming language, touts bug-free, fast AI-generated applications via formal proofs and GPU-accelerated execution, aiming to eliminate AI mistakes in a 'post-AGI economy'. However, its unconventional GitHub history and bold claims have ignited fervent skepticism and debate on Hacker News regarding its credibility and the practicality of its formal verification approach. The author actively engaged with critics, clarifying technical details and acknowledging some missteps in project presentation and communication.
The Lowdown
Bend is introduced as a novel programming language designed for a future 'post-AGI economy,' where AI agents write code but require ironclad guarantees against mistakes. It promises C-level speed, GPU parallelism, and formal verification inspired by Lean, all wrapped in Python-like syntax, aiming to ensure AI-generated applications are both fast and reliably bug-free.
- AI Error Blocking: Its core innovation is
LAWS.bend, a mechanism for declaring formal invariants. AI-generated code is mathematically proven against these laws before deployment, theoretically preventing bugs from reaching production. - Performance: Benchmarks on the website claim impressive speed, with up to 124x acceleration on GPUs compared to single-core execution for specific tasks, and notably fast proof checking times (0.38s) compared to existing proof assistants.
- Automatic Parallelism: Bend claims to automatically parallelize code across CPU cores and GPUs without requiring explicit threading or kernel programming, simplifying high-performance computing.
- Foundations: The language is built on an affine dependent type theory, focusing on explicitness to achieve speed, and is presented with a minimalistic standard library.
While Bend positions itself as a critical tool for future AI-driven software development, its current state is described as 'evolving,' and users are advised to expect bugs. The project emphasizes the importance of precise, unambiguous specifications for AI to prevent unintended consequences.
The Gossip
Commits, Stars, and Skepticism
A dominant theme revolved around skepticism regarding Bend's GitHub repository, particularly its disproportionately high star count (20K) compared to forks and issues, alongside a recently squashed commit history. Many commenters found this 'hella sus,' raising concerns about botting, transparency, and trust—crucial for a foundational programming language. The author clarified the history was condensed to remove personal data, 'AI slop,' and proprietary code, acknowledging it was a misstep that hindered benchmark reproducibility. Supporters defended the author's long-standing research background.
Proving Ground: The Practicality of Proofs
Discussion extensively explored the practical challenges of writing effective and comprehensive 'laws' to guide AI, with many drawing parallels to the 'monkey-paw' effect. Commenters pointed out that overly simple laws could lead AI to undesired but technically compliant solutions (e.g., changing game mechanics to prevent winning rather than fixing a bug). The inherent difficulty of writing exhaustive, unambiguous specifications was highlighted, with some arguing it might become more complex than writing the code itself. The author acknowledged these limitations, stressing that laws are not a silver bullet but can effectively guard against entire classes of bugs if properly formulated, and noted the need for a more comprehensive 'mathlib' to ease proof writing.
AGI Ambitions and AI Accusations
The language's premise, set in a 'post-AGI economy' where humans provide unambiguous instructions to AI, garnered mixed reactions. Some questioned the necessity of such formal strictness for advanced AGI, suggesting that AIs might naturally handle ambiguity or even intelligently redefine requirements. A subset of commenters used terms like 'vibecoded' and 'AI slop' to describe parts of the project, implying AI-generated or unpolished development. The author clarified that critical components were human-designed, and AI was used for non-critical 'slop' and paper writing, which would be refined, while defending the approach as making AI safer.
Deep Dive into Type Theory & Performance
A significant portion of the discussion delved into the technical underpinnings of Bend. Questions arose about its GPU parallelism model for proof assistants, the interpretation of its affine dependent type system (including erased arguments and array semantics), and comparisons to established formal methods like Lean. The author engaged deeply, providing detailed explanations on Bend's explicit proof style, the GPU runtime's architecture, and clarifying complex type system semantics. He candidly acknowledged certain syntax choices as potentially confusing or needing redesign, further demonstrating the project's early stage of development.