Skip to content

Commit fd7175b

Browse files
committed
ai dumb post
1 parent 2fae4ce commit fd7175b

File tree

1 file changed

+43
-0
lines changed
  • apps/frontendsupport/blog-posts/2026-01-23-ai-makes-your-codebase-dumb

1 file changed

+43
-0
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
meta:
3+
title: AI Makes Your Codebase Dumber (Unless You Fight Back)
4+
description: AI favours quick wins over maintainable code, here is how to stop it
5+
date: "2026-01-123T00:00:00.000Z"
6+
tags: ["AI", "slop"]
7+
---
8+
9+
The [Ralph Wiggum pattern](https://ghuntley.com/ralph/), letting AI agents run unsupervised in infinite loops while you go away from the keyboard, has me convinced we've slipped into a parallel universe where "naive persistence" counts as engineering.
10+
11+
## AI's Default Behaviors That Destroy Codebases
12+
13+
### 1. Speed Over Sustainability
14+
15+
AI optimises for the first thing that works, not the right solution. Ask it to fix a bug and it'll reach for the quickest hack: disable the feature, hardcode a value, bypass the problem entirely. Understanding the actual root cause takes effort, and effort isn't in the training data.
16+
17+
Recently I was debugging a table with virtualisation that wasn't rendering. The fix was `min-height: 0` on the flex container. Instead of investigating, the AI blindly slapped on `height: 600px`, a hack that "works" but breaks layout everywhere else.
18+
19+
### 2. Brute Force Over Optimization
20+
21+
AI defaults to the naive O(n²) approach every time. I had a search filter that needed to check nested objects. AI's solution was to loop through every field in every nested object on every keystroke. It would have blown the stack on any real dataset. I used a pre-computed `searchableText` field, building the search string once when data loads instead of on every filter operation. AI would never have suggested this.
22+
23+
## What Actually Works
24+
25+
### Treat AI as a Coding Assistant, Not a Code Generator
26+
27+
You own the code, you understand the code. AI explores solutions, you make decisions. The moment you stop catching it reaching for hacks, your codebase starts rotting.
28+
29+
### Demand Justification
30+
31+
"Why this approach?" "What are the tradeoffs?" "Is this the proper fix or a hack?" If AI can't answer these, it doesn't know what it's doing.
32+
33+
### Verify Everything
34+
35+
Check that APIs actually exist. Check existing patterns in the codebase. Don't assume AI knows your dependencies. It will confidently use functions that don't exist.
36+
37+
### Push for Optimization
38+
39+
AI won't suggest pre-computation, memoization, or debouncing unprompted. You have to ask "this loops on every keystroke, is there a better way?" or you'll ship O(n²) garbage.
40+
41+
### Say No to Hacks
42+
43+
"Don't just disable the feature." "No hardcoded pixel values." "Understand the actual problem first." If you don't say this, AI will take the path of least resistance every time.

0 commit comments

Comments
 (0)