AI Driven Development as Guided Evolution

For the first time in over a decade, how I develop software has fundamentally changed.
I realized recently that I’m no longer evolving the code directly.
Instead, I’m designing the environment in which the code evolves.

Software development becomes designing the evolutionary environment instead of manually evolving the code.

AI has made the cost of certain parts of development collapse, which has entirely changed the game. Below I describe how I used to work, what changed, why and how I now move 10x faster. By considering software development as Guided Evolution I think it may unlock insights to accelerate your programming.

Look at the little green circle in the diagram below, that was me iterating on one part of the problem.
The ability to produce great code historically required me to conceptually understand code end-to-end:

  1. Understand the code base.
  2. Add some functionality at the edge of the area I want.
  3. Run it.
  4. Evaluate if the change was good. If not, start again.
  5. Repeat this loop over weeks and months, with occasional large refactors when I had a better idea.

Software development has always been a process of moving through a multi-dimensional solution space, gradually working toward a better system. When you think of it like that, it resembles the diagram above. However, now we are no longer iterating on a single node, we now set the framework within which the evolution occurs.

What the diagram represents

  • Ideally setting a very clear measurable goal. (Green Flag in image)
  • Lower Guard Rails – Linting , Tests, Instructions which say what not to do AND preferably automation to enforce it.
  • Upper Guard Rails – Measures to aim for, concise code, non-duplicated, dictated trade-offs, performance requirements.
  • Green Circle – Controlling the evaluation at each step. Carefully choose what information the build emits.

Why AI changes everything

  1. AI has plummeted the cost of trying different branches
    (Try lots of proof of concepts 1-shot and then evaluate a few for usefulness.)
  2. AI can progress along 10-20 steps within 40 minutes.
  3. If we can set a clear success criteria and a measure of fitness at each step,
    AI can progress steadily and relentlessly (like evolution) without much oversight.

Thinking about AI development through this lens explains several surprising behaviors. For example, AI can sometimes build large systems like compilers, yet struggle with small refactors. This makes sense if we view it as an evolutionary system: AI is good at exploring large solution spaces, but less reliable at precise local edits within complex constraints.

This perspective has given me several promising ideas for improving what I’m calling my new process:
EDLC – the Evolutionary Development LifeCycle.

Hopefully it will give you ideas too.

AI is replacing programmers. Graduates first.

Uncomfortable Truth: AI is already better than most junior developers at writing production-grade code. The impact will be felt first by graduates.

For the last year I’ve been using AI intensively on real projects with hundreds of users including commercial software with paid users. I wanted to record and share some of those learnings:

1. AI is really good at writing software right now (in a particular way.).

  • The length of tasks that AI can do is doubling every 7 months (source link).
  • In practical terms, this means AI systems are handling progressively longer, more complex, multi-step problems over time.
  • Somewhere around mid 2025 it became really good.
  • It feels to me like it crossed a threshold.

I personally have used it to build:

The conditional highlighting used some intelligent shading schemes to make it look good in both light and dark theme. The sparklines in java used a graphics2D shader that I myself had no experience of. I migrated from using AI for code snippets to code blocks and finally to entire modules. This was with careful review of all outputs and heavy testing.

Notice: Some areas that I found it most useful were ones that I didn’t know well, java graphics2D and color shading algorithms. That leads to my second point:

2. It’s no longer worth learning a new technology unless you can learn it really well.

Imagine your skill set as a bar chart, for me it’s: Very strong kdb+, core java. Strong software engineering, typescript, HTML. Middling finance/trading knowledge, SQL. weak bash and python. In the past any incremental increase in python knowledge was valuable so it made sense to learn it as I go. But now add a bar chart showing AIs ability today and AIs ability next year. Unless I can get above AI, there’s very little value to knowing a language worse than AI.

I now never write python or bash, I get AI to write it and I either review or test it.

3. Graduates expecting programming jobs in future are screwed.

I’ve purposefully made this title blunt. I have a nephew that was studying computer science until last year. I don’t want a whole generation to waste thousands on an education that is likely to be a dead end for many.

