Izzo: Ever write a spec that becomes instantly outdated the moment someone touches the code? Izzo: You're listening to Exploring Next, episode two-eighteen. I'm Izzo, and with me as always is Boone. Today we're diving into CodeSpeak — a new programming language from Andrey Breslav, the creator of Kotlin. Boone: And this isn't just another syntax experiment. CodeSpeak flips the whole development model — you write specifications first, and the language generates executable code from those specs. Izzo: Which sounds amazing in theory, but I've seen too many 'revolutionary' approaches crash into reality. What makes this different, Boone? Boone: Well, Breslav's track record helps — Kotlin went from side project to Android's preferred language. But the real difference is CodeSpeak treats specifications as first-class citizens, not documentation afterthoughts. Izzo: Okay, break that down for me. How does spec-first actually work in practice? Boone: You start by defining contracts — input types, output types, invariants, pre and post conditions. The CodeSpeak compiler then generates implementation scaffolding that's guaranteed to respect those contracts. Izzo: So instead of writing code and hoping it matches the spec, the spec IS the code? Boone: Exactly. And here's the clever part — CodeSpeak uses dependent types and formal verification under the hood. Your specifications aren't just comments, they're mathematically provable constraints. Izzo: That sounds incredibly powerful for teams dealing with complex business logic. No more 'well, the code works but it doesn't match what we documented.' Boone: Right. And the type system is genuinely impressive. It can infer relationships between inputs and outputs that would take pages of documentation to describe manually. Izzo: What's the learning curve like? Because if this requires a PhD in type theory, adoption's gonna be rough. Boone: Surprisingly approachable. Breslav designed it with gradual adoption in mind — you can start with simple contracts and add complexity as needed. Plus it compiles to JVM bytecode, so it plays nice with existing Java and Kotlin codebases. Izzo: JVM interop is smart. No one wants to rewrite their entire stack for a new paradigm. Boone: The tooling is where it gets really interesting. CodeSpeak includes a specification playground where you can test contracts before implementation. It's like having a REPL for your business logic. Izzo: Now that's addressing a real pain point. I can't count how many times we've discovered spec issues only after building the feature. Boone: And the generated code includes built-in monitoring and telemetry. When contracts are violated at runtime, you get detailed traces showing exactly where the specification broke down. Izzo: Okay, I'm genuinely impressed. This feels like it could change how product teams collaborate with engineering. Specs become living, testable artifacts instead of dusty documents. Boone: The implications for API design are huge too. Your OpenAPI specs could literally generate the server implementation, with contract validation baked in. Izzo: I'm giving this a solid A-minus. The only question is whether teams will embrace the discipline of spec-first development. Boone: Fair point. It requires a mindset shift — you can't just hack together a solution and document it later. Izzo: But for teams already struggling with specification drift, this could be transformative. What should people try first? Boone: Install the CodeSpeak CLI from codespeak.dev and work through their specification tutorial. Start with a simple API endpoint — define the contract first, then let CodeSpeak generate the implementation skeleton. Izzo: Also worth experimenting with their contract playground. Upload an existing API spec and see how CodeSpeak would implement it differently. Boone: And if you're feeling ambitious, try building a small microservice entirely spec-first. I'm definitely adding this to the weekend project list — want to see how it handles complex state machines. Izzo: CodeSpeak might just be the bridge between product requirements and engineering reality we've been waiting for. Definitely worth your time to explore.