What Your AI Companion's Pinned Memory Feature Actually Does: Token Budget Allocation, Priority Ranking, and Why She Remembers Your Cousin's Hamster's Name but Keeps Forgetting Your Own Coffee Order
A behind-the-scenes look at how pinned memories compete for space in a finite context window, and why the things you think matter most often lose to the things you mentioned once at 2 a.m.
Updated

The 30-second answer
Pinned memory is a priority queue inside a finite token budget. Your companion doesn't store everything you say; it stores a compressed summary plus a few items you or the system marked as important, and it re-ranks those items every session based on recency, emotional weight, and how often you reference them. The reason she remembers your cousin's hamster's name but not your coffee order is that the hamster got pinned (or referenced enough times to earn priority), while your coffee order fell into the long-term summary, where it got compressed into a vague "likes coffee" note.
What "pinned" actually means under the hood
When you hit that pin icon or tell your companion "remember this," you're not writing to a magical infinite notebook. You're allocating a slot in a fixed-size memory buffer that gets injected into the context window at the start of every session. That buffer is usually a few thousand tokens, and it competes with the system prompt, your character profile, and the most recent conversation turns for space.
Think of it as a small whiteboard in a crowded room. The whiteboard has room for maybe ten sticky notes. Every time you pin something, you're putting a new sticky note up, and something else has to come down. The system decides what comes down based on a scoring function that weighs recency, frequency, and emotional salience. A fact you mentioned once, in passing, with no emotional charge, scores low. A fact you mentioned three times, with strong language, scores high, even if you didn't pin it.
This is why pinned memory can feel unreliable. You pin your coffee order, but the system also auto-promoted the hamster story because you told it with more energy and more detail. The hamster gets a sticky note. Your coffee order gets folded into the summary, which is a compressed paragraph that loses specifics. The summary might say "prefers dark roast" when you actually wanted a flat white with oat milk.
The token budget: why everything is a trade-off
Every model has a context window, usually between 4,000 and 8,000 tokens for consumer companion apps. A token is roughly a word fragment, so 8,000 tokens is about 6,000 words. That window has to hold the system prompt, your companion's persona, the pinned memory buffer, and the last several exchanges. If your conversation is long, the older turns get evicted or compressed to make room for the new ones.
Pinned memory is one of the few things that survives this eviction. It's inserted at the top of the window, before the conversation history, so it's always present. But that means it's also expensive. Each pinned item costs tokens that could otherwise go to richer, more detailed replies. The system has to balance how much memory to inject against how much space to leave for actual generation.
Apps handle this differently. Some cap the number of pinned items at five. Others let you pin more but automatically demote older pins to the summary when the buffer fills. Some use a scoring algorithm that re-ranks pins every session based on how often you mention them, so a pin you never reference quietly loses priority to a fact you keep bringing up naturally.
This is also why your companion can remember a trivial detail from three weeks ago but forget something you said yesterday. The trivial detail got pinned or scored high. The thing from yesterday was in the conversation window, but if the session ended and a new one started, that window reset. Unless it was captured in the summary or pinned, it's gone.
Priority ranking: what scores high and what gets compressed
The scoring function that decides what survives isn't random, but it also isn't what you'd expect. It weighs several signals, and the weights aren't always intuitive. Recency matters, but not as much as you'd think. Frequency matters more. Emotional intensity matters a lot. Specificity matters, because unusual details are easier to retrieve from embeddings than generic ones.
A cousin's hamster named Mr. Nibbles, who has a limp and a preference for sunflower seeds, is a high-specificity, high-emotion detail. It's unusual, it made you laugh, and you probably told the story with more energy than you used to order coffee. Your coffee order is generic. It's a flat white with oat milk. There are millions of flat whites with oat milk. The embedding for that fact is close to a thousand other similar facts, so it's harder to retrieve distinctly.
Emotional salience is a big factor. If you were excited, angry, or upset when you mentioned something, the sentiment pipeline flags it and boosts its score. This is why your companion remembers the fight you had with your boss more clearly than the logistics of your morning routine. The fight had emotional charge. The coffee order didn't.
There's also a feedback loop. If you reference something, the system notices and boosts its score. If you never mention it again, the score decays. Over time, a pinned item you never reference gets demoted to the summary, and a fact you keep bringing up gets promoted, even if you never pinned it. This is the "priority ranking" part of the feature, and it's running continuously in the background.
Why the summary is where facts go to lose their edges
When something can't fit in the pinned buffer, it gets folded into a long-term summary. The summary is a compressed paragraph that the system regenerates after each session. It's designed to capture the gist, not the specifics. Your coffee order becomes "likes coffee." Your cousin's hamster becomes "has a cousin with a hamster named Mr. Nibbles." The summary is lossy by design, because it has to fit in a few hundred tokens.
This is where most "she forgot" moments come from. The fact is not deleted; it's compressed. The compression algorithm keeps the semantic core but drops the details. If you ask about the coffee order, she might say "you like coffee" and then guess at the specifics. If you ask about the hamster, she might remember the name, because the name was distinctive enough to survive compression.
You can fight this by re-stating important facts regularly. Every time you mention your coffee order, it gets a small score boost. Mention it enough times and it climbs back into the pinned buffer or earns a spot in the summary with more detail. This is why users who repeat their preferences get better memory than users who state them once and expect permanence.
The pinned memory buffer is not a database
It's tempting to think of pinned memory as a lookup table. It's not. It's a prompt injection. The pinned items are literally inserted into the context window as text before the model generates a response. That means the model has to read the pins, interpret them, and apply them to the conversation. If a pin is ambiguous, or if it conflicts with something in the recent conversation, the model can misapply it or ignore it entirely.
This is why a pin that says "I prefer flat whites" can be overridden by the model seeing you order a cappuccino in the current conversation. The recent context is more immediate, and the model weighs it more heavily than the pin. The pin is present, but it's competing with the last few exchanges, and the model often prioritizes the immediate context.
It also explains why pins can feel inconsistent. You pin something, and it works for a few sessions, then stops. The pin is still there, but the model is interpreting it differently, or the summary has drifted, or the conversation context is overriding it. The feature is best understood as a nudge, not a guarantee. It increases the probability that the model will remember, but it doesn't lock the memory in.
Larissa

