Skip to main content

The Last Mile Problem

5 min read

Backend

AI writes the endpoint. You own: deployment, env config, monitoring, and 'why does it fail in prod?' That's the last mile.

Frontend

AI builds the component. You own: design system fit, accessibility, and 'it works in Chrome but Safari is broken.' Last 20%.

Devops

AI writes the Terraform. You own: state, secrets, and 'why did this fail at 3am?' Integration and operations — human.

The Last Mile Problem

TL;DR

  • "Shipping software is not a syntax problem. It's a policy problem." The gap between AI's ability to generate code and organizations' ability to responsibly deploy it. AI can write code that compiles, runs, passes tests—ensuring it aligns with security, licensing, and compliance policies remains manual and error-prone.
  • Less than half of AI projects ever reach production deployment. Democratizing AI requires deploying and tracking performance—challenging when models function as "black boxes."
  • Policy lives in Slack threads, tribal memory, and "the heads of people you can't afford to lose." It's fragmented, undocumented, rarely machine-readable. AI can't intuit the policies that keep code safe, compliant, and releasable. You can.

The first 80% is increasingly automated. The last 20% is where things get interesting—and where AI consistently falls short. SWE-Bench focuses on short GitHub-issue patches—a few hundred lines. Industry-scale work touches millions of lines. Real software engineering includes refactoring, legacy migrations, testing, debugging, code review, performance optimization. AI excels at the small, self-contained slice. You own the rest.

What the 80% Looks Like

  • Code: Functions, components, API endpoints. Structure. Syntax. The "happy path."
  • Docs: Drafts. Structure. Standard explanations.
  • Tests: Basic coverage. Happy path. Obvious cases.
  • Config: Boilerplate. Standard setups.

AI is good at this. It's pattern-matching. It's seen thousands of examples. Output is often usable with light editing.

What the Last 20% Is

Governance, Not Generation

  • "Should we ship this?" — AI suggests dependencies with known vulnerabilities. AI-generated code violates compliance policies. AI introduces libraries under restrictive licenses—legal exposure. The hard part isn't getting code to run. It's deciding if it should. Model Context Protocol (MCP) is proposed as a policy-aware layer—security scanners, license databases, compliance frameworks. Until that's real, you're the policy layer.
  • "Does this pass our security review?" — AI can't intuit your policies. You can.

Integration

  • "It works locally. Why doesn't it work in prod?" — Env vars. Permissions. Network. Other services. AI didn't run it in your environment. You debug.
  • "This fits the new service. How does it fit our 47 existing services?" — Integration points. Contracts. Legacy quirks. Human map.
  • "The API is correct. The client is wrong. Who fixes what?" — Coordination. AI can't run the standup.

Edge Cases

  • "What happens when the DB is slow?" — Timeouts. Retries. Degradation. AI might add a retry. It won't add the right retry strategy for your context.
  • "What if the user does X, then Y, then Z in that order?" — Unusual flows. AI tests the happy path. You find the weird ones.
  • "This works for 99% of customers. The other 1% have legacy data." — Edge case handling. Human discovery.

Production Reality

  • "It worked in staging. Prod has 100x the load." — Scale. AI doesn't profile. You do.
  • "The alert fires. Is it real or a fluke?" — On-call judgment. AI can't page in. You triage.
  • "We need to roll back. What's the safest path?" — Incident response. AI suggests. You decide.

Polish and "Feel"

  • "It works but it feels slow." — Perceived performance. Loading states. Skeleton screens. UX. Human territory.
  • "It's accessible in theory. In practice, screen readers choke." — Real-world testing. AI generates. You verify.
  • "The design system says X. This edge case needs Y." — Exception handling. Judgment. You.

Why the Last Mile Is the Moat

  • It's where value is delivered. Code that doesn't integrate, doesn't handle edge cases, and doesn't run in prod is worthless. Code that violates policy doesn't ship. The last mile is where "working" and "shippable" happen.
  • It's where AI struggles. Integration requires context. Edge cases require discovery. Policy requires tribal knowledge. Production requires being there. AI has limited context, no discovery process, no access to Slack threads.
  • It's where you differentiate. Anyone can get 80% from AI. The people who own the last 20%—including policy and governance—are the ones who ship. And keep their jobs.

How to Own the Last Mile

  1. Always run it. AI output that hasn't been executed, integrated, and tested in your environment is a draft. You make it real.
  2. Hunt edge cases. "What could go wrong?" "What's the weird user flow?" AI won't. You do.
  3. Own production. Deployment, monitoring, incident response. AI assists. You're accountable.
  4. Own the policy check. Before you ship: security scan? License clear? Compliance green? Policy lives in people's heads. You're one of those people. Document what you know.
  5. Measure by outcome, not output. Lines of code matter less. "Did it ship? Does it work? Did we avoid incidents? Did we pass compliance?" That's the last mile. You own it.

Quick Check

AI writes the endpoint. It works locally. What's the last 20% you own?

You write all the code. You own integration, deployment, monitoring. One person, full stack. Exhausting.

Click "With AI" to see the difference →

Do This Next

  1. Take one AI-generated artifact (code, config, doc). List 5 things you'd need to do to make it "production ready"—including: Would it pass our security review? License check? Compliance? That's your last-mile checklist.
  2. Fix one "works in dev, breaks in prod" issue this week. Document what was different. That's the last mile in action. Build the habit. If you don't have one: document one policy that lives only in tribal memory. That's the invisible infrastructure AI can't access.