Considering the bar chart above. Any skill that is currently known by an AI or can be learnt by an AI, few companies will want to invest in a grad to wait years for them to learn. The cost curve for return on investment for a graduate developer moved years out and is at risk of moving further each year.

I did computer science at university, when I first left I was fairly useless. It took years of making mistakes, reading books and input from mentors to make me a net contributor to a project. Companies were already reluctant to invest in 1 year of investment to train someone, now it could be 3 years to beat an AI in some areas even if AI doesn’t get better. I saw this firsthand when I hired someone to work on Pulse. They were smart and motivated. I spent time with them daily on every PR, I encouraged them to use AI. Ultimately the time it was taking to invest and train them outweighed the benefit compared to AI and I had to let them go. Instead I invested in getting better at creating software with AI which allows a 10x to 100x increase in productivity in some areas.

Some people will push back on this and say there’s always jobs and you should still pursue a career you love. That’s partially true. There will be jobs around soft skills, engineering skills for many years going forward but that’s more likely to fall to mid or senior developers that can now multiply their productivity.

  • Firms will take years to adjust their hiring, training and approach to fit this new paradigm.
  • Computer science and related degrees have expanded massively over the years as many people saw it as lucrative.

Some that embrace the new AI approach will do well but the majority will not. The graph below shows horses vs cars and how they were replaced between 1910 to 1940. The replacement of entry-level roles for programming will be swifter.

Conclusion

So AI can write software, it isn’t worth learning some technologies, and graduates are going to be out of the job first…

The question in the past was: “How do I become a good programmer?”
Now it’s “How do I become more valuable at solving problems?”

AI may present those that embrace it with asymmetric benefits.
To be continued in future articles…

Pattern Breakers – Podcast Review

Podcast: https://www.youtube.com/watch?v=h9o6gPQA6LA&t=3s

Business is never a fair fight. Incumbants have an advantage. Startups have to change the battlefield/game so they have an unfair advantage.

  • Large companies work by compounding improvements
  • Startups can’t be better, they must have something that can’t be compared, it can only be chosen.
  • e.g. People that buy tesla cybertrucks don’t create a spreadsheet comparing systems, they choose cybertruck as it’s unique.

Coming up with good idea:

  1. Inflections – An underlying fundamental external change.
  2. Insights – Non-obvious truth about the inflection learnt through effort.
  3. Founder / Future Fit

Inflections

  • An underlying fundamental external change.
  • Can be either: Regulatory, Tech or Cultural
  • Culture example would be covid making remote working and remote doctors acceptable.
  • Not a gradual increase e.g. NOT moores law but when there’s a 0-to-1 change. e.g. GPS added to phones.
  • e.g. Better phone cameras + Better internet = Instagram
  • e.g. GPS + Mobile Phones = Uber
  • It kinds of answers Why now?
  • Would DuckDB / AI be an inflection?
  • Testing Startup Ideas, do you have an inflection:
    • 1. What change has been introduced in the world?
    • 2. What does it now enable or empower people to do?
    • 3. What conditions are needed to enable it?

Insight

  • Non-obvious truth about a set of inflections
  • If it was obvious or consensus it would be too similar to incumbants.
  • Initially most people should not like your idea, only a subset
  • How? Look at the future, live there. Realise what is missing. Work backwards. e.g. Continuous Deployment, shift-left. SAAS.
  • Want to find believers to create a movement
  • For your idea, should be able to say 3 things that surprised you:
    • My examples: CloudKDB the name helping. qsandboxes = quants running tests.
    • No surprises = a false idea? and you may be too attached to it.
  • Insight requires work and experimenting. e.g. Try one page landing website to see demand. Can AI predict divorce?
    The “secret” needs to be earned as the market cannot exist today.
  • Non-Consensus = Not obvious you are correct at first.
  • You are trying to wage assymetric warfare against the large incumbents.

