<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Posts on Programmer.ie: Modern AI programming</title>
    <link>http://programmer.ie/post/</link>
    <description>Recent content in Posts on Programmer.ie: Modern AI programming</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Sun, 09 Aug 2026 16:09:00 +0100</lastBuildDate>
    <atom:link href="http://programmer.ie/post/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Build a Production AI Agent From First Principles: The Complete Reference Architecture</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-44/</link>
      <pubDate>Sun, 09 Aug 2026 16:09:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-44/</guid>
      <description>&lt;h1 id=&#34;build-a-production-ai-agent-from-first-principles-the-complete-reference-architecture&#34;&gt;Build a Production AI Agent From First Principles: The Complete Reference Architecture&lt;/h1&gt;&#xA;&lt;p&gt;We have spent this series adding mechanisms only when a specific failure demanded them.&lt;/p&gt;&#xA;&lt;p&gt;We started with a model call.&lt;/p&gt;&#xA;&lt;p&gt;Then we added candidate generation, critique, planning, tool use, memory, search and verification.&lt;/p&gt;&#xA;&lt;p&gt;Then the system stopped looking like a clever prompt.&lt;/p&gt;&#xA;&lt;p&gt;It started looking like software.&lt;/p&gt;&#xA;&lt;p&gt;Then distributed systems problems arrived:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;duplicate work,&lt;/li&gt;&#xA;&lt;li&gt;retries,&lt;/li&gt;&#xA;&lt;li&gt;leases,&lt;/li&gt;&#xA;&lt;li&gt;fencing,&lt;/li&gt;&#xA;&lt;li&gt;backpressure,&lt;/li&gt;&#xA;&lt;li&gt;dependency failure,&lt;/li&gt;&#xA;&lt;li&gt;behavioral drift,&lt;/li&gt;&#xA;&lt;li&gt;release compatibility,&lt;/li&gt;&#xA;&lt;li&gt;replay,&lt;/li&gt;&#xA;&lt;li&gt;incident forensics,&lt;/li&gt;&#xA;&lt;li&gt;SLOs,&lt;/li&gt;&#xA;&lt;li&gt;authority,&lt;/li&gt;&#xA;&lt;li&gt;competence,&lt;/li&gt;&#xA;&lt;li&gt;capability acquisition,&lt;/li&gt;&#xA;&lt;li&gt;placement,&lt;/li&gt;&#xA;&lt;li&gt;handoff,&lt;/li&gt;&#xA;&lt;li&gt;stale state,&lt;/li&gt;&#xA;&lt;li&gt;stale intent,&lt;/li&gt;&#xA;&lt;li&gt;commitments,&lt;/li&gt;&#xA;&lt;li&gt;durable workflows,&lt;/li&gt;&#xA;&lt;li&gt;transaction recovery,&lt;/li&gt;&#xA;&lt;li&gt;trust boundaries,&lt;/li&gt;&#xA;&lt;li&gt;multi-agent coordination,&lt;/li&gt;&#xA;&lt;li&gt;and finally an explicit control plane.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;At this point the architecture is complete enough that adding another isolated mechanism would make the series worse rather than better.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 24: How Do You Release Agent Behavior Safely? Add Behavioral Contracts, Compatibility Checks and Promotion Gates</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-24/</link>
      <pubDate>Sun, 09 Aug 2026 12:09:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-24/</guid>
      <description>&lt;p&gt;A model change can pass health checks and still break your agent.&lt;/p&gt;&#xA;&lt;p&gt;A prompt change can preserve output schema and still change which tools the agent chooses.&lt;/p&gt;&#xA;&lt;p&gt;A router change can improve average cost and silently starve a specialist that is essential for one high-risk workload.&lt;/p&gt;&#xA;&lt;p&gt;A memory migration can keep every row intact and still change which memories are retrieved.&lt;/p&gt;&#xA;&lt;p&gt;A verifier upgrade can make every dashboard greener while making the system less trustworthy.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 23: Your Infrastructure Is Healthy. Why Is the Agent Getting Worse? Detect Behavioral Drift and Roll Back Safely</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-23/</link>
      <pubDate>Sun, 09 Aug 2026 12:00:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-23/</guid>
      <description>&lt;h1 id=&#34;your-infrastructure-is-healthy-why-is-the-agent-getting-worse&#34;&gt;Your Infrastructure Is Healthy. Why Is the Agent Getting Worse?&lt;/h1&gt;&#xA;&lt;p&gt;Your dashboards are green.&lt;/p&gt;&#xA;&lt;p&gt;The model endpoint is responding.&lt;/p&gt;&#xA;&lt;p&gt;The browser workers are alive.&lt;/p&gt;&#xA;&lt;p&gt;The database is healthy.&lt;/p&gt;&#xA;&lt;p&gt;The queue is draining.&lt;/p&gt;&#xA;&lt;p&gt;The verifier service is up.&lt;/p&gt;&#xA;&lt;p&gt;Latency has not exploded.&lt;/p&gt;&#xA;&lt;p&gt;There are no obvious exceptions.&lt;/p&gt;&#xA;&lt;p&gt;And yet the agent is getting worse.&lt;/p&gt;&#xA;&lt;p&gt;It fixes fewer bugs.&lt;/p&gt;&#xA;&lt;p&gt;It retrieves weaker evidence.&lt;/p&gt;&#xA;&lt;p&gt;It escalates to expensive models more often.&lt;/p&gt;&#xA;&lt;p&gt;It chooses the wrong tools more frequently.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 22: What Happens When One Dependency Starts Failing? Add Circuit Breakers, Bulkheads and Graceful Degradation</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-22/</link>
      <pubDate>Sun, 09 Aug 2026 11:26:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-22/</guid>
      <description>&lt;h1 id=&#34;what-happens-when-one-dependency-starts-failing&#34;&gt;What Happens When One Dependency Starts Failing?&lt;/h1&gt;&#xA;&lt;p&gt;An advanced agent platform can be working perfectly and still collapse.&lt;/p&gt;&#xA;&lt;p&gt;Not because the planner became confused.&lt;/p&gt;&#xA;&lt;p&gt;Not because the router chose the wrong model.&lt;/p&gt;&#xA;&lt;p&gt;Not because MCTS explored the wrong branch.&lt;/p&gt;&#xA;&lt;p&gt;Because one dependency became unhealthy.&lt;/p&gt;&#xA;&lt;p&gt;Maybe:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;the frontier model starts returning 503s,&lt;/li&gt;&#xA;&lt;li&gt;the browser pool starts timing out,&lt;/li&gt;&#xA;&lt;li&gt;the embedding service slows from 80 ms to 8 seconds,&lt;/li&gt;&#xA;&lt;li&gt;the verifier database starts dropping connections,&lt;/li&gt;&#xA;&lt;li&gt;the search API starts rate limiting,&lt;/li&gt;&#xA;&lt;li&gt;a sandbox cluster stops accepting jobs,&lt;/li&gt;&#xA;&lt;li&gt;or an external provider is technically up but so slow that every request consumes a worker for minutes.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Then the retries begin.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 21: What Happens When Too Many Agents Compete for the Same Resources? Add Admission Control, Quotas and Backpressure</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-21/</link>
      <pubDate>Sun, 09 Aug 2026 11:21:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-21/</guid>
      <description>&lt;h1 id=&#34;what-happens-when-too-many-agents-compete-for-the-same-resources&#34;&gt;What Happens When Too Many Agents Compete for the Same Resources?&lt;/h1&gt;&#xA;&lt;p&gt;A single agent can look healthy in isolation.&lt;/p&gt;&#xA;&lt;p&gt;It gets a request.&lt;/p&gt;&#xA;&lt;p&gt;It calls a model.&lt;/p&gt;&#xA;&lt;p&gt;It launches a few search branches.&lt;/p&gt;&#xA;&lt;p&gt;It opens a browser.&lt;/p&gt;&#xA;&lt;p&gt;It runs tests.&lt;/p&gt;&#xA;&lt;p&gt;It asks a verifier to check the result.&lt;/p&gt;&#xA;&lt;p&gt;Everything works.&lt;/p&gt;&#xA;&lt;p&gt;Then production traffic arrives.&lt;/p&gt;&#xA;&lt;p&gt;Ten agents start at once.&lt;/p&gt;&#xA;&lt;p&gt;Then fifty.&lt;/p&gt;&#xA;&lt;p&gt;Then five hundred.&lt;/p&gt;&#xA;&lt;p&gt;Now every agent still has a perfectly reasonable local plan.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 20: Can Your Agent Coordinate Across Machines Without Duplicating Work? Use Leases, Idempotency and Fencing</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-20/</link>
      <pubDate>Sun, 09 Aug 2026 11:13:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-20/</guid>
      <description>&lt;h1 id=&#34;can-your-agent-coordinate-across-machines-without-duplicating-work&#34;&gt;Can Your Agent Coordinate Across Machines Without Duplicating Work?&lt;/h1&gt;&#xA;&lt;p&gt;A single-process agent can already be complicated.&lt;/p&gt;&#xA;&lt;p&gt;It can plan.&lt;/p&gt;&#xA;&lt;p&gt;It can search.&lt;/p&gt;&#xA;&lt;p&gt;It can launch speculative branches.&lt;/p&gt;&#xA;&lt;p&gt;It can cancel losing work.&lt;/p&gt;&#xA;&lt;p&gt;It can verify outcomes.&lt;/p&gt;&#xA;&lt;p&gt;Then you move that work onto multiple workers.&lt;/p&gt;&#xA;&lt;p&gt;Now a new class of failure appears.&lt;/p&gt;&#xA;&lt;p&gt;Two workers both believe they own the same task.&lt;/p&gt;&#xA;&lt;p&gt;One worker pauses for thirty seconds.&lt;/p&gt;&#xA;&lt;p&gt;Another worker assumes it died and takes over.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 19: Can Your Agent Explore in Parallel Without Creating Chaos? Use Speculative Execution and Early Cancellation</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-19/</link>
      <pubDate>Sun, 09 Aug 2026 11:10:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-19/</guid>
      <description>&lt;h1 id=&#34;advanced-agents-from-first-principles-19-can-your-agent-explore-in-parallel-without-creating-chaos-use-speculative-execution-and-early-cancellation&#34;&gt;Advanced Agents From First Principles 19: Can Your Agent Explore in Parallel Without Creating Chaos? Use Speculative Execution and Early Cancellation&lt;/h1&gt;&#xA;&lt;p&gt;A production agent often has more than one useful thing it could do next.&lt;/p&gt;&#xA;&lt;p&gt;It could:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;inspect repository state,&lt;/li&gt;&#xA;&lt;li&gt;run a targeted test,&lt;/li&gt;&#xA;&lt;li&gt;retrieve documentation,&lt;/li&gt;&#xA;&lt;li&gt;ask a second model to critique a candidate,&lt;/li&gt;&#xA;&lt;li&gt;generate an alternative implementation,&lt;/li&gt;&#xA;&lt;li&gt;probe an API,&lt;/li&gt;&#xA;&lt;li&gt;inspect a deployment,&lt;/li&gt;&#xA;&lt;li&gt;or verify an invariant.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;If those actions are independent, executing them one by one can be needlessly slow.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 18: What Should Your Agent Observe Next? Use Expected Value of Information</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-18/</link>
      <pubDate>Sun, 09 Aug 2026 11:06:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-18/</guid>
      <description>&lt;h1 id=&#34;what-should-your-agent-observe-next&#34;&gt;What Should Your Agent Observe Next?&lt;/h1&gt;&#xA;&lt;p&gt;Your agent is uncertain.&lt;/p&gt;&#xA;&lt;p&gt;That does not tell you what to do.&lt;/p&gt;&#xA;&lt;p&gt;In the previous post we split uncertainty into operational categories:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;interpretation uncertainty,&lt;/li&gt;&#xA;&lt;li&gt;evidence uncertainty,&lt;/li&gt;&#xA;&lt;li&gt;route uncertainty,&lt;/li&gt;&#xA;&lt;li&gt;state uncertainty,&lt;/li&gt;&#xA;&lt;li&gt;tool uncertainty,&lt;/li&gt;&#xA;&lt;li&gt;candidate uncertainty,&lt;/li&gt;&#xA;&lt;li&gt;verification uncertainty.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;That is already better than one generic confidence score.&lt;/p&gt;&#xA;&lt;p&gt;But it still leaves a harder question:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;Which piece of information is worth buying next?&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;Suppose a coding agent is trying to fix a failing test.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 17: What Is Your Agent Actually Uncertain About?</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-17/</link>
      <pubDate>Sun, 09 Aug 2026 11:02:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-17/</guid>
      <description>&lt;h1 id=&#34;what-is-your-agent-actually-uncertain-about&#34;&gt;What Is Your Agent Actually Uncertain About?&lt;/h1&gt;&#xA;&lt;p&gt;An agent reaches a difficult point in a task.&lt;/p&gt;&#xA;&lt;p&gt;It is not sure what to do next.&lt;/p&gt;&#xA;&lt;p&gt;A common implementation responds like this:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;uncertain&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;call the model again&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;still uncertain&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;call a stronger model&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;still uncertain&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;search more&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That is not a reasoning strategy.&lt;/p&gt;&#xA;&lt;p&gt;It is a spending strategy.&lt;/p&gt;&#xA;&lt;p&gt;The system is using more computation without identifying what information is actually missing.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 16: Where Should an Agent Spend Its Compute? Build a Dynamic Budget Scheduler</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-16/</link>
      <pubDate>Sun, 09 Aug 2026 10:53:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-16/</guid>
      <description>&lt;h1 id=&#34;where-should-an-agent-spend-its-compute&#34;&gt;Where Should an Agent Spend Its Compute?&lt;/h1&gt;&#xA;&lt;p&gt;A production agent has a budget whether you designed one or not.&lt;/p&gt;&#xA;&lt;p&gt;Every model call costs something.&lt;/p&gt;&#xA;&lt;p&gt;Every search node costs something.&lt;/p&gt;&#xA;&lt;p&gt;Every tool invocation costs something.&lt;/p&gt;&#xA;&lt;p&gt;Every verifier costs something.&lt;/p&gt;&#xA;&lt;p&gt;Every retry adds latency.&lt;/p&gt;&#xA;&lt;p&gt;Every escalation to a stronger model spends money and time that could have been used somewhere else.&lt;/p&gt;&#xA;&lt;p&gt;The naive architecture gives every subsystem its own fixed limit:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;MAX_STEPS &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;20&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;MAX_SEARCH_NODES &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;32&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;MAX_CRITIC_CALLS &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;MAX_RETRIES &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;4&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;MAX_VERIFIER_CALLS &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That looks safe.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 15: How Do You Optimize an Agent Policy Without Turning It Into Another Black Box?</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-15/</link>
      <pubDate>Sun, 09 Aug 2026 10:49:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-15/</guid>
      <description>&lt;h1 id=&#34;how-do-you-optimize-an-agent-policy-without-turning-it-into-another-black-box&#34;&gt;How Do You Optimize an Agent Policy Without Turning It Into Another Black Box?&lt;/h1&gt;&#xA;&lt;p&gt;By now our advanced agent can do a lot.&lt;/p&gt;&#xA;&lt;p&gt;It can:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;route tasks to different models or specialists,&lt;/li&gt;&#xA;&lt;li&gt;decide whether to search,&lt;/li&gt;&#xA;&lt;li&gt;choose a search budget,&lt;/li&gt;&#xA;&lt;li&gt;decide when to escalate,&lt;/li&gt;&#xA;&lt;li&gt;invoke critics,&lt;/li&gt;&#xA;&lt;li&gt;retry or recover,&lt;/li&gt;&#xA;&lt;li&gt;stop when evidence is strong enough,&lt;/li&gt;&#xA;&lt;li&gt;learn from verified production trajectories,&lt;/li&gt;&#xA;&lt;li&gt;and trace the decisions that produced each outcome.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;That creates a new problem.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 14: Can Your Agent Learn From Its Own Trajectories Without Learning the Wrong Lessons?</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-14/</link>
      <pubDate>Sun, 09 Aug 2026 10:33:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-14/</guid>
      <description>&lt;p&gt;An advanced agent now leaves behind something extremely valuable:&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;evidence.&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;Not merely chat history.&lt;/p&gt;&#xA;&lt;p&gt;Not merely model outputs.&lt;/p&gt;&#xA;&lt;p&gt;Not merely traces.&lt;/p&gt;&#xA;&lt;p&gt;A sufficiently instrumented system can record:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;what state it was in,&lt;/li&gt;&#xA;&lt;li&gt;what alternatives it considered,&lt;/li&gt;&#xA;&lt;li&gt;which route it selected,&lt;/li&gt;&#xA;&lt;li&gt;what branches it pruned,&lt;/li&gt;&#xA;&lt;li&gt;which model or specialist it escalated to,&lt;/li&gt;&#xA;&lt;li&gt;which tools it called,&lt;/li&gt;&#xA;&lt;li&gt;which critic changed the answer,&lt;/li&gt;&#xA;&lt;li&gt;what verification evidence was produced,&lt;/li&gt;&#xA;&lt;li&gt;how much compute was spent,&lt;/li&gt;&#xA;&lt;li&gt;and whether the final result actually passed.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;That immediately suggests a tempting idea:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 13: How Do You Debug an Agent That Made the Wrong Decision? Add Trajectory Observability</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-13/</link>
      <pubDate>Sun, 09 Aug 2026 10:18:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-13/</guid>
      <description>&lt;p&gt;An advanced agent fails.&lt;/p&gt;&#xA;&lt;p&gt;You look at the final answer.&lt;/p&gt;&#xA;&lt;p&gt;It is wrong.&lt;/p&gt;&#xA;&lt;p&gt;So you inspect the prompt.&lt;/p&gt;&#xA;&lt;p&gt;The prompt looks reasonable.&lt;/p&gt;&#xA;&lt;p&gt;You inspect the model response.&lt;/p&gt;&#xA;&lt;p&gt;That also looks reasonable.&lt;/p&gt;&#xA;&lt;p&gt;But somewhere between the original request and the final result the system:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;chose the wrong specialist,&lt;/li&gt;&#xA;&lt;li&gt;pruned the branch that contained the right solution,&lt;/li&gt;&#xA;&lt;li&gt;trusted a critic that was wrong,&lt;/li&gt;&#xA;&lt;li&gt;escalated to an expensive model unnecessarily,&lt;/li&gt;&#xA;&lt;li&gt;failed to escalate when it should have,&lt;/li&gt;&#xA;&lt;li&gt;retrieved stale memory,&lt;/li&gt;&#xA;&lt;li&gt;spent most of its budget exploring duplicates,&lt;/li&gt;&#xA;&lt;li&gt;accepted a weak verifier signal,&lt;/li&gt;&#xA;&lt;li&gt;retried the same strategy under a different name,&lt;/li&gt;&#xA;&lt;li&gt;or transformed a local success into a global failure.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;The final answer does not tell you which one happened.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 12: Is Your Advanced Agent Actually Better? Benchmark It Under Equal Budgets</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-12/</link>
      <pubDate>Sun, 09 Aug 2026 10:10:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-12/</guid>
      <description>&lt;h1 id=&#34;is-your-advanced-agent-actually-better-benchmark-it-under-equal-budgets&#34;&gt;Is Your Advanced Agent Actually Better? Benchmark It Under Equal Budgets&lt;/h1&gt;&#xA;&lt;p&gt;You replace one model call with eight.&lt;/p&gt;&#xA;&lt;p&gt;Success rises from 62% to 74%.&lt;/p&gt;&#xA;&lt;p&gt;Great.&lt;/p&gt;&#xA;&lt;p&gt;Except the new system used:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;eight times the inference,&lt;/li&gt;&#xA;&lt;li&gt;three extra judges,&lt;/li&gt;&#xA;&lt;li&gt;two rounds of critique,&lt;/li&gt;&#xA;&lt;li&gt;a larger context,&lt;/li&gt;&#xA;&lt;li&gt;a stronger verifier,&lt;/li&gt;&#xA;&lt;li&gt;and several times the latency.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Did the architecture improve?&lt;/p&gt;&#xA;&lt;p&gt;Or did you just buy more attempts?&lt;/p&gt;&#xA;&lt;p&gt;This is one of the easiest mistakes to make in advanced agent engineering.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 11: Which Advanced Agent Architecture Should You Use? A Practical Selection Guide</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-11/</link>
      <pubDate>Sun, 09 Aug 2026 09:20:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-11/</guid>
      <description>&lt;h1 id=&#34;which-advanced-agent-architecture-should-you-use&#34;&gt;Which Advanced Agent Architecture Should You Use?&lt;/h1&gt;&#xA;&lt;p&gt;You now have too many options.&lt;/p&gt;&#xA;&lt;p&gt;That is a better problem than having none.&lt;/p&gt;&#xA;&lt;p&gt;But it is still a problem.&lt;/p&gt;&#xA;&lt;p&gt;You can add:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;self-consistency,&lt;/li&gt;&#xA;&lt;li&gt;Tree of Thoughts,&lt;/li&gt;&#xA;&lt;li&gt;beam search,&lt;/li&gt;&#xA;&lt;li&gt;Monte Carlo Tree Search,&lt;/li&gt;&#xA;&lt;li&gt;evolutionary search,&lt;/li&gt;&#xA;&lt;li&gt;specialist routing,&lt;/li&gt;&#xA;&lt;li&gt;planner/executor/critic separation,&lt;/li&gt;&#xA;&lt;li&gt;multi-agent debate,&lt;/li&gt;&#xA;&lt;li&gt;adaptive policies,&lt;/li&gt;&#xA;&lt;li&gt;learning from previous runs,&lt;/li&gt;&#xA;&lt;li&gt;or a mixture-of-agents runtime that chooses among several of them.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;The temptation is to combine everything.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 08: Is Your Agent Spending the Same Compute on Every Task? Build Adaptive Agents That Escalate Only When Needed</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-08/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-08/</guid>
      <description>Build adaptive agent runtimes that start cheap, measure uncertainty and failure, and escalate selectively into deeper reasoning, more samples, search, stronger models or specialist review only when the evidence justifies it.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 25: Can You Reproduce an Agent Run Months Later? Add Deterministic Replay and Provenance</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-25/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-25/</guid>
      <description>&lt;p&gt;A production agent fails on Tuesday.&lt;/p&gt;&#xA;&lt;p&gt;You inspect it on Wednesday and cannot reproduce the failure.&lt;/p&gt;&#xA;&lt;p&gt;Three weeks later someone asks a harder question:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;What exactly did this agent see, which release was running, which tools were called, which evidence was used, and why did the verifier accept the result?&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;If the answer is &amp;ldquo;we have some logs&amp;rdquo;, you do not yet have reproducibility.&lt;/p&gt;&#xA;&lt;p&gt;You have fragments.&lt;/p&gt;&#xA;&lt;p&gt;Advanced agents accumulate hidden variability quickly:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 26: Why Did the Agent Fail? Build an Incident Forensics Pipeline</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-26/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-26/</guid>
      <description>A practical incident-forensics workflow for advanced agents: reconstruct the run, find the earliest divergence, distinguish root cause from downstream symptoms, measure blast radius, and prove that a remediation would have prevented the incident.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 27: How Reliable Does an Agent Need to Be? Define SLOs and Error Budgets</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-27/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-27/</guid>
      <description>A practical reliability framework for advanced agents: define verified-success SLOs, false-success ceilings, UNKNOWN budgets, latency and cost targets, then use error-budget burn to decide when to ship capability and when to stop and harden the system.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 28: Where Should You Spend the Next Engineering Hour? Prioritize Reliability by Risk and Expected Return</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-28/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-28/</guid>
      <description>A practical framework for deciding where to spend the next engineering hour in an advanced-agent system: rank remediation by expected reduction in verified reliability loss, severity, recurrence, blast radius, confidence and implementation cost.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 29: When Should an Agent Stop and Ask a Human? Design Authority Boundaries and Escalation</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-29/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-29/</guid>
      <description>A practical architecture for agent authority boundaries: decide what an agent may do autonomously, when it must escalate, what evidence a human reviewer needs, and how to avoid turning human approval into rubber-stamping.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 30: Is This Task Outside Your Agent’s Competence? Build Competence Envelopes and OOD Detection</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-30/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-30/</guid>
      <description>A practical framework for competence envelopes in production agents: distinguish uncertainty from lack of validated competence, detect out-of-distribution tasks, contract authority when evidence is weak, and expand autonomy only through measured evidence.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 31: How Can an Agent Learn New Capabilities Without Expanding Its Own Authority? Use Sandboxed Capability Acquisition</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-31/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-31/</guid>
      <description>A practical architecture for sandboxed capability acquisition: let agents explore tasks outside their validated competence envelope, accumulate externally verified evidence, and propose capability expansion without ever granting themselves production authority.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 32: Which Capabilities Are Actually Worth Building? Design a Capability Portfolio</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-32/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-32/</guid>
      <description>A practical framework for deciding which agent capabilities are worth acquiring: rank missing capabilities by user value, verifier availability, reliability risk, acquisition cost, maintenance burden, and the quality of human or deterministic alternatives.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 33: Which Shared Components Actually Unlock More Capability? Build a Capability Dependency Graph</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-33/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-33/</guid>
      <description>A practical capability-dependency architecture for advanced agents: identify shared primitives that unlock many capabilities, quantify leverage, expose correlated-failure hotspots, and invest in platform components without creating hidden systemic risk.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 34: Where Should This Task Actually Run? Build Capability-Aware Placement Across Models, Providers and Resource Pools</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-34/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-34/</guid>
      <description>A practical placement architecture for advanced agents: route work across local and frontier models, providers, regions, GPUs, browser pools and specialist runtimes using demonstrated competence, verifier availability, policy constraints, health, cost and latency rather than model prestige.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 35: How Do You Move a Running Agent Between Workers Without Losing Meaning? Build Portable Execution State and Safe Handoff</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-35/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-35/</guid>
      <description>A practical architecture for portable agent execution state: checkpoint long-running runs, transfer ownership safely across workers and providers, preserve evidence and authority, and reject migrations that cannot be proven compatible.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 36: Is Your Agent Acting on Stale State? Build Temporal Consistency, Freshness Budgets and Conflict Detection</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-36/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-36/</guid>
      <description>A practical architecture for keeping long-running agents from acting on stale assumptions: classify state by freshness, track version vectors, detect conflicts, revalidate before consequential actions, and force replanning when the world has changed underneath the run.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 37: Is Your Agent Still Solving the Right Task? Build Intent Versioning, Supersession and Cancellation</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-37/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-37/</guid>
      <description>A production architecture for intent versioning, supersession and cancellation in long-running agents: stop obsolete work, preserve committed effects, reconcile partial actions, and prevent stale goals from retaining authority.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 38: A Plan Is Not a Commitment — Model Goals, Commitments and Executable Work</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-38/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-38/</guid>
      <description>A practical architecture for separating goals, plans, commitments, tasks and actions in long-running agents so replanning, cancellation, handoff and external obligations remain correct.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 39: How Do You Make an Agent Survive for Days? Build Durable Long-Running Workflows</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-39/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-39/</guid>
      <description>A practical architecture for long-running agents: keep workflow state durable while treating models and workers as disposable, with explicit waits, retries, timers, human approvals, checkpoints, commitments, cancellation and replay.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 40: Your Agent Changed the World. What Happens When Step Two Fails? Build Transactions, Compensation and Reconciliation</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-40/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-40/</guid>
      <description>A practical architecture for agent workflows that span systems without a global transaction: classify side effects, prepare carefully, commit with identity, verify externally, compensate when possible, reconcile ambiguity, and never pretend rollback is free.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 41: What Should Your Agent Trust? Build Explicit Security and Trust Boundaries</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-41/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-41/</guid>
      <description>A practical security architecture for production agents: separate data from authority, classify trust, scope credentials and capabilities, preserve provenance, isolate generated code, resist prompt injection, and keep security-critical decisions outside model control.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 42: How Do Multiple Agents Coordinate Without Becoming a Distributed Argument?</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-42/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-42/</guid>
      <description>A practical architecture for multi-agent coordination: explicit ownership, delegation, contracts, commitment transfer, shared intent, evidence provenance, conflict handling, deadlock prevention, and independent verification instead of agents merely chatting until they agree.</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 43: Who Controls the Agent? Build an Explicit Agent Control Plane</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-43/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-43/</guid>
      <description>A production-agent architecture that separates control-plane policy from execution-plane reasoning: intent, competence, authority, placement, budgets, reliability, releases, security and escalation remain enforceable outside the model.</description>
    </item>
    <item>
      <title>You Probably Don&#39;t Need All of This: Build the Minimum Production Agent Architecture</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-45/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-45/</guid>
      <description>&lt;h1 id=&#34;you-probably-dont-need-all-of-this&#34;&gt;You Probably Don&amp;rsquo;t Need All of This&lt;/h1&gt;&#xA;&lt;p&gt;Over the previous forty-five steps, we built almost every major mechanism you might need in a serious agent platform.&lt;/p&gt;&#xA;&lt;p&gt;Search.&lt;/p&gt;&#xA;&lt;p&gt;Critique.&lt;/p&gt;&#xA;&lt;p&gt;Planning.&lt;/p&gt;&#xA;&lt;p&gt;Memory.&lt;/p&gt;&#xA;&lt;p&gt;Verification.&lt;/p&gt;&#xA;&lt;p&gt;Distributed execution.&lt;/p&gt;&#xA;&lt;p&gt;Leases.&lt;/p&gt;&#xA;&lt;p&gt;Fencing.&lt;/p&gt;&#xA;&lt;p&gt;Backpressure.&lt;/p&gt;&#xA;&lt;p&gt;Behavioral releases.&lt;/p&gt;&#xA;&lt;p&gt;Replay.&lt;/p&gt;&#xA;&lt;p&gt;Incident forensics.&lt;/p&gt;&#xA;&lt;p&gt;SLOs.&lt;/p&gt;&#xA;&lt;p&gt;Competence envelopes.&lt;/p&gt;&#xA;&lt;p&gt;Authority boundaries.&lt;/p&gt;&#xA;&lt;p&gt;Capability portfolios.&lt;/p&gt;&#xA;&lt;p&gt;Placement.&lt;/p&gt;&#xA;&lt;p&gt;Portable execution state.&lt;/p&gt;&#xA;&lt;p&gt;Temporal consistency.&lt;/p&gt;&#xA;&lt;p&gt;Intent versioning.&lt;/p&gt;&#xA;&lt;p&gt;Commitments.&lt;/p&gt;&#xA;&lt;p&gt;Durable workflows.&lt;/p&gt;&#xA;&lt;p&gt;Transaction recovery.&lt;/p&gt;&#xA;&lt;p&gt;Security boundaries.&lt;/p&gt;&#xA;&lt;p&gt;Multi-agent coordination.&lt;/p&gt;&#xA;&lt;p&gt;An explicit control plane.&lt;/p&gt;&#xA;&lt;p&gt;And finally, in Step 44, we assembled those ideas into a complete reference architecture for a production AI agent.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 10: Are You Combining Every Agent Technique Into One Monster? Build a Mixture-of-Agents Runtime</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-10/</link>
      <pubDate>Sun, 09 Aug 2026 00:25:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-10/</guid>
      <description>&lt;p&gt;You have a working agent.&lt;/p&gt;&#xA;&lt;p&gt;Then you add retrieval.&lt;/p&gt;&#xA;&lt;p&gt;Then memory.&lt;/p&gt;&#xA;&lt;p&gt;Then Best-of-N.&lt;/p&gt;&#xA;&lt;p&gt;Then critique and revision.&lt;/p&gt;&#xA;&lt;p&gt;Then Tree of Thoughts.&lt;/p&gt;&#xA;&lt;p&gt;Then MCTS.&lt;/p&gt;&#xA;&lt;p&gt;Then specialist models.&lt;/p&gt;&#xA;&lt;p&gt;Then adversarial review.&lt;/p&gt;&#xA;&lt;p&gt;Then a planner, executor, critic and verifier.&lt;/p&gt;&#xA;&lt;p&gt;Then a stronger model for hard cases.&lt;/p&gt;&#xA;&lt;p&gt;Eventually the architecture starts to look like this:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;request&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;planner&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;retrieval&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;reasoning&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;Best-of-N&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;critic&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;Tree of Thoughts&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;MCTS&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;frontier model&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;second critic&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;verifier&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Every mechanism may have been individually reasonable.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 09: Can Your Agent Actually Learn From Previous Runs?</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-09/</link>
      <pubDate>Sun, 09 Aug 2026 00:19:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-09/</guid>
      <description>&lt;h1 id=&#34;can-your-agent-actually-learn-from-previous-runs&#34;&gt;Can Your Agent Actually Learn From Previous Runs?&lt;/h1&gt;&#xA;&lt;p&gt;A production agent can execute the same class of task hundreds or thousands of times.&lt;/p&gt;&#xA;&lt;p&gt;It can see the same failure repeatedly.&lt;/p&gt;&#xA;&lt;p&gt;It can discover the same workaround repeatedly.&lt;/p&gt;&#xA;&lt;p&gt;It can call the same expensive model repeatedly.&lt;/p&gt;&#xA;&lt;p&gt;And still behave as if every task is the first one it has ever seen.&lt;/p&gt;&#xA;&lt;p&gt;That is not necessarily a memory problem.&lt;/p&gt;&#xA;&lt;p&gt;It may already have excellent memory.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 06: Does One Agent Plan, Execute and Judge Its Own Work? Build a Planner-Executor-Critic Architecture</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-06/</link>
      <pubDate>Sat, 08 Aug 2026 23:49:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-06/</guid>
      <description>&lt;h1 id=&#34;does-one-agent-plan-execute-and-judge-its-own-work-build-a-planner-executor-critic-architecture&#34;&gt;Does One Agent Plan, Execute and Judge Its Own Work? Build a Planner-Executor-Critic Architecture&lt;/h1&gt;&#xA;&lt;p&gt;A single model can often do all of these things:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;understand a task,&lt;/li&gt;&#xA;&lt;li&gt;decide what to do,&lt;/li&gt;&#xA;&lt;li&gt;execute a tool call,&lt;/li&gt;&#xA;&lt;li&gt;inspect the result,&lt;/li&gt;&#xA;&lt;li&gt;critique its own work,&lt;/li&gt;&#xA;&lt;li&gt;decide whether it succeeded,&lt;/li&gt;&#xA;&lt;li&gt;and produce the final answer.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;That is convenient.&lt;/p&gt;&#xA;&lt;p&gt;It is also a dangerous concentration of responsibilities.&lt;/p&gt;&#xA;&lt;p&gt;If the same component creates the plan, executes it, explains why the result is good, and decides whether the job is complete, then failures become difficult to localize.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 05: Is One Model Doing Everything? Build a Mixture of Experts at the Agent Level</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-05/</link>
      <pubDate>Sat, 08 Aug 2026 23:41:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-05/</guid>
      <description>&lt;p&gt;A common agent architecture starts simply:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;request&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;model&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;action&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That simplicity is valuable.&lt;/p&gt;&#xA;&lt;p&gt;It should be your default.&lt;/p&gt;&#xA;&lt;p&gt;But eventually you may notice something strange.&lt;/p&gt;&#xA;&lt;p&gt;The same model is being asked to do everything:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;classify the task,&lt;/li&gt;&#xA;&lt;li&gt;search documentation,&lt;/li&gt;&#xA;&lt;li&gt;reason about code,&lt;/li&gt;&#xA;&lt;li&gt;write SQL,&lt;/li&gt;&#xA;&lt;li&gt;review a patch,&lt;/li&gt;&#xA;&lt;li&gt;summarize logs,&lt;/li&gt;&#xA;&lt;li&gt;judge another model,&lt;/li&gt;&#xA;&lt;li&gt;decide whether a deployment is safe,&lt;/li&gt;&#xA;&lt;li&gt;and answer simple questions that did not require an expensive model in the first place.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;At that point the problem may no longer be:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 04: Does Your Agent Prune Good Ideas Too Early? Use Monte Carlo Tree Search for Long-Horizon Reasoning</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-04/</link>
      <pubDate>Sat, 08 Aug 2026 23:37:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-04/</guid>
      <description>&lt;p&gt;A common failure in search-based agents is easy to miss.&lt;/p&gt;&#xA;&lt;p&gt;The agent generates several plausible branches.&lt;/p&gt;&#xA;&lt;p&gt;It scores them.&lt;/p&gt;&#xA;&lt;p&gt;One branch looks weak.&lt;/p&gt;&#xA;&lt;p&gt;So the runtime prunes it.&lt;/p&gt;&#xA;&lt;p&gt;Later, you discover that the discarded branch was the only one that could have reached the correct solution.&lt;/p&gt;&#xA;&lt;p&gt;The problem was not generation.&lt;/p&gt;&#xA;&lt;p&gt;The problem was not necessarily the model.&lt;/p&gt;&#xA;&lt;p&gt;The problem was &lt;strong&gt;search allocation&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;The agent spent too much compute exploiting what looked good early and too little compute exploring alternatives whose value only became visible later.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 03: Does Your Agent Commit to a Bad Reasoning Path Too Early? Build a Tree of Thoughts</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-03/</link>
      <pubDate>Sat, 08 Aug 2026 23:25:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-03/</guid>
      <description>&lt;p&gt;A reasoning agent can fail even when every individual step looks plausible.&lt;/p&gt;&#xA;&lt;p&gt;The problem is often not that the model cannot produce a good line of reasoning.&lt;/p&gt;&#xA;&lt;p&gt;The problem is that it commits too early.&lt;/p&gt;&#xA;&lt;p&gt;It chooses one interpretation, one hypothesis, one plan, or one next step and then spends the rest of the run trying to make that decision work.&lt;/p&gt;&#xA;&lt;p&gt;That gives us a common failure pattern:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;problem&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;first plausible thought&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;second thought conditioned on the first&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;third thought conditioned on both&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;...&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;confident answer built on an early mistake&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;If the first branch was wrong, every later step inherits the error.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 02: Why Does My Reasoning Agent Give a Different Answer Every Time? Use Self-Consistency Without Confusing Consensus With Truth</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-02/</link>
      <pubDate>Sat, 08 Aug 2026 22:44:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-02/</guid>
      <description>&lt;p&gt;A reasoning agent gives you one answer.&lt;/p&gt;&#xA;&lt;p&gt;You run it again.&lt;/p&gt;&#xA;&lt;p&gt;It gives you another.&lt;/p&gt;&#xA;&lt;p&gt;You change nothing important:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;same task,&lt;/li&gt;&#xA;&lt;li&gt;same tools,&lt;/li&gt;&#xA;&lt;li&gt;same model family,&lt;/li&gt;&#xA;&lt;li&gt;same broad context.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Yet the result changes.&lt;/p&gt;&#xA;&lt;p&gt;That is not necessarily a bug.&lt;/p&gt;&#xA;&lt;p&gt;A probabilistic model is allowed to produce more than one plausible trajectory.&lt;/p&gt;&#xA;&lt;p&gt;The engineering question is different:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;How should an agent system use that variation?&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;One common answer is &lt;strong&gt;self-consistency&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 01: Does Your AI Agent Fail on Complex Reasoning Tasks? Treat Chain of Thought as Computation, Not Proof</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-01/</link>
      <pubDate>Sat, 08 Aug 2026 22:35:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-01/</guid>
      <description>&lt;p&gt;Most developers first encounter chain of thought as a prompting trick:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;Think step by step.&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That framing is too shallow for agent engineering.&lt;/p&gt;&#xA;&lt;p&gt;For an advanced agent, the useful idea is not that the model should produce a long explanation. The useful idea is that a difficult task may benefit from &lt;strong&gt;intermediate computational state&lt;/strong&gt; before the system commits to an action or answer.&lt;/p&gt;&#xA;&lt;p&gt;That is a very different claim.&lt;/p&gt;&#xA;&lt;p&gt;A reasoning trace can help a system decompose a problem, preserve intermediate conclusions, identify missing information, decide what to verify next, and expose places where search or tools should be used.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 00: When Should You Use an Advanced Agent Architecture?</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-00/</link>
      <pubDate>Sat, 08 Aug 2026 22:27:00 +0100</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-00/</guid>
      <description>&lt;h1 id=&#34;advanced-agents-from-first-principles-00-when-should-you-use-an-advanced-agent-architecture&#34;&gt;Advanced Agents From First Principles 00: When Should You Use an Advanced Agent Architecture?&lt;/h1&gt;&#xA;&lt;p&gt;You built an agent.&lt;/p&gt;&#xA;&lt;p&gt;It can:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;call tools,&lt;/li&gt;&#xA;&lt;li&gt;maintain state,&lt;/li&gt;&#xA;&lt;li&gt;plan,&lt;/li&gt;&#xA;&lt;li&gt;revise its own work,&lt;/li&gt;&#xA;&lt;li&gt;search over alternatives,&lt;/li&gt;&#xA;&lt;li&gt;remember useful information,&lt;/li&gt;&#xA;&lt;li&gt;and verify whether the requested outcome actually happened.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Now the temptation begins.&lt;/p&gt;&#xA;&lt;p&gt;You add another model.&lt;/p&gt;&#xA;&lt;p&gt;Then a critic.&lt;/p&gt;&#xA;&lt;p&gt;Then a planner.&lt;/p&gt;&#xA;&lt;p&gt;Then a judge.&lt;/p&gt;&#xA;&lt;p&gt;Then a router.&lt;/p&gt;&#xA;&lt;p&gt;Then three specialist agents.&lt;/p&gt;&#xA;&lt;p&gt;Then a tree search.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 09: AI Agent Says It Worked When It Didn’t? Verify the Result Outside the LLM</title>
      <link>http://programmer.ie/post/agents-from-first-principles-09/</link>
      <pubDate>Sat, 08 Aug 2026 17:31:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-09/</guid>
      <description>&lt;p&gt;An AI agent says:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Done. The task is complete.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;That sentence is almost worthless.&lt;/p&gt;&#xA;&lt;p&gt;The agent may have:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;edited the wrong file,&lt;/li&gt;&#xA;&lt;li&gt;changed the right file incorrectly,&lt;/li&gt;&#xA;&lt;li&gt;skipped part of the request,&lt;/li&gt;&#xA;&lt;li&gt;broken another subsystem,&lt;/li&gt;&#xA;&lt;li&gt;failed to save its work,&lt;/li&gt;&#xA;&lt;li&gt;misread a tool result,&lt;/li&gt;&#xA;&lt;li&gt;passed a stale test,&lt;/li&gt;&#xA;&lt;li&gt;inspected the wrong environment,&lt;/li&gt;&#xA;&lt;li&gt;or simply decided that its own answer looked convincing.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;The central problem is simple:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;The system that produced the answer should not be the only system deciding whether the answer is correct.&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 08: AI Agent Picks the First Solution? Add Search Instead of One-Shot Generation</title>
      <link>http://programmer.ie/post/agents-from-first-principles-08/</link>
      <pubDate>Sat, 08 Aug 2026 17:26:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-08/</guid>
      <description>&lt;p&gt;An AI agent often fails for a surprisingly ordinary reason:&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;it commits too early.&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;It finds one plausible next action, follows it, and then spends the rest of the run trying to make that first choice work.&lt;/p&gt;&#xA;&lt;p&gt;That can look intelligent because the agent keeps reasoning, calling tools, revising plans, and explaining itself.&lt;/p&gt;&#xA;&lt;p&gt;But underneath, the trajectory may be almost completely determined by an early mistake.&lt;/p&gt;&#xA;&lt;p&gt;A coding agent chooses the wrong implementation strategy and spends twenty tool calls repairing it.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 07: AI Agent Forgets Previous Work? Add Working, Semantic and Episodic Memory</title>
      <link>http://programmer.ie/post/agents-from-first-principles-07/</link>
      <pubDate>Sat, 08 Aug 2026 17:14:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-07/</guid>
      <description>&lt;h1 id=&#34;ai-agent-forgets-previous-work-add-working-semantic-and-episodic-memory&#34;&gt;AI Agent Forgets Previous Work? Add Working, Semantic and Episodic Memory&lt;/h1&gt;&#xA;&lt;p&gt;An agent can use the right model, call the right tools, execute the right plan, and still behave as if nothing that happened five minutes ago matters.&lt;/p&gt;&#xA;&lt;p&gt;You see the symptoms quickly:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;it re-reads files it already inspected;&lt;/li&gt;&#xA;&lt;li&gt;it repeats research it already completed;&lt;/li&gt;&#xA;&lt;li&gt;it asks for information the user already supplied;&lt;/li&gt;&#xA;&lt;li&gt;it forgets why a previous approach failed;&lt;/li&gt;&#xA;&lt;li&gt;it loses decisions made earlier in a long task;&lt;/li&gt;&#xA;&lt;li&gt;it treats every new run as if the system has never seen the problem before;&lt;/li&gt;&#xA;&lt;li&gt;it retrieves an old answer and treats it as current truth;&lt;/li&gt;&#xA;&lt;li&gt;it fills the prompt with so much history that the useful information is buried.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;The usual response is:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 06: AI Agent Chooses the Wrong Tool? Design Better Tool Interfaces, Schemas and Routing</title>
      <link>http://programmer.ie/post/agents-from-first-principles-06/</link>
      <pubDate>Sat, 08 Aug 2026 17:09:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-06/</guid>
      <description>&lt;p&gt;An agent can have a perfectly capable model and still behave badly because its tools are badly designed.&lt;/p&gt;&#xA;&lt;p&gt;This is one of the most common agent failures in production:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;user goal&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;agent&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;wrong tool&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;wrong action&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The model may understand the task.&lt;/p&gt;&#xA;&lt;p&gt;The agent may have enough context.&lt;/p&gt;&#xA;&lt;p&gt;The problem is that the action space is ambiguous.&lt;/p&gt;&#xA;&lt;p&gt;If two tools overlap, their descriptions are vague, their schemas are huge, or their results are difficult to interpret, the model has to guess.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 05: AI Agent Gets Stuck in a Loop? Add State, Feedback and Stopping Conditions</title>
      <link>http://programmer.ie/post/agents-from-first-principles-05/</link>
      <pubDate>Sat, 08 Aug 2026 16:56:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-05/</guid>
      <description>&lt;p&gt;An AI agent that keeps calling the same tool, revisiting the same page, rewriting the same file, or repeatedly saying “I’ll try again” is not displaying persistence.&lt;/p&gt;&#xA;&lt;p&gt;It is displaying a control-flow bug.&lt;/p&gt;&#xA;&lt;p&gt;This is one of the most common failure modes in agent software because the basic loop is deceptively simple:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;observe&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;decide&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;act&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;observe&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;repeat&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The problem is hidden inside the final word.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 04: AI Agent Fails on Multi-Step Tasks? Separate Planning From Execution</title>
      <link>http://programmer.ie/post/agents-from-first-principles-04/</link>
      <pubDate>Sat, 08 Aug 2026 16:35:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-04/</guid>
      <description>&lt;p&gt;A surprising number of agent failures are not really model failures.&lt;/p&gt;&#xA;&lt;p&gt;The model may be perfectly capable of writing each individual step. The failure happens because the system tries to decide &lt;strong&gt;what to do&lt;/strong&gt; and &lt;strong&gt;do it&lt;/strong&gt; at the same time.&lt;/p&gt;&#xA;&lt;p&gt;That works for simple tasks:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;question&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;model&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;answer&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;It becomes fragile when success depends on several ordered actions:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;goal&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;step 1&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;step 2&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;step 3&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;verification&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;A useful next step in agent design is therefore to separate two jobs:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 03: AI Agent Keeps Making the Same Mistake? Add a Critique-and-Revision Loop</title>
      <link>http://programmer.ie/post/agents-from-first-principles-03/</link>
      <pubDate>Sat, 08 Aug 2026 16:23:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-03/</guid>
      <description>&lt;p&gt;An AI agent can fail in a particularly frustrating way: it produces an answer that is almost right, you ask it to improve the answer, and it produces another answer with the same underlying defect.&lt;/p&gt;&#xA;&lt;p&gt;Sometimes the wording changes. Sometimes it adds more explanation. Sometimes it becomes longer and more confident. But the important mistake survives.&lt;/p&gt;&#xA;&lt;p&gt;That usually means the system is doing this:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;prompt&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;model&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;answer&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;or this:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 02: AI Agent Gives Inconsistent Answers? Generate Multiple Candidates and Rank Them</title>
      <link>http://programmer.ie/post/agents-from-first-principles-02/</link>
      <pubDate>Sat, 08 Aug 2026 15:54:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-02/</guid>
      <description>&lt;p&gt;One of the first things you notice when you build anything around a large language model is that the same prompt does not always produce the same quality of answer.&lt;/p&gt;&#xA;&lt;p&gt;Sometimes the first response is excellent.&lt;/p&gt;&#xA;&lt;p&gt;Sometimes it is merely acceptable.&lt;/p&gt;&#xA;&lt;p&gt;Sometimes it misses the point entirely.&lt;/p&gt;&#xA;&lt;p&gt;That creates a very common agent-engineering question:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;If the model is inconsistent, should the agent trust the first answer it gets?&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;Often, no.&lt;/p&gt;</description>
    </item>
    <item>
      <title>AI Agent Returning Invalid Tool Calls? How to Validate LLM Actions</title>
      <link>http://programmer.ie/post/agents-from-first-principles-01/</link>
      <pubDate>Sat, 08 Aug 2026 15:46:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-01/</guid>
      <description>&lt;p&gt;If your agent sometimes invents a tool name, omits a required argument, returns malformed JSON, or produces an action that looks plausible but cannot actually be executed, the problem is usually not &amp;ldquo;the agent is dumb.&amp;rdquo;&lt;/p&gt;&#xA;&lt;p&gt;The problem is that &lt;strong&gt;raw language-model output has been allowed to cross directly into execution&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;That boundary is too weak.&lt;/p&gt;&#xA;&lt;p&gt;The simplest useful agent architecture is not:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;prompt&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;model&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;execute whatever came back&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;It is:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents From First Principles 00: What Is an Agent, Really?</title>
      <link>http://programmer.ie/post/agents-from-first-principles-00/</link>
      <pubDate>Sat, 08 Aug 2026 15:40:00 +0100</pubDate>
      <guid>http://programmer.ie/post/agents-from-first-principles-00/</guid>
      <description>&lt;h1 id=&#34;what-is-an-agent-really&#34;&gt;What Is an Agent, Really?&lt;/h1&gt;&#xA;&lt;p&gt;This is the first post in &lt;strong&gt;Agents From First Principles&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;It follows two earlier series.&lt;/p&gt;&#xA;&lt;p&gt;In &lt;strong&gt;PyTorch: Zero to Hero&lt;/strong&gt;, we worked upward from tensors, autograd and neural-network building blocks until we could build a small language model ourselves.&lt;/p&gt;&#xA;&lt;p&gt;In &lt;strong&gt;Models From First Principles&lt;/strong&gt;, we moved one level higher. We looked at how learned components can be composed into scorers, value models, policy heads, recurrent models, hierarchical models and compact recursive systems.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 08: Which Model Should You Use? MR.Q, EBT, SICQL, HRM, Tiny and PACS Compared</title>
      <link>http://programmer.ie/post/models-from-first-principles-08/</link>
      <pubDate>Sat, 08 Aug 2026 15:11:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-08/</guid>
      <description>&lt;h1 id=&#34;which-model-should-you-use-mrq-ebt-sicql-hrm-tiny-and-pacs-compared&#34;&gt;Which Model Should You Use? MR.Q, EBT, SICQL, HRM, Tiny and PACS Compared&lt;/h1&gt;&#xA;&lt;p&gt;This is the final post in &lt;strong&gt;Models From First Principles&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;The earlier posts asked a sequence of architectural questions:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;how do we score a context-response pair?&lt;/li&gt;&#xA;&lt;li&gt;when is one scalar no longer enough?&lt;/li&gt;&#xA;&lt;li&gt;when should Q, V and policy become explicit components?&lt;/li&gt;&#xA;&lt;li&gt;when is one forward pass insufficient?&lt;/li&gt;&#xA;&lt;li&gt;when does recurrence help?&lt;/li&gt;&#xA;&lt;li&gt;when does hierarchy help?&lt;/li&gt;&#xA;&lt;li&gt;when is a smaller recursive model a better trade-off?&lt;/li&gt;&#xA;&lt;li&gt;when should attention or a sparse autoencoder be added?&lt;/li&gt;&#xA;&lt;li&gt;when should we change the optimizer rather than the model?&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;This post asks the question that matters when building a real system:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 07: PACS — Building an Optimizer From Gradient Statistics</title>
      <link>http://programmer.ie/post/models-from-first-principles-07/</link>
      <pubDate>Sat, 08 Aug 2026 15:05:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-07/</guid>
      <description>&lt;h1 id=&#34;pacs--building-an-optimizer-from-gradient-statistics&#34;&gt;PACS — Building an Optimizer From Gradient Statistics&lt;/h1&gt;&#xA;&lt;p&gt;So far in &lt;strong&gt;Models From First Principles&lt;/strong&gt;, every post has asked some version of the same question:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;What should the model compute?&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;MR.Q gave us a scalar quality estimate.&lt;/p&gt;&#xA;&lt;p&gt;EBT split one shared representation into Q, V and Policy.&lt;/p&gt;&#xA;&lt;p&gt;SICQL made those heads explicit, replaceable components.&lt;/p&gt;&#xA;&lt;p&gt;HRM introduced repeated computation over fast and slow latent states.&lt;/p&gt;&#xA;&lt;p&gt;Tiny compressed iterative refinement into one recursive latent state.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 06: Inside Tiny — Residual Blocks, Attention and Sparse Autoencoders</title>
      <link>http://programmer.ie/post/models-from-first-principles-06/</link>
      <pubDate>Sat, 08 Aug 2026 15:00:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-06/</guid>
      <description>&lt;h1 id=&#34;inside-tiny-residual-blocks-attention-and-sparse-autoencoders&#34;&gt;Inside Tiny: Residual Blocks, Attention and Sparse Autoencoders&lt;/h1&gt;&#xA;&lt;p&gt;In the previous post, we built a compact recursive model around one idea:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;context + candidate + latent state&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;              ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;          projection&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;              ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;         reusable core&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;              ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;       proposed update&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;              ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;      z ← z + α · update&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;              ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;            repeat&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That architecture looked more sophisticated than MR.Q, EBT or SICQL because it introduced recurrence.&lt;/p&gt;&#xA;&lt;p&gt;But the central idea of this series is that a model stops looking mysterious when we keep opening it.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 05: Tiny — Recursive Reasoning With a Small Neural Network</title>
      <link>http://programmer.ie/post/models-from-first-principles-05/</link>
      <pubDate>Sat, 08 Aug 2026 14:55:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-05/</guid>
      <description>&lt;h1 id=&#34;tiny--recursive-reasoning-with-a-small-neural-network&#34;&gt;Tiny — Recursive Reasoning With a Small Neural Network&lt;/h1&gt;&#xA;&lt;p&gt;The previous post introduced a much more ambitious architecture.&lt;/p&gt;&#xA;&lt;p&gt;Instead of taking one representation and predicting from it once, the &lt;strong&gt;Hierarchical Reasoning Model&lt;/strong&gt; repeatedly updated two latent states:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;input&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;low-level state&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓ ↓ ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;high-level state&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;repeat&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That gave us something genuinely new:&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;computation could continue without adding a new set of parameters for every step.&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 04: HRM — Hierarchical Reasoning With Fast and Slow Recurrent State</title>
      <link>http://programmer.ie/post/models-from-first-principles-04/</link>
      <pubDate>Sat, 08 Aug 2026 14:48:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-04/</guid>
      <description>&lt;h1 id=&#34;hrm--hierarchical-reasoning-with-fast-and-slow-recurrent-state&#34;&gt;HRM — Hierarchical Reasoning With Fast and Slow Recurrent State&lt;/h1&gt;&#xA;&lt;p&gt;The previous models in this series were mostly &lt;strong&gt;one-pass models&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;MR.Q took two embeddings and produced one score.&lt;/p&gt;&#xA;&lt;p&gt;EBT kept the same basic structure but added several heads.&lt;/p&gt;&#xA;&lt;p&gt;SICQL made those heads explicit components.&lt;/p&gt;&#xA;&lt;p&gt;The architecture grew, but the shape of the computation was still familiar:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;input&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;encoder&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;representation&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;heads&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;outputs&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;HRM changes the question.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 03: SICQL — Building a Model From Q, V and Policy Networks</title>
      <link>http://programmer.ie/post/models-from-first-principles-03/</link>
      <pubDate>Sat, 08 Aug 2026 14:44:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-03/</guid>
      <description>&lt;h1 id=&#34;sicql--building-a-model-from-q-v-and-policy-networks&#34;&gt;SICQL — Building a Model From Q, V and Policy Networks&lt;/h1&gt;&#xA;&lt;p&gt;In the previous post we took the MR.Q idea and expanded it into something richer.&lt;/p&gt;&#xA;&lt;p&gt;Instead of asking one question of a shared representation, EBT asked several:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;How good is this state-action pair?      -&amp;gt; Q&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;How good is the state more generally?    -&amp;gt; V&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;What action should be preferred?         -&amp;gt; Policy&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;How much better is Q than V?              -&amp;gt; Advantage&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That already gave us a more expressive system.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 02: EBT — From One Score to Q, V, Policy and Advantage</title>
      <link>http://programmer.ie/post/models-from-first-principles-02/</link>
      <pubDate>Sat, 08 Aug 2026 14:39:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-02/</guid>
      <description>&lt;h1 id=&#34;ebt--from-one-score-to-q-v-policy-and-advantage&#34;&gt;EBT — From One Score to Q, V, Policy and Advantage&lt;/h1&gt;&#xA;&lt;p&gt;In the previous post we built MR.Q: a small model that takes a context embedding and a response embedding, combines them, and predicts one scalar.&lt;/p&gt;&#xA;&lt;p&gt;That architecture is useful because it is brutally simple:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;context embedding&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        +&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;response embedding&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;     encoder&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;   representation z&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    predictor&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        ↓&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;      Q value&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;But one scalar eventually becomes restrictive.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 01: MR.Q — Building a Neural Quality Model From Two Embeddings</title>
      <link>http://programmer.ie/post/models-from-first-principles-01/</link>
      <pubDate>Sat, 08 Aug 2026 14:33:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-01/</guid>
      <description>&lt;h1 id=&#34;mrq--building-a-neural-quality-model-from-two-embeddings&#34;&gt;MR.Q — Building a Neural Quality Model From Two Embeddings&lt;/h1&gt;&#xA;&lt;p&gt;In the previous post, we established the core idea behind this series:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;A complicated model becomes understandable when you recursively decompose it into smaller models, blocks, layers and tensor operations.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;Now we build the first real model.&lt;/p&gt;&#xA;&lt;p&gt;Not a transformer.&lt;/p&gt;&#xA;&lt;p&gt;Not a giant language model.&lt;/p&gt;&#xA;&lt;p&gt;Not an agent.&lt;/p&gt;&#xA;&lt;p&gt;A scorer.&lt;/p&gt;&#xA;&lt;p&gt;We will take two embeddings:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;context embedding&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;response embedding&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;combine them, encode the relationship between them, and predict one scalar:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Models From First Principles 00: The Model Inside the Model</title>
      <link>http://programmer.ie/post/models-from-first-principles-00/</link>
      <pubDate>Sat, 08 Aug 2026 14:27:00 +0100</pubDate>
      <guid>http://programmer.ie/post/models-from-first-principles-00/</guid>
      <description>&lt;h1 id=&#34;the-model-inside-the-model&#34;&gt;The Model Inside the Model&lt;/h1&gt;&#xA;&lt;p&gt;This is the first post in &lt;strong&gt;Models From First Principles&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;The previous &lt;strong&gt;PyTorch: Zero to Hero&lt;/strong&gt; series worked from the bottom up.&lt;/p&gt;&#xA;&lt;p&gt;We started with tensors.&lt;/p&gt;&#xA;&lt;p&gt;Then gradients.&lt;/p&gt;&#xA;&lt;p&gt;Then &lt;code&gt;nn.Module&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;Then data pipelines, convolution, attention, debugging, performance and finally a small GPT-style language model built from scratch.&lt;/p&gt;&#xA;&lt;p&gt;That series answered:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;What are the pieces?&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;This series asks a different question:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;What happens when we start composing those pieces into increasingly sophisticated models?&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch Zero to Hero 10: Build a Small GPT-Style Language Model From Scratch</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-10/</link>
      <pubDate>Sat, 08 Aug 2026 14:03:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-10/</guid>
      <description>&lt;h1 id=&#34;build-a-small-gpt-style-language-model-from-scratch-in-pytorch&#34;&gt;Build a Small GPT-Style Language Model From Scratch in PyTorch&lt;/h1&gt;&#xA;&lt;p&gt;This is the final post in the &lt;strong&gt;PyTorch: Zero to Hero&lt;/strong&gt; series.&lt;/p&gt;&#xA;&lt;p&gt;We have spent the previous posts learning the machinery underneath PyTorch:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;tensors and shapes;&lt;/li&gt;&#xA;&lt;li&gt;autograd;&lt;/li&gt;&#xA;&lt;li&gt;manual neural networks;&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;nn.Module&lt;/code&gt; and parameter registration;&lt;/li&gt;&#xA;&lt;li&gt;DataLoader performance;&lt;/li&gt;&#xA;&lt;li&gt;convolutional networks;&lt;/li&gt;&#xA;&lt;li&gt;attention and masks;&lt;/li&gt;&#xA;&lt;li&gt;training failures;&lt;/li&gt;&#xA;&lt;li&gt;CUDA performance and &lt;code&gt;torch.compile&lt;/code&gt;.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Now we put it together.&lt;/p&gt;&#xA;&lt;p&gt;The goal is not to download a pretrained model.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch Performance Debugging: CUDA OOM, Slow Training, GPU Utilization and torch.compile</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-09/</link>
      <pubDate>Sat, 08 Aug 2026 13:56:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-09/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-09&#34;&gt;PyTorch: Zero to Hero — Step 09&lt;/h2&gt;&#xA;&lt;p&gt;At this point in the series, the model runs.&lt;/p&gt;&#xA;&lt;p&gt;That does not mean it runs well.&lt;/p&gt;&#xA;&lt;p&gt;A training loop can be correct and still waste most of the machine.&lt;/p&gt;&#xA;&lt;p&gt;A model can fit in memory and still spend half its time waiting on synchronization.&lt;/p&gt;&#xA;&lt;p&gt;A &lt;code&gt;torch.compile&lt;/code&gt; call can make code faster, slower, or simply move the bottleneck somewhere else.&lt;/p&gt;&#xA;&lt;p&gt;A CUDA out-of-memory error can be caused by the model, the optimizer, activations, fragmentation, a leaked reference, a larger batch, a longer sequence, or an innocent-looking tensor that was kept alive by Python.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch Model Not Learning? A Systematic Debugging Guide</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-08/</link>
      <pubDate>Sat, 08 Aug 2026 13:51:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-08/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-08&#34;&gt;PyTorch: Zero to Hero — Step 08&lt;/h2&gt;&#xA;&lt;p&gt;Your model runs.&lt;/p&gt;&#xA;&lt;p&gt;The loss is finite.&lt;/p&gt;&#xA;&lt;p&gt;Nothing crashes.&lt;/p&gt;&#xA;&lt;p&gt;And it still does not learn.&lt;/p&gt;&#xA;&lt;p&gt;This is one of the most frustrating states in machine learning because there is no stack trace telling you what is wrong.&lt;/p&gt;&#xA;&lt;p&gt;The program is valid Python.&lt;/p&gt;&#xA;&lt;p&gt;The tensors have legal shapes.&lt;/p&gt;&#xA;&lt;p&gt;The GPU is busy.&lt;/p&gt;&#xA;&lt;p&gt;The optimizer is stepping.&lt;/p&gt;&#xA;&lt;p&gt;And the model is useless.&lt;/p&gt;&#xA;&lt;p&gt;This post is a systematic way to debug that situation.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch Attention Shapes: Q, K, V, Multi-Head Attention Masks and Transformer Dimension Errors</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-07/</link>
      <pubDate>Sat, 08 Aug 2026 13:30:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-07/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-07&#34;&gt;PyTorch: Zero to Hero — Step 07&lt;/h2&gt;&#xA;&lt;p&gt;Attention code is where tensor-shape mistakes stop being annoying and start becoming architectural.&lt;/p&gt;&#xA;&lt;p&gt;A CNN usually makes its dimensional assumptions fairly obvious. Attention does not.&lt;/p&gt;&#xA;&lt;p&gt;A tensor that starts as:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;(batch, sequence, embedding)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;is projected into Q, K and V, split into heads, transposed, multiplied, masked, normalized, multiplied again, transposed again, concatenated and projected back to the embedding dimension.&lt;/p&gt;&#xA;&lt;p&gt;A single bad &lt;code&gt;view&lt;/code&gt;, &lt;code&gt;transpose&lt;/code&gt;, mask shape or head calculation can produce anything from an immediate runtime error to a model that trains while attending to the wrong tokens.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch CNN Shape Errors: Conv2d Output Sizes, Channels, Flatten Bugs and How to Debug Them</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-06/</link>
      <pubDate>Sat, 08 Aug 2026 13:26:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-06/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-06&#34;&gt;PyTorch: Zero to Hero — Step 06&lt;/h2&gt;&#xA;&lt;p&gt;CNN code is usually easy to write.&lt;/p&gt;&#xA;&lt;p&gt;CNN shape bugs are usually easy to create.&lt;/p&gt;&#xA;&lt;p&gt;A typical failure looks like this:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;RuntimeError: Given groups=1, weight of size [32, 3, 3, 3],&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;expected input[64, 224, 224, 3] to have 3 channels,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;but got 224 channels instead&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Or this:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;RuntimeError: mat1 and mat2 shapes cannot be multiplied&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Or worse: the model runs, but the dimensions are wrong in a way that silently damages the architecture.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch DataLoader Performance: num_workers, pin_memory, Prefetching and Why Your GPU Is Waiting</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-05/</link>
      <pubDate>Sat, 08 Aug 2026 13:21:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-05/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-05&#34;&gt;PyTorch: Zero to Hero — Step 05&lt;/h2&gt;&#xA;&lt;p&gt;A fast model with a slow input pipeline is still a slow training system.&lt;/p&gt;&#xA;&lt;p&gt;One of the most common PyTorch performance failures looks like this:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;GPU utilization: 20% → 95% → 10% → 90% → 15%&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The model is not necessarily slow.&lt;/p&gt;&#xA;&lt;p&gt;The GPU may simply be waiting for the next batch.&lt;/p&gt;&#xA;&lt;p&gt;This article is about finding out &lt;strong&gt;where the wait is happening&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch nn.Module Explained: Missing Parameters, state_dict, Buffers and Registration Bugs</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-04/</link>
      <pubDate>Sat, 08 Aug 2026 13:09:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-04/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-04&#34;&gt;PyTorch: Zero to Hero — Step 04&lt;/h2&gt;&#xA;&lt;p&gt;In the previous post we built a neural network using raw tensors and autograd.&lt;/p&gt;&#xA;&lt;p&gt;Now we are going to add the abstraction PyTorch expects almost every real model to use:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;class&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;Model&lt;/span&gt;(torch&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;nn&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Module):&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#f92672&#34;&gt;...&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;But this is not going to be a tour of &lt;code&gt;nn.Module&lt;/code&gt; methods.&lt;/p&gt;&#xA;&lt;p&gt;The useful question for programmers is:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;What exactly does &lt;code&gt;nn.Module&lt;/code&gt; register, track, move, save and expose — and how do those mechanisms break?&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Build a Neural Network From Scratch in PyTorch Without nn.Module</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-03/</link>
      <pubDate>Sat, 08 Aug 2026 12:59:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-03/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-03&#34;&gt;PyTorch: Zero to Hero — Step 03&lt;/h2&gt;&#xA;&lt;p&gt;Most PyTorch tutorials begin with something like this:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;import&lt;/span&gt; torch.nn &lt;span style=&#34;color:#66d9ef&#34;&gt;as&lt;/span&gt; nn&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;model &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; nn&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Sequential(&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    nn&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Linear(&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;16&lt;/span&gt;),&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    nn&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;ReLU(),&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    nn&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;Linear(&lt;span style=&#34;color:#ae81ff&#34;&gt;16&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;),&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;That is useful code.&lt;/p&gt;&#xA;&lt;p&gt;It is also hiding almost everything interesting.&lt;/p&gt;&#xA;&lt;p&gt;In this post we are going to build the same kind of neural network using ordinary PyTorch tensors.&lt;/p&gt;&#xA;&lt;p&gt;No &lt;code&gt;nn.Module&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;No &lt;code&gt;nn.Linear&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;No &lt;code&gt;torch.optim.Adam&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;No &lt;code&gt;optimizer.step()&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;p&gt;We will manually create the parameters, write the forward pass, calculate the loss, call autograd, update the weights, zero the gradients, batch the data, evaluate the model and then compare the result with the idiomatic PyTorch version.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch Autograd Debugging: requires_grad, detach, backward() and NaN Gradients</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-02/</link>
      <pubDate>Sat, 08 Aug 2026 12:55:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-02/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-02&#34;&gt;PyTorch: Zero to Hero — Step 02&lt;/h2&gt;&#xA;&lt;p&gt;In the previous post we treated tensor shapes as a debugging problem rather than a mathematical vocabulary exercise.&lt;/p&gt;&#xA;&lt;p&gt;We are going to do the same thing with autograd.&lt;/p&gt;&#xA;&lt;p&gt;If you use PyTorch for any serious amount of time, you eventually see errors like:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;RuntimeError: element 0 of tensors does not require grad and does not have a grad_fn&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;or:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;RuntimeError: Trying to backward through the graph a second time...&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;or worse:&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch Tensor Shapes: Broadcasting, Reshape, View, Permute and the Errors That Waste Your Time</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-01/</link>
      <pubDate>Sat, 08 Aug 2026 12:45:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-01/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero--step-01&#34;&gt;PyTorch: Zero to Hero — Step 01&lt;/h2&gt;&#xA;&lt;p&gt;Most PyTorch bugs are not really &amp;ldquo;AI bugs&amp;rdquo;.&lt;/p&gt;&#xA;&lt;p&gt;They are shape bugs.&lt;/p&gt;&#xA;&lt;p&gt;You expected:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;[batch, features]&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;but actually had:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;[batch, sequence, features]&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;You expected two tensors to line up.&lt;/p&gt;&#xA;&lt;p&gt;They broadcast instead.&lt;/p&gt;&#xA;&lt;p&gt;You called &lt;code&gt;view()&lt;/code&gt; after &lt;code&gt;permute()&lt;/code&gt; and got a contiguity error.&lt;/p&gt;&#xA;&lt;p&gt;You removed a dimension with &lt;code&gt;squeeze()&lt;/code&gt; and accidentally removed the batch dimension too.&lt;/p&gt;&#xA;&lt;p&gt;Or you reached the familiar message:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;RuntimeError: The size of tensor a (...) must match the size of tensor b (...)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This article is about becoming dangerous enough with tensors that these errors stop being mysterious.&lt;/p&gt;</description>
    </item>
    <item>
      <title>PyTorch Zero to Hero 00: What Are We Actually Doing?</title>
      <link>http://programmer.ie/post/pytorch-zero-to-hero-00/</link>
      <pubDate>Sat, 08 Aug 2026 12:40:00 +0100</pubDate>
      <guid>http://programmer.ie/post/pytorch-zero-to-hero-00/</guid>
      <description>&lt;h2 id=&#34;pytorch-zero-to-hero&#34;&gt;PyTorch: Zero to Hero&lt;/h2&gt;&#xA;&lt;p&gt;This is &lt;strong&gt;Step 0&lt;/strong&gt; of a practical PyTorch series that starts with tensors and ends with building a small language model from scratch.&lt;/p&gt;&#xA;&lt;p&gt;The goal is not to learn a collection of PyTorch commands.&lt;/p&gt;&#xA;&lt;p&gt;The goal is to understand what the framework is doing well enough that the commands stop looking like magic.&lt;/p&gt;&#xA;&lt;p&gt;By the end of the series we will have moved through tensors, gradients, neural networks, data pipelines, convolutional networks, attention, transformers, training, performance, and finally a small language model.&lt;/p&gt;</description>
    </item>
    <item>
      <title>ZeroModel: Evidence Before Ambition</title>
      <link>http://programmer.ie/post/evidence/</link>
      <pubDate>Sat, 08 Aug 2026 01:03:04 +0100</pubDate>
      <guid>http://programmer.ie/post/evidence/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;ZeroModel is an attempt to compile useful parts of intelligence into identified, portable, inspectable decision artifacts — and to preserve enough evidence around those artifacts that we can reproduce, challenge and replay what they do.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;That sentence now covers considerably more ground than I expected when I started.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;start-with-the-strangest-result&#34;&gt;Start with the strangest result&lt;/h2&gt;&#xA;&lt;p&gt;One ZeroModel policy contains 112 states.&lt;/p&gt;&#xA;&lt;p&gt;It can be executed in Python.&lt;/p&gt;&#xA;&lt;p&gt;It can also be exported into a completely dependency-free Lua module.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Advanced Agents From First Principles 07: Do Your Agents Agree Too Easily? Use Adversarial Review and Multi-Agent Debate Without Confusing Debate With Truth</title>
      <link>http://programmer.ie/post/advanced-agents-from-first-principles-07/</link>
      <pubDate>Sat, 08 Aug 2026 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/advanced-agents-from-first-principles-07/</guid>
      <description>&lt;p&gt;A multi-agent system can look sophisticated while every agent quietly repeats the same mistake.&lt;/p&gt;&#xA;&lt;p&gt;That is one of the most dangerous failure modes in advanced agent architectures.&lt;/p&gt;&#xA;&lt;p&gt;You ask one model to solve the problem.&lt;/p&gt;&#xA;&lt;p&gt;Then you ask a second model to review it.&lt;/p&gt;&#xA;&lt;p&gt;Then a third model judges the disagreement.&lt;/p&gt;&#xA;&lt;p&gt;Three calls later, the system sounds more confident than before.&lt;/p&gt;&#xA;&lt;p&gt;But if all three agents share the same blind spot, the extra machinery has not created independent evidence.&lt;/p&gt;</description>
    </item>
    <item>
      <title>RELATE: Searching Embeddings by Relation, Not Just Similarity</title>
      <link>http://programmer.ie/post/relate/</link>
      <pubDate>Wed, 05 Aug 2026 23:24:45 +0100</pubDate>
      <guid>http://programmer.ie/post/relate/</guid>
      <description>&lt;p&gt;Embeddings are everywhere in modern AI.&lt;/p&gt;&#xA;&lt;p&gt;They power semantic search, retrieval-augmented generation, recommendations, clustering, duplicate detection, code search, memory systems, and many of the mechanisms through which an AI system decides what information is relevant.&lt;/p&gt;&#xA;&lt;p&gt;Yet most systems interrogate embeddings in essentially the same way:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Take two vectors and calculate cosine similarity.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;That is useful. But it also makes a strong assumption.&lt;/p&gt;&#xA;&lt;p&gt;It assumes that the information we care about is expressed directly through the default geometry of the embedding space.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Singularity Is Here</title>
      <link>http://programmer.ie/post/singularity/</link>
      <pubDate>Wed, 29 Jul 2026 11:14:54 +0100</pubDate>
      <guid>http://programmer.ie/post/singularity/</guid>
      <description>&lt;p&gt;For decades, the technological singularity has been presented as a future event. At some point, an artificial intelligence would become as intelligent as a human being, improve itself, become superintelligent and accelerate beyond our ability to understand or control it. Humanity would stand on one side of that moment and something fundamentally different would exist on the other.&lt;/p&gt;&#xA;&lt;p&gt;It is a dramatic story, and it may be the wrong one.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Signs, Not Directions: Compiling AI Policy into Visual Artifacts</title>
      <link>http://programmer.ie/post/zero/</link>
      <pubDate>Thu, 16 Jul 2026 18:43:53 +0100</pubDate>
      <guid>http://programmer.ie/post/zero/</guid>
      <description>&lt;p&gt;&lt;em&gt;What happens when a system stops asking an AI for the same directions repeatedly, and starts placing signs where decisions need to be made?&lt;/em&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;zeromodel-in-one-image&#34;&gt;ZeroModel in One Image&lt;/h2&gt;&#xA;&lt;p&gt;Most AI systems repeatedly invoke a policy: observe the current state, ask a model what to do, execute the answer, and ask again at the next decision.&lt;/p&gt;&#xA;&lt;p&gt;ZeroModel explores a different architecture. When a policy is bounded and stable, it can be compiled into a deterministic artifact that the runtime addresses directly.&lt;/p&gt;</description>
    </item>
    <item>
      <title>What Does a Preference Know About the Future?</title>
      <link>http://programmer.ie/post/future/</link>
      <pubDate>Fri, 10 Jul 2026 11:32:58 +0100</pubDate>
      <guid>http://programmer.ie/post/future/</guid>
      <description>&lt;h2 id=&#34;we-trained-a-model-on-editorial-choices-to-see-whether-it-learned-what-happened-next&#34;&gt;We Trained a Model on Editorial Choices to See Whether It Learned What Happened Next&lt;/h2&gt;&#xA;&lt;p&gt;Most preference-learning systems use a choice to change the future.&lt;/p&gt;&#xA;&lt;p&gt;A model produces two responses. A human selects one. The chosen response becomes positive evidence, the rejected response becomes negative evidence, and training makes outputs resembling the chosen response more likely.&lt;/p&gt;&#xA;&lt;p&gt;The preference acts as an instruction:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Produce more things like this.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;I wanted to know whether the same choice could also function as evidence.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Preference Was Only the Beginning</title>
      <link>http://programmer.ie/post/preferences/</link>
      <pubDate>Tue, 07 Jul 2026 00:00:00 +0100</pubDate>
      <guid>http://programmer.ie/post/preferences/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;A preference is not only a label on what just happened. When the decision belongs to a continuing trajectory, it can also be evidence about what happens next.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;abstract&#34;&gt;Abstract&lt;/h2&gt;&#xA;&lt;p&gt;Most preference-learning systems stop at the choice.&lt;/p&gt;&#xA;&lt;p&gt;A model produces two responses. A human selects one. The chosen response becomes positive evidence, the rejected response becomes negative evidence, and the training system moves on.&lt;/p&gt;&#xA;&lt;p&gt;The work itself usually continues.&lt;/p&gt;&#xA;&lt;p&gt;The selected answer may later be revised, partially retained, contradicted or abandoned. The rejected alternative may reveal a constraint that remains active long after the immediate decision. The preference is therefore not necessarily the outcome. It may be an event inside a longer trajectory.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The State Optimized the Dashboard and Lost the Citizen</title>
      <link>http://programmer.ie/post/serf/</link>
      <pubDate>Wed, 24 Jun 2026 20:19:56 +0100</pubDate>
      <guid>http://programmer.ie/post/serf/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;An AI-assisted model of how GDP optics, housing pressure, debt rollover, and fiscal constraint can hide citizen insolvency.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;1-a-country-is-its-citizens&#34;&gt;1. A Country Is Its Citizens&lt;/h2&gt;&#xA;&lt;p&gt;A country is not its GDP, its bond market, its housing index, or its stock-market capitalization. A country is its citizens.&lt;/p&gt;&#xA;&lt;p&gt;That sounds obvious enough to be useless, but most modern economic dashboards quietly forget it. They measure the state, the asset market, the tax base, the debt stock, the growth rate, the investment flow, the headline employment number, the budget balance, the bond spread, and the index level. They do not directly measure whether citizens can stand on their own.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Moment: Intelligence beyond context</title>
      <link>http://programmer.ie/post/moment/</link>
      <pubDate>Fri, 19 Jun 2026 14:49:56 +0100</pubDate>
      <guid>http://programmer.ie/post/moment/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;Most AI systems answer and move on. The next step is different: preserve the reasoning state, replay it, measure whether it improves, and keep only what survives verification.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Most AI workflows still treat intelligence as a single pass.&lt;/p&gt;&#xA;&lt;p&gt;You ask a question.&#xA;The model answers.&#xA;Maybe you ask it to try again.&#xA;Maybe you add more context.&#xA;Maybe you save something to memory.&lt;/p&gt;&#xA;&lt;p&gt;But the basic shape remains the same:&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Asset‑Price State: How the U.S. Fiscal Machine Now Depends on Rising Markets</title>
      <link>http://programmer.ie/post/asset/</link>
      <pubDate>Wed, 17 Jun 2026 17:18:52 +0100</pubDate>
      <guid>http://programmer.ie/post/asset/</guid>
      <description>&lt;h2 id=&#34;what-this-post-argues&#34;&gt;What this post argues&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;The U.S. does not merely like a high stock market. It increasingly needs one.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;The stock market has become an amplifier inside the largest federal revenue pipe: individual income tax. When asset prices rise, capital gains, stock compensation, options, bonuses, business equity, and other asset-sensitive income strengthen federal receipts. When the market falls hard, that same amplifier runs in reverse.&lt;/p&gt;&#xA;&lt;p&gt;This matters because the real debt problem is not debt alone. It is interest cost relative to federal revenue. If interest grows faster than normal revenue, the system becomes more dependent on asset inflation, AI valuations, national champions, and foreign capital to keep the fiscal machine stable.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The AI Application Gap: Why Capability Is Not Deployment</title>
      <link>http://programmer.ie/post/real/</link>
      <pubDate>Sat, 06 Jun 2026 14:40:59 +0000</pubDate>
      <guid>http://programmer.ie/post/real/</guid>
      <description>&lt;h2 id=&#34;capability-is-real-application-is-the-bet&#34;&gt;Capability is real. Application is the bet&lt;/h2&gt;&#xA;&lt;p&gt;The AI economy is no longer theoretical.&lt;/p&gt;&#xA;&lt;p&gt;AI is now showing up in financial statements, capex plans, and reported investment gains.&lt;/p&gt;&#xA;&lt;p&gt;The largest technology companies in the world are not merely talking about AI, demoing AI, or adding AI features to their products. They are booking AI-related investment gains, redirecting capital expenditure toward AI infrastructure, reorganizing product interfaces around AI, and asking investors to value them as AI platform companies.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Warranted Search: When AI Must Prove Before It Looks</title>
      <link>http://programmer.ie/post/grep/</link>
      <pubDate>Tue, 02 Jun 2026 18:54:26 +0100</pubDate>
      <guid>http://programmer.ie/post/grep/</guid>
      <description>&lt;h2 id=&#34;tldr&#34;&gt;TL;DR&lt;/h2&gt;&#xA;&lt;p&gt;Modern AI systems often retrieve nearby text and generate confident answers, but that is not the same as proof. A citation can be real, the answer can be correct, and the evidence can still fail to support the claim.&lt;/p&gt;&#xA;&lt;p&gt;This post argues for &lt;strong&gt;warranted search&lt;/strong&gt;: a scoped, claim-driven form of intelligent grep. Instead of asking an AI to rummage through a corpus, we give it a specific claim, a bounded search warrant, and a limited set of safe operations.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Thinking in Primitives: Why AI Reasoning Should Learn to Point</title>
      <link>http://programmer.ie/post/primitive/</link>
      <pubDate>Sun, 24 May 2026 13:16:50 +0100</pubDate>
      <guid>http://programmer.ie/post/primitive/</guid>
      <description>&lt;p&gt;&lt;strong&gt;From visual primitives to context-filtered reasoning, grounded verification, and AI movie repair&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;h2 id=&#34;tldr&#34;&gt;TL;DR&lt;/h2&gt;&#xA;&lt;p&gt;This post argues that AI reasoning should not operate over everything it can see, read, or detect. It should operate over the &lt;strong&gt;right primitives for the current task&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;The paper &lt;em&gt;Thinking with Visual Primitives&lt;/em&gt; shows that multimodal models reason better when they can point to visual entities using boxes and points. That solves a &lt;strong&gt;Reference Gap&lt;/strong&gt;: language is often too vague to anchor reasoning to the right part of an image.&lt;/p&gt;</description>
    </item>
    <item>
      <title>AI and the End of Easy Growth</title>
      <link>http://programmer.ie/post/growth/</link>
      <pubDate>Tue, 19 May 2026 09:52:38 +0100</pubDate>
      <guid>http://programmer.ie/post/growth/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;Constraint, Continuity, and Human Agency&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;1-introduction-the-strange-feeling-around-ai&#34;&gt;1. Introduction: The Strange Feeling Around AI&lt;/h2&gt;&#xA;&lt;p&gt;Artificial Intelligence is clearly real. The infrastructure buildout is enormous, adoption is accelerating, and AI systems are already reshaping software, research, administration, and knowledge work. Yet for many people, daily life feels strangely unchanged. Housing remains expensive, wages remain under pressure, debt continues to rise, and institutions across the West increasingly appear constrained rather than confident.&lt;/p&gt;&#xA;&lt;p&gt;This post explores the possibility that AI is currently being deployed less as a technology of broad civilizational expansion and more as a technology of continuity management, a way for highly complex systems under demographic, economic, and energetic pressure to optimize themselves, compress costs, and maintain stability in an era where traditional growth models are becoming harder to sustain.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Delta Memory: Cargo-Culting Human Memory with Search</title>
      <link>http://programmer.ie/post/delta/</link>
      <pubDate>Mon, 18 May 2026 11:14:15 +0100</pubDate>
      <guid>http://programmer.ie/post/delta/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;AI systems today have no idea why their own memory changes, that’s the problem we are trying to solve in this post.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Most AI memory systems start from a practical place: retrieval. Retrieval is useful, scalable, and often the right tool for the job. But if we want systems that interact with humans in more human‑like ways, we need a different analogy, not storage, but &lt;strong&gt;thinking&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;Humans don’t store perfect records. We don’t retrieve exact text or replay video files. What we call “memory” is a shifting landscape of associations, impressions, weights, and patterns. When you recall something, you’re not pulling a file from disk, you’re running a &lt;strong&gt;search&lt;/strong&gt; across your internal world, shaped by everything you’ve lived through.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Codex Manager: Building a Prompt-State Runtime for Hackathon-Grade Code Optimization</title>
      <link>http://programmer.ie/post/codex/</link>
      <pubDate>Sat, 16 May 2026 20:15:59 +0100</pubDate>
      <guid>http://programmer.ie/post/codex/</guid>
      <description>&lt;h2 id=&#34;tldr&#34;&gt;TL;DR&lt;/h2&gt;&#xA;&lt;p&gt;Codex Manager uses AI to generate code as an artifact, then tests that artifact, diagnoses what happened, and repairs the prompt state that produced it. The code is not the thing being optimized directly. The prompt state is.&lt;/p&gt;&#xA;&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://huggingface.co/humanitys-last-hackathon?utm_source=chatgpt.com&#34;&gt;Humanity’s Last Hackathon&lt;/a&gt; framed the challenge as a test of &lt;strong&gt;context, not code&lt;/strong&gt;: the task was hard enough that the real question was not whether someone could hand-write one clever kernel, but whether they could build a system that used AI effectively under changing constraints.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cognitive Graphs: A General Architecture for Replayable Reasoning</title>
      <link>http://programmer.ie/post/graph/</link>
      <pubDate>Mon, 11 May 2026 10:50:29 +0100</pubDate>
      <guid>http://programmer.ie/post/graph/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;A Cognitive Graph is an enhanced chat log one that doesn’t just record what was said, but structurally preserves how thoughts, decisions, alternatives, and artifacts evolve over time, making the whole history replayable and auditable.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;TL;DR:&lt;/strong&gt; A Cognitive Graph turns AI-assisted work from lossy chat logs into event-sourced, replayable reasoning state. Instead of preserving only the final output, it preserves the decisions, alternatives, rationales, mutations, hashes, and snapshots that explain how the output came to exist.&lt;/p&gt;</description>
    </item>
    <item>
      <title>AI as an Amplifier, Not a Utility</title>
      <link>http://programmer.ie/post/electricity/</link>
      <pubDate>Mon, 11 May 2026 10:43:01 +0100</pubDate>
      <guid>http://programmer.ie/post/electricity/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;AI turns language into an interface for implementation.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;1-the-builders-world&#34;&gt;&lt;strong&gt;1. The Builder’s World&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;There is a version of AI people talk about.&lt;/p&gt;&#xA;&lt;p&gt;And then there is the version you discover when you actually use it consistently.&lt;/p&gt;&#xA;&lt;p&gt;They are not the same thing.&lt;/p&gt;&#xA;&lt;p&gt;AI’s real value is not doing old work faster.&lt;/p&gt;&#xA;&lt;p&gt;It is this:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;AI collapses the distance between an idea and a working system.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;That is the part I think people are still missing.&lt;/p&gt;</description>
    </item>
    <item>
      <title>🎂 CAKE: Cognitive Amplification Knowledge Engine</title>
      <link>http://programmer.ie/post/cake/</link>
      <pubDate>Mon, 27 Apr 2026 21:17:19 +0100</pubDate>
      <guid>http://programmer.ie/post/cake/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;We’re not teaching machines to think. We’re teaching ourselves to build thinking systems.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-from-ai-assistants-to-controlled-cognitive-amplification&#34;&gt;🎨 From AI Assistants to Controlled Cognitive Amplification&lt;/h2&gt;&#xA;&lt;p&gt;Most people use AI to write faster.&lt;br&gt;&#xA;But the real opportunity isn’t speed.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;It’s amplification.&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;A useful analogy is physical labor. A person can move earth with their hands, but only at a limited scale. A bulldozer does not replace the human it allows them to operate at a completely different level of throughput.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Answering Machine Effect</title>
      <link>http://programmer.ie/post/answer/</link>
      <pubDate>Mon, 27 Apr 2026 09:38:25 +0100</pubDate>
      <guid>http://programmer.ie/post/answer/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;Why you already know what you’re about to read isn’t real and what to do about it.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;p&gt;Imagine a small red badge on every article, every design, every conversation: &lt;strong&gt;AI-Generated Content&lt;/strong&gt;.&lt;br&gt;&#xA;Before you read a single word, you feel it: a tiny click of disengagement, an instinctive pullback. You wouldn’t press “Accept cookies” without thinking, but you’d skip the AI label without even deciding.&lt;/p&gt;&#xA;&#xA;  &lt;img src=&#34;http://programmer.ie/img/ai_generated.png&#34; alt=&#34;An image signifying the content was ai generated&#34; style=&#34;max-width: 160px; height:auto;&#34;&gt;&#xA;&lt;p&gt;Most people already know what they’d do. Close the tab. That reaction isn&amp;rsquo;t new. Let me take you back to the first phones.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Beyond Hallucination Energy: A Three-Dimensional Framework for Reliable AI Outputs</title>
      <link>http://programmer.ie/post/trendslop/</link>
      <pubDate>Wed, 22 Apr 2026 10:35:46 +0100</pubDate>
      <guid>http://programmer.ie/post/trendslop/</guid>
      <description>&lt;h2 id=&#34;-1--tldr&#34;&gt;🧩 1.  TLDR&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;AI doesn&amp;rsquo;t just hallucinate.&#xA;Sometimes it gives answers that are fluent, safe… and completely useless.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;Most discussions about AI failure focus on hallucination:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;making things up&lt;/li&gt;&#xA;&lt;li&gt;getting facts wrong&lt;/li&gt;&#xA;&lt;li&gt;fabricating sources&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;That&amp;rsquo;s real. It matters.&lt;/p&gt;&#xA;&lt;p&gt;But it&amp;rsquo;s not the most dangerous failure mode in production systems.&lt;/p&gt;&#xA;&lt;p&gt;There is a quieter one.&lt;/p&gt;&#xA;&lt;p&gt;A more subtle one.&lt;/p&gt;&#xA;&lt;p&gt;And in practice a more &lt;em&gt;pervasive&lt;/em&gt; one.&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;AI systems often fail not by being wrong,&#xA;but by failing to think at all.&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Living Against Parkinson’s: A Practical Guide to Fighting Back</title>
      <link>http://programmer.ie/post/parkinsons/</link>
      <pubDate>Tue, 21 Apr 2026 11:52:11 +0100</pubDate>
      <guid>http://programmer.ie/post/parkinsons/</guid>
      <description>&lt;h2 id=&#34;-section-1-introduction&#34;&gt;🧩 SECTION 1: Introduction&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;How would you actually live if you were trying to fight this properly?&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;Not cure it.&#xA;Not pretend it&amp;rsquo;s easy.&#xA;But fight it intelligently, consistently, and over time.&lt;/p&gt;&#xA;&lt;p&gt;That&amp;rsquo;s what this is.&lt;/p&gt;&#xA;&lt;p&gt;Parkinson&amp;rsquo;s isn&amp;rsquo;t the largest disease in the world but it is one of the most demanding long-term neurological conditions a person can face. It reshapes movement, energy, thinking, and daily life and it does so unevenly, changing from day to day.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Silent Reset: Currency Devaluation and the Extension of the Debt Cycle</title>
      <link>http://programmer.ie/post/reset/</link>
      <pubDate>Fri, 17 Apr 2026 18:44:49 +0100</pubDate>
      <guid>http://programmer.ie/post/reset/</guid>
      <description>&lt;h2 id=&#34;abstract&#34;&gt;&lt;strong&gt;Abstract&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;Recent analysis of U.S. fiscal dynamics suggests a structural constraint emerging around the end of this decade, driven by rising interest burdens relative to government revenue.&lt;/p&gt;&#xA;&lt;p&gt;This paper explores the possibility that a system-level reset may &lt;strong&gt;already be underway&lt;/strong&gt;, not as a discrete event, but as a gradual process of &lt;strong&gt;currency adjustment, inflation, and asset repricing&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;A modeled &lt;strong&gt;20–40% devaluation of the U.S. dollar (~30% midpoint)&lt;/strong&gt; materially alters debt sustainability trajectories, extending the fiscal runway by an estimated &lt;strong&gt;10–20 years&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Eye That Sees</title>
      <link>http://programmer.ie/post/eye/</link>
      <pubDate>Fri, 17 Apr 2026 14:27:45 +0100</pubDate>
      <guid>http://programmer.ie/post/eye/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;em&gt;Using AI to Decode Symbols Without Assuming Meaning&lt;/em&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;executive-summary-from-symbol-to-system&#34;&gt;&lt;strong&gt;Executive Summary: From Symbol to System&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;em&gt;We set out to understand a single image. We ended up building a system that can understand structure itself.&lt;/em&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;We started with a constraint:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;Assume we do not understand the symbol.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;No prior knowledge. No accepted interpretations.&lt;/p&gt;&#xA;&lt;p&gt;Just an image: an eye, a triangle, rays, an unfinished pyramid.&lt;/p&gt;&#xA;&lt;p&gt;From that starting point, we:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Canada: When Interest Meets Reliable Revenue</title>
      <link>http://programmer.ie/post/canada/</link>
      <pubDate>Wed, 15 Apr 2026 12:55:18 +0100</pubDate>
      <guid>http://programmer.ie/post/canada/</guid>
      <description>&lt;h2 id=&#34;executive-summary&#34;&gt;&lt;strong&gt;Executive Summary&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;Canada’s fiscal position looks stable on paper. Headline interest costs consume only ~10.6% of federal revenue. But this ratio masks a structural reality: &lt;strong&gt;the engine that drove revenue growth has stalled, and the cost of past debt is rising faster than the system can generate new fiscal space.&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;For decades, population expansion concealed weak per-capita productivity. In 2025, that demographic engine stopped. At the same time, Canada does not fully capture or retain the economic value it produces, due to commodity pricing discounts, single-customer trade concentration, and high-skill outflows. When these factors are applied to the revenue base, the effective denominator shrinks.&lt;/p&gt;</description>
    </item>
    <item>
      <title>From Fuel Protests to Fiscal Risk: What’s Really Happening in Ireland</title>
      <link>http://programmer.ie/post/irish_debt/</link>
      <pubDate>Tue, 14 Apr 2026 17:53:37 +0100</pubDate>
      <guid>http://programmer.ie/post/irish_debt/</guid>
      <description>&lt;h2 id=&#34;executive-summary&#34;&gt;Executive Summary&lt;/h2&gt;&#xA;&lt;p&gt;This post applies a simple, testable framework to Ireland&amp;rsquo;s fiscal system:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;Fiscal constraint emerges when the cost of debt rises relative to the revenue supporting it.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;In large, stable systems like the United States, this dynamic unfolds gradually. Ireland presents a different case.&lt;/p&gt;&#xA;&lt;p&gt;While headline metrics suggest strength, three structural factors create a distinct risk profile:&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&lt;strong&gt;Revenue composition&lt;/strong&gt;: A significant portion derives from multinational activity and is not fully under domestic control.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Measurement distortion&lt;/strong&gt;: The effective economic base (GNI*) is ~43% smaller than GDP implies.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Debt repricing&lt;/strong&gt;: Existing debt is being refinanced at materially higher interest rates.&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;These factors introduce a critical refinement to the model:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Real Problems. AI Solutions.</title>
      <link>http://programmer.ie/post/debt/</link>
      <pubDate>Mon, 13 Apr 2026 08:53:47 +0100</pubDate>
      <guid>http://programmer.ie/post/debt/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;How We Used AI to Analyze When U.S. Debt Becomes a Constraint&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;executive-summary&#34;&gt;&lt;strong&gt;Executive Summary&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;We demonstrate a &lt;strong&gt;human + AI research process&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;AI was used to:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;refine the question&lt;/li&gt;&#xA;&lt;li&gt;identify the correct metric&lt;/li&gt;&#xA;&lt;li&gt;expose assumptions&lt;/li&gt;&#xA;&lt;li&gt;and test the model through adversarial critique&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;The goal was to transform a vague macro concern into a &lt;strong&gt;quantifiable, testable system model&lt;/strong&gt;.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;the-question&#34;&gt;&lt;strong&gt;The Question&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;We began with a simple but vague concern:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;“Is U.S. debt becoming a problem?”&lt;/p&gt;</description>
    </item>
    <item>
      <title>A Memory Gate for AI: Policy-Bounded Acceptance in the Executable Cognitive Kernel</title>
      <link>http://programmer.ie/post/verify/</link>
      <pubDate>Tue, 17 Mar 2026 09:58:14 +0000</pubDate>
      <guid>http://programmer.ie/post/verify/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Dynamic AI systems face a hidden failure mode: they can learn from their own mistakes.&#xA;If every output is allowed into memory, stochastic errors do not stay local they accumulate.&lt;/p&gt;&#xA;&lt;p&gt;In earlier posts, I argued that AI systems should not be trusted to enforce their own correctness.&lt;/p&gt;&#xA;&lt;p&gt;Modern models are stochastic. They produce correct outputs, partially correct outputs, and completely incorrect outputs, but they do not reliably distinguish between them. That means a system that stores everything it generates will eventually learn from its own mistakes.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Intelligence Through Execution: The Executable Cognitive Kernel</title>
      <link>http://programmer.ie/post/eck/</link>
      <pubDate>Tue, 10 Mar 2026 21:58:14 +0000</pubDate>
      <guid>http://programmer.ie/post/eck/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🧭 Summary&lt;/h2&gt;&#xA;&lt;p&gt;Most modern AI systems treat intelligence as something stored inside a model.&lt;/p&gt;&#xA;&lt;p&gt;A neural network is trained on massive datasets, its weights are adjusted, and those weights become the system’s knowledge. When the model produces an output, we interpret that output as the result of the intelligence encoded inside those parameters.&lt;/p&gt;&#xA;&lt;p&gt;But this perspective has a limitation.&lt;/p&gt;&#xA;&lt;p&gt;Once training is complete, the model is largely static. It does not improve through its own actions, and it does not adapt based on the outcome of its behavior unless we retrain it.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The “Negative Contrast Trap”: Why AI Writing Overuses “Not X, But Y”</title>
      <link>http://programmer.ie/post/not/</link>
      <pubDate>Tue, 10 Mar 2026 12:35:56 +0000</pubDate>
      <guid>http://programmer.ie/post/not/</guid>
      <description>&lt;p&gt;Read enough AI prose and a rhythm starts to appear. Not fear. Not relief. Not strategy.Once you see it, you cannot unsee it.&lt;/p&gt;&#xA;&lt;h2 id=&#34;-abstract&#34;&gt;🧠 Abstract&lt;/h2&gt;&#xA;&lt;p&gt;Large language models frequently produce rhetorical constructions such as &lt;em&gt;“not fear, but relief”&lt;/em&gt; or &lt;em&gt;“not intelligence, but memory.”&lt;/em&gt; While these patterns exist in human writing, AI systems tend to overproduce them, creating repetitive and unnatural prose. This article identifies the phenomenon as the &lt;strong&gt;Negative Contrast Trap&lt;/strong&gt;, explains why it emerges from statistical language modeling, and proposes practical methods to detect and mitigate it in AI-assisted writing systems.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Applied Policy: How to incorporate Policy and Hallucination in self-improving system</title>
      <link>http://programmer.ie/post/policy_applied/</link>
      <pubDate>Wed, 18 Feb 2026 08:00:16 +0000</pubDate>
      <guid>http://programmer.ie/post/policy_applied/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;Building a Self-Improving AI: Cooperative ERL and Embed-RL in a Trace-Native Architecture&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;1-the-problem&#34;&gt;1. The Problem&lt;/h2&gt;&#xA;&lt;p&gt;Most self-improving AI systems fail for one of three reasons:&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;First, scalar reward collapse.&lt;/strong&gt; Traditional reinforcement learning compresses multi-dimensional quality into a single scalar. This creates catastrophic interference: improving one axis (e.g., coherence) can degrade another (e.g., hallucination safety). The system optimizes for the blended metric, not the underlying objectives.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Second, representation drift.&lt;/strong&gt; Embedding-based optimization without behavioral feedback creates geometric collapse. The embedding space becomes increasingly narrow, losing discriminative power. Similar queries map to identical regions. Diversity vanishes. The system becomes brittle.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Hallucination Energy: A Geometric Foundation for Policy-Bounded AI</title>
      <link>http://programmer.ie/post/energy/</link>
      <pubDate>Thu, 05 Feb 2026 13:29:55 +0000</pubDate>
      <guid>http://programmer.ie/post/energy/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🚀 Summary&lt;/h2&gt;&#xA;&lt;p&gt;This post presents the current research draft and implementation of a geometric framework for bounding stochastic language models through deterministic policy enforcement.&lt;/p&gt;&#xA;&lt;p&gt;The central contribution is a scalar metric termed &lt;strong&gt;Hallucination Energy&lt;/strong&gt;, defined as the projection residual between a claim embedding and the subspace spanned by its supporting evidence embeddings. This metric operationalizes grounding as a measurable geometric quantity.&lt;/p&gt;&#xA;&lt;p&gt;We proceed in three stages:&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&lt;strong&gt;Formal Definition&lt;/strong&gt; a draft manuscript introducing Hallucination Energy, its mathematical formulation, and its role within a policy-controlled architecture.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Empirical Evaluation&lt;/strong&gt; structured calibration and adversarial stress testing across multiple domains to assess the robustness and limits of projection-based grounding.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Applied Validation&lt;/strong&gt; large-scale evaluation on 10,000 samples from the HaluEval summarization benchmark, demonstrating that projection-based containment functions as a strong first-order grounding signal in a real generative setting.&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;This work does not claim to solve hallucination. Rather, it characterizes the boundary of projection-based grounding, establishes its suitability as a deterministic policy scalar, and documents both its strengths and its structural limitations.&lt;/p&gt;</description>
    </item>
    <item>
      <title>From Evidence to Verifiability: Rebuilding Trust in AI Outputs 🔏</title>
      <link>http://programmer.ie/post/policy/</link>
      <pubDate>Tue, 03 Feb 2026 12:25:58 +0000</pubDate>
      <guid>http://programmer.ie/post/policy/</guid>
      <description>&lt;h2 id=&#34;-tldr&#34;&gt;⏰ TLDR&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;This work shows that the hardest part of using AI in high-trust environments is not the model, but the policy.&#xA;Once editorial policy is made explicit and executable, AI systems become interchangeable the real challenge is engineering reliable measurements and deterministic enforcement of those policies.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-summary&#34;&gt;📋 Summary&lt;/h2&gt;&#xA;&lt;p&gt;AI systems are becoming deeply embedded in how we research, write, and reason.&#xA;At the same time, their use in high-trust environments is under strain not because models are incapable, but because they are being deployed into settings that demand &lt;strong&gt;determinism, provenance, and enforceable rules&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Review: What We’ve Learned So Far</title>
      <link>http://programmer.ie/post/review/</link>
      <pubDate>Mon, 01 Dec 2025 22:57:41 +0000</pubDate>
      <guid>http://programmer.ie/post/review/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;😶‍🌫️ Summary&lt;/h2&gt;&#xA;&lt;p&gt;This post is a quick review of the journey so far.&lt;/p&gt;&#xA;&lt;p&gt;We’re one third of the way through the &lt;strong&gt;Self-Learning Systems (100-part)&lt;/strong&gt; series, and this checkpoint pulls together the first 33 posts and the research papers that shaped them. The table below lists each post, its place in the series, and the key references it builds on, so you can see how the system and the ideas behind it have evolved since May.&lt;/p&gt;</description>
    </item>
    <item>
      <title>✨ TINY CRITICS: Lightweight Reasoning Checks for Large AI Systems</title>
      <link>http://programmer.ie/post/critic/</link>
      <pubDate>Sat, 29 Nov 2025 00:06:42 +0000</pubDate>
      <guid>http://programmer.ie/post/critic/</guid>
      <description>&lt;h2 id=&#34;-0-tldr&#34;&gt;🥹 &lt;strong&gt;0. TL;DR&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;Large language models write fluent explanations even when they’re wrong.&#xA;Verifying their reasoning usually requires &lt;em&gt;another&lt;/em&gt; LLM slow, expensive, and circular.&lt;/p&gt;&#xA;&lt;p&gt;We needed something different:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;A miniature reasoning critic &amp;lt;50 KB trained on synthetic reasoning mistakes, able to instantly detect broken reasoning in much larger models.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;The Tiny Critic:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;trains on GSM8K-style reasoning traces generated by DeepSeek or Mistral&lt;/li&gt;&#xA;&lt;li&gt;uses &lt;strong&gt;FrontierLens&lt;/strong&gt;, and &lt;strong&gt;Visual Policy Maps (VPMs)&lt;/strong&gt; to convert reasoning into &lt;em&gt;canonical numerical features&lt;/em&gt;&lt;/li&gt;&#xA;&lt;li&gt;is just a logistic regression with ~30 parameters&lt;/li&gt;&#xA;&lt;li&gt;runs in microseconds&lt;/li&gt;&#xA;&lt;li&gt;plugs into any agent&lt;/li&gt;&#xA;&lt;li&gt;dramatically improves InitAgent, R1-Loops, and research-planning stability&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;This post tells the full story how we built it, why it works, and what we learned about the &lt;em&gt;shape of reasoning&lt;/em&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Nexus Blossom: How AI Thoughts Turn into Habits</title>
      <link>http://programmer.ie/post/nexus/</link>
      <pubDate>Wed, 19 Nov 2025 23:23:16 +0100</pubDate>
      <guid>http://programmer.ie/post/nexus/</guid>
      <description>We turn any text into scorables, grow them into blossoms, and weave them into a living graph. Then we A/B test the graph’s thinking quality.</description>
    </item>
    <item>
      <title>Search–Solve–Prove: building a place for thoughts to develop</title>
      <link>http://programmer.ie/post/ssp/</link>
      <pubDate>Sun, 02 Nov 2025 01:13:06 +0000</pubDate>
      <guid>http://programmer.ie/post/ssp/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🌌 Summary&lt;/h2&gt;&#xA;&lt;p&gt;What if you could &lt;strong&gt;see an AI think&lt;/strong&gt; not just the final answer, but the whole stream of reasoning: every search, every dead end, every moment of insight? We’re building exactly that: a visible, measurable thought process we call &lt;strong&gt;the Jitter&lt;/strong&gt;. This post &lt;strong&gt;the first in a series&lt;/strong&gt; shows how we’re creating the &lt;strong&gt;habitat&lt;/strong&gt; where that digital thought stream can live and grow.&lt;/p&gt;&#xA;&lt;p&gt;We’ll draw on ideas from:&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Space Between Models Has Holes: Mapping the AI Gap</title>
      <link>http://programmer.ie/post/gap/</link>
      <pubDate>Wed, 22 Oct 2025 20:30:36 +0100</pubDate>
      <guid>http://programmer.ie/post/gap/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🌌 Summary&lt;/h2&gt;&#xA;&lt;p&gt;What if the most valuable insights in AI evaluation aren&amp;rsquo;t in model agreements, but in &lt;strong&gt;systematic disagreements&lt;/strong&gt;?&lt;/p&gt;&#xA;&lt;p&gt;This post reveals that the &amp;ldquo;gap&amp;rdquo; between large and small reasoning models contains &lt;strong&gt;structured, measurable intelligence&lt;/strong&gt; about how different architectures reason. We demonstrate how to transform model disagreements from a problem into a solution, using the space between models to make tiny networks behave more like their heavyweight counterparts.&lt;/p&gt;&#xA;&lt;p&gt;We start by assembling a high-quality corpus (10k–50k conversation turns), score it with a local LLM to create targets, and train both HRM and Tiny models under identical conditions. Then we run fresh documents through both models, collecting not just final scores but rich &lt;strong&gt;auxiliary signals&lt;/strong&gt; (uncertainty, consistency, OOD detection, etc.) and visualize what these signals reveal.&lt;/p&gt;</description>
    </item>
    <item>
      <title>A Complete Visual Reasoning Stack: From Conversations to Epistemic Fields</title>
      <link>http://programmer.ie/post/visual_reasoning_stack/</link>
      <pubDate>Sun, 12 Oct 2025 10:30:45 +0100</pubDate>
      <guid>http://programmer.ie/post/visual_reasoning_stack/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;📝 Summary&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;We asked a blunt question: &lt;strong&gt;Can we see reasoning?&lt;/strong&gt;&lt;br&gt;&#xA;The answer surprised us: &lt;strong&gt;Yes, and you can click on it.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;This post shows the complete stack that turns AI reasoning from a black box into an &lt;strong&gt;editable canvas&lt;/strong&gt;. Watch as:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Your single insight becomes 10,000 reasoning variations&lt;/li&gt;&#xA;&lt;li&gt;Abstract &amp;ldquo;understanding&amp;rdquo; becomes visible epistemic fields&lt;/li&gt;&#xA;&lt;li&gt;Manual prompt engineering becomes automated evolution&lt;/li&gt;&#xA;&lt;li&gt;Blind trust becomes visual verification&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;This isn’t just code it’s a visual way of interacting with AI, where reasoning becomes something you can see, explore, and refine.&lt;/p&gt;</description>
    </item>
    <item>
      <title>🔦 Phōs: Visualizing How AI Learns and How to Build It Yourself</title>
      <link>http://programmer.ie/post/phos/</link>
      <pubDate>Thu, 09 Oct 2025 00:30:36 +0100</pubDate>
      <guid>http://programmer.ie/post/phos/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;“The eye sees only what the mind is prepared to comprehend.” &lt;em&gt;Henri Bergson&lt;/em&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-we-finally-see-learning&#34;&gt;🔍 We Finally See Learning&lt;/h2&gt;&#xA;&lt;p&gt;For decades, we’ve measured artificial intelligence with numbers loss curves, accuracy scores, reward signals.&lt;br&gt;&#xA;We’ve plotted progress, tuned hyperparameters, celebrated benchmarks.&lt;/p&gt;&#xA;&lt;p&gt;But we’ve never actually &lt;em&gt;seen&lt;/em&gt; learning happen.&lt;/p&gt;&#xA;&lt;p&gt;Not really.&lt;/p&gt;&#xA;&lt;p&gt;Sure, we’ve visualized attention maps or gradient flows but those are snapshots, proxies, not processes.&lt;/p&gt;&#xA;&lt;p&gt;What if we could watch understanding emerge not as a number going up, but as a pattern stabilizing across time?&lt;br&gt;&#xA;What if reasoning itself left a visible trace?&lt;/p&gt;</description>
    </item>
    <item>
      <title>Episteme: Distilling Knowledge into AI</title>
      <link>http://programmer.ie/post/episteme/</link>
      <pubDate>Fri, 03 Oct 2025 11:24:58 +0100</pubDate>
      <guid>http://programmer.ie/post/episteme/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🚀 Summary&lt;/h2&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;When you can measure what you are speaking about… you know something about it; but when you cannot measure it… your knowledge is of a meagre and unsatisfactory kind. &lt;em&gt;Lord Kelvin&lt;/em&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;Remember that time you spent an hour with an AI, and in one perfect response, it solved a problem you&amp;rsquo;d been stuck on for weeks?&lt;/strong&gt; Where is that answer now? Lost in a scroll of chat history, a fleeting moment of brilliance that vanished as quickly as it appeared. This post is about how to make that moment permanent, and turn it into an intelligence that amplifies everything you do.&lt;/p&gt;</description>
    </item>
    <item>
      <title>🔄 Learning from Learning: Stephanie’s Breakthrough</title>
      <link>http://programmer.ie/post/knowledge/</link>
      <pubDate>Wed, 10 Sep 2025 10:09:22 +0100</pubDate>
      <guid>http://programmer.ie/post/knowledge/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;📖 Summary&lt;/h2&gt;&#xA;&lt;p&gt;&lt;em&gt;AI has always been about absorption: first data, then feedback. But even at its best, it hit a ceiling. What if, instead of absorbing inputs, it absorbed the act of learning itself?&lt;/em&gt;&lt;/p&gt;&#xA;&lt;p&gt;In our &lt;strong&gt;last post&lt;/strong&gt;, we reached a breakthrough: Stephanie isn’t just learning from data or feedback, but from the &lt;em&gt;process of learning itself&lt;/em&gt;. That realization changed our direction from building “just another AI” to building a system that absorbs knowledge, reflects on its own improvement, and evolves from the act of learning.&lt;/p&gt;</description>
    </item>
    <item>
      <title>From Photo Albums to Movies: Teaching AI to See Its Own Progress</title>
      <link>http://programmer.ie/post/pacs/</link>
      <pubDate>Sun, 07 Sep 2025 08:50:43 +0100</pubDate>
      <guid>http://programmer.ie/post/pacs/</guid>
      <description>&lt;h2 id=&#34;-tldr&#34;&gt;🥱 TLDR&lt;/h2&gt;&#xA;&lt;p&gt;This post details the implementation of:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;a href=&#34;https://arxiv.org/abs/2509.02522&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;PACS&lt;/strong&gt;: Implicit Actor–Critic Coupling via a Supervised Learning Framework for RLVR&#xA;&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;https://arxiv.org/abs/2509.04011&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;NER Retriever&lt;/strong&gt;: Zero-Shot Named Entity Retrieval with Type-Aware Embeddings&#xA;&lt;/a&gt;&#xA;within our self-improving AI, &lt;a href=&#34;https://github.com/ernanhughes/stephanie&#34;&gt;Stephanie&lt;/a&gt;.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;The core idea is to move beyond static, single-point feedback to a richer, more dynamic form of learning:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Case Based Reasoning: Teaching AI to Learn From itself</title>
      <link>http://programmer.ie/post/cbr/</link>
      <pubDate>Wed, 03 Sep 2025 23:52:29 +0100</pubDate>
      <guid>http://programmer.ie/post/cbr/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;✨ Summary&lt;/h2&gt;&#xA;&lt;p&gt;Imagine an AI that gets smarter every time it works   not by retraining on massive datasets, but by &lt;strong&gt;learning from its own reasoning and reflection&lt;/strong&gt;, just like humans.&lt;/p&gt;&#xA;&lt;p&gt;Most AI systems are frozen in time. Trained once, deployed forever, they never learn from mistakes or build on successes. Real intelligence   human or artificial   doesn’t work that way. It learns from experience.&lt;/p&gt;&#xA;&lt;p&gt;This is the vision behind &lt;strong&gt;Stephanie&lt;/strong&gt;: a self-improving AI that gets better every time it acts, not by fine-tuning, but by &lt;strong&gt;remembering, reusing, and revising&lt;/strong&gt; its reasoning.&lt;/p&gt;</description>
    </item>
    <item>
      <title>SIS: The Visual Dashboard That Makes Stephanie&#39;s AI Understandable</title>
      <link>http://programmer.ie/post/sis/</link>
      <pubDate>Mon, 25 Aug 2025 15:30:43 +0100</pubDate>
      <guid>http://programmer.ie/post/sis/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;h2 id=&#34;-the-invisible-ai-problem&#34;&gt;🔍 The Invisible AI Problem&lt;/h2&gt;&#xA;&lt;p&gt;How do you debug a system that generates thousands of database entries, hundreds of prompts, and dozens of knowledge artifacts for a single query?&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;SIS is our answer&lt;/strong&gt; a visual dashboard that transforms Stephanie&amp;rsquo;s complex internal processes into something developers can actually understand and improve.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-in-this-post&#34;&gt;📰 In This Post&lt;/h2&gt;&#xA;&lt;p&gt;I&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;🔎 &lt;strong&gt;See how Stephanie pipelines really work&lt;/strong&gt; – from Arxiv search to cartridges, step by step.&lt;/li&gt;&#xA;&lt;li&gt;📜 &lt;strong&gt;View logs and pipeline steps clearly&lt;/strong&gt; – no more digging through raw DB entries.&lt;/li&gt;&#xA;&lt;li&gt;📝 &lt;strong&gt;Generate dynamic reports from pipeline runs&lt;/strong&gt; – structured outputs you can actually use.&lt;/li&gt;&#xA;&lt;li&gt;🤖 &lt;strong&gt;Use pipelines to train the system&lt;/strong&gt; – showing how runs feed back into learning.&lt;/li&gt;&#xA;&lt;li&gt;🧩 &lt;strong&gt;Turn raw data into functional knowledge&lt;/strong&gt; – cartridges, scores, and reasoning traces.&lt;/li&gt;&#xA;&lt;li&gt;🔄 &lt;strong&gt;Move from fixed pipelines toward self-learning&lt;/strong&gt; – what it takes to make the system teach itself.&lt;/li&gt;&#xA;&lt;li&gt;🖥️ &lt;strong&gt;SIS isn’t just a pretty GUI&lt;/strong&gt; - it’s the layer that makes Stephanie’s knowledge visible and usable.&lt;/li&gt;&#xA;&lt;li&gt;🈸️ &lt;strong&gt;Configuring Stephanie&lt;/strong&gt; – We will show you how to get up and running with Stephanie.&lt;/li&gt;&#xA;&lt;li&gt;💡 &lt;strong&gt;What we learned&lt;/strong&gt; – the big takeaway: knowledge without direction is just documentation.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-why-we-built-sis&#34;&gt;❓ Why We Built SIS&lt;/h2&gt;&#xA;&lt;p&gt;When you’re developing a self-improving AI like &lt;strong&gt;Stephanie&lt;/strong&gt;, the real challenge isn’t just running pipelines it’s making sense of the flood of logs, evaluations, and scores the system generates.&lt;/p&gt;</description>
    </item>
    <item>
      <title>ZeroModel: Visual AI you can scrutinize</title>
      <link>http://programmer.ie/post/zeromodel/</link>
      <pubDate>Mon, 11 Aug 2025 22:41:43 +0100</pubDate>
      <guid>http://programmer.ie/post/zeromodel/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;em&gt;“The medium is the message.”&lt;/em&gt; Marshall McLuhan&lt;br&gt;&#xA;&lt;strong&gt;We took him literally.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;What if you could literally watch an AI think not through confusing graphs or logs, but by seeing its reasoning process, frame by frame? Right now, AI decisions are black boxes. When your medical device rejects a treatment, your security system flags a false positive, or your recommendation engine fails catastrophically you get no explanation, just a &amp;rsquo;trust me&amp;rsquo; from a $10M model. ZeroModel changes this forever.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Everything is a Trace: Stephanie Enters Full Reflective Mode</title>
      <link>http://programmer.ie/post/trace/</link>
      <pubDate>Sun, 03 Aug 2025 22:03:10 +0100</pubDate>
      <guid>http://programmer.ie/post/trace/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🔧 Summary&lt;/h2&gt;&#xA;&lt;p&gt;In our last post, &lt;a href=&#34;http://programmer.ie/post/hrm/&#34;&gt;&lt;strong&gt;Layers of Thought: Smarter Reasoning with the Hierarchical Reasoning Model&lt;/strong&gt;&lt;/a&gt;, we introduced a new epistemic lens a way to evaluate not just final answers, but the entire sequence of reasoning steps that led to them. We realized we could apply &lt;strong&gt;this way of seeing&lt;/strong&gt; to &lt;strong&gt;every action in our system&lt;/strong&gt; not just answers, but inferences, lookups, scorings, decisions, and even model selections. This post shows how we&amp;rsquo;re doing exactly that.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Layers of thought: smarter reasoning with the Hierarchical Reasoning Model</title>
      <link>http://programmer.ie/post/hrm/</link>
      <pubDate>Thu, 31 Jul 2025 09:20:54 +0100</pubDate>
      <guid>http://programmer.ie/post/hrm/</guid>
      <description>&lt;h2 id=&#34;-introduction&#34;&gt;🤝 Introduction&lt;/h2&gt;&#xA;&lt;p&gt;Forget everything you thought you knew about AI reasoning. What you&amp;rsquo;re about to discover isn&amp;rsquo;t just another scoring algorithm it&amp;rsquo;s Stephanie&amp;rsquo;s first true capacity for &lt;em&gt;thought&lt;/em&gt;. Let&amp;rsquo;s peel back the layers of the&#xA;&lt;a href=&#34;https://arxiv.org/abs/2506.21734&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;HRM&lt;/strong&gt;: Hierarchical Reasoning Model&#xA;&lt;/a&gt; and see why this represents a quantum leap in how AI systems can genuinely reason rather than merely react.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Stephanie&#39;s Secret: The Dawn of Reflective AI</title>
      <link>http://programmer.ie/post/gild/</link>
      <pubDate>Sun, 27 Jul 2025 22:23:45 +0100</pubDate>
      <guid>http://programmer.ie/post/gild/</guid>
      <description>&lt;h2 id=&#34;-introduction-the-dawn-of-self-reflective-ai&#34;&gt;🌅 Introduction: The Dawn of Self-Reflective AI&lt;/h2&gt;&#xA;&lt;p&gt;What if your AI could not only answer questions but also question &lt;em&gt;itself&lt;/em&gt; about those answers? Not with programmed doubt, but with genuine self-awareness recognizing when it&amp;rsquo;s uncertain, analyzing why it made a mistake, and systematically improving its own reasoning process? This isn&amp;rsquo;t science fiction. Today, we&amp;rsquo;re unveiling the first working implementation of an AI that doesn&amp;rsquo;t just think, but &lt;em&gt;learns how to think better&lt;/em&gt;. It&amp;rsquo;s a bit cold here&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Shape of Thought: Exploring Embedding Strategies with Ollama, HF, and H-Net</title>
      <link>http://programmer.ie/post/hnet/</link>
      <pubDate>Sat, 19 Jul 2025 22:06:13 +0100</pubDate>
      <guid>http://programmer.ie/post/hnet/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🔍 Summary&lt;/h2&gt;&#xA;&lt;p&gt;Stephanie, a self-improving system, is built on a powerful belief:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;&lt;strong&gt;If an AI can evaluate its own understanding, it can reshape itself.&lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;p&gt;This principle fuels every part of her design from embedding to scoring to tuning.&lt;/p&gt;&#xA;&lt;p&gt;At the heart of this system is a &lt;strong&gt;layered reasoning pipeline&lt;/strong&gt;:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;MRQ&lt;/strong&gt; offers directional, reinforcement-style feedback.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;EBT&lt;/strong&gt; provides uncertainty-aware judgments and convergence guidance.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;SVM&lt;/strong&gt; delivers fast, efficient evaluations for grounded comparisons.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;These models form Stephanie’s &lt;strong&gt;subconscious engine&lt;/strong&gt; the part of her mind that runs beneath explicit thought, constantly shaping her understanding. But like any subconscious, its &lt;em&gt;clarity&lt;/em&gt; depends on how raw experience is &lt;strong&gt;represented&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Getting Smarter at Getting Smarter: A Practical Guide to Self-Tuning AI</title>
      <link>http://programmer.ie/post/models/</link>
      <pubDate>Thu, 10 Jul 2025 09:01:45 +0100</pubDate>
      <guid>http://programmer.ie/post/models/</guid>
      <description>&lt;h2 id=&#34;-summary-the-self-tuning-imperative&#34;&gt;🔥 Summary: The Self-Tuning Imperative&lt;/h2&gt;&#xA;&lt;p&gt;&lt;em&gt;&amp;ldquo;We&amp;rsquo;re drowning in models but starved for wisdom.&amp;rdquo;&lt;/em&gt; Traditional AI stacks:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Require constant manual tuning&lt;/li&gt;&#xA;&lt;li&gt;Suffer from version lock-in&lt;/li&gt;&#xA;&lt;li&gt;Can&amp;rsquo;t explain their confidence&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;What if your AI system could &lt;strong&gt;learn which models to trust&lt;/strong&gt; and when &lt;strong&gt;without your help&lt;/strong&gt;?&lt;/p&gt;&#xA;&lt;p&gt;In this post, we’ll show you a practical, working strategy for building &lt;strong&gt;self-tuning AI&lt;/strong&gt; not theoretical, not hand-wavy, but a real system you can build today using modular components and a few powerful insights.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Epistemic Engines: Building Reflective Minds with Belief Cartridges and In-Context Learning</title>
      <link>http://programmer.ie/post/epistemic-engines/</link>
      <pubDate>Wed, 02 Jul 2025 14:15:50 +0100</pubDate>
      <guid>http://programmer.ie/post/epistemic-engines/</guid>
      <description>&lt;h2 id=&#34;-summary-building-the-engine-of-understanding&#34;&gt;🔍 Summary: Building the Engine of Understanding&lt;/h2&gt;&#xA;&lt;p&gt;This is not a finished story. It’s the beginning of one and likely the most ambitious post we’ve written yet.&lt;/p&gt;&#xA;&lt;p&gt;We&amp;rsquo;re venturing into new ground: designing epistemic engines modular, evolving AI systems that don’t just respond to prompts, but build understanding, accumulate beliefs, and refine themselves through In-Context Learning.&lt;/p&gt;&#xA;&lt;p&gt;In this series, we’ll construct a self-contained system separate from our core framework Stephanie that runs its own pipelines, evaluates its own beliefs, and continuously improves through repeated encounters with new data. Its core memory will be made of cartridges: scored, structured markdown artifacts distilled from documents, papers, and the web. These cartridges form a kind of belief substrate that guides the system’s judgments.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Self-Improving AI: A System That Learns, Validates, and Retrains Itself</title>
      <link>http://programmer.ie/post/rivals/</link>
      <pubDate>Mon, 30 Jun 2025 10:13:03 +0100</pubDate>
      <guid>http://programmer.ie/post/rivals/</guid>
      <description>&lt;h2 id=&#34;-the-static-ai-trap&#34;&gt;🤖 &lt;strong&gt;The Static AI Trap&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;Today’s AI systems are frozen in time: trained once, deployed forever. Yet the real world never stops evolving. Goals shift overnight. New research upends old truths. Context transforms without warning.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;What if your AI could wake up?&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;In this post, we engineer an intelligence that &lt;strong&gt;teaches itself&lt;/strong&gt;   a system that continuously learns from the web, audits its own judgments, and retrains itself when confidence wavers.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Teaching Tiny Models to Think Big: Distilling Intelligence Across Devices</title>
      <link>http://programmer.ie/post/pupil/</link>
      <pubDate>Fri, 27 Jun 2025 23:24:14 +0100</pubDate>
      <guid>http://programmer.ie/post/pupil/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🧪 Summary&lt;/h2&gt;&#xA;&lt;p&gt;As AI developers, we often face the tradeoff between intelligence and accessibility. Powerful language models like Qwen3 run beautifully on servers but what about on the edge? On devices like Raspberry Pi or old Android phones, we’re limited to small models. The question we asked was simple:&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Can we teach a small model to behave like a large one without retraining it from scratch using only its outputs and embeddings?&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agent Architectures: Chapter 2</title>
      <link>http://programmer.ie/post/agents_02/</link>
      <pubDate>Fri, 27 Jun 2025 11:24:51 +0100</pubDate>
      <guid>http://programmer.ie/post/agents_02/</guid>
      <description>&lt;p&gt;This is a summary of the second chapter of a book I wrote:&lt;/p&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://www.amazon.co.uk/dp/B0F3XJ3R4D&#34;&gt;Agent Architectures: Advanced Strategies for Intelligent LLM Systems&lt;/a&gt;&lt;/p&gt;&#xA;&lt;h1 id=&#34;-chapter-2--how-to-think-with-ai-agents&#34;&gt;🤖 Chapter 2 : How to &lt;em&gt;Think&lt;/em&gt; With AI Agents&lt;/h1&gt;&#xA;&lt;p&gt;&lt;em&gt;Agents aren’t just tools they’re thinking partners. This post explores the core mindset shifts, methodologies, and feedback loops that define how to work with intelligent systems.&lt;/em&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-five-core-shifts-in-the-aihuman-paradigm&#34;&gt;🌊 Five Core Shifts in the AI–Human Paradigm&lt;/h2&gt;&#xA;&lt;p&gt;Before diving into methods, we need to understand the &lt;strong&gt;big changes&lt;/strong&gt; redefining how we work with AI:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Compiling Thought: Building a Prompt Compiler for Self-Improving AI</title>
      <link>http://programmer.ie/post/compiler/</link>
      <pubDate>Thu, 26 Jun 2025 13:31:41 +0100</pubDate>
      <guid>http://programmer.ie/post/compiler/</guid>
      <description>&lt;p&gt;&lt;strong&gt;How to design a pipeline that turns vague goals into smart prompts&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;h2 id=&#34;-summary&#34;&gt;🧪 Summary&lt;/h2&gt;&#xA;&lt;p&gt;Why spend hours engineering prompts when AI can optimize its own instructions. This blog post introduces a novel approach toward creating a self-improving AI by treating prompts as programs. Traditional AI systems often rely on static instructions rigid and limited in adaptability. Here, we present a different perspective: viewing the Large Language Model (LLM) as a &lt;strong&gt;prompt compiler&lt;/strong&gt; capable of dynamically transforming raw instructions into optimized prompts through iterative cycles of decomposition, evaluation, and intelligent reassembly.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agent Architectures: Chapter 1</title>
      <link>http://programmer.ie/post/agents_01/</link>
      <pubDate>Thu, 26 Jun 2025 12:51:33 +0100</pubDate>
      <guid>http://programmer.ie/post/agents_01/</guid>
      <description>&lt;p&gt;This is a summary of the first chapter of a book I wrote:&lt;/p&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://www.amazon.co.uk/dp/B0F3XJ3R4D&#34;&gt;Agent Architectures: Advanced Strategies for Intelligent LLM Systems&lt;/a&gt;&lt;/p&gt;&#xA;&lt;h1 id=&#34;-introduction-to-llm-agents&#34;&gt;🚀 Introduction to LLM Agents&lt;/h1&gt;&#xA;&lt;h2 id=&#34;-what-is-an-llm-agent&#34;&gt;🤖 What is an LLM Agent?&lt;/h2&gt;&#xA;&lt;p&gt;An &lt;strong&gt;LLM agent&lt;/strong&gt; is an intelligent software system built around a large language model (LLM). Unlike traditional LLMs, these agents don&amp;rsquo;t merely respond to prompts they actively reason, maintain context, and interact dynamically with external tools and environments. This autonomy enables them to manage complex workflows independently.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Thoughts of Algorithms</title>
      <link>http://programmer.ie/post/thoughts/</link>
      <pubDate>Mon, 23 Jun 2025 11:10:59 +0100</pubDate>
      <guid>http://programmer.ie/post/thoughts/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;How a self-evolving AI learns to reflect, score, and rewrite its own reasoning&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-summary&#34;&gt;🧪 Summary&lt;/h2&gt;&#xA;&lt;p&gt;What if an AI could think not just solve problems, but reevaluate its beliefs in the face of new information?&lt;/p&gt;&#xA;&lt;p&gt;In this post, we introduce a system that does exactly that. At the core of our pipeline is a lightweight scoring model called MR.Q, responsible for evaluating ideas and choosing the best ones. But when it encounters a new domain, a new goal, or a shift in task format, it doesn’t freeze it adapts.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Document Intelligence: Turning Documents into Structured Knowledge</title>
      <link>http://programmer.ie/post/docs/</link>
      <pubDate>Tue, 17 Jun 2025 23:31:13 +0100</pubDate>
      <guid>http://programmer.ie/post/docs/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;📖 Summary&lt;/h2&gt;&#xA;&lt;p&gt;Imagine drowning in a sea of research papers, each holding a fragment of the knowledge you need for your next breakthrough. How does an AI system, striving for self-improvement, navigate this information overload to find precisely what it needs? This is the core challenge our Document Intelligence pipeline addresses, transforming chaotic documents into organized, searchable knowledge.&lt;/p&gt;&#xA;&lt;p&gt;In this post we combine insights from &lt;a href=&#34;https://arxiv.org/pdf/2505.21497&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;Paper2Poster&lt;/strong&gt;: Towards Multimodal Poster Automation from Scientific Papers&#xA;&lt;/a&gt; and&#xA;&lt;a href=&#34;https://arxiv.org/abs/2506.10952&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;Domain2Vec&lt;/strong&gt;: Vectorizing Datasets to Find the Optimal Data Mixture without Training&#xA;&lt;/a&gt; to build an AI document profiler that transforms unstructured papers into structured, searchable knowledge graphs.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Learning to Learn: A LATS-Based Framework for Self-Aware AI Pipelines</title>
      <link>http://programmer.ie/post/lats/</link>
      <pubDate>Thu, 12 Jun 2025 09:23:46 +0100</pubDate>
      <guid>http://programmer.ie/post/lats/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;📖 Summary&lt;/h2&gt;&#xA;&lt;p&gt;In this post, we introduce the LATSAgent, an implementation of &lt;a href=&#34;https://arxiv.org/pdf/2310.04406&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;LATS&lt;/strong&gt;: Language Agent Tree Search Unifies Reasoning..&#xA;&lt;/a&gt; within the &lt;a href=&#34;https://github.com/ernanhughes/co-ai&#34;&gt;stephanie&lt;/a&gt; framework. Unlike prior agents that followed a single reasoning chain, this agent explores multiple reasoning paths in parallel, evaluates them using multidimensional scoring, and learns symbolic refinements over time. This is our most complete integration yet of search, simulation, scoring, and symbolic tuning bringing together all of our previous work on sharpening, pipeline reflection, and symbolic rules into a unified, intelligent reasoning loop.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Dimensions of Thought: A Smarter Way to Evaluate AI</title>
      <link>http://programmer.ie/post/dimensions/</link>
      <pubDate>Mon, 09 Jun 2025 10:00:03 +0100</pubDate>
      <guid>http://programmer.ie/post/dimensions/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;📖 Summary&lt;/h2&gt;&#xA;&lt;p&gt;This post introduces a multidimensional reward modeling pipeline built on top of the &lt;a href=&#34;https://github.com/ernanhughes/co-ai&#34;&gt;stephanieanie&lt;/a&gt; framework. It covers:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;✅ &lt;strong&gt;Structured Evaluation Setup&lt;/strong&gt;&#xA;How to define custom evaluation dimensions using YAML or database-backed rubrics.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;🧠 &lt;strong&gt;Automated Scoring with LLMs&lt;/strong&gt;&#xA;Using the &lt;code&gt;ScoreEvaluator&lt;/code&gt; to produce structured, rationale-backed scores for each dimension.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;🧮 &lt;strong&gt;Embedding-Based Hypothesis Indexing&lt;/strong&gt;&#xA;Efficiently embedding hypotheses and comparing them for contrastive learning using similarity.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;🔄 &lt;strong&gt;Contrast Pair Generation&lt;/strong&gt;&#xA;Creating training pairs where one hypothesis outperforms another on a given dimension.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Programming Intelligence: Using Symbolic Rules to Steer and Evolve AI</title>
      <link>http://programmer.ie/post/symbolic/</link>
      <pubDate>Wed, 04 Jun 2025 20:57:20 +0100</pubDate>
      <guid>http://programmer.ie/post/symbolic/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🧪 Summary&lt;/h2&gt;&#xA;&lt;p&gt;&amp;ldquo;What if AI systems could learn how to improve themselves not just at the level of weights or prompts, but at the level of strategy itself? In this post, we show how to build such a system, powered by symbolic rules and reflection.&lt;/p&gt;&#xA;&lt;p&gt;The paper &lt;a href=&#34;https://arxiv.org/pdf/2406.18532v1&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;Symbolic Agents&lt;/strong&gt;: Symbolic Learning Enables Self-Evolving Agents&#xA;&lt;/a&gt; introduces a framework where &lt;strong&gt;symbolic rules&lt;/strong&gt; guide, evaluate, and evolve agent behavior.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Adaptive Reasoning with ARM: Teaching AI the Right Way to Think</title>
      <link>http://programmer.ie/post/arm/</link>
      <pubDate>Wed, 28 May 2025 22:22:46 +0100</pubDate>
      <guid>http://programmer.ie/post/arm/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Chain-of-thought is powerful, but which chain? Short explanations work for easy tasks, long reflections help on hard ones, and code sometimes beats them both. What if your model could adaptively pick the best strategy, per task, and improve as it learns?&lt;/p&gt;&#xA;&lt;p&gt;The &lt;code&gt;Adaptive Reasoning Model&lt;/code&gt; &lt;strong&gt;(ARM)&lt;/strong&gt; is a framework for teaching language models how to choose the right reasoning format direct answers, chain-of-thoughts, or code depending on the task. It works by evaluating responses, scoring them based on rarity, conciseness, and difficulty alignment, and then updating model behavior over time.&lt;/p&gt;</description>
    </item>
    <item>
      <title>A Novel Approach to Autonomous Research: Implementing NOVELSEEK with Modular AI Agents</title>
      <link>http://programmer.ie/post/novel/</link>
      <pubDate>Tue, 27 May 2025 22:40:50 +0100</pubDate>
      <guid>http://programmer.ie/post/novel/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;AI research tools today are often narrow: one generates summaries, another ranks models, a third suggests ideas. But real scientific discovery isn’t a single step—it’s a pipeline. It’s iterative, structured, and full of feedback loops.&lt;/p&gt;&#xA;&lt;p&gt;In this post, I show how to build a modular AI system that mirrors this full research lifecycle. From initial idea generation to method planning, each phase is handled by a specialized agent working in concert.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Self-Aware Pipeline: Empowering AI to Choose Its Own Path to the Goal</title>
      <link>http://programmer.ie/post/pipeline/</link>
      <pubDate>Sat, 24 May 2025 13:48:15 +0100</pubDate>
      <guid>http://programmer.ie/post/pipeline/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🔧 Summary&lt;/h2&gt;&#xA;&lt;p&gt;Modern AI systems require more than just raw processing power they need contextual awareness, strategic foresight, and adaptive learning capabilities. In this post, we walk through how we implemented a self-aware pipeline system inspired by the &lt;strong&gt;Devil’s Advocate&lt;/strong&gt; paper.&lt;/p&gt;&#xA;&lt;p&gt;Unlike brittle, static workflows, this architecture empowers agents to reflect on their own steps, predict failure modes, and adapt their strategies in real time.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-grounding-in-research&#34;&gt;🧠 Grounding in Research&lt;/h2&gt;&#xA;&lt;h3 id=&#34;devils-advocate-rerest&#34;&gt;Devil’s Advocate (ReReST)&lt;/h3&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://arxiv.org/abs/2405.16334&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;ReReST&lt;/strong&gt;: Devil&amp;#39;s Advocate: Anticipatory Reflection for LLM Agents&#xA;&lt;/a&gt;  introduces a self-training framework for LLM agents. The core idea is to have a &amp;ldquo;reflector&amp;rdquo; agent anticipate failures and revise the original plan before executing a powerful method for reducing hallucinations and improving sample quality. Our implementation draws heavily on these ideas to enable dynamic planning and feedback loops within the pipeline.&lt;/p&gt;</description>
    </item>
    <item>
      <title>General Reasoner: The smarter Local Agent</title>
      <link>http://programmer.ie/post/general/</link>
      <pubDate>Thu, 22 May 2025 21:41:54 +0100</pubDate>
      <guid>http://programmer.ie/post/general/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🔧 Summary&lt;/h2&gt;&#xA;&lt;p&gt;The &lt;a href=&#34;https://arxiv.org/abs/2505.14652&#34;&gt;General Reasoner&lt;/a&gt; paper shows how we can train LLMs to reason across domains using diverse data and a generative verifier. In this post, I walk through our open-source implementation showing how we built a modular reasoning agent capable of generating multiple hypotheses, evaluating them with an LLM-based judge, and selecting the best answer.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-what-we-built&#34;&gt;🧠 What We Built&lt;/h2&gt;&#xA;&lt;p&gt;We built a &lt;code&gt;GeneralReasonerAgent&lt;/code&gt; that:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Dynamically generates multiple hypotheses using different &lt;strong&gt;reasoning strategies&lt;/strong&gt; (e.g., &lt;code&gt;cot&lt;/code&gt;, &lt;code&gt;debate&lt;/code&gt;, &lt;code&gt;verify_then_answer&lt;/code&gt;, etc.)&lt;/li&gt;&#xA;&lt;li&gt;Evaluates each pair of hypotheses using either a &lt;strong&gt;local LLM judge&lt;/strong&gt; or our custom &lt;strong&gt;MR.Q evaluator&lt;/strong&gt;&lt;/li&gt;&#xA;&lt;li&gt;Classifies the winning hypothesis using &lt;strong&gt;rubric dimensions&lt;/strong&gt;&lt;/li&gt;&#xA;&lt;li&gt;Logs structured results to a PostgreSQL-backed system&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;All of this was integrated with our existing stephanie framework, which includes:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Building a Self-Improving Chain-of-Thought Agent: Local LLMs Meet the CoT Encyclopedia</title>
      <link>http://programmer.ie/post/cot/</link>
      <pubDate>Wed, 21 May 2025 18:36:51 +0100</pubDate>
      <guid>http://programmer.ie/post/cot/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;Most AI systems generate answers. Ours examines how they think. This isn’t just prompt engineering this is structured reasoning at scale.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-summary&#34;&gt;🔧 Summary&lt;/h2&gt;&#xA;&lt;p&gt;Large Language Models are transforming every field, yet their internal reasoning remains a formidable black box. We can get brilliant outputs, but without understanding how those conclusions were reached, we&amp;rsquo;re left guessing how to improve, debug, or even trust them. This opacity limits our ability to build truly reliable and self-improving AI systems.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Self-Improving Agents: Applying the Sharpening Framework to Local LLMs</title>
      <link>http://programmer.ie/post/sharpen/</link>
      <pubDate>Tue, 20 May 2025 09:23:16 +0100</pubDate>
      <guid>http://programmer.ie/post/sharpen/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;This is the second post in a 100-part series, where we take breakthrough AI papers and turn them into working code building the next generation of AI, one idea at a time.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-summary&#34;&gt;🔧 Summary&lt;/h2&gt;&#xA;&lt;p&gt;In my previous post, I introduced &lt;code&gt;stephanie&lt;/code&gt; a &lt;strong&gt;modular implementation of the AI co-scientist concept&lt;/strong&gt;, inspired by DeepMind’s recent paper &lt;em&gt;&lt;a href=&#34;https://arxiv.org/abs/2502.18864&#34;&gt;Towards an AI Co-Scientist&lt;/a&gt;&lt;/em&gt;.&lt;/p&gt;&#xA;&lt;p&gt;But now, we’re going deeper.&lt;/p&gt;&#xA;&lt;p&gt;This isn’t just about &lt;strong&gt;running prompts through an agent system&lt;/strong&gt; it’s about building something radically different:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Building an AI Co-Scientist</title>
      <link>http://programmer.ie/post/co/</link>
      <pubDate>Thu, 15 May 2025 09:23:16 +0100</pubDate>
      <guid>http://programmer.ie/post/co/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;This is the first post in a 100-part series, where we take breakthrough AI papers and turn them into working code building the next generation of AI, one idea at a time.&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-summary&#34;&gt;🧾 Summary&lt;/h2&gt;&#xA;&lt;p&gt;In this post, I’ll walk through how I implemented the ideas from&lt;br&gt;&#xA;&lt;a href=&#34;https://arxiv.org/pdf/2502.18864&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;AI Co-Scientist&lt;/strong&gt;: Towards an AI Co-Scientist&#xA;&lt;/a&gt; into a working system called &lt;a href=&#34;https://ernanhughes.github.io/stephanie/&#34;&gt;&lt;code&gt;Stephanie&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Building Clipper: An AI Image Generator You Control</title>
      <link>http://programmer.ie/post/clipper/</link>
      <pubDate>Wed, 07 May 2025 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/clipper/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;“If you’ve ever pasted 50 prompts into an image generator one-by-one, this is for you. I hit my limit and built Clipper to solve it.”&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;h2 id=&#34;-summary&#34;&gt;📖 Summary&lt;/h2&gt;&#xA;&lt;p&gt;In the previous blog post I wrote a research paper: &lt;a href=&#34;http://programmer.ie/post/seeing-thought/&#34;&gt;Cross-Modal Cognitive Mapping&lt;/a&gt;. This paper is about turning your conversations into images to gradually map your thought patterns. The implementation of this paper is an application called &lt;a href=&#34;https://github.com/ernanhughes/prism&#34;&gt;Prism&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;A component of this app is image generation from prompts or your conversations. All of the Foundation models support this but it&amp;rsquo;s a pretty janky process where you have to generate the prompt paste it into a text box and download the image. I just went through a week of doing this while building a &lt;a href=&#34;https://aibussin.com/toolkit/index.html&#34;&gt;prompt toolkit&lt;/a&gt;. While I was doing this I kept wishing I built the app which I&amp;rsquo;m going to share with you now.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cross-Modal Cognitive Mapping: A Technical Overview</title>
      <link>http://programmer.ie/post/seeing-thought/</link>
      <pubDate>Sat, 26 Apr 2025 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/seeing-thought/</guid>
      <description>&lt;h1 id=&#34;cross-modal-cognitive-mapping&#34;&gt;Cross-Modal Cognitive Mapping&lt;/h1&gt;&#xA;&lt;h3 id=&#34;a-technical-overview-of-system-design-and-implementation&#34;&gt;A Technical Overview of System Design and Implementation&lt;/h3&gt;&#xA;&lt;p&gt;&lt;strong&gt;Author:&lt;/strong&gt; Ernan Hughes&lt;br&gt;&#xA;&lt;strong&gt;Published:&lt;/strong&gt; April 2025&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;abstract&#34;&gt;Abstract&lt;/h2&gt;&#xA;&lt;p&gt;Cross-Modal Cognitive Mapping is a new framework designed to extend traditional text-based cognition modeling into multimodal representations.&lt;br&gt;&#xA;This system combines &lt;strong&gt;text prompts&lt;/strong&gt;, &lt;strong&gt;visual generation&lt;/strong&gt;, &lt;strong&gt;human selection behavior&lt;/strong&gt;, and &lt;strong&gt;semantic memory retrieval&lt;/strong&gt; to better understand and track human conceptual architectures.&lt;/p&gt;&#xA;&lt;p&gt;This post presents a technical overview of the core architecture, database design, embedding workflows, search functionality, and resonance mapping built during the initial research phase.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Uncovering Reasoning in LLMs with Sparse Autoencoders</title>
      <link>http://programmer.ie/post/reason/</link>
      <pubDate>Thu, 27 Mar 2025 11:45:33 +0000</pubDate>
      <guid>http://programmer.ie/post/reason/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Large Language Models (LLMs) like DeepSeek-R1 show remarkable reasoning abilities, but how these abilities are internally represented has remained a mystery. This paper explores the mechanistic interpretability of reasoning in LLMs using Sparse Autoencoders (SAEs) — a tool that decomposes LLM activations into human-interpretable features.&#xA;In this post, we’ll:&lt;/p&gt;&#xA;&lt;p&gt;• Explain the SAE architecture used&#xA;• Compute and visualize ReasonScore&#xA;• Explore feature steering with sample completions&#xA;• Provide live visualizations using Python + Streamlit&lt;/p&gt;</description>
    </item>
    <item>
      <title>Optimizing Prompt Generation with MARS and DSPy</title>
      <link>http://programmer.ie/post/mars/</link>
      <pubDate>Mon, 24 Mar 2025 15:45:33 +0000</pubDate>
      <guid>http://programmer.ie/post/mars/</guid>
      <description>&lt;h2 id=&#34;-tldr&#34;&gt;🕒 TL;DR&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;We explore &lt;strong&gt;MARS&lt;/strong&gt;, a multi-agent prompt optimizer using Socratic dialogue.&lt;/li&gt;&#xA;&lt;li&gt;We implement it using &lt;strong&gt;DSPy&lt;/strong&gt; + &lt;strong&gt;Fin-R1&lt;/strong&gt; + &lt;strong&gt;EDGAR&lt;/strong&gt; giving us an end-to-end financial reasoning pipeline.&lt;/li&gt;&#xA;&lt;li&gt;We deploy the whole thing to Hugging Face Spaces with a &lt;strong&gt;Gradio&lt;/strong&gt; UI.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;-introduction&#34;&gt;🌟 Introduction&lt;/h2&gt;&#xA;&lt;p&gt;Prompt engineering has become the defining skill of the Large Language Model (LLM) era a delicate balance between science and art. Crafting the perfect prompt often feels like an exercise in intuition, trial, and error. But what if we could take the guesswork out of the process? What if prompts could optimize themselves?&lt;/p&gt;</description>
    </item>
    <item>
      <title>Fin-R1: a Financial Reasoning LLM with Reinforcement Learning and CoT</title>
      <link>http://programmer.ie/post/finr1/</link>
      <pubDate>Fri, 21 Mar 2025 03:27:30 +0000</pubDate>
      <guid>http://programmer.ie/post/finr1/</guid>
      <description>&lt;h2 id=&#34;introduction&#34;&gt;Introduction&lt;/h2&gt;&#xA;&lt;p&gt;&lt;strong&gt;Fin-R1&lt;/strong&gt; is a new model specifically fine-tuned for financial reasoning, with performance that beats much larger models like DeepSeek-R1.&lt;/p&gt;&#xA;&lt;p&gt;This post will use this model and compare it with &lt;code&gt;phi3&lt;/code&gt; across various tasks.&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;phi3&lt;/strong&gt; for comparison&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Phi-3: a lightweight, general-purpose model known for its efficiency and strong reasoning performance at smaller parameter scales. It serves as a great baseline for assessing how domain-specific tuning in Fin-R1 improves financial understanding and response structure.&lt;/p&gt;</description>
    </item>
    <item>
      <title>MR.Q: Model-Based Representations for Model-Free Trading</title>
      <link>http://programmer.ie/post/mrq/</link>
      <pubDate>Tue, 18 Mar 2025 13:05:34 +0000</pubDate>
      <guid>http://programmer.ie/post/mrq/</guid>
      <description>&lt;h2 id=&#34;introduction&#34;&gt;Introduction&lt;/h2&gt;&#xA;&lt;p&gt;Model-free reinforcement learning learns a policy directly from experience, but it can struggle to discover useful representations from sparse or noisy rewards. Model-based reinforcement learning receives a denser training signal by learning how states, actions, rewards, and termination relate to one another, but it often pays for that knowledge through planning complexity and model error.&lt;/p&gt;&#xA;&lt;a href=&#34;https://arxiv.org/abs/2501.16142&#34; target=&#34;_blank&#34; class=&#34;paper-badge&#34;&#xA;    style=&#34;display: inline-block; padding: 6px 10px; background: #f3f4f6; border-left: 4px solid #3b82f6; border-radius: 4px; margin: 4px 0; text-decoration: none; color: #1f2937;&#34;&gt;&#xA;    &lt;strong&gt;MR.Q&lt;/strong&gt;: MR.Q&#xA;&lt;/a&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Can a model-free agent keep the representation-learning benefits of a learned model without using that model to plan?&lt;/p&gt;</description>
    </item>
    <item>
      <title>Using Hugging Face Datasets</title>
      <link>http://programmer.ie/post/dataset/</link>
      <pubDate>Sat, 15 Mar 2025 13:05:34 +0000</pubDate>
      <guid>http://programmer.ie/post/dataset/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Machine learning operates on data. Essentially, it processes data to extract meaningful information, which can then be used to make intelligent decisions. This is the foundation of Artificial Intelligence.&#xA;The more data you have the better your machine learning apps will be. There is a caveat though the data has to be high quality. The more data you have and the higher quality the better your apps will be.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Detecting AI-Generated Text: Challenges and Solutions</title>
      <link>http://programmer.ie/post/aitext/</link>
      <pubDate>Thu, 13 Mar 2025 13:28:24 +0000</pubDate>
      <guid>http://programmer.ie/post/aitext/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Artificial Intelligence (AI) has revolutionized the way we generate and consume text. From chatbots crafting customer responses to AI-authored articles, artificial intelligence is reshaping how we create and consume content. As AI-generated text becomes indistinguishable from human writing, distinguishing between the two has never been more critical. Here are some of the reasons it is important to be able to verify the source of information:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Preventing plagiarism&lt;/li&gt;&#xA;&lt;li&gt;Maintaining academic integrity&lt;/li&gt;&#xA;&lt;li&gt;Ensuring transparency in content creation&lt;/li&gt;&#xA;&lt;li&gt;If AI models are repeatedly trained on AI-generated text, their quality may degrade over time.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;In this blog post, we’ll explore the current most effective methods for detecting AI-generated text.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Shakespeare and the Bible: An AI Investigation</title>
      <link>http://programmer.ie/post/shakespeare/</link>
      <pubDate>Tue, 11 Mar 2025 22:47:36 +0000</pubDate>
      <guid>http://programmer.ie/post/shakespeare/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Could the greatest playwright of all time have secretly shaped one of the most influential religious texts in history? Some believe William Shakespeare left his mark on the King James Bible hidden in plain sight. With the power of AI, we’ll investigate whether there’s any truth to this conspiracy.&lt;/p&gt;&#xA;&lt;p&gt;You can read about the conspiracy here:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://www.eden.co.uk/blog/did-shakespeare-write-the-king-james-bible&#34;&gt;Did Shakespeare write the King James Bible?&lt;/a&gt;&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://quiteirregular.wordpress.com/2019/03/21/shakespeare-and-the-king-james-bible-some-tentative-conclusions/&#34;&gt;Shakespeare and the King James Bible – Some Tentative Conclusions&lt;/a&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>PostgreSQL for AI: Storing and Searching Embeddings with pgvector</title>
      <link>http://programmer.ie/post/pgvector/</link>
      <pubDate>Mon, 10 Mar 2025 21:35:37 +0000</pubDate>
      <guid>http://programmer.ie/post/pgvector/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Vector databases are essential for modern AI applications like semantic search, recommendation systems, and natural language processing. They allow us to store and query high-dimensional vectors efficiently. With the &lt;a href=&#34;https://github.com/pgvector/pgvector&#34;&gt;pgvector&lt;/a&gt; extension &lt;a href=&#34;https://www.postgresql.org/download/&#34;&gt;PostgreSQL&lt;/a&gt; becomes a powerful vector database, enabling you to combine traditional relational data with vector-based operations.&lt;/p&gt;&#xA;&lt;p&gt;In this post, we will walk through the full process:&lt;/p&gt;&#xA;&lt;p&gt;Installing PostgreSQL and pgvector&#xA;Setting up a vector-enabled database&#xA;Generating embeddings using Ollama&#xA;Running similarity queries with Python&#xA;By the end, you&amp;rsquo;ll be able to store, query, and compare high-dimensional vectors in PostgreSQL, opening up new possibilities for AI-powered applications.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Build Smarter AI: Leveraging the Model Context Protocol for Dynamic Context</title>
      <link>http://programmer.ie/post/mcp/</link>
      <pubDate>Thu, 06 Mar 2025 13:08:42 +0000</pubDate>
      <guid>http://programmer.ie/post/mcp/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;&lt;strong&gt;Summary&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;The &lt;strong&gt;evolution of technology&lt;/strong&gt; is driven by protocols structured ways for systems to communicate and interact. The internet, APIs, and even modern databases rely on &lt;strong&gt;protocols&lt;/strong&gt; to function efficiently. Similarly, as AI becomes more powerful, it needs a &lt;strong&gt;structured and standardized way to manage context&lt;/strong&gt; across interactions.&lt;/p&gt;&#xA;&lt;p&gt;Enter the &lt;strong&gt;Model Context Protocol (MCP)&lt;/strong&gt; a framework designed to &lt;strong&gt;enhance the way AI models understand, retain, and utilize context&lt;/strong&gt; over multiple exchanges. Large Language Models (LLMs) are powerful, but without &lt;strong&gt;effective context management&lt;/strong&gt;, they can:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Getting Started with Neo4j: Build Your First Knowledge Graph</title>
      <link>http://programmer.ie/post/neo4j/</link>
      <pubDate>Thu, 06 Mar 2025 08:37:29 +0000</pubDate>
      <guid>http://programmer.ie/post/neo4j/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;In AI and data science, knowledge graphs are powerful tools for modeling complex relationships between entities. They enable intelligent querying, recommendation systems, and semantic search. &lt;a href=&#34;https://github.com/neo4j/neo4j&#34;&gt;Neo4j&lt;/a&gt;, an open-source graph database, is one of the most popular tools for building and managing knowledge graphs.&lt;/p&gt;&#xA;&lt;p&gt;In this post, we&amp;rsquo;ll walk you through setting up Neo4j, configuring it for use as a knowledge graph, and manipulating the database using Python.&lt;/p&gt;&#xA;&lt;p&gt;&lt;img src=&#34;http://programmer.ie/img/kg_example.png&#34; alt=&#34;Knowledge Graph Example&#34;&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Beyond Text Generation: Coding Ollama Function Calls and Tools</title>
      <link>http://programmer.ie/post/functions/</link>
      <pubDate>Wed, 05 Mar 2025 09:07:59 +0000</pubDate>
      <guid>http://programmer.ie/post/functions/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Function calling allows Large Language Models (LLMs) to interact with APIs, databases, and other tools, making them more than just text generators.&lt;/p&gt;&#xA;&lt;p&gt;Integrating LLMs with functions enables you to harness their powerful text processing capabilities, seamlessly enhancing the technological solutions you develop.&lt;/p&gt;&#xA;&lt;p&gt;This post will explain how you can call local python functions and tools in &lt;a href=&#34;www.ollama.com&#34;&gt;Ollama&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;introduction-to-ollama-function-calling&#34;&gt;Introduction to Ollama Function Calling&lt;/h2&gt;&#xA;&lt;p&gt;Ollama allows you to run state-of-the-art LLMs like &lt;code&gt;Qwen&lt;/code&gt;, &lt;code&gt;Llama&lt;/code&gt;, and others locally without relying on cloud APIs. Its function-calling feature enables models to execute external Python functions, making it ideal for applications like chatbots, automation tools, and data-driven systems.&lt;/p&gt;</description>
    </item>
    <item>
      <title>From &#43;AI to AI&#43;: Embracing AI as the Foundation of Everything You Do</title>
      <link>http://programmer.ie/post/aiorai/</link>
      <pubDate>Fri, 28 Feb 2025 21:35:03 +0000</pubDate>
      <guid>http://programmer.ie/post/aiorai/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;What if AI isn’t just a tool but the foundation of how you work, create, and think?&lt;/p&gt;&#xA;&lt;p&gt;Today there are two distinct ways to approach AI: &lt;code&gt;+AI&lt;/code&gt; and &lt;code&gt;AI+&lt;/code&gt;. &lt;code&gt;+AI&lt;/code&gt; means integrating AI into an existing workflow, business, or process. It&amp;rsquo;s the approach discussed in countless books, YouTube videos, and business strategies. If you’re working, running a business, or earning money, this is the natural and logical way to use AI.&#xA;But this post isn&amp;rsquo;t about that. Instead this post is about &lt;code&gt;AI+&lt;/code&gt; a radically different approach where AI is the foundation of everything you do.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Building AI-Powered Applications with Haystack and Ollama</title>
      <link>http://programmer.ie/post/haystack/</link>
      <pubDate>Fri, 28 Feb 2025 13:58:16 +0000</pubDate>
      <guid>http://programmer.ie/post/haystack/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;In this post, I will demonstrate how to set up and use &lt;a href=&#34;https://haystack.deepset.ai/&#34;&gt;haystack&lt;/a&gt; with &lt;a href=&#34;https://ollama.com/&#34;&gt;Ollama&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;haystack&lt;/strong&gt; is a framework that helps when building applications powered by LLMs.&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;It offers extensive LLM-related functionality.&lt;/li&gt;&#xA;&lt;li&gt;It is open source under the Apache license.&lt;/li&gt;&#xA;&lt;li&gt;It is actively developed, with numerous contributors.&lt;/li&gt;&#xA;&lt;li&gt;It is widely used in production by various clients.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;These are some of the key items to watch for when using a library in a project.&lt;/p&gt;</description>
    </item>
    <item>
      <title>LiteLLM: A Lightweight Wrapper for Multi-Provider LLMs</title>
      <link>http://programmer.ie/post/litellm/</link>
      <pubDate>Mon, 24 Feb 2025 14:13:26 +0000</pubDate>
      <guid>http://programmer.ie/post/litellm/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;In this post I will cover &lt;a href=&#34;https://github.com/BerriAI/litellm&#34;&gt;&lt;strong&gt;LiteLLM&lt;/strong&gt;&lt;/a&gt;. I used it for my implementation of &lt;a href=&#34;http://programmer.ie/post/textgrad/&#34;&gt;Textgrad&lt;/a&gt; also it was using in blog posts I did about &lt;a href=&#34;http://programmer.ie/post/agents/&#34;&gt;Agents&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;Working with multiple LLM providers is painful. Every provider has its own API, requiring custom integration, different pricing models, and maintenance overhead.&#xA;LiteLLM solves this by offering a single, unified API that allows developers to switch between OpenAI, Hugging Face, Cohere, Anthropic, and others without modifying their code.&lt;/p&gt;</description>
    </item>
    <item>
      <title>🧠 TextGrad: Dynamic Optimization of Your LLM</title>
      <link>http://programmer.ie/post/textgrad/</link>
      <pubDate>Sun, 23 Feb 2025 21:47:10 +0000</pubDate>
      <guid>http://programmer.ie/post/textgrad/</guid>
      <description>&lt;h2 id=&#34;-summary&#34;&gt;🧩 &lt;strong&gt;Summary&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;This post aims to be a comprehensive tutorial on &lt;a href=&#34;https://github.com/zou-group/textgrad&#34;&gt;Textgrad&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;Textgrad enables the optimization of LLM&amp;rsquo;s using their text responses.&lt;/p&gt;&#xA;&lt;p&gt;This will be part of &lt;code&gt;SmartAnswer&lt;/code&gt; the ultimate LLM query tool which I will be blogging about shortly.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-why-textgrad&#34;&gt;❓ Why TextGrad?&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;🔄 Brings Gradient Descent to LLMs – Instead of numerical gradients, TextGrad leverages textual feedback to iteratively improve outputs.&lt;/li&gt;&#xA;&lt;li&gt;🤖 Automates Prompt Optimization – Eliminates the guesswork in refining LLM prompts.&lt;/li&gt;&#xA;&lt;li&gt;🌐 Works with Any LLM – From OpenAI&amp;rsquo;s GPT to local models like Ollama.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-what-is-textgrad&#34;&gt;🧠 &lt;strong&gt;What is TextGrad?&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;h3 id=&#34;-bringing-gradients-to-llm-optimization&#34;&gt;⚡ &lt;strong&gt;Bringing Gradients to LLM Optimization&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Traditional AI optimization techniques rely on numerical gradients computed via backpropagation. However in &lt;strong&gt;LLM-driven AI systems&lt;/strong&gt;, inputs and outputs are often text, making standard gradient computation impossible.&lt;/p&gt;</description>
    </item>
    <item>
      <title>The Power of Logits: Unlocking Smarter, Safer LLM Responses</title>
      <link>http://programmer.ie/post/logits/</link>
      <pubDate>Sun, 23 Feb 2025 20:51:48 +0000</pubDate>
      <guid>http://programmer.ie/post/logits/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;In this blog post&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;I want to fully explore &lt;code&gt;logits&lt;/code&gt; and how they can be used to enhance AI applications&lt;/li&gt;&#xA;&lt;li&gt;I want to understand the ideas from this paper: &lt;a href=&#34;https://arxiv.org/abs/2502.13962&#34;&gt;&lt;em&gt;&amp;ldquo;Is That Your Final Answer? Test-Time Scaling Improves Selective Question Answering&amp;rdquo;&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;This paper introduces a new approach, &lt;strong&gt;Selective Question Answering (SQA)&lt;/strong&gt;. This introduces confidence scores to decide when an answer should be given.&#xA;In this post, we’ll cover the core insights of the paper and implement a basic confidence-based selection function in Python.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Efficient Similarity Search with FAISS and SQLite in Python</title>
      <link>http://programmer.ie/post/faiss_db/</link>
      <pubDate>Sun, 23 Feb 2025 07:57:28 +0000</pubDate>
      <guid>http://programmer.ie/post/faiss_db/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;This is another component in &lt;code&gt;SmartAnswer&lt;/code&gt; and enhanced LLM interface.&lt;/p&gt;&#xA;&lt;p&gt;In this blog post, we introduce a wrapper class, &lt;code&gt;FaissDB&lt;/code&gt;, which integrates FAISS with SQLite or any database to manage document embeddings and enable efficient similarity search.&#xA;This approach combines FAISS&amp;rsquo;s vector search capabilities with the storage and querying power of a database, making it ideal for applications such as Retrieval-Augmented Generation (RAG) and recommendation systems.&lt;/p&gt;&#xA;&lt;p&gt;It builds up this tool &lt;a href=&#34;http://programmer.ie/post/paper_search/&#34;&gt;PaperSearch&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Automating Paper Retrieval and Processing with PaperSearch</title>
      <link>http://programmer.ie/post/paper_search/</link>
      <pubDate>Sat, 22 Feb 2025 07:28:15 +0000</pubDate>
      <guid>http://programmer.ie/post/paper_search/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;This is part on in a series of blog post working towards &lt;code&gt;SmartAnswer&lt;/code&gt; a comprehensive improvement to how &lt;code&gt;Large Language Models&lt;/code&gt; LLMs answer questions.&lt;/p&gt;&#xA;&lt;p&gt;This tool will be the source of data for &lt;code&gt;SmartAnswer&lt;/code&gt; and allow it to find and research better data when generating answers.&lt;/p&gt;&#xA;&lt;p&gt;I want this tool to be included in that solution but I dot want all the code from this tool distracting from the &lt;code&gt;SmartAnswer&lt;/code&gt; solution. Hence this post.&lt;/p&gt;</description>
    </item>
    <item>
      <title>SQLite: the small database that packs a big punch</title>
      <link>http://programmer.ie/post/sqlite/</link>
      <pubDate>Thu, 20 Feb 2025 07:54:29 +0000</pubDate>
      <guid>http://programmer.ie/post/sqlite/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://www.sqlite.org/index.html&#34;&gt;SQLite&lt;/a&gt; is one of the most widely used database engines in the world, powering everything from mobile applications (Android, iOS) to browsers (Google Chrome, Mozilla Firefox), IoT devices, and even gaming consoles. Unlike traditional client-server databases (e.g., MySQL, PostgreSQL), SQLite is an embedded, serverless database that stores data in a single file, making it easy to manage and deploy.&lt;/p&gt;&#xA;&lt;p&gt;Python developers frequently choose SQLite for its inherent simplicity and portability, leveraging the built-in sqlite3 module for effortless database integration.&lt;/p&gt;</description>
    </item>
    <item>
      <title>RAFT: Reward rAnked FineTuning - A New Approach to Generative Model Alignment</title>
      <link>http://programmer.ie/post/raft/</link>
      <pubDate>Wed, 19 Feb 2025 14:48:58 +0000</pubDate>
      <guid>http://programmer.ie/post/raft/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;This post is an explanation of this paper:&lt;a href=&#34;https://arxiv.org/abs/2304.06767&#34;&gt;RAFT: Reward rAnked FineTuning for Generative Foundation Model Alignment&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;Generative foundation models, such as &lt;strong&gt;Large Language Models (LLMs)&lt;/strong&gt; and &lt;strong&gt;diffusion models&lt;/strong&gt;, have revolutionized AI by achieving human-like content generation.&#xA;However, they often suffer from&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;Biases – Models can learn and reinforce societal biases present in the training data (e.g., gender, racial, or cultural stereotypes).&lt;/li&gt;&#xA;&lt;li&gt;Ethical Concerns – AI-generated content can be misused for misinformation, deepfakes, or spreading harmful narratives.&lt;/li&gt;&#xA;&lt;li&gt;Alignment Issues – The model’s behavior may not match human intent, leading to unintended or harmful outputs despite good intentions.&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;Traditionally, &lt;strong&gt;Reinforcement Learning from Human Feedback (RLHF)&lt;/strong&gt; has been used to align these models, but RLHF comes with stability and efficiency challenges.&#xA;To address these limitations, &lt;strong&gt;RAFT (Reward rAnked FineTuning)&lt;/strong&gt; was introduced as a more stable and scalable alternative. RAFT fine-tunes models using a &lt;strong&gt;ranking-based approach&lt;/strong&gt; to filter high-reward samples, allowing generative models to improve without complex reinforcement learning setups.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Faiss: A Fast, Efficient Similarity Search Library</title>
      <link>http://programmer.ie/post/faiss/</link>
      <pubDate>Mon, 17 Feb 2025 08:16:15 +0000</pubDate>
      <guid>http://programmer.ie/post/faiss/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Searching through massive datasets efficiently is a challenge, whether in image retrieval, recommendation systems, or semantic search. &lt;a href=&#34;https://github.com/facebookresearch/faiss&#34;&gt;Faiss&lt;/a&gt; (&lt;code&gt;Facebook AI Similarity Search&lt;/code&gt;) is a powerful open-source library developed by Meta to handle high-dimensional similarity search at scale.&lt;/p&gt;&#xA;&lt;p&gt;It&amp;rsquo;s well-suited for tasks like:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Image search:&lt;/strong&gt; Finding visually similar images in a large database.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Recommendation systems:&lt;/strong&gt; Recommending items (products, movies, etc.) to users based on their preferences.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Semantic search:&lt;/strong&gt; Finding documents or text passages that are semantically similar to a given query.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Clustering:&lt;/strong&gt; Grouping similar vectors together.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;In many of the upcoming projects in this blog I will be using it. It is a good local developer solution.&lt;/p&gt;</description>
    </item>
    <item>
      <title>K-Means Clustering</title>
      <link>http://programmer.ie/post/kmeans/</link>
      <pubDate>Mon, 17 Feb 2025 06:52:23 +0000</pubDate>
      <guid>http://programmer.ie/post/kmeans/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Imagine you have a dataset of customer profiles.&#xA;How can you group similar customers together to tailor marketing campaigns?&#xA;This is where K-Means clustering comes into play.&lt;/p&gt;&#xA;&lt;p&gt;K-Means is a popular &lt;code&gt;unsupervised&lt;/code&gt; learning algorithm used for clustering data points into distinct groups based on their similarities.&#xA;It is widely used in various domains such as customer segmentation, image compression, and anomaly detection.&lt;/p&gt;&#xA;&lt;p&gt;In this blog post, we&amp;rsquo;ll cover how K-Means works and demonstrate its implementation in Python using &lt;code&gt;scikit-learn&lt;/code&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>AI: The Future Interface to Technology</title>
      <link>http://programmer.ie/post/ai_is_the_interface/</link>
      <pubDate>Fri, 14 Feb 2025 12:58:51 +0000</pubDate>
      <guid>http://programmer.ie/post/ai_is_the_interface/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Imagine a world where you simply think of a task, and invisible devices seamlessly execute it. In fact most of what used to be your daily tasks you won&amp;rsquo;t even think about they will be automatically executed. Sounds like science fiction? This I believe is the future of human technology interaction. The technology disappears behind an AI driven interface.&lt;/p&gt;&#xA;&lt;h2 id=&#34;do-we-currently-have-artificial-intelligence&#34;&gt;Do we currently have Artificial Intelligence&lt;/h2&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;Artificial intelligence refers to computer programs designed to mimic human cognitive abilities, &#xA;such as understanding natural language, recognizing patterns, learning from data, and solving complex problems.&#xA;While AGI aims to replicate general human intelligence, &#xA;narrow AI focuses on excelling at specific tasks within predefined parameters.&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;A common debate in AI discourse revolves around whether large language models (LLMs) truly qualify as artificial intelligence or if they are merely sophisticated algorithms mimicking human-like behavior. While discussions about &lt;code&gt;Artificial General Intelligence&lt;/code&gt; (AGI) a theoretical form of AI capable of replicating human cognition across all domains are intriguing, they distract from the practical applications of AI that already exist today. AGI may never materialize, not because it’s unachievable, but because it lacks practical utility. A godlike AI with unrestricted capabilities offers little tangible benefit compared to specialized narrow AI systems.&#xA;Instead, what we have now is &lt;strong&gt;narrow AI&lt;/strong&gt;, which excels at specific tasks and operates within defined parameters. This AI can get broader through the use of Agents and can automatically self improve and learn as I have shown in previous blog posts.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Self-Learning LLMs for Stock Forecasting: A Python Implementation with Direct Preference Optimization</title>
      <link>http://programmer.ie/post/self_learning/</link>
      <pubDate>Thu, 13 Feb 2025 14:22:06 +0000</pubDate>
      <guid>http://programmer.ie/post/self_learning/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Forecasting future events is a critical task in fields like finance, politics, and technology. However, improving the forecasting abilities of large language models (LLMs) often requires extensive human supervision.&#xA;In this post, we explore a novel approach from the paper &lt;a href=&#34;https://arxiv.org/abs/2502.05253&#34;&gt;LLMs Can Teach Themselves to Better Predict the Future&lt;/a&gt; that enables LLMs to teach themselves better forecasting skills using self-play and Direct Preference Optimization (DPO). We&amp;rsquo;ll walk through a Python implementation of this method, step by step.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Using Quantization to speed up and slim down your LLM</title>
      <link>http://programmer.ie/post/quantization/</link>
      <pubDate>Wed, 12 Feb 2025 11:07:50 +0000</pubDate>
      <guid>http://programmer.ie/post/quantization/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Large Language Models (LLMs) are powerful, but their size can lead to slow inference speeds and high memory consumption, hindering real-world deployment. Quantization, a technique that reduces the precision of model weights, offers a powerful solution.&#xA;This post will explore how to use quantization techniques like &lt;code&gt;bitsandbytes&lt;/code&gt;, &lt;code&gt;AutoGPTQ&lt;/code&gt;, and &lt;code&gt;AutoRound&lt;/code&gt; to dramatically improve LLM inference performance.&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-is-quantization&#34;&gt;What is Quantization?&lt;/h2&gt;&#xA;&lt;p&gt;Quantization reduces the computational and storage demands of a model by representing its weights with lower-precision data types.&#xA;Lets imagine data is water and we hold that water in buckets, most of the time we don&amp;rsquo;t need massive floating point buckets to hold data that can be represented by integers.&#xA;&lt;code&gt;Quantization&lt;/code&gt; is using smaller buckets to hold the same amount of water – you save space and can move the containers more quickly. &lt;code&gt;Quantization&lt;/code&gt; trades a tiny amount of precision for significant gains in speed and memory efficiency.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Mastering LLM Fine-Tuning: A Practical Guide with LLaMA-Factory and LoRA</title>
      <link>http://programmer.ie/post/fine_tuning/</link>
      <pubDate>Wed, 12 Feb 2025 07:07:50 +0000</pubDate>
      <guid>http://programmer.ie/post/fine_tuning/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Large Language Models (LLMs) offer immense potential, but realizing that potential often requires fine-tuning them on task-specific data. This guide provides a comprehensive overview of LLM fine-tuning, focusing on practical implementation with &lt;code&gt;LLaMA-Factory&lt;/code&gt; and the powerful LoRA technique.&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-is-fine-tuning&#34;&gt;What is Fine-Tuning?&lt;/h2&gt;&#xA;&lt;p&gt;Fine-tuning adapts a pre-trained model to a new, specific task or dataset.  It leverages the general knowledge already learned by the model from a massive dataset (&lt;code&gt;source domain&lt;/code&gt;) and refines it with a smaller, more specialized dataset (&lt;code&gt;target domain&lt;/code&gt;). This approach saves time, resources, and data while often achieving superior performance.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Debugging Jupyter Notebooks in VS Code</title>
      <link>http://programmer.ie/post/debugging/</link>
      <pubDate>Tue, 11 Feb 2025 11:48:38 +0000</pubDate>
      <guid>http://programmer.ie/post/debugging/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://code.visualstudio.com/&#34;&gt;Visual Studio Code&lt;/a&gt; is the most popular editor for development.&lt;/p&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://jupyter.org/&#34;&gt;Jupyter Notebooks&lt;/a&gt; is the most widely used way to share, demonstrate and develop code in modern AI development.&lt;/p&gt;&#xA;&lt;p&gt;Debugging code is not just used when you have a bug. After you have written any substantial piece of code I suggest  stepping through it in the debugger if possible. This can help improve you understanding and the quality of the code you have written&lt;/p&gt;</description>
    </item>
    <item>
      <title>DeepResearch Part 3: Getting the best web data for your research</title>
      <link>http://programmer.ie/post/deepresearch3/</link>
      <pubDate>Sat, 08 Feb 2025 18:46:58 +0000</pubDate>
      <guid>http://programmer.ie/post/deepresearch3/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;This post details building a robust web data pipeline using SmolAgents. We&amp;rsquo;ll create tools to retrieve content from various web endpoints, convert it to a consistent format (Markdown), store it efficiently, and then evaluate its relevance and quality using Large Language Models (LLMs). This pipeline is crucial for building a knowledge base for LLM applications.&lt;/p&gt;&#xA;&lt;h3 id=&#34;web-data-convertor-markdownconverter&#34;&gt;Web Data Convertor (&lt;code&gt;MarkdownConverter&lt;/code&gt;)&lt;/h3&gt;&#xA;&lt;p&gt;We leverage the &lt;code&gt;MarkdownConverter&lt;/code&gt; class, inspired by the one in &lt;a href=&#34;https://github.com/microsoft/autogen/blob/v0.4.4/python/packages/autogen-magentic-one/src/autogen_magentic_one/markdown_browser/mdconvert.py&#34;&gt;&lt;code&gt;autogen&lt;/code&gt;&lt;/a&gt;, to handle the diverse formats encountered on the web. This ensures consistency for downstream processing.&lt;/p&gt;</description>
    </item>
    <item>
      <title>DeepResearch Part 2: Building a RAG Tool for arXiv PDFs</title>
      <link>http://programmer.ie/post/deepresearch2/</link>
      <pubDate>Fri, 07 Feb 2025 19:33:51 +0000</pubDate>
      <guid>http://programmer.ie/post/deepresearch2/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;In this post, we&amp;rsquo;ll build a Retrieval Augmented Generation (RAG) tool to process the PDF files downloaded from arXiv in the previous post &lt;a href=&#34;http://programmer.ie/post/deepresearch1/&#34;&gt;DeepResearch Part 1&lt;/a&gt;.&#xA;This RAG tool will be capable of loading, processing, and semantically searching the document content.&#xA;It&amp;rsquo;s a versatile tool applicable to various text sources, including web pages.&lt;/p&gt;&#xA;&lt;h3 id=&#34;building-the-rag-tool&#34;&gt;Building the RAG Tool&lt;/h3&gt;&#xA;&lt;p&gt;Following up on our arXiv downloader, we now need a tool to process the downloaded PDF&amp;rsquo;s. This post details the creation of such a tool.&lt;/p&gt;</description>
    </item>
    <item>
      <title>DeepResearch Part 1: Building an arXiv Search Tool with SmolAgents</title>
      <link>http://programmer.ie/post/deepresearch1/</link>
      <pubDate>Fri, 07 Feb 2025 08:33:23 +0000</pubDate>
      <guid>http://programmer.ie/post/deepresearch1/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;This post kicks off a series of three where we&amp;rsquo;ll build, extend, and use the open-source DeepResearch application inspired by the &lt;a href=&#34;https://huggingface.co/blog/open-deep-research&#34;&gt;Hugging Face blog post&lt;/a&gt;.  In this first part, we&amp;rsquo;ll focus on creating an arXiv search tool that can be used with SmolAgents.&lt;/p&gt;&#xA;&lt;p&gt;DeepResearch aims to empower research by providing tools that automate and streamline the process of discovering and managing academic papers. This series will demonstrate how to build such tools, starting with a powerful arXiv search tool.&lt;/p&gt;</description>
    </item>
    <item>
      <title>FFmpeg: A Practical Guide to Essential Command-Line Options</title>
      <link>http://programmer.ie/post/ffmpeg/</link>
      <pubDate>Thu, 06 Feb 2025 13:38:55 +0000</pubDate>
      <guid>http://programmer.ie/post/ffmpeg/</guid>
      <description>&lt;h3 id=&#34;introduction&#34;&gt;Introduction&lt;/h3&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://ffmpeg.org/&#34;&gt;FFmpeg&lt;/a&gt; is an incredibly versatile command-line tool for manipulating audio and video files. This post provides a practical collection of useful FFmpeg commands for common tasks.&lt;/p&gt;&#xA;&lt;h3 id=&#34;ffmpeg-command-structure&#34;&gt;FFmpeg Command Structure&lt;/h3&gt;&#xA;&lt;p&gt;The general structure of an FFmpeg command is:&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;ffmpeg [global_options] {[input_file_options] -i input_url} ... {[output_file_options] output_url} ...&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;h3 id=&#34;merging-video-and-audio&#34;&gt;Merging Video and Audio&lt;/h3&gt;&#xA;&lt;h4 id=&#34;merging-video-and-audio-with-audio-re-encoding&#34;&gt;Merging video and audio, with audio re-encoding&lt;/h4&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;ffmpeg -i video.mp4 -i audio.wav -c:v copy -c:a aac output.mp4&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;h4 id=&#34;copying-the-audio-without-re-encoding&#34;&gt;Copying the audio without re-encoding&lt;/h4&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;ffmpeg -i video.mp4 -i audio.wav -c copy output.mkv&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;Why copy audio?&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Writing Neural Networks with PyTorch</title>
      <link>http://programmer.ie/post/pytorch/</link>
      <pubDate>Thu, 06 Feb 2025 08:44:07 +0000</pubDate>
      <guid>http://programmer.ie/post/pytorch/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;This post provides a practical guide to building common neural network architectures using PyTorch. We&amp;rsquo;ll explore &lt;code&gt;feedforward&lt;/code&gt; networks, &lt;code&gt;convolutional&lt;/code&gt; neural networks (CNNs), &lt;code&gt;recurrent&lt;/code&gt; neural networks (RNNs), &lt;code&gt;LSTM&lt;/code&gt;s, &lt;code&gt;transformers&lt;/code&gt;, &lt;code&gt;autoencoders&lt;/code&gt;, and &lt;code&gt;GAN&lt;/code&gt;s, along with code examples and explanations.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;1-understanding-pytorch&#34;&gt;&lt;strong&gt;1️⃣ Understanding PyTorch&amp;rsquo;s Neural Network Module&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;PyTorch provides the &lt;code&gt;torch.nn&lt;/code&gt; module to build neural networks.&#xA;It provides classes for defining layers, &lt;a href=&#34;http://programmer.ie/post/activation/&#34;&gt;activation functions&lt;/a&gt;, and loss functions, making it easy to create and manage complex network architectures in a structured way.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Mastering Prompt Engineering: A Practical Guide</title>
      <link>http://programmer.ie/post/prompt/</link>
      <pubDate>Wed, 05 Feb 2025 14:58:04 +0000</pubDate>
      <guid>http://programmer.ie/post/prompt/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;This post provides a comprehensive guide to prompt engineering, the art of crafting effective inputs for Large Language Models (LLMs).  Mastering prompt engineering is crucial for maximizing the potential of LLMs and achieving desired results.&lt;/p&gt;&#xA;&lt;p&gt;Effective prompting is the easiest way to enhance your experience with &lt;code&gt;Large Language Models&lt;/code&gt; (LLMs).&lt;/p&gt;&#xA;&lt;p&gt;The prompts we make are our interface to LLMs. This is how we communicate with them. This is why it is important to understand how to do it well.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Harnessing the Power of Stable Diffusion WebUI</title>
      <link>http://programmer.ie/post/sd_webui/</link>
      <pubDate>Wed, 05 Feb 2025 12:39:16 +0000</pubDate>
      <guid>http://programmer.ie/post/sd_webui/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;In this blog I aim to try building using open source tools where possible. The benefits are price, control, knowledge and eventually quality.&#xA;In the shorter term though the quality will trail the paid versions.&#xA;My belief is we can construct AI applications to be &lt;code&gt;self correcting&lt;/code&gt; sort of like how your camera auto focuses for you. This process will involve a lot of computation so using a paid service could be costly. This for me is the key reason to choose solutions using free tools.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Creating AI-Powered Paper Videos: From Research to YouTube</title>
      <link>http://programmer.ie/post/wav_to_text/</link>
      <pubDate>Fri, 31 Jan 2025 11:09:13 +0000</pubDate>
      <guid>http://programmer.ie/post/wav_to_text/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;This post demonstrates how to automatically transform a scientific paper (or any text/audio content) into a YouTube video using AI.  We&amp;rsquo;ll leverage several powerful tools, including large language models (LLMs), Whisper for transcription, Stable Diffusion for image generation, and FFmpeg for video assembly. This process can streamline content creation and make research more accessible.&lt;/p&gt;&#xA;&lt;h2 id=&#34;overview&#34;&gt;Overview&lt;/h2&gt;&#xA;&lt;p&gt;Our pipeline involves these steps:&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&lt;strong&gt;Audio Generation (Optional):&lt;/strong&gt; If starting from a text document, we&amp;rsquo;ll use a text-to-speech service (like NotebookLM, or others) to create an audio narration.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Transcription:&lt;/strong&gt; We&amp;rsquo;ll use Whisper to transcribe the audio into text, including timestamps for each segment.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Database Storage:&lt;/strong&gt; The transcribed text, timestamps, and metadata will be stored in an SQLite database for easy management.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Text Chunking:&lt;/strong&gt; We&amp;rsquo;ll divide the transcript into logical chunks (e.g., by sentence or time duration).&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Concept Summarization:&lt;/strong&gt; An LLM will summarize the core concept of each chunk.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Image Prompt Generation:&lt;/strong&gt; Another LLM will create a detailed image prompt based on the summary.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Image Generation:&lt;/strong&gt; Stable Diffusion (or a similar tool) will generate images from the prompts.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Video Assembly:&lt;/strong&gt; FFmpeg will combine the images and audio into a final video.&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;h2 id=&#34;prerequisites&#34;&gt;Prerequisites&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Hugging Face CLI:&lt;/strong&gt; Install it to download the Whisper model: &lt;code&gt;pip install huggingface_hub&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Whisper:&lt;/strong&gt;  Install the &lt;code&gt;whisper-timestamped&lt;/code&gt; package, or your preferred Whisper implementation.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Ollama:&lt;/strong&gt; You&amp;rsquo;ll need a running instance of Ollama to access the LLMs.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Stable Diffusion WebUI (or similar):&lt;/strong&gt;  For image generation.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;FFmpeg:&lt;/strong&gt; For video and audio processing. Ensure it&amp;rsquo;s in your system&amp;rsquo;s PATH.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Python Libraries:&lt;/strong&gt; Install necessary Python packages: &lt;code&gt;pip install pydub sqlite3 requests Pillow&lt;/code&gt; (and any others as needed).&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;1-audio-generation-optional&#34;&gt;1️⃣ Audio Generation (Optional)&lt;/h2&gt;&#xA;&lt;p&gt;If you&amp;rsquo;re starting with a text document, you&amp;rsquo;ll need to convert it to audio. Several cloud services and libraries can do this.  For this example, we&amp;rsquo;ll assume you have an audio file (&lt;code&gt;audio.wav&lt;/code&gt;).&lt;/p&gt;</description>
    </item>
    <item>
      <title>Fast Poisson Disk Sampling in Arbitrary Dimensions</title>
      <link>http://programmer.ie/post/poisson/</link>
      <pubDate>Tue, 28 Jan 2025 15:01:00 +0000</pubDate>
      <guid>http://programmer.ie/post/poisson/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;In this post I explore Robert Bridson&amp;rsquo;s paper:&#xA;&lt;a href=&#34;https://www.cs.ubc.ca/~rbridson/docs/bridson-siggraph07-poissondisk.pdf&#34;&gt;Fast Poisson Disk Sampling in Arbitrary Dimensions&lt;/a&gt; and provide an example python implementation.&#xA;Additionally, I introduce an alternative method using &lt;code&gt;Cellular Automata&lt;/code&gt; to generate Poisson disk distributions.&lt;/p&gt;&#xA;&lt;p&gt;Poisson disk sampling is a widely used technique in computer graphics, particularly for applications like rendering, texture generation, and particle simulation. Its appeal lies in producing sample distributions with &amp;ldquo;blue noise&amp;rdquo; characteristics—random yet evenly spaced, avoiding clustering.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Activation Functions</title>
      <link>http://programmer.ie/post/activation/</link>
      <pubDate>Tue, 28 Jan 2025 09:16:10 +0000</pubDate>
      <guid>http://programmer.ie/post/activation/</guid>
      <description>&lt;h3 id=&#34;introduction&#34;&gt;Introduction&lt;/h3&gt;&#xA;&lt;p&gt;Activation functions are a component of neural networks they introduce non-linearity into the model, enabling it to learn complex patterns. Without activation functions, a neural network would essentially act as a linear model, regardless of its depth.&lt;/p&gt;&#xA;&lt;h4 id=&#34;key-properties-of-activation-functions&#34;&gt;Key Properties of Activation Functions&lt;/h4&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Non-linearity&lt;/strong&gt;: Enables the model to learn complex relationships.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Differentiability&lt;/strong&gt;: Allows backpropagation to optimize weights.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Range&lt;/strong&gt;: Defines the output range, impacting gradient flow.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;In this post I will outline each of the most common activation functions how they are calculated and when they should be used.&lt;/p&gt;</description>
    </item>
    <item>
      <title>SVM Support Vector Machine an introduction</title>
      <link>http://programmer.ie/post/svm/</link>
      <pubDate>Mon, 27 Jan 2025 14:41:41 +0000</pubDate>
      <guid>http://programmer.ie/post/svm/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;In this post I will implement a Support Vector Machine (SVM) in python. Then describe what it does how it does it and some applications of the instrument.&lt;/p&gt;&#xA;&lt;h4 id=&#34;what-are-support-vector-machines-svm&#34;&gt;&lt;strong&gt;What Are Support Vector Machines (SVM)?&lt;/strong&gt;&lt;/h4&gt;&#xA;&lt;p&gt;Support Vector Machines (SVM) are supervised learning algorithms used for classification and regression tasks. Their strength lies in handling both linear and non-linear problems effectively. By finding the optimal hyperplane that separates classes, SVMs maximize the margin between data points of different classes, making them highly effective in high-dimensional spaces.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Color wars: Cellular Automata fight until one dominates</title>
      <link>http://programmer.ie/post/color_wars/</link>
      <pubDate>Tue, 21 Jan 2025 11:53:56 +0000</pubDate>
      <guid>http://programmer.ie/post/color_wars/</guid>
      <description>&lt;h3 id=&#34;summary&#34;&gt;Summary&lt;/h3&gt;&#xA;&lt;p&gt;This post is about color wars: a grid containing dynamic automata at war until one dominates.&lt;/p&gt;&#xA;&lt;h3 id=&#34;implementation&#34;&gt;&lt;strong&gt;Implementation&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;The implementation consists of two core components: the &lt;strong&gt;Grid&lt;/strong&gt; and the &lt;strong&gt;CellularAutomaton&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;h4 id=&#34;1-cellularautomaton-class&#34;&gt;&lt;strong&gt;1️⃣ CellularAutomaton Class&lt;/strong&gt;&lt;/h4&gt;&#xA;&lt;p&gt;The &lt;code&gt;CellularAutomaton&lt;/code&gt; class represents individual entities in the grid. Each automaton has:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Attributes&lt;/strong&gt;: ID, strength, age, position.&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Behavior&lt;/strong&gt;: Updates itself by aging, reproducing, or dying based on simple rules.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h4 id=&#34;2-grid-class&#34;&gt;&lt;strong&gt;2️⃣ Grid Class&lt;/strong&gt;&lt;/h4&gt;&#xA;&lt;p&gt;The &lt;code&gt;Grid&lt;/code&gt; manages a collection of automata. It:&lt;/p&gt;</description>
    </item>
    <item>
      <title>More Machine Learning Questions and Answers with Python examples</title>
      <link>http://programmer.ie/post/questions2/</link>
      <pubDate>Mon, 20 Jan 2025 20:25:03 +0000</pubDate>
      <guid>http://programmer.ie/post/questions2/</guid>
      <description>&lt;h3 id=&#34;44-what-does-it-mean-to-fit-a-model&#34;&gt;&lt;strong&gt;44. What does it mean to Fit a Model?&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;&lt;strong&gt;Answer&lt;/strong&gt;&lt;br&gt;&#xA;&lt;strong&gt;Fitting a model&lt;/strong&gt; refers to the process of adjusting the model&amp;rsquo;s internal parameters to best match the given training data. It&amp;rsquo;s like tailoring a suit – you adjust the fabric and stitching to make it fit the wearer perfectly.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Key Terms:&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Model:&lt;/strong&gt; A mathematical representation that captures patterns in data. Examples include linear regression, decision trees, neural networks, etc.&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Parameters:&lt;/strong&gt; These are the internal variables within the model that determine its behavior. For instance:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cellular Automata: Traffic Flow Simulation using the Nagel-Schreckenberg Model</title>
      <link>http://programmer.ie/post/traffic/</link>
      <pubDate>Sat, 18 Jan 2025 16:38:07 +0000</pubDate>
      <guid>http://programmer.ie/post/traffic/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;The &lt;strong&gt;Nagel-Schreckenberg (NaSch) model&lt;/strong&gt; is a traffic flow model which uses used cellular automata to simulate and predict traffic on roads.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;design-of-the-nagel-schreckenberg-model&#34;&gt;&lt;strong&gt;Design of the Nagel-Schreckenberg Model&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Discrete Space and Time:&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;The road is divided into &lt;strong&gt;cells&lt;/strong&gt;, each representing a fixed length (e.g., a few meters).&lt;/li&gt;&#xA;&lt;li&gt;Time advances in discrete steps.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Vehicle Representation:&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Each cell is either &lt;strong&gt;empty&lt;/strong&gt; or occupied by a single vehicle.&lt;/li&gt;&#xA;&lt;li&gt;Each vehicle has a &lt;strong&gt;velocity&lt;/strong&gt; (an integer) which determines how many cells it moves in a single time step.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;h3 id=&#34;rules-of-the-model&#34;&gt;&lt;strong&gt;Rules of the Model:&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;The NaSch model uses &lt;strong&gt;local rules&lt;/strong&gt; to update the state of each vehicle at every time step. These rules are:&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Acceleration&lt;/strong&gt;:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Simulate Gastropod Shell Growth Using Cellular Automata</title>
      <link>http://programmer.ie/post/shell/</link>
      <pubDate>Sat, 18 Jan 2025 03:03:36 +0000</pubDate>
      <guid>http://programmer.ie/post/shell/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;I started with this paper &lt;a href=&#34;https://royalsocietypublishing.org/doi/epdf/10.1098/rsif.2019.0721&#34;&gt;A developmentally descriptive method forquantifying shape in gastropod shells&lt;/a&gt;&#xA;and bridged the results to a cellular automata approach.&lt;/p&gt;&#xA;&lt;p&gt;An example of the shell we are modelling: &lt;img src=&#34;http://programmer.ie/img/Turritella_communis_fossiel.jpg&#34; alt=&#34;Shell Shape&#34;&gt;&lt;/p&gt;&#xA;&lt;h2 id=&#34;steps&#34;&gt;Steps&lt;/h2&gt;&#xA;&lt;h3 id=&#34;1-identify-the-key-biological-features&#34;&gt;&lt;strong&gt;1️⃣ Identify the Key Biological Features&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;The paper outlines the &lt;strong&gt;logarithmic helicospiral model&lt;/strong&gt; for shell growth, where:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;The shell grows outward and upward in a spiral shape.&lt;/li&gt;&#xA;&lt;li&gt;Parameters like width growth (\(g_w\)), height growth (\(g_h\)), and aperture shape dictate the final form.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;These features describe how the shell expands over time in a predictable geometric pattern.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cellular Automata: Introduction</title>
      <link>http://programmer.ie/post/ca/</link>
      <pubDate>Thu, 16 Jan 2025 00:21:05 +0000</pubDate>
      <guid>http://programmer.ie/post/ca/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;This page is the first in a series of posts about Cellular Automata.&lt;/p&gt;&#xA;&lt;p&gt;I believe that we could get the first evidence of AI through cellular automata.&lt;/p&gt;&#xA;&lt;p&gt;A recent paper &lt;a href=&#34;https://arxiv.org/pdf/2410.02536&#34;&gt;Intelligence at the Edge of Chaos&lt;/a&gt; found that LLM&amp;rsquo;s trained on more complex data generate better results. Which makes sense in a human context like the harder the material is I study the smarter I get. We need to find out why this is also the case with machines. The conjecture of this paper is that creating intelligence may require only exposure to complexity.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Rag: Retrieval-Augmented Generation </title>
      <link>http://programmer.ie/post/rag/</link>
      <pubDate>Tue, 14 Jan 2025 14:40:59 +0000</pubDate>
      <guid>http://programmer.ie/post/rag/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;&lt;strong&gt;Summary&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;Retrieval-Augmented Generation (RAG) is a powerful technique that enhances large language models (LLMs) by allowing them to use external knowledge sources.&lt;/p&gt;&#xA;&lt;p&gt;An &lt;strong&gt;Artificial Intelligence (AI)&lt;/strong&gt; system consists of components working together to apply knowledge learned from data. Some common components of those systems are:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;&lt;strong&gt;Large Language Model (LLM)&lt;/strong&gt;: Typically the core component of the system, often there is more than one. These are large models that have been trained on massive amounts of data and can make intelligent predictions based on their training.&lt;/p&gt;</description>
    </item>
    <item>
      <title>CAG: Cache-Augmented Generation</title>
      <link>http://programmer.ie/post/cag/</link>
      <pubDate>Fri, 10 Jan 2025 20:32:03 +0000</pubDate>
      <guid>http://programmer.ie/post/cag/</guid>
      <description>&lt;h2 id=&#34;summary&#34;&gt;Summary&lt;/h2&gt;&#xA;&lt;p&gt;Retrieval-Augmented Generation (RAG) has become the dominant approach for integrating external knowledge into LLMs, helping models access information beyond their training data. However, RAG comes with limitations, such as retrieval latency, document selection errors, and system complexity. Cache-Augmented Generation (CAG) presents an alternative that improves performance but does not fully address the core challenge of small context windows.&lt;/p&gt;&#xA;&lt;p&gt;RAG has some drawbacks&#xA;- There can be significant retrieval latency as it searches for and organizes the correct data.&lt;br&gt;&#xA;- There can be errors in the documents/data it selects as results for a query. For example it may select the wrong document or give priority to the wrong document.&#xA;- It may introduce security and data issues &lt;a href=&#34;#references&#34;&gt;2️⃣&lt;/a&gt;.&lt;br&gt;&#xA;- It introduces complication&lt;br&gt;&#xA;- an external application to manage the data (Vector Database)&#xA;- a process to continually update this data when the data goes stale&lt;/p&gt;</description>
    </item>
    <item>
      <title>Agents: A tutorial on building agents in python</title>
      <link>http://programmer.ie/post/agents/</link>
      <pubDate>Tue, 07 Jan 2025 16:51:43 +0000</pubDate>
      <guid>http://programmer.ie/post/agents/</guid>
      <description>&lt;h2 id=&#34;llm-agents&#34;&gt;LLM Agents&lt;/h2&gt;&#xA;&lt;p&gt;Agents are used enhance and extend the functionality of LLM&amp;rsquo;s.&lt;/p&gt;&#xA;&lt;p&gt;In this tutorial, we’ll explore what LLM agents are, how they work, and how to implement them in Python.&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-are-llm-agents&#34;&gt;What Are LLM Agents?&lt;/h2&gt;&#xA;&lt;p&gt;An agent is an autonomous process that may use the LLM and other tools multiple times to achieve a goal.&#xA;The LLM output often controls the workflow of the agent(s).&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-is-the-difference-between-agents-and-llms-or-ai&#34;&gt;What is the difference between Agents and LLMs or AI?&lt;/h2&gt;&#xA;&lt;p&gt;Agents are processes that may use LLM&amp;rsquo;s and other agents to achieve a task.&#xA;Agents act as orchestrators or facilitators, combining various tools and logic, whereas LLMs are the underlying generative engines.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Courses: Free course on Agentic AI</title>
      <link>http://programmer.ie/post/courses/</link>
      <pubDate>Tue, 07 Jan 2025 16:11:41 +0000</pubDate>
      <guid>http://programmer.ie/post/courses/</guid>
      <description>&lt;h2 id=&#34;some-free-ai-courses-on-agents-i-recommend-doing&#34;&gt;Some FREE AI courses on Agents I recommend doing&lt;/h2&gt;&#xA;&lt;p&gt;Agents were important in Machine Learning development last year.&lt;/p&gt;&#xA;&lt;p&gt;These are some courses I have done and recommend they are all free.&lt;br&gt;&#xA;A good reason to do courses and look at youtube videos is you will learn current applications of AI and may get ideas for new applications.&lt;/p&gt;&#xA;&lt;h2 id=&#34;ai-agentic-design-patterns-with-autogen&#34;&gt;AI Agentic Design Patterns with AutoGen&lt;/h2&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://www.deeplearning.ai/short-courses/ai-agentic-design-patterns-with-autogen/&#34;&gt;AI Agentic Design Patterns with AutoGen&lt;/a&gt;&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Topics&lt;/strong&gt;: Agents, Microsoft, Autogen.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Ollama: The local LLM solution</title>
      <link>http://programmer.ie/post/ollama/</link>
      <pubDate>Mon, 06 Jan 2025 19:52:16 +0000</pubDate>
      <guid>http://programmer.ie/post/ollama/</guid>
      <description>&lt;h3 id=&#34;using-ollama&#34;&gt;&lt;strong&gt;Using Ollama&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;introduction&#34;&gt;&lt;strong&gt;Introduction&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Ollama is the best platform for running, managing, and interacting with Large Language Models (LLM) models locally.&#xA;For Python programmers, Ollama offers seamless integration and robust features for querying, manipulating, and deploying LLMs.&#xA;In this post I will explore how Python developers can leverage Ollama for powerful and efficient AI-based workflows.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;1-what-is-ollama&#34;&gt;&lt;strong&gt;1️⃣ What is Ollama?&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;Ollama is a tool designed to enable local hosting and interaction with LLMs. Unlike cloud-based APIs, Ollama prioritizes privacy and speed by running models directly on your machine. Key benefits include:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Hugo: A Static Site Generator</title>
      <link>http://programmer.ie/post/hugo/</link>
      <pubDate>Mon, 06 Jan 2025 17:34:21 +0000</pubDate>
      <guid>http://programmer.ie/post/hugo/</guid>
      <description>&lt;h1 id=&#34;hugo-a-static-site-generator&#34;&gt;Hugo: A Static Site Generator&lt;/h1&gt;&#xA;&lt;p&gt;In this post I give an introduction to what I think is the best static site generator: &lt;a href=&#34;https://gohugo.io/&#34;&gt;Hugo&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-is-hugo&#34;&gt;What is Hugo?&lt;/h2&gt;&#xA;&lt;p&gt;Hugo is an open-source static site generator written in Go. It takes structured content, often written in Markdown, and compiles it into static HTML, CSS, and JavaScript files.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;setting-up-hugo-a-quickstart-guide&#34;&gt;Setting Up Hugo: A Quickstart Guide&lt;/h2&gt;&#xA;&lt;p&gt;Follow these steps to set up your first Hugo site&lt;/p&gt;&#xA;&lt;h2 id=&#34;1-install-hugo&#34;&gt;**1️⃣ Install Hugo&lt;/h2&gt;&#xA;&lt;p&gt;First, ensure you have Hugo installed. Use your package manager of choice:&lt;/p&gt;</description>
    </item>
    <item>
      <title>ChromaDB: The Lightweight Open-Source Vector Database for AI Applications</title>
      <link>http://programmer.ie/post/chromadb/</link>
      <pubDate>Wed, 06 Mar 2024 14:08:42 +0000</pubDate>
      <guid>http://programmer.ie/post/chromadb/</guid>
      <description>&lt;h2 id=&#34;1-introduction&#34;&gt;&lt;strong&gt;1️⃣ Introduction&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;p&gt;In the era of AI-powered search, retrieval-augmented generation (RAG), and recommendation systems, efficient vector search is a necessity. While many vector databases exist, most require heavy infrastructure.&lt;/p&gt;&#xA;&lt;p&gt;Enter &lt;strong&gt;ChromaDB&lt;/strong&gt;: a lightweight, open-source vector database optimized for rapid prototyping and local AI applications.&lt;/p&gt;&#xA;&lt;h2 id=&#34;2-what-is-chromadb&#34;&gt;&lt;strong&gt;2️⃣ What is ChromaDB?&lt;/strong&gt;&lt;/h2&gt;&#xA;&lt;h3 id=&#34;definition&#34;&gt;&lt;strong&gt;Definition:&lt;/strong&gt;&lt;/h3&gt;&#xA;&lt;p&gt;ChromaDB is a &lt;strong&gt;vector database&lt;/strong&gt; for storing and querying embeddings. It provides an easy-to-use interface for AI developers to integrate similarity search into their applications.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 8: acdb a super fast database for Android</title>
      <link>http://programmer.ie/post/acdb/</link>
      <pubDate>Thu, 19 May 2016 23:45:48 +0100</pubDate>
      <guid>http://programmer.ie/post/acdb/</guid>
      <description>&lt;p&gt;An android implementation of [CDB] (&lt;a href=&#34;https://cr.yp.to/cdb.html&#34;&gt;https://cr.yp.to/cdb.html&lt;/a&gt;) database.&#xA;With some simple testing I am seeing a five to ten times increase in speed over Sqlite&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 7: FX-Trader</title>
      <link>http://programmer.ie/post/fx-trader/</link>
      <pubDate>Thu, 12 May 2016 23:45:48 +0100</pubDate>
      <guid>http://programmer.ie/post/fx-trader/</guid>
      <description>&lt;p&gt;A derivatives trading system. This is my attempt at building a derivatives trading system.&#xA;In this first post I am going to outline the goals of the project and some of the early design decisions.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 6: Validator</title>
      <link>http://programmer.ie/post/validator/</link>
      <pubDate>Thu, 28 Apr 2016 23:45:48 +0100</pubDate>
      <guid>http://programmer.ie/post/validator/</guid>
      <description>&lt;p&gt;A validation tool for excel files. Sometimes you need to export data from one system for loading into another. For instance&#xA;you may export a report from a derivatives trading system for information for a collateral management system.&lt;/p&gt;&#xA;&lt;p&gt;This Excel macro file validates input files to make sure that they are in a specific format.&#xA;The input file can be in any format that excel can load. The workbook will load the file and check for errors in place.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 5: Dictator</title>
      <link>http://programmer.ie/post/dictator/</link>
      <pubDate>Mon, 28 Mar 2016 23:45:48 +0100</pubDate>
      <guid>http://programmer.ie/post/dictator/</guid>
      <description>&lt;p&gt;Google have just released their speech API. One really cool feature is the ability to transcribe voice in real time.&#xA;Two years ago I built an app with this idea in mind. At that at the time I could no make it work. Now it is time to resurrect that app.&#xA;This post will cover the recording section of that application.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 4: Meth</title>
      <link>http://programmer.ie/post/meth/</link>
      <pubDate>Tue, 08 Mar 2016 20:46:38 +0000</pubDate>
      <guid>http://programmer.ie/post/meth/</guid>
      <description>&lt;p&gt;This is another simple android application. It does one thing&#xA;It keeps your phone awake.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 3: Site Shot</title>
      <link>http://programmer.ie/post/site_shot/</link>
      <pubDate>Wed, 03 Feb 2016 20:46:38 +0000</pubDate>
      <guid>http://programmer.ie/post/site_shot/</guid>
      <description>&lt;p&gt;This is a really simple android application. It does one thing&#xA;It takes a photo of a web site and allows you to share the photo.&lt;/p&gt;</description>
    </item>
    <item>
      <title>A script to generate android images</title>
      <link>http://programmer.ie/post/image_script/</link>
      <pubDate>Wed, 03 Feb 2016 20:27:15 +0000</pubDate>
      <guid>http://programmer.ie/post/image_script/</guid>
      <description>&lt;p&gt;This is a script I use in my android projects to generate different sized images.&lt;/p&gt;&#xA;&lt;p&gt;You can find the script here &lt;a href=&#34;https://github.com/ernan/vbscripts/process.vbs&#34; title=&#34;Process SVG Images for Android&#34;&gt;process.vbs&lt;/a&gt;&lt;/p&gt;&#xA;&lt;p&gt;So I build all my images in &lt;a href=&#34;https://inkscape.org/en/download/&#34; title=&#34;inkscape&#34;&gt;inkscape&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;p&gt;This is brilliant application.&lt;/p&gt;&#xA;&lt;p&gt;You can find some brilliant tutorials here &lt;a href=&#34;http://screencasters.heathenx.org/&#34; title=&#34;heathenx&#34;&gt;heathenx&lt;/a&gt;&lt;/p&gt;&#xA;&lt;p&gt;The script uses &lt;a href=&#34;https://inkscape.org/en/download/&#34; title=&#34;inkscape&#34;&gt;inkscape&lt;/a&gt; to convert the svg files to png images of&#xA;different sizes.&lt;/p&gt;&#xA;&lt;p&gt;The script also use &lt;a href=&#34;http://www.imagemagick.org/script/binary-releases.php&#34; title=&#34;ImageMagic&#34;&gt;imagemajic&lt;/a&gt; to format the pngs nicely.&lt;/p&gt;&#xA;&lt;p&gt;Finally it compresses the result using two png crushing programs&lt;/p&gt;</description>
    </item>
    <item>
      <title>A simple android log class</title>
      <link>http://programmer.ie/post/simple_log/</link>
      <pubDate>Mon, 01 Feb 2016 23:00:08 +0000</pubDate>
      <guid>http://programmer.ie/post/simple_log/</guid>
      <description>&lt;p&gt;This is a very simple log class I reuse in my projects&lt;/p&gt;&#xA;&lt;p&gt;It is  a hybrid of &lt;a href=&#34;https://github.com/JakeWharton/timber&#34; title=&#34;Timber&#34;&gt;Timber&lt;/a&gt; by Jake Wharton and the Log in&#xA;&lt;a href=&#34;https://github.com/nostra13/Android-Universal-Image-Loader&#34; title=&#34;Android Universal Image Loader&#34;&gt;Android Universal Image Loader&lt;/a&gt; by Sergey Tarasevich&lt;/p&gt;</description>
    </item>
    <item>
      <title>Everything</title>
      <link>http://programmer.ie/post/everything/</link>
      <pubDate>Sun, 31 Jan 2016 14:39:14 +0000</pubDate>
      <guid>http://programmer.ie/post/everything/</guid>
      <description>&lt;p&gt;I think that this tool is the best search tool for windows.&lt;/p&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://www.voidtools.com/downloads/&#34; title=&#34;Everything&#34;&gt;Everything&lt;/a&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>An android SharedPreferences wrapper class</title>
      <link>http://programmer.ie/post/android_settings/</link>
      <pubDate>Sun, 31 Jan 2016 00:08:26 +0000</pubDate>
      <guid>http://programmer.ie/post/android_settings/</guid>
      <description>&lt;p&gt;This is a wrapper around the Android &lt;a href=&#34;http://developer.android.com/reference/android/content/SharedPreferences.html&#34; title=&#34;SharedPreferences&#34;&gt;SharedPreferences&lt;/a&gt;&lt;/p&gt;&#xA;&lt;p&gt;It adds a few useful extensions&lt;/p&gt;</description>
    </item>
    <item>
      <title>Tools I use for this Blog</title>
      <link>http://programmer.ie/post/blog_tools/</link>
      <pubDate>Sat, 30 Jan 2016 19:19:19 +0000</pubDate>
      <guid>http://programmer.ie/post/blog_tools/</guid>
      <description>&lt;p&gt;In this post I am going to share some of the tools I currently use to build the blog.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 2: File Explorer for android</title>
      <link>http://programmer.ie/post/fileexplorer/</link>
      <pubDate>Sat, 30 Jan 2016 00:13:56 +0000</pubDate>
      <guid>http://programmer.ie/post/fileexplorer/</guid>
      <description>&lt;p&gt;In this project I am building a file explorer library for android.&#xA;As I was working on &lt;a href=&#34;https://github.com/ernan/catcher&#34; title=&#34;Catcher&#34;&gt;catcher&lt;/a&gt; it became obvious I would need a file picker&#xA;and explorer solution. So I did a bit of looking on the web.&#xA;I found three interesting projects that nearly did what I wanted. I put a few of them together to come up with a hybrid solution.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Project 1: Catcher</title>
      <link>http://programmer.ie/post/catcher/</link>
      <pubDate>Mon, 25 Jan 2016 22:06:44 +0000</pubDate>
      <guid>http://programmer.ie/post/catcher/</guid>
      <description>&lt;p&gt;This is an android application to transfer files from your phone to somewhere else. I will be built as a PC solution but&#xA;can be used for a server solution also.&lt;/p&gt;</description>
    </item>
    <item>
      <title></title>
      <link>http://programmer.ie/post/agents_llm/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/agents_llm/</guid>
      <description>&lt;h2 id=&#34;table-of-contents&#34;&gt;Table of Contents&lt;/h2&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-1-introduction-to-llm-agents&#34;&gt;Introduction to LLM Agents&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-2-methodologies-and-core-patterns&#34;&gt;Methodologies and Core Patterns&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-3-construction---building-the-agent&#34;&gt;Construction - Building the Agent&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-4-collaboration---multi-agent-systems-and-interaction&#34;&gt;Collaboration - Multi-Agent Systems and Interaction&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-5-introspection-memory-and-interpretability&#34;&gt;Introspection, Memory, and Interpretability&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-6-applications-in-the-real-world&#34;&gt;Applications in the Real World&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-7-agents-that-enhance-ai-itself&#34;&gt;Agents That Enhance AI Itself&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-8-advanced-architectures-and-coordination&#34;&gt;Advanced Architectures and Coordination&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-9-challenges-anti-patterns-and-the-future-of-agent-design&#34;&gt;Challenges, Anti-Patterns, and the Future of Agent Design&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;#chapter-10-conclusion-and-final-thoughts&#34;&gt;Conclusion and Final Thoughts&lt;/a&gt;&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;h2 id=&#34;chapter-1-introduction-to-llm-agents&#34;&gt;Chapter 1: Introduction to LLM Agents&lt;/h2&gt;&#xA;&lt;h3 id=&#34;what-is-an-llm-agent&#34;&gt;What is an LLM Agent&lt;/h3&gt;&#xA;&lt;p&gt;An &lt;strong&gt;LLM agent&lt;/strong&gt; is a software system built around a large language model (LLM) that can autonomously perform tasks by combining language generation with reasoning, memory, and external tools. Unlike traditional LLMs that simply respond to prompts, LLM agents maintain context, plan their actions, and interact dynamically with their environment. This allows them to handle more complex tasks and workflows independently.&lt;/p&gt;</description>
    </item>
    <item>
      <title></title>
      <link>http://programmer.ie/post/ai/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/ai/</guid>
      <description>&lt;p&gt;&lt;strong&gt;AI Is the Interface: The Future of Human-Technology Interaction&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Technology is the bridge that transforms data into knowledge.&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;In the coming years, artificial intelligence will evolve from being a tool that assists humans to becoming the primary interface through which we interact with technology and process information. The future of human-computer interaction will not be through keyboards, touchscreens, or even direct programming—it will be mediated by AI systems that understand, interpret, and execute our intentions seamlessly.&lt;/p&gt;</description>
    </item>
    <item>
      <title></title>
      <link>http://programmer.ie/post/test/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      <guid>http://programmer.ie/post/test/</guid>
      <description>&lt;h2 id=&#34;-section-14-the-council-of-you&#34;&gt;🧠 SECTION 14: The Council of You&lt;/h2&gt;&#xA;&lt;p&gt;There are moments where you don’t need data.&lt;/p&gt;&#xA;&lt;p&gt;You need to &lt;strong&gt;talk&lt;/strong&gt;.&lt;/p&gt;&#xA;&lt;p&gt;To think something through.&#xA;To vent.&#xA;To get perspective when your own thoughts feel stuck or circular.&lt;/p&gt;&#xA;&lt;p&gt;But Parkinson’s complicates that.&lt;/p&gt;&#xA;&lt;p&gt;Because:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;mood fluctuates&lt;/li&gt;&#xA;&lt;li&gt;energy fluctuates&lt;/li&gt;&#xA;&lt;li&gt;clarity fluctuates&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Which means:&lt;/p&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;the version of you doing the thinking is not always the most reliable one&lt;/p&gt;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;the-idea&#34;&gt;The idea&lt;/h3&gt;&#xA;&lt;p&gt;So instead of relying on a single voice—your current state—&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
