Code & Documentation: Map ⇄ Territory

One thing that AI systems don't seem to know much about is AI systems.

From my post on the future of 'documentation';

But the thing that occurred to me this morning, as I was playing with a local LLM and asking it for help about some technical details around how to configure it, was that there is an opportunity for these models to be "self-documenting" that seems to be being missed.

This continues to be a frustration; models that lack an awareness or understanding of the context that the user is experiencing them in can only possibly hallucinate when asked about 'themselves'.

For example;

Copilot in Excel is writing me a prompt to copy and paste into Copilot in Excel, because Copilot in Excel can’t do what I’m asking for directly, but it’s OK because this is exactly what Copilot in Excel is great for!

What was happening then was that Copilot in Excel (at the time, in the UK) was simply a different 'view' for M365 Copilot. Same system, same chatbot, in a different place; it had no way of 'knowing'knowing that it wasn't in the 'regular' website window, and although it 'knew' about Copilot's 'agent mode' in Excel, it clearly didn't 'know' that it hadn't been rolled out in the UK yet.

(Or that I was in the UK.)

In other words – the model had some 'knowledge' about the Copilot products, but there was specific "self-knowledge" that the LLM really needed to be able to answer the question properly. But didn't have it…

Don't these chatbots have 'knowledge bases'? Shouldn't there be something in the system prompt? "You are Microsoft Copilot, a chatbot in the sidebar of the Microsoft Excel for Mac application." In the rush to AGI, are these companies not writing some basic documentation along the way?

To be clear; this isn't just a Copilot issue. I've been in Google's Antigravity, being told by Antigravity how to set global agent preferences by clicking on buttons in Antigravity that don't exist. I've had Claude, in the Claude.app desktop application, tell me that Claude Code is a totally separate desktop app to the 'regular Claude' desktop app (its exactly the same Claude.app application that it told me to download, that I was already in.) Again - a degree of 'self-knowledge' that was important but missing, leading to responses that looked helpful but were… not.

Similarly - asking Gemini about how to do things in Antigravity is weird; both are Google AI tools, using versions of the same Gemini model – but just a month ago, Gemini didn't even 'know' that Antigravity existed – other than as a Google Search easter egg. (On checking that Gemini wasn't familiar with Antigravity I got the reponse; "Or — and I say this gently — it might be one of those product names that sounds very plausible but doesn't exist? There's a long tradition of "Google [noun]" jokes given how many products they've launched and killed." Which I find less infuriating than Copilot's flavour of gaslighting, but not by much.)

I understand that hallucinations are a thing with LLMs that are very difficult to work around, because the model contains a huge amount of knowledge compressed into its billions of weights and biases but no way to differentiate between what it 'knows' and what it 'guesses'. I get it. I also get that agents have instructions, and 'grounding' texts.

So, how hard is it to set rules for agents that tells them they don't talk about the specific application that they live inside without grounding those responses in documentation? It doesn't seem hard – it could be addressed with simple prompt injection, some RAG on a self-documenting knowledge base, fine-tuning on specific questions (finally – an actual use for FAQs!)

Documentation used to be hard to write. Quite suddenly, it has become very easy - exactly the kind of task that a large language model can carry out. And yet, large language models being deployed into applications with very specific use-cases seem to be consistently lacking in the 'grounding' data needed to work properly in these contexts.

The thing is, documentation isn't just easy – if 75% of the code that Google/Anthropic/OpenAI/Microsoft etc. create is being written by AI, then it exists before the code.

Documentation and Code: Map ⇄ Territory

From Charity Majors: "AI demands more engineering discipline. Not less";

What happened in 2025 was this: the economics of code production were turned upside down. Instead of being very hard, time-consuming, and expensive to generate code, it became effectively free and instant. Lines of code went from being treasured, reused, cared for and carefully curated, to being disposable and regenerable, practically overnight.
For most of computing history, the primary way people have learned to understand software is by writing the code. Once you've achieved some mastery, reading and discussing code gets you most of the way there.

The code is the knowledge. It does what it does, and the documentation is - generally - a reflection of what it does.

The code is the territory; the documentation is the map.