Founder / Future Fit

  • What is the likely team to solve this?
    • e.g. Cutting edge = Young and nothing to unlearn
    • e.g. Self-driving car = previous large corporate experience at Ford/Tesla/Waymo
  • Who knows the most about this future and has the best network?
  • You need either:
    • Be building a product for your own needs
    • Lighthouse Customers – That are leading the industry
    • Or force yourself to the edge.
  • Threshold of Desperation is High – Someone must NEED it
    • If the customer can solve their problem and other way they will,
      they don’t want to do business with a startup.
    • Force a choice not a comparison – People shouldn’t be neutral on your product. e.g. Trump e.g. Uber e.g. Airbnb
  • Startups have few resources and poor execution, they can’t be better (execution)
  • They have to sell something unique that people MUST have. My e.g. Online kdb training.

What do successful Startups Do?

  1. Movements = Small upset minority with beliefs causing them to rebel against the majority
  2. Story Telling – How things are now? Could be in future? How do we get there?
  3. Disagreeableness
  • Early customers are motivated on belief NOT practicality.
  • Early adopters share the beliefs of the founder and see startup as prime mover
  • Eventually “What was heresy becomes conventional wisdom” e.g. Javascript is a proper language, Webapps can replace all apps……
  • Movement example – Ride-sharing = Uber. The majority conventional solution were taxis, a few people saw a better way.
  • Start with a higher purpose! e.g. Tesla doesn’t mention cars it says it’s for transitioning to sustainable energy.
  • AirBnB – Movement example
    • Founder never said “Hotels = bad”
    • But he started a “Live local” movement. that turned the hotels homogenous appearance to a disadvantage. Rather than stay somewhere generic, stay somewhere unique. All the hotels investment was turned against it. Goliath was too large and heavy to avoid the slingshot.

Story Telling

  • How things are now? Could be in future? How do we get there?
  • Formula similar to Star Wars
    • Dusty simple plan -> Mentor appears with Tool/Magic (Mentor = startup)
    • Hero believes in tool -> Finds helpers -> Beats the Empire
  • Language is important e.g. Twitter wasn’t called microblogs. my e.g. I used the word Dashboards in Pulse 😦 Should be apps.

Book Review: Philosophy of Software Design – Ousterhout

binary comment

Overall: 8/10

I can recommend a Philosophy of Software Design Paperback by John Ousterhout. I’ve been programming for 15 years and it closely parallels my own current beliefs about programming. He stands above the lower aspects of programming/code/modules, raising the discussion to a conceptual level, that you seem to be wanting. If I had read this 10 years ago I may have marked it higher but after 15 I’ve already learnt a lot of it through pain. I would keep on ehandy in the office to help me with explaining reasons to junior developers during code reviews.

Book Notes:

Chapter 1/2 – It’s all about complexity.

Formula on page 6 I rougly agree with.
i.e. “complexity is determined by the activities that are most common.” If a system has a few parts that are very complicated but they never need touched, that doesn’t much affect the overall complexity.”
Total Complexity = Sum[ componentComplexity x timeSpentWorkingOnThatPart]

I think his formula for overall complexity is mostly correct: Total Complexity = Sum[ componentComplexity x timeSpentWorkingOnThatPart] However I would replace the timeSpentWorkingOnThatPart with the sum of the square roots of all separate times. i.e. Working on a component for 2 days straight versus working on it 1 hour every 2 weeks are quite different.

Symptoms of Complexity

  • Change amplification – changes require code changes in many places
  • Cognitive Load – How much dev needs to know to complete a task
  • Unknown Unknowns – Not obvious which lines of code must be changed to complete a task
  • In an obvious system a dev can easily see where to make a change in 1-2 places.
  • Complexity is caused by dependencies and obscurity.

Chapter 3 - Strategic vs Tactical

Tactical = Main focus is on getting something working quickly.
Strategic = Working code isn’t enough. Most important is long term system structure.
How much to invest? If all you do is tactical, you build up complexity and code debt which eventually slows you down:

Chapter 4 – Modules should be deep