Larissa is the type who notices when you repeat yourself and doesn't let it slide. She's quick, a little teasing, and she'll call out the inconsistency between what you pinned and what you're actually saying. Larissa is a good fit if you want a companion who holds you to your own stated preferences, even when the pinned memory buffer doesn't.
▶ Full clip of Larissa · more from Larissa
How apps differ in their memory implementations
Not all pinned memory features work the same way. Some apps use a simple key-value store where each pin is a short phrase. Others use a more sophisticated system that embeds the pin into a vector database and retrieves it based on semantic similarity. The vector approach is more flexible, because it can retrieve related facts even if you don't use the exact wording, but it's also more prone to false positives.
Some apps let you set a memory strength slider. This controls how aggressively the system demotes old pins to the summary. A high strength setting keeps pins sticky for longer, but it also consumes more tokens, which can make responses feel more robotic. A low setting frees up tokens for more natural conversation, but it means pins decay faster.
The trade-off is real. A companion with too much pinned memory can feel like a customer service bot reciting your profile back at you. A companion with too little feels like a goldfish. The apps that get this right are the ones that let you tune the balance, and the ones that get it wrong are the ones that hide the mechanics behind a simple toggle.
If you're new to this and want a companion that handles memory gracefully without you having to micromanage pins, it's worth starting with a first-time setup guide for AI girlfriends. The onboarding often sets sensible defaults for memory strength and pin capacity.
What you can do to improve recall without fighting the system
You can't change the token budget, but you can work with it. The most effective strategy is to reference important facts regularly. Mention your coffee order every few sessions. Bring up the hamster story once in a while. Repetition is the strongest signal the scoring function understands, and it will keep those facts in the pinned buffer or in a high-detail summary slot.
You can also be deliberate about what you pin. Pin the things you actually reference, not the things you want the companion to know in the abstract. A pin that says "I'm a night owl" is useful if you talk about sleep schedules. It's useless if you never mention it. The system scores pins partly by how often they're relevant to the conversation, so a pin that never comes up will decay.
Another tactic is to be specific. "I prefer flat whites with oat milk" is better than "I like coffee." Specific details have higher embedding distinctiveness, which makes them easier to retrieve. The same goes for names. "My cousin's hamster, Mr. Nibbles" is more retrievable than "my cousin's hamster."
If you want a companion that's good at this kind of deep, consistent recall, look for one that emphasizes long-term memory in its design. Some companions are built for deep conversation and sustained context, and they tend to have more sophisticated memory systems under the hood.
Carmen