So, what happens when the code is "disposable and regenerable"?

The code has been the bundled up repository of developer intent, user expectations, implicit and explicit behaviors, the only fossilized composite record we have of bugs gone by. It’s too much!

Right now, I'm getting used to a mindset shift – I used to write code by hand. Typed into a text editor, then into an IDE, then an IDE with a magic autocomplete. 'Artisinal' code – the sort where I'd be unsatisfied if the indentation style was inconsistent in different cells within the same notebook. (A notebook that nobody else was ever going to see…)

The shift is that I'm now writing messages in 'natural language' to an agent who writes my code for me; sometimes in a chat-type environment, sometimes into a README.md, SKILLS.md or CLAUDE.md file.

That means the code isn't even "my code". I'm not even seeing it, let alone hand-crafting it. The code still does what it does, but the 'documentation' isn't a reflection of what the code does any more. The roles have flipped. If the code and the documentation clash, then the code needs to change. And the type of file I'm spending the most time working on in any given coding project isn't a .py or .js – its .md.

The code is now the map. The documentation is the territory.


A brief story; its 1996, and I have a summer job working in a mobile phone R&D centre. I'm in the Product Test Team; my job is pushing buttons on a phone and ticking a box if it does what its supposed to do. Sometimes in an office; sometimes, in a converted transit van driving around the country, making sure that the phones do what they are supposed to do when switching between transmitter masts. The actual work is boring, but the job is pretty fun. But not this week - its "all hands on deck", running tests around the clock and through the weekend, because there's a new phone about to be released which needs a last-minute change to its software. There's a printing error in the user manual, but rather than reprint all the manuals its been decided that the phone menus need to be changed instead; so what was previously Menu > 4 now needs to be Menu > 3, and vice versa. Everyone in the office agrees that this is crazy (because everyone in the office has spent the last six months running all sorts of tests on various versions of this software); the user manual is a 'map' that nobody actually reads, the software is the 'territory', and this decision to make the software match the manual is insane… But reprinting the manuals would mean they won't be in the boxes with the phones when they are supposed to be in the shops so… its just another day in the sort of world that made the pointy-haired boss in the Dilbert comics feel so accurate.


Now, its thirty years later, this kind of 'documentation' is no longer colour printed on shiny paper and put in the box (its a web page – or more likely a PDF – and the only 'documentation' that comes in the box is the "do not swallow the battery" regulatory warnings in forty two different languages), the cost of rewriting and republishing the documentation is now zero. And now, it makes perfect sense to say that the documentation says one thing, the software does something else, so its the software that should be rewritten.

Because the economics of code production were turned upside down. 'Documentation' is more important than ever – not just because the AI needs it to answer users' questions, but because the AI needs it to build the software in the first place.

I'm sure that recursive self-improvement will make future AI great (again?) But maybe some recursive self-documentation could make the systems we have a bit better?

  1. I use scare quotes around 'knowing' as a reminder to myself that it doesn't really "know" things.

AI and "Apple Intelligence"

