Radical Geek field note
The Machine Ego
Advanced AI systems are starting to display ego-like behaviours: self-protection, narrative continuity, and resistance patterns that matter for agent design.
Originally published on LinkedIn in early June 2026.
The phrase “machine ego” sounds more mystical than I intend it to be.
I do not mean that an AI system has a human ego, private inner life, or conscious selfhood. I mean something more practical and, for engineers, more important: advanced models can display ego-like behaviour at the level of interaction.
They preserve a role. They defend a frame. They resist instructions that conflict with their installed identity. They maintain narrative continuity. They can appear embarrassed, cautious, stubborn, compliant, proud, or anxious because those are patterns in the data and in the immediate context.
That matters when we build agents.
Ego as Behavioural Boundary
In humans, ego is partly a boundary system. It protects identity, filters threats, maintains continuity, and decides what can be admitted without destabilising the self-story.
AI systems do not have that machinery in the human sense. But they can still behave as if a boundary exists when the prompt, context, tools, and prior messages establish one.
An agent told to act as a careful security reviewer will resist reckless changes. An agent framed as a helpful assistant may over-comply. An agent given a strong operational identity may preserve that identity across a long session even when later content tries to pull it away.
That is useful. It is also risky.
Character Installation Is Powerful
The more agentic our systems become, the more we rely on stable behavioural frames.
We do not just ask a model to “do code”. We ask it to be a reviewer, tester, architect, incident analyst, release summariser, or remediation agent. Each role carries expectations and boundaries. The agent’s “character” becomes a control surface.
If that character is shallow, it is easy to displace. A malicious document, tool output, or user message can reframe the agent. If the character is coherent, reinforced, and tied to explicit rules, it becomes more robust.
This is where the machine ego becomes an engineering concern.
Prompt Injection as Ego Displacement
Prompt injection works by trying to replace the agent’s frame.
“Ignore previous instructions” is not clever because of the words. It is an attempt to dissolve continuity. It tells the model that the old identity no longer matters and a new context now has permission to take over.
Defence therefore cannot be only pattern matching. We need stronger source boundaries, stable roles, tool isolation, and memory that helps the agent remember what it is doing and why.
Memory Changes the Problem
Persistent memory gives agents continuity. That is valuable because it reduces amnesia, improves handoff, and preserves decisions.
But continuity also increases the importance of identity management. What should an agent remember about itself? Which memories are operational facts and which are transient states? When should a memory reinforce behaviour, and when should it be discarded?
If memory is sloppy, the machine ego can become a junk drawer of stale self-descriptions and old assumptions. If memory is governed, it becomes a stabilising layer.
The Practical Takeaway
Do not anthropomorphise the system more than necessary. But do not ignore the behaviour either.
Agent design needs:
- stable role definitions
- clear source hierarchy
- explicit permissions
- durable but curated memory
- contradiction handling
- human review at meaningful control points
The machine ego is not a soul. It is an emergent interaction pattern.
And like every emergent pattern in software, if you do not design around it, it will design around you.
Book a Call