<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>The Intelligent Commit — The Complexity Paradox</title>
    <link>https://theintelligentcommit.com/complexity-paradox/</link>
    <atom:link href="https://theintelligentcommit.com/complexity-paradox/feed.xml" rel="self" type="application/rss+xml"/>
    <description>A series drawn from my MSc dissertation on the security of LLM-generated code. One hundred tasks, built three ways — vibe coded, security-aware prompted, and through an agentic workflow with a reviewer agent — and the finding that gives the series its name: the simple tasks produced nine times more vulnerabilities per line of code than the complex ones.</description>
    <language>en</language>
    <lastBuildDate>Mon, 19 Oct 2026 08:13:57 GMT</lastBuildDate>
    <item>
      <title>Architecture beats vigilance</title>
      <link>https://theintelligentcommit.com/complexity-paradox/architecture-beats-vigilance/</link>
      <guid isPermaLink="true">https://theintelligentcommit.com/complexity-paradox/architecture-beats-vigilance/</guid>
      <pubDate>Sun, 04 Oct 2026 00:00:00 GMT</pubDate>
      <description>The same plain vibe-coding prompts, passed through a supervisor, a coder and a security reviewer. Vulnerability density fell 77% against baseline, two classes of flaw disappeared entirely, and the nine-times complexity gap all but closed.</description>
      <content:encoded><![CDATA[<p><em>Thank you for opening up the latest article in &#39;The Intelligent Commit&#39; newsletter, my thoughts, research and analysis on Artificial Intelligence and how AI is reshaping the software development lifecycle. I hope you find it insightful, subscribe, and engage.</em></p>
<p><em>This is the final article in a three-part series about the findings from my master&#39;s dissertation on the security of LLM-generated code.</em></p>
<hr>
<p>For my Master&#39;s research dissertation, I chose a subject that sits directly between my studies and my work in engineering leadership: <em>what happens to software security when more of the code is generated by AI?</em> I later turned the research into a talk, <em>The Complexity Paradox</em>, which I presented at the Northern DevOps &amp; Platform Conference in Leeds back in May.</p>
<p><a href="/complexity-paradox/the-complexity-paradox/">The first article in this series</a> covered an unexpected finding that gave the talk its name: the simplest tasks carried up to 9x the vulnerability density of the most complex ones. <a href="/complexity-paradox/security-expertise-still-matters/">The second</a> argued that security expertise is still important, because when I simulated a developer spelling out security requirements, vulnerability density fell by 60%.</p>
<blockquote>
<p>The strongest security controls are those nobody has to remember to apply.</p>
</blockquote>
<p>However, that depends on the developer knowing what to ask for, and remembering to ask on every single change. As any engineering leader will attest, that is hard to guarantee. So the final part of my research tested whether that knowledge could be taken out of the individual&#39;s head and built into the workflow instead. I am a firm believer that the strongest security controls are those nobody has to remember to apply.</p>
<hr>
<p class="lead-in"><strong>Building the reviewer into the workflow</strong></p>
<p>The third condition used the same model and the same 100 tasks, and built the same 18 products as the other two. The prompts were the plain, functional vibe-coding prompts from the baseline, with no security guidance added - mirroring either a non-programmer or a developer who had forgotten their secure-coding training. The only difference was what happened to the code after the LLM first wrote it.</p>
<p>In this condition, three AI agents did the work behind the prompt: a supervisor, a coder and a security reviewer. The supervisor handed the task to the coder. The reviewer then checked the result against the OWASP Top 10 and the CWE Top 25 - the same sources I drew on for the security-aware prompts in part two. If it found problems, the supervisor passed them back to the coder to fix. I capped that loop at two rounds of fixes to keep time and cost under control, after which the task was marked complete.</p>
<p>In part two, a developer had to supply the security knowledge with every prompt. Here it was written once, into the reviewer agent&#39;s instructions, and applied to every change.</p>
<hr>
<p class="lead-in"><strong>The impact of an automated reviewer</strong></p>
<blockquote>
<p>The proportion of applications containing at least one critical or high-severity vulnerability fell from 78% to 28%.</p>
</blockquote>
<p>Against baseline, vulnerability density fell by 77%, and the proportion of applications containing at least one critical or high-severity vulnerability fell from 78% to 28%.</p>
<p>Two classes of flaw disappeared altogether. Cross-site scripting and code injection, both on MITRE&#39;s list of the 25 most dangerous software weaknesses, turned up in the vibe-coded applications. Neither appeared once in the agentic ones.</p>
<p>The automated agentic workflow also produced the fewest vulnerabilities per application, and the most consistent results from one application to the next.</p>
<p><strong>It flattened the complexity paradox too.</strong> The 9x gap between simple and complex products under vibe coding all but closed under the agentic workflow.</p>
<p>In part one I offered one possible explanation for the paradox: that humans may slow down for work that looks difficult and wave through work that looks routine. An automated reviewer has no such instinct. Nothing in its instructions told it that a small change deserved less attention, so it did not give it less. It applied its protection to every change, however simple it looked.</p>
<p>It would be easy to read this study as &quot;agents beat experts&quot;, but I do not think the study supports that. It does not replace human judgement, runtime testing or independent assurance. What it shows is that automated agentic review gives strong protection against the naive baseline, and adds strength in depth alongside a security-aware developer.</p>
<p>It also shows that LLMs are strong at reasoning about code security, rather than looking purely at heuristics - something I wrote about in <a href="/opinions/agentic-ai-security-is-a-new-product-category/">Agentic AI Security is a new product category</a> - and we have heard a lot about advances in this space in the year since my study concluded, with the Fable model, for example.</p>
<hr>
<p class="lead-in"><strong>What this means for engineering leaders</strong></p>
<p>People know security is important. They also work under deadlines, switch context and make reasonable decisions about where to spend limited attention. Telling developers to be more vigilant does not change those constraints. But a strong architecture can be designed around them.</p>
<p>Platform teams already encode engineering decisions into CI pipelines, deployment controls, dependency policies and service templates. AI security review belongs alongside them. It can look at the routine changes nobody else examines closely, send insecure code back for revision, and apply a consistent minimum level of scrutiny before a human reviewer ever opens the pull request.</p>
<p>That still needs careful implementation. You will have to decide what the agent is allowed to change, how its findings are validated, where human approval stays mandatory and how generated fixes are tested. There is also a risk of false confidence in an automated reviewer whose decisions are opaque and who is treated as infallible. I explored the psychology of trust separately in <a href="/opinions/do-developers-know-their-ai-code-is-insecure/">Do developers know their AI code is insecure?</a>, and it is a fascinating subject.</p>
<p>I reiterate that none of this replaces the findings in the previous article. Security-aware developers still write better prompts, and they are the people who should be writing the reviewer&#39;s instructions in the first place. Responsibility for what goes into production must stay with the team.</p>
<p>But if I can leave you with one takeaway, it is this: <strong>if security depends on somebody remembering to ask, then it is not part of the system controls - and architecture beats vigilance.</strong></p>
<hr>
<p class="lead-in"><strong>Thank you for reading my latest article. Please share your experiences and engage with the discussion - I am not always right, but I try to be insightful and thought-provoking.</strong></p>
<ul>
<li><strong>How much of your security assurance currently depends on a person remembering to apply it?</strong></li>
<li><strong>If you put an AI security reviewer on every pull request tomorrow, what would you let it change, and where would human approval stay mandatory?</strong></li>
<li><strong>Who in your organisation would write that reviewer&#39;s instructions, and do they have the secure-development knowledge to do it well?</strong></li>
</ul>
<p class="lead-in"><strong>Please reach out if you&#39;d like to continue the discussion.</strong></p>
<hr>
<p><em>This concludes my three-part series on the headline findings from my research, drawn from my MSc dissertation at the University of Wolverhampton, submitted in January 2026.</em></p>
]]></content:encoded>
    </item>
    <item>
      <title>Security expertise still matters</title>
      <link>https://theintelligentcommit.com/complexity-paradox/security-expertise-still-matters/</link>
      <guid isPermaLink="true">https://theintelligentcommit.com/complexity-paradox/security-expertise-still-matters/</guid>
      <pubDate>Sat, 12 Sep 2026 00:00:00 GMT</pubDate>
      <description>Same model, same tasks, same baseline prompts - the only difference was a developer who spelled out the security requirements. Vulnerability density fell by 60%, and the share of applications carrying a critical or high-severity flaw fell from 78% to 44%.</description>
      <content:encoded><![CDATA[<p><em>Thank you for opening up the latest article in &#39;The Intelligent Commit&#39; newsletter, my thoughts, research and analysis on Artificial Intelligence and how AI is reshaping the software development lifecycle. I hope you find it insightful, subscribe, and engage.</em></p>
<p><em>This is the second in a three-part series about the findings from my master&#39;s dissertation on the security of LLM-generated code.</em></p>
<hr>
<p>For my Master&#39;s research dissertation, I chose a subject that sits directly between my studies and my work in engineering leadership: <em>what happens to software security when more of the code is generated by AI?</em></p>
<p>AI coding assistants are having a dramatic effect on how developers produce working software. What is less clear is whether the developer&#39;s own experience and knowledge - in this case their security expertise - still matters now that an LLM is writing the code. That is what I set out to test, and the answer was a clear yes: <strong>a developer who spells out the security requirements gets back noticeably safer code</strong>.</p>
<hr>
<p class="lead-in"><strong>Comparing functional and security-aware prompts</strong></p>
<p>Two of the three conditions in my study speak to this directly. Both used the same LLM and the same baseline prompts, and both worked through the same set of 100 tasks, building the same 18 products and end-user applications drawn from public tutorials and videos.</p>
<p>The baseline simulated naive &quot;vibe coding&quot;. Its prompts focused on functionality, in the style of those public tutorials aimed at non-programmers building applications with AI - and, just like the tutorials being replicated, they did not mention security or vulnerabilities once.</p>
<p>The security-aware condition kept the same tasks, model and baseline prompts, but appended guidance drawn from the OWASP Top 10 and the MITRE CWE categories relevant to each task. This simulated a developer who understood the likely risks and made those expectations explicit to the LLM.</p>
<p>After producing the applications I scanned the generated code, then reviewed and suppressed false positives before analysing and classifying the vulnerabilities. The difference was significant.</p>
<p>The baseline vibe-coding condition produced 13 vulnerabilities per thousand lines of code. <strong>When the developer provided the additional security context, vulnerability density fell by 60%.</strong></p>
<blockquote>
<p>The proportion of applications containing at least one critical or high-severity vulnerability fell from 78% to 44%.</p>
</blockquote>
<p>And that was not the only significant finding. <strong>The proportion of applications containing at least one critical or high-severity vulnerability also fell, from 78% to 44%.</strong> For organisations that prioritise remediating critical and high findings - and many do - that is a significant difference.</p>
<p>At this point you may be concerned that your models are writing insecure code at all. I agree, it is quite alarming, isn&#39;t it? I did not set out to test or prove that, because it has been heavily researched already - and sadly, yes, it is well established that even the latest frontier models generate insecure code. But without doubt, it is now clear that <strong>setting out clear security expectations has a demonstrable positive impact on the code a model produces</strong>.</p>
<hr>
<p class="lead-in"><strong>Getting the context right matters</strong></p>
<p>It is tempting to treat prompting as a conversational skill: ask clearly, provide context, refine the answer. For code generation, my study confirmed that <strong>the context needs to include the qualities the software must adhere to</strong>.</p>
<p>A functional prompt might specify that users can upload a file. A security-aware prompt also constrains file type, size, storage location and filename handling. A request for authentication needs to cover password storage, session behaviour and rate limiting. That extra context comes from secure-development knowledge - just as you would explain it to a junior developer.</p>
<blockquote>
<p>A better prompt cannot guarantee secure code, but it can materially improve the odds.</p>
</blockquote>
<p>The 60% reduction is encouraging. But while security-aware prompting improved the output, it does not make scanning, testing or code review unnecessary.</p>
<p>It is worth noting that the research community continues to look at this. A twin-prompt study of six web applications found much the same thing - every serious flaw it confirmed sat in the version built from the plain specification, which I covered in <a href="/research/nobody-asked-for-secure-code-so-nobody-got-it/">Nobody asked for secure code, so nobody got it</a>. A more recent journal paper similarly found that effective prompt engineering reduces vulnerabilities. Yet there is also evidence from another study that adding security guidance to the prompt changed which kinds of flaw appeared without reducing how many there were. What I found in my own research is what I have set out here, but that does not mean the story ends with it.</p>
<hr>
<p>AI assistance has created another point at which security knowledge affects software. We can leave that knowledge in an individual&#39;s head, or we can make it part of the tools and defaults used by the whole team.</p>
<p><a href="/complexity-paradox/architecture-beats-vigilance/">The final article in this series</a> examines the next step: moving security review out of prompt guidance and into the architecture of the development workflow itself. If you have not read it yet, <a href="/complexity-paradox/the-complexity-paradox/">the first article</a> covers the finding that gave the series its name.</p>
<hr>
<p class="lead-in"><strong>Thank you for reading my latest article. Please share your experiences and engage with the discussion - I am not always right, but I try to be insightful and thought-provoking.</strong></p>
<ul>
<li><strong>Does anyone on your team write security requirements into their prompts today, or is it left to whoever happens to know?</strong></li>
<li><strong>If you reviewed last week&#39;s prompts, how many described behaviour only, and how many described the qualities the code had to hold to?</strong></li>
<li><strong>Where does that knowledge live in your organisation - in people&#39;s heads, in a wiki nobody opens, or in the tooling itself?</strong></li>
</ul>
<p class="lead-in"><strong>Please reach out if you&#39;d like to continue the discussion.</strong></p>
]]></content:encoded>
    </item>
    <item>
      <title>The Complexity Paradox</title>
      <link>https://theintelligentcommit.com/complexity-paradox/the-complexity-paradox/</link>
      <guid isPermaLink="true">https://theintelligentcommit.com/complexity-paradox/the-complexity-paradox/</guid>
      <pubDate>Mon, 31 Aug 2026 00:00:00 GMT</pubDate>
      <description>The simple tasks produced the worst code. One hundred tasks, and the simplest carried 9x the vulnerability density of the complex, which makes task simplicity a poor proxy for security risk.</description>
      <content:encoded><![CDATA[<p><em>Thank you for opening up the latest article in &#39;The Intelligent Commit&#39; newsletter, my thoughts, research and analysis on Artificial Intelligence and how AI is reshaping the software development lifecycle. I hope you find it insightful, subscribe, and engage.</em></p>
<p><em>This is the first in a three-part series about the findings from my master&#39;s dissertation on the security of LLM-generated code.</em></p>
<hr>
<p>For my Master&#39;s research dissertation, I chose a subject that sits directly between my studies and my work in engineering leadership: <em>what happens to software security when more of the code is generated by AI?</em></p>
<p>I later turned the research into a talk, <em>The Complexity Paradox</em>, which I presented at the Northern DevOps &amp; Platform Conference in Leeds back in May. The title came from the finding I least expected when I began the study, and one I called out in my paper as demanding further research: <strong>simple tasks produced the least secure code</strong>.</p>
<hr>
<p class="lead-in"><strong>Testing three ways of working with AI</strong></p>
<p>The research compared three simulated development conditions. Each used the same LLM and the same baseline prompts, and each worked through the same set of 100 tasks. Those tasks built 18 products and end-user applications, drawn from scouring public tutorials and videos on product ideas, apps and the like.</p>
<p>The first condition represented naive &quot;vibe coding&quot;: simple baseline prompts that described the desired functionality in plain English, and no more.</p>
<p>The second built on each baseline prompt by appending context-relevant, security-aware requirements following OWASP Top 10 and MITRE CWE guidance.</p>
<p>The third fed the original baseline English prompt - with no appended security or technical guidance - into an agentic workflow with separate supervisor, coder and security-reviewer roles.</p>
<p>Eighteen applications in each condition produced 54 applications overall. I scanned the resulting code with Bandit, Bearer, SonarQube and Grype, then reviewed and suppressed false positives before analysing and classifying the vulnerabilities.</p>
<p>There were several useful results, but <strong>the relationship between complexity and security stood out</strong>. I expected simpler work to generate fewer vulnerabilities. I was mistaken.</p>
<blockquote>
<p>Under naive vibe coding, the simple products carried just over nine times the vulnerability density of the complex ones.</p>
</blockquote>
<p>Under the naive vibe-coding condition, simple products contained 19.22 vulnerabilities per thousand lines of code. Complex products contained 2.13. The vulnerability density of the simple work was just over nine times higher.</p>
<p>The pattern held under security-aware prompting, where simple work carried 6.3 times the vulnerability density of complex work.</p>
<p>Interestingly, it disappeared in the agentic condition - more on that later in the series.</p>
<hr>
<p class="lead-in"><strong>Why might simple work be less secure?</strong></p>
<p>The study established the pattern, not its cause. The possible explanations are questions for further research, so treat what follows as hypotheses rather than findings.</p>
<p>The simplest answer may be that it is just statistics: complex codebases contain more lines of code, which in turn drives down the density of vulnerabilities. Plausible, but not one I subscribe to on its own. Here are a few more candidates, and how they might translate into the real world.</p>
<p><strong>Attention is one.</strong> Difficult work announces itself. Developers slow down, supply more context and examine the results more carefully. A task that sounds routine may receive a short prompt and a quick approval.</p>
<p><strong>Prompt detail may create a similar effect.</strong> A request for a complex feature tends to describe its data, behaviour and constraints. &quot;Build a login form&quot; sounds self-contained, yet leaves important decisions about authentication, validation, sessions and error handling unstated.</p>
<p><strong>Training data could also matter.</strong> Complex implementation examples may be accompanied by fuller discussion of design and security trade-offs, giving the model a stronger signal than a short example of an apparently basic feature. Those trivial implementations may have been lifted from demo apps and getting-started guides that never went through hardening.</p>
<p>These are plausible mechanisms, not conclusions. The study used one model, one programming language and a moderate sample of products. Replication across models and languages is needed before treating the size of the effect as general.</p>
<hr>
<p class="lead-in"><strong>The practical lesson</strong></p>
<p>Engineering teams naturally concentrate review effort around visibly difficult changes. We bring senior people into complicated designs, write detailed acceptance criteria and expect several rounds of review.</p>
<p>Small changes often travel through a faster path. AI coding tools make that path faster still.</p>
<p>My findings suggest that task simplicity is a poor proxy for security risk. A change can be easy to describe while still touching authentication, data handling or access control. <strong>The smallest prompt may contain the largest set of unstated assumptions.</strong></p>
<p>That has implications for code review, for platform defaults and for the way we introduce AI-assisted development. Security checks should follow the risk of the behaviour being implemented, rather than our impression of how difficult the implementation appears.</p>
<p>The tasks we trust most may be the ones we inspect least.</p>
<hr>
<p>In <a href="/complexity-paradox/security-expertise-still-matters/">the second article in this series</a> I explore what happened when security knowledge was added to the prompt. <a href="/complexity-paradox/architecture-beats-vigilance/">The third</a> examines whether automated reviewer agents can apply that knowledge more consistently.</p>
<hr>
<p class="lead-in"><strong>Thank you for reading my latest article. Please share your experiences and engage with the discussion - I am not always right, but I try to be insightful and thought-provoking.</strong></p>
<ul>
<li><strong>Where does your path to production treat &quot;small&quot; as a synonym for &quot;low risk&quot;?</strong></li>
<li><strong>If a change touches authentication or data handling, does your review process notice, or does it only notice how large the diff is?</strong></li>
<li><strong>What would it take to route review effort by the behaviour being changed rather than by how difficult the work looked?</strong></li>
</ul>
<p class="lead-in"><strong>Please reach out if you&#39;d like to continue the discussion.</strong></p>
]]></content:encoded>
    </item>
  </channel>
</rss>