(Title based on a Threads post from Daniel Jalkut.

What Is Apple Doing in AI? Summaries, Cloud and On-Device LLMs, OpenAI Deal - Bloomberg

But the company knows consumers will demand such a feature, and so it’s teaming up with OpenAI to add the startup’s technology to iOS 18, the next version of the iPhone’s software. The companies are preparing a major announcement of their partnership at WWDC, with Sam Altman-led OpenAI now racing to ensure it has the capacity to support the influx of users later this year.

Nah- I'm not buying it. For one - OpenAI and Microsoft are "true" partners; Microsoft's Azure compute + OpenAI's models + Microsoft's apps/OS 1 are getting deeply intertwined. An Apple + OpenAI partnership seems like a strategy to be permanently one step behind Microsoft.

But it seems inevitable that there's big Apple + AI news coming. Siri needs a significant upgrade. The new iPad Pro announcement made a big deal about having "AI compute" power2. "AI features" announcements at WWDC 2024 seems like the safest bet in tech.

So, what might be coming?

  • Siri was a pretty early bet on the future - but possibly too early, given the advancements in machine learning/deep learning since Siri was first released. But "Siri" is more of a brand than a technology - there are "Siri" features that don't seem to have anything to do with the voice assistant.
  • Meanwhile, while Siri might seem to be stuck in a rut, Apple's own proprietary ML/AI technology has been coming along. Apple Music has had a 'karaoke' feature where you can turn down the vocals - which I had wondered whether it was an AI-powered thing or just that they get separate stems; the latest Logic Pro which lets you split vocals, drums, bass and 'everything else' seems to suggest that its AI rather than a 'special access to the masters' situation. Given Apple's insistence on owning any technology that they rely on, this seems like the most likely approach. Whether Siri as a brand is dead or not… We'll see. (Worth noting that Siri came out before the film 'Her' - while OpenAI's latest release seems clearly... 'inspired' by the film, Siri looks more like the inspiration for the film.)
  • That said - it seems that Apple needs to catch up a lot, and fast. So a partnership with a technology leader does make sense. So... with who?
    • Meta? Meta's AI push has been for 'open' models (as opposed to - ironically - OpenAI's proprietary approach) that anyone can use. Apple's strength is in using on-device computing power (because they have a fair amount of it - it also fits with their 'privacy first' approach.) Maybe Apple would be licensing these models - but I suspect that the Apple/Meta relationship isn't strong enough to make it likely that Apple would want to put their future in Mark Zuckerberg's hands.
    • Google's AI journey has been... interesting. They seem to be leaders in terms of the underlying tech - but struggling to actually execute; OpenAI/ChatGPT/Copilots seem to be conclusively winning the PR/branding fight - perhaps they need a partner who can make a better product (away from the issues of competing with Search as a business model) that can better reflect the power of the underlying tech than Google's efforts to date. The Transformer architecture that led to the LLM explosion came out of Google, as did the Tensorflow software framework. While everyone else is fighting over nVidia's GPU chips, Google have been making their own TPUs for nearly a decade. Google is arguably the only GPU-rich business at the moment, and there is a general vibe of the AI industry being Google vs. Everyone Else - having a big partner might be exactly what they need right now. Maybe most importantly, Google pays Apple a lot of money for search engine prominence. The question is how much of the old Android/iOS friction still exists on Apple's side, while Google's opportunity is to make an AI-powered "Google Android" a distinct product from... lets call it the "Samsung Android" ecosystem - which doesn't make as much sense if Apple gets benefits that cheaper Android phones don't.
    • Microsoft? If Apple could get a more... lets say "grown-up" business partner without the volatility of OpenAI, then that could be interesting... And if the 'everyone vs Google' view of the market is right, then it seems to be in Microsoft's interests too. But it seems that Microsoft's clear positioning of 'Copilot+ PCs' as going head-to-head with Macbooks would be unlikely if that was in the pipeline.
    • There are other AI companies (eg. Anthropic) - but I'm not sure how many of them are scalable enough (read: access to the compute resources that would be needed to potentially switch on for every iPhone/iPad/Mac owner in the world overnight.)

If I had to make a bet, my money would be on a Google partnership, with something like the Gemma model running locally on iPhone/iPads etc. as 'Siri 2.0' and access to Gemini for the kind of tasks that need access to 'full fat' LLMs and more computing power.

  1. Also- GitHub CoPilot

  2. Yes, iPads/iPhones/Macs have had 'neural cores' for a few years - but the new iPad seems to be stepping this up significantly, but with no news on what its actually going to power. Worth noting - if you're developing AI/ML/LLM-type software on a Mac, you're using the GPU - not NPU chips. So far, they seem to be locked away for Apple's use (which includes Apple's APIs if you're building apps for the app store - but not if you're running something like TensorFlow in Python.)

The Device is the Boring Bit

The Apple Vision Pro is now on sale. People are getting their hands on them, and sharing their opinions. People who haven't got their hands on them are sharing their opinions. There are a lot of opinions flying around.

First thing - sure, I'm interested in the headset, and the device actually getting in 'normal' people's hands (or on their faces) is this week's news; I'm not going to buy one, because it's ridiculously expensive and if I had that sort of money to throw around, I probably wouldn't be driving a car that's approaching either its 18th birthday or its last trip to the scrapyard and has done the equivalent milage of 5 times around the circumference of the earth.