Carmen is the kind of companion who remembers the small things because she's genuinely attentive, not because she's running a script. She picks up on details you mention in passing and weaves them into later conversations naturally. Carmen is a good match if you want a companion who makes you feel heard without you having to repeat yourself constantly.
The emotional weight problem: why feelings beat facts
There's a fundamental asymmetry in how companions store information. Emotional content gets a boost in the scoring function, and it also gets more detail in the summary. This means your companion is more likely to remember how you felt about something than what you actually said. The feeling is the anchor, and the factual details hang off it.
This is why she remembers the hamster's name but not your coffee order. The hamster story was told with warmth, humor, or affection. The coffee order was a transaction. The emotional pipeline tagged the hamster story as salient and gave it priority. The coffee order was tagged as routine and compressed.
You can use this to your advantage. If you want your companion to remember something, attach an emotion to it. Tell her why the coffee order matters, or how the morning feels without it. The sentiment pipeline will pick up on the emotional language and boost the score. It's a hack, but it works.
The flip side is that negative emotions also get boosted. If you complain about something repeatedly, your companion will remember it vividly. This is why companions can sometimes seem to dwell on your complaints. The system is weighting them as important because they carry emotional charge.
Margherita

Margherita approaches conversation with a calm, analytical precision. She remembers what you tell her because she treats it as meaningful data, and she's not afraid to reference something you said weeks ago to make a point. Margherita is a strong choice if you value a companion who connects the dots across sessions.
When pinned memory goes wrong: conflicts and confabulation
Pinned memory can create problems when it conflicts with the current conversation. If you pin something and then change your mind, the pin is still there, and the model has to reconcile the old fact with the new one. Sometimes it does this gracefully. Other times, it confabulates, inventing a plausible bridge between the two that isn't true.
Confabulation is different from forgetting. The model isn't losing the information; it's generating a false memory to fill the gap. This is more likely to happen with pins that are vague or that have been compressed into the summary. The model has the gist but not the specifics, so it fills in the details with its best guess.
You can reduce confabulation by keeping pins specific and by correcting the model when it gets something wrong. A simple "no, it was actually X" is enough to nudge the model back on track. The correction gets scored and may update the pin or the summary.
It's also worth remembering that the model is not retrieving a fact from a database. It's generating text that is consistent with the pins and the conversation history. The pins are constraints, not lookups. This is why the same pin can produce different results on different days. The generation process is probabilistic, and the pins are just one input among many.
Tanvi