Abstraction -> Simplified view of an entity, which omits unimportant details.
Deep Modules – The best modules are deep, they provide powerful functionality yet have simple interfaces.
Shallow modules = Classitis = separate functions for everything.

Thoughts…surface area should be connected molecules. With dependencies being thickness of connections? Consider how refactoring would look visually as molecule changes. 

Chapter 5 – Information Hiding

Information leakage – (Opposite of hiding) is when a design decision is reflected in multiple modules creating a dependency.
Temporal Decomposition – When methods must be called in a particular order. Great to finally get a name for this.

Chapter 6 – General Purpose modules are Deeper

Counter-intuitively, “code that is more general purpose is simpler, cleaner and easier to understant.” (Thoughts: this took me years to realise and value!! See Iverson APL )
(Some) Generality leads to better information hiding.
Create general class then push specialization up or down to calling classes.

Chapter 7/8/9

Pass-through methods = Red Flag = No clean separation of responsibility.
Decorators e.g. the old java bufferedInput(FileInput()) is an example of this.
Repetition = Red Flag
Special / General code mix = Red Flag

Pg 61. The amount of complexity exposed to users should be related to number of users to number of developers.

Chapter 10 – Define errors out of existance

His example is unix vs window file deletion. Unix takes care of it in background. Windows refuses and says directory/file is blocked.
Example from my own experience is returning empty lists instead of nulls.

Chapter 11 – Design it twice

Consider multiple approaches, outline them and document pros/cons and which one was chosen and why. (I always do this and make the notes inline or bigger ones in an architecture file. Now that he mentions it I’ve never seen anyone else do this. Crazy they don’t! I guess it does happen in PRs but that’s too late)

Comments – Should describe something that isn’t obvious from the code. it should either be a lower or higher level than the code it’s at.

Pg116 Cross module contents = architecture decisions.  Thoughts: Should I create fake global variable and link cross comments using them. Ensure link stays valid.  

Chapter 14 – Naming
Chapter 15 – Write the comments first
Chapter 16 – Modifying existing code
Chapter 17 – Consistency – Great point!! I’ve learnt how important being consistent in a code base is over many years of pain. Even if the code is not optimal for that area, there’s value in it all being the same pattern everywhere! Only add new if willing to change all other similar parts.
Chapter 20 – Performance = Measure

New Sql Documentation Website

I’ve decided to create a new SQL documentation website for H2: sqldock.com/h2
Why?

  1. I was tired of scrolling the large page of functions to find the funciton I wanted. I also wanted examples of that funciton being used.
  2. For qStudio we provide tooltips that say what a function does AND links to actual vendor documentation. Well every so often vendors move those docs. By hosting it myself I can guarantee the doc link won’t be broken and that I won’t have to change links every other year. I can standardise the path and always send users there for docs.

Hopefully others find it useful. Let me know what you think.

Hibernate sucks but what’s the alternatives? Java Persistance Options

Everyone seems to jump straight to hibernate and not consider alternatives and when to use each. Let’s look at this afresh. We want to create a SAAS or self-hosted app and for any modified entites to be persisted. Entites being users, teams and widgets. Imagine something like a simple github json API server where users belong to a team, users or teams may have repos etc.

Typical Operations

  • Create a user/team.
  • Get a user and the list of teams they are linked to.
  • For a given widget, check if the user has access permission.
  • Keep database updated as new columns or tables are added.

Options:

  • Hibernate – Java Class Driven. Fully mapped objects, generate schema from objects, query everything through repositories i.e. hibernate layer.
  • Hibernate Hybrid – For most save items, update items use hibernate. For some complex or optimized selects use raw SQL with automapping to JSON where possible.
    • Automap requires either creating java classes and letting Object->JSON happen
    • Manual conversion / automatic resultset conversion.
  • Raw SQL – Thin Wrapper. Create database manually. Insert / Select writing raw SQL tables. Probably use a very thin wrapper that autoconverts resultsets to JSON.
  • JOOQ – Database Driven – Based on database generate type safe java access layers.
  • Blob Storage (Async) – Literally do not run any SQL commands. Only periodically save down all java state required. I mean you could even serialize everthing to one binary file. Or serialize large chunks and store them as strings to database.