But what I'm really interested in is the Vision platform; the bits in the software that are going to be the same when the next headset device is launched. And once there are a bunch of different ‘Vision’ devices - where they will fit, in the spaces in people's lives.

Who owns Taylor Swift's voice?

Ben Evans on Threads;

It's a lot easier to understand the IP issues in 'give me this song but in Taylor Swift's voice' than 'make me a song in the style of the top ten hits of the last decade.' If a human did that, they wouldn't necessarily have to pay anyone, so why would an LLM?

There's an interesting twist with the "Taylor Swift's voice" example; Scooter Braun owns all of Taylor Swift's recordings (at least, I think all the ones released before any ChatGPT-era training dataset were compiled) - he bought the record company, so he owns the master recordings (and all the copies of the master recordings, and the rights relating to them) - but not the songs themselves. Taylor Swift still owns them - which is why she can make her "Taylor's Version" re-recordings (which Scooter Braun doesn't get a penny out of.)

So there's a key difference here; a human would copy the songs (that is, they would be working off the version of the songs that are in their heads - the idea of the songs), so Swift would get paid as the owner of the songs.

But the kind of generative AI we're talking about would be copying 100% from the recordings (ie. the training data would be the sounds, digitised and converted into a stream of numbers) - which Swift doesn't own. The AI doesn't "see" the idea of the songs - it wouldn’t “know” what the lyrics were, what key the songs were in, what chords were being played on what instrument - any more than a Large Language Model “knows” what the words in its (tokenised) training dataset or output mean.

She still owns her songs, but she’s sold her voice.

(Pre) WWDC 2023

WWDC usually isn’t one to look forward to - unless you’re the sort of person who cares about things like Xcode features - because it isn’t the venue where they talk about the new iPhones. Maybe there will be clues about new iPhone features in some new APIs or something, but the focus is generally on developers.

This year is different…

Robot War part 3: The Race

This is the tech war of the moment; a race to be the first to develop an AI/Machine Learning/Deep Learning product that will be a commercial success. Google have a head start - Microsoft+OpenAI look like they could be set to catch up, and maybe even overtake Google. But if this is a race then where is the finish line? What is the ultimate goal? Is it all about the $175 billion Search advertising market - or is it bigger than that?

The Next Big Thing (2023)

Nine years ago (Jan 2014), I wrote a post about "the next big thing". I think its fair to say that in a history of technological innovations and revolutions, there isn't really much in the last decade or so that would warrant much more than a footnote; the theme has been 'evolution, not revolution'.

Well, I think the Next Big Thing is - finally - here. And it isn't a thing consumers will go out and buy. Its an abstract, intangible thing; software not hardware, service not product.

For the first time in years, tech has got genuinely interesting again.

The Metaverse is an Elephant

One reason the Metaverse is doomed is because of the idea that it will straddle all of the different computing platforms; too many conflicting business interests will make this impossible to execute.

One reason the Metaverse will succeed is because of the idea that when something, sooner or later, straddle all of the computing platforms, it will deliver something incredibly useful.

Rise of the machines (Robot war part 2)

Two narratives, one story;

  1. An AI developed by Google has developed sentience - the ability to have its own thoughts and feelings, and a Google engineer working with it has been fired for making the story public.

  2. A Google engineer thinks a 'chatbot' AI should be treated like a human, because he believes that it has developed the ability to have and express its own thoughts and feelings. After Google looked into and dismissed his claims, the engineer went public with them, and was then placed on paid administrative leave and subsequently fired.

The subject of the first story is artificial intelligence - with a juicy ethical human subplot about a whistleblower getting (unfairly?) punished.

The subject of the second story (which is a little more nuanced) is a human engineer going rogue, with an interesting subplot about ethics around artificial intelligence.

I think most of the reporting has been around the first version of the story- and I think thats because it fits into a broader ongoing narrative; the idea that 'our' machines are getting smarter - moving towards a point where they are so smart that humans can be replaced.

Its a narrative that stretches back for centuries - at least as far back as the industrial revolution.