惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

U
Unit 42
T
The Blog of Author Tim Ferriss
H
Help Net Security
博客园 - 叶小钗
云风的 BLOG
云风的 BLOG
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
D
DataBreaches.Net
博客园 - 聂微东
A
About on SuperTechFans
大猫的无限游戏
大猫的无限游戏
P
Proofpoint News Feed
Martin Fowler
Martin Fowler
博客园 - 【当耐特】
S
SegmentFault 最新的问题
Blog — PlanetScale
Blog — PlanetScale
酷 壳 – CoolShell
酷 壳 – CoolShell
G
Google Developers Blog
I
InfoQ
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
GbyAI
GbyAI
B
Blog
Engineering at Meta
Engineering at Meta
V
V2EX
Hugging Face - Blog
Hugging Face - Blog

DEV Community

Authentication Security Deep Dive: From Brute Force to Salted Hashing (With Java Examples) Why AI Systems Don’t Fail — They Drift Spilling beans for how i learn for exam😁"Reinforcement Learning Cheat Sheet" I Replaced Chrome with Safari for AI Browser Automation. Here's What Broke (and What Finally Worked) How Python Borrows Other People's Work The $40 Architecture: Processing 1 Billion API Requests with 99.99% Uptime Vibe Coding: A Workflow Guide (From Zero to SaaS) Most webhook security guides protect the wrong side. The scary part is delivery. Headless CMS for TanStack Start: Build a Blog with Cosmic EU Age Verification App "Hacked in 2 Minutes" — What Actually Happened Comfy Cloud’s delete function does not actually remove files Running AI Models on GPU Cloud Servers: A Beginner Guide Event-driven media intelligence with AWS Step Functions and Bedrock I scored 500 AI prompts across 8 quality dimensions — here's what broke How to Call Google Gemini API from Next.js (Free Tier, No Backend Needed) The Portal Protocol: Reclaiming Human Connection in the Age of AI How to Fix Your Team's Scattered Knowledge Problem With a Self-Hosted Forum Intro to tc Cloud Functors: A Graph-First Mental Model for the Modern Cloud Designing Multi-Tenant Backends With Both Ownership and Team Access I Built a Neumorphic CSS Library with 77+ Components — Here's What I Learned PostgreSQL Performance Optimization: Why Connection Pooling Is Critical at Scale Cómo construí un SaaS multi-rubro para gestionar expensas en Argentina con FastAPI + Vue 3 🚀 I Built an Ethical Hacking Scanner Tool – Open Source Project I Replaced /usage and /context in Claude Code With a Single Statusline A Pythonic Way to Handle Emails (IMAP/SMTP) with Auto-Discovery and AI-Ready Design I Collected 8.9 Million Polymarket Price Points — Here's What I Found About How Markets Really Move EcoTrack AI — Carbon Footprint Tracker & Dashboard Everyone's Using AI. No One Agrees How. 5 self-hosted ebook managers worth trying in 2026 Building Your First AI Agent with LangChain: From Chatbot to Autonomous Assistant
Code Is the New Server. Specs Are the New Terraform.
Daniel Stolf · 2026-06-20 · via DEV Community

Most of us are committing the wrong artifact to version control.

When you commit code today, you're committing the output of a process. The thinking happened somewhere upstream (a Linear ticket, a Slack thread, a notebook, a conversation with the team), and what survived that thinking is the code in the repo. The spec, the trade-offs, the constraints you considered and rejected? Mostly gone. The code is the record. The repo is the source of truth.

We had this exact conversation a decade ago. It was about servers.


Before Terraform, the server WAS the truth. You'd SSH in, install packages, edit configuration files, restart services. Maybe you wrote a runbook. The runbook went stale. The server kept going. When something broke, you debugged the server, not the runbook. The version of truth was the running machine.

Then IaC happened. The .tf file became the source of truth. The server became the build artifact. You stopped backing up servers and started backing up .tf files. When a server drifted from the .tf, you didn't reach for the server to figure out what changed. You ran terraform plan, saw the diff, decided whether to update the .tf or re-apply. The server stopped being something you protected. It became something you could reliably regenerate.

We didn't stop having servers. We stopped versioning them.


AI changes the cost of regenerating code from a description of what it should do.

Not perfectly. Not in every case. But enough that, for a growing set of work, the implementation is cheaper to regenerate from intent than to maintain by hand. And once that's true, the implementation can move into the role the server played: the build artifact. The thing you keep around but don't treat as the canonical source.

What plays the role of the .tf file? The spec. Or whatever you want to call it: the acceptance criteria, the contract, the intent-doc. The thing that says what should be true about the behavior, captured in a form structured enough to regenerate the code from.

That's the thing worth versioning.


If intent is the source of truth, several things shift.

PRs stop being about code diffs and start being about intent diffs. The reviewer asks: did the spec change? does the new spec make sense? does the code match? The interesting conversation moves upstream of the implementation. The downstream check (code matches spec) gets cheaper, often automatable.

Tests come from the spec, not from the code. Acceptance criteria become failing tests before any implementation exists. The code has to satisfy them. This is what test-first really means once code becomes regenerable.

Drift, when it happens, gets repaired differently. If the code stops matching the spec, you don't reach into the code to fix it. You decide whether the spec was right (in which case, regenerate the code) or the spec was wrong (in which case, fix the spec, then regenerate). The same loop terraform plan teaches you.

History and memory attach to the spec. The reasons a decision was made, the alternatives considered, the failure mode that bit you in production last quarter, those belong with the spec they shaped. The code is downstream. It inherits those reasons but doesn't carry them.


The natural pushback is: but code is still code. You still have to read it, debug it, run it, pay for it in CPU cycles. It doesn't go away just because it's downstream.

Right. Servers don't go away under Terraform either. You still SSH in when things break. You still tail logs. You still get woken up at 2am. The change wasn't that the artifact disappeared. The change was where the source of truth lived.

Code in an intent-versioned workflow is the same. It stays in the repo. You can read it. You can debug it. You can ship it. But when you need to change WHAT the system does, you change the spec, and the code follows. When the code drifts from the spec, you investigate why, and the fix lands upstream more often than not. The shift isn't "no more code." The shift is "code answers to something now."


This is what Speccraft is built around.

Specs are first-class versioned artifacts in the repo, not throwaway prompts. Code generation flows from those specs through a structured process. Tests come from the spec before implementation, enforced by a hook that blocks production edits without a corresponding test edit. Decisions, conventions, and scars attach to specs and persist across sessions, so the next contributor (human or model) inherits the rationale, not just the diff.

It's the .tf file for code. The thing you version, the thing you review, the thing you treat as canonical. The code becomes what it should have been all along: the runnable expression of an intent the team agreed on.


What would your repo look like if the spec was the source of truth and the code was the build artifact? Most of us already half-believe this. We just haven't restructured anything to act on it yet.

Have you started treating intent as a versioned artifact in your workflow? Or is the spec still living in a ticket somewhere?