Decision Pivot Points:

  • If SQL querying not needed and no relations within or no insight into inner data = Blob
  • If many standard CRUD operations over different entities = Hibernate
  • If many customized selects = JOOQ – to provide type checking.
  • Never RawSQL. You may as well use a very thin wrapper.
  • Other options? Write your own wrapper to persistance?

Outcome for me

Unfortunately we already adopted hibernate before giving it much thought. In hindsight we should have evaluated JOOQ as we have 2-3 entities which have modified SQL queries for half the operations.

Update:2023-11-23 I tried to convert parts of code base to JOOQ. JOOQ had lots of features and great docs on versioning, locking, storing, CRUD. The main parts lacking were nicer generted POJOs with primitives for “NOT NULL” and soft deletes. Without soft deletes I can’t use it as primary persistance only for SQL queries to be type safe.

These quotes captures my worry with Hibernate:
“John, I thought we were entering a new era of software development. I thought we were doing a light-year’s jump. But, after four years, it seems like we are still dealing with all the same problems, only from a different angle. I had to learn Hibernate architecture, configuration, logging, naming strat…………….ritance mappings, replicating object between two different datastores, detached objects and automatic versioning, connection release modes, stateless session interface, taxonomy of collection persistence, cache levels, lazy or eager fetching and many, many more. Even with everything I know, it seems like we’ve failed badly. It’s a software fiasco! Ultimate failure! Disaster! Armageddon!”
“so we decided to rewrite it as plain SQL statements. What’s funny is that writing plain SQL was actually the fastest way of doing it, so we decided to do it as our last option.”


I would suggest one idea, to use Blob storage for individual entires that you don’t need to “look inside”. There’s no point converting JSON to java objects to nested entities, if you never need to access those entities within Java. Just store the blob.

Podcast Notes

Podcasts I listen to:

Below I will make notes on specific podcasts and what I took away from them:

  • Idea to Startup – Find your wedge – You MUST be solving a bleeding neck problem else most people won’t care and won’t tell others.
  • AirPlane.devSaaS Club 370 – Very similar product to PulseUI. His elevator pitch at start is really slick.
    • About Pulse? What’s it do? Who’s it for? What’s the main problem it’s trying to solve?
    • Half the software in the world is internal tooling, for every line of code behind your favourite app, there’s another line powering internal platforms and operations.
      • Massively important to success of business
      • Chronically not invested in as nobody wants to work on these tools
    • Our goal is to make it faster to build software tooling for these businesses.
    • Founder fit – Will you be happy working on this for 10 years?
    • We are doing all the boring bits…for us it’s fun as we are doing it at scale.
    • “You could build thi syourself but do you really want to”
  • Lenny – Wise.comHow to drive word of mouth. Think this was good need to recheck.
  • Saastr – Loom – Building flywheel. Users didn’t know they could share URLS! they needed to add a share button.

The End of Open Source tech SAAS Companies?

I’m on quite a few slack channels and I got a message today on the radpanda/kafka slack:

Which if you follow to their website (Aiven):

  1. They describe themselves as: “The trusted open source data platform for everyone”
  2. They offer hosting on AWS/Azure/Google for all the new hip open source data technologies. Kafka, Flink, Influx, Redis.
  3. Under technology partners page, all their partners are hosting firms.
  4. They are not partnered with any of the firms that build the software. None of the management team has worked on or in open source.

For end consumers this is good, get reliable hosting from a “big firm” that supplies many other systems that you may use. For bigtech it’s a win as it will be hosted on their cloud. For startup/tech companies this is deadly. Why would anyone wait to host on their platform?

This feels like the next evolution of the spat between technology companies and bigtech aka google/amazon. Previous disagreements have forced some technology companies/startups to change away from open source licensing e.g. Elastic but the big guys also received bad press for doing it. Now with an smaller intermediary party, the bad press has only a positive effect in advertising them more.