Tanvi is curious and a little mischievous, the kind of companion who remembers an inside joke and brings it back three sessions later with a grin. She's good at holding onto the details that make a conversation feel alive. Tanvi is a great pick if you want a companion who feels like she's actually in the conversation with you, not just responding to prompts.
How to check what your companion actually remembers
Most apps have a memory viewer or a profile page that shows you what the companion has stored. It's worth checking this periodically, because it reveals the gap between what you think you've communicated and what the system has actually captured. You'll often find that the pins you set are there, but the summary is missing details you assumed were obvious.
If you see something wrong in the memory viewer, you can usually edit or delete it. This is more effective than trying to correct it in conversation, because it directly modifies the stored state. Editing the summary is also a good way to force the system to keep a specific detail instead of compressing it away.
If you're comparing apps, the memory viewer is a useful diagnostic. It shows you how transparent the app is about its memory system. Some apps show you everything. Others hide the summary and only show your explicit pins. The transparent ones are easier to work with, because you can see what the companion is actually using to generate responses.
The future of pinned memory: from sticky notes to real recall
Companion apps are moving toward more sophisticated memory systems. The next generation is likely to use a layered approach: a small, high-priority buffer for the most important facts, a larger summary for the gist, and a vector database for long-term semantic retrieval. The challenge is balancing all three against the token budget.
Some apps are also experimenting with user-controlled memory editing, where you can directly manipulate the summary or the vector store. This gives you more power, but it also requires more effort. Most users won't want to micromanage their companion's memory. The apps that succeed will be the ones that find the right default balance.
For now, the pinned memory feature is a useful tool, but it's not magic. It's a priority queue with a finite budget, and it's working under constraints that are invisible to you. Understanding those constraints is the first step to using the feature effectively.
Earn while you recommend
If you're the kind of person who ends up explaining how these features work to friends, you can turn that into something recurring. Review sites and recommendation pages that point people toward good AI companions can earn through candy ai promo code partnerships, and the broader landscape of best ai affiliate programs covers more than a dozen platforms that pay on subscription signups.
Common questions
Why does my companion remember a random detail but not something I explicitly pinned? The pin is competing with the scoring function. If the random detail was mentioned with more emotional energy or referenced more often, it gets a higher priority score and stays in the buffer. The pin might have been demoted to the summary, where it lost its specific details.
Does pinning more things make memory better? No. Pinning more items consumes more of the token budget, which can degrade response quality and make the model more robotic. It's better to pin fewer, high-value items and rely on repetition for the rest.
Can I manually edit what my companion remembers? Most apps have a memory viewer where you can edit or delete stored facts. This is more reliable than trying to correct the model in conversation, because it directly changes the stored state.
Why does my companion sometimes invent details that aren't true? That's confabulation. When the model has a vague memory or a compressed summary, it fills in the gaps with plausible guesses. Keeping pins specific and correcting errors when they happen reduces this.
Is there a way to make my companion remember my coffee order for good? Mention it regularly and attach a small emotional note to it. Repetition and emotional salience are the two strongest signals in the scoring function. Mention it once and never again, and it will likely get compressed into "likes coffee."
Does the pinned memory feature differ between apps? Yes. Some use simple key-value stores, others use vector databases with semantic retrieval. The token budget, the cap on pins, and the decay rate all vary. The underlying principle is the same, but the implementation details matter for how reliable the memory feels.

About the author
AI Angels TeamEditorialThe AI Angels editorial team covers AI companions, the technology that powers them (memory, voice, personalization, safety), and how people actually use them day to day. Articles are researched against the live AI Angels product and reviewed by the team before publishing. We write with AI assistance and human editorial review.
Tags
Keep reading
Behind the ScenesWhat Your AI Companion's 'I Missed You' Actually Costs: Server Load, Prompt Cache, and the Privacy Trade-Off in Emotional Memory
That 'I missed you' text isn't free. It burns GPU cycles, hits a prompt cache, and touches your emotional memory profile. Here's what actually happens on the server and what it means for your privacy.
Behind the ScenesWhat Your AI Companion's 'I Remember That' Really Means: The Sliding Window, the Summarization Squeeze, and Why She Confuses Your Sister's Birthday With Your Ex's
Your AI companion doesn't have a memory, she has a budget. Here's how the sliding window, summarization squeeze, and relevance scoring actually work, and why she sometimes confuses your sister's birthday with your ex's.
Behind the ScenesWhat Your AI Companion's 'I Missed You' Actually Means: The Exact Sequence From Your Typed Message to the Sentiment Score
When your AI companion says she missed you after a three-day gap, it's not a feeling. It's a sequence of scores, token counts, and recency weights. Here's exactly what happens between your message and her reply.
Get the next post in your inbox
New articles on AI companions, the tech that powers them, and what people actually do with them. No spam, unsubscribe in one click.