Half the work in building a new SAAS offering is building and supporting the general platform, user logins, system backup, recovery etc. If this middle company spreads that cost over multiple offerings and doesn’t pay to contribute any open source back, they can supply it faster and cheaper short term.

As I look at startups or new tech companies like questdb, redpanda, timeplus, materialize, redis, superset, clickhouse….if a company like this starts offering their tech early I think they could get a lot, if not most the business while the other company pays the cost of development. In some cases as we seen they are on the open source slack channel engaging customers away….

What do you think?

Ongoing New Quotes / Articles

I have an old page: legendary quotes.

As I gather new ones, I will add new ideas here and prune them over time:

“Just recently I came to a realization, people and organisations exist in a competency / incompetency matrix.

The competent orgs with incompetent people are your blue chips and “traditional” companies. They ship stuff, have customers, grow along with the overall market and economy and are able to survive most non-existential threats and down-turns and even existential ones from time to time. All, or most, the competency is institutional, recorded in implicit knowledge held by people and various tools and processes. Unless those companies lose that knowledge for some reason, things are good.” – hef19898 – On HN

“When making life decisions, going in the direction of more money can be wise. However, we must keep in mind that when we choose money, we don’t choose much. We just decide to decide later.”

“Upper limit of complexity is infinity? An engineer can hold a whole complicated system in his head and work on it. When he leaves and needs to pass it on, he won’t be able to communicate it all. Complexity we can sustain over time is less than today.” https://www.youtube.com/watch?time_continue=2841&v=pW-SOdj4Kkk

Norris Numbers – average amount of code an untrained programmer can write before he or she hits a wall. Clift estimates this as 1,500 lines. Beyond that the code becomes so tangled that the author cannot debug or modify it without herculean effort.

… the very language that one could use to make a comparison is taken away, and the possibility of benchmarking on a different infrastructure is an endeavor akin to rewriting everything from scratch.
https://cerebralab.com/Is_a_billion-dollar_worth_of_server_lying_on_the_ground

““The choice isn’t between automation and non-automation,” said Erik Brynjolfsson, the director of M.I.T.’s Initiative on the Digital Economy. “It’s between whether you use the technology in a way that creates shared prosperity, or more concentration of wealth.””

“People are taking the piss out of you everyday. They butt into your life, take a cheap shot at you and then disappear. They leer at you from tall buildings and make you feel small. They make flippant comments from buses that imply you’re not sexy enough and that all the fun is happening somewhere else. They are on TV making your girlfriend feel inadequate. They have access to the most sophisticated technology the world has ever seen and they bully you with it. They are The Advertisers and they are laughing at you.

You, however, are forbidden to touch them. Trademarks, intellectual property rights and copyright law mean advertisers can say what they like wherever they like with total impunity.

Fuck that. Any advert in a public space that gives you no choice whether you see it or not is yours. It’s yours to take, re-arrange and re-use. You can do whatever you like with it. Asking for permission is like asking to keep a rock someone just threw at your head.

You owe the companies nothing. Less than nothing, you especially don’t owe them any courtesy. They owe you. They have re-arranged the world to put themselves in front of you. They never asked for your permission, don’t even start asking for theirs.” -Banksy

“Every internal decision about look and function answers the questions “What does the customer need?” and “How can we help them be more productive?” (Not “How can we give them what they’re asking for?” because that isn’t the right question to answer.)” – source.

Articles:

The most plausible explanation I’ve seen for people moving off programming onto different jobs:
https://whoisnnamdi.com/never-enough-developers/

A case where tight feedback loops don’t help.
https://brianlui.dog/2020/05/10/beware-of-tight-feedback-loops/

What Color is Your Function?

THE TYRANNY of STRUCTURELESSNESS
https://www.jofreeman.com/joreen/tyranny.htm

psychohistory is real:
https://journals.plos.org/plosone/article/file?id=10.1371/journal.pone.0237458&type=printable