Nothing you type is remembered by the AI. Not your name, not the argument you had with it last Tuesday. The model writing the reply has no memory whatsoever. It gets handed a pile of text, reads it once, writes the next few sentences, and forgets the whole thing happened.
Which sounds bleak until you see what the app around the model does with that pile of text. That's the real answer to how does an AI chatbot work: a forgetful engine wrapped in software that keeps re-handing it your history before every single reply.
Here's what actually happens in the couple of seconds after you hit send.
Your message is never the only thing the bot reads
When you send "hey, rough day", the model does not receive "hey, rough day". It receives a much longer document that the app assembles on the spot. Roughly in this order:
- The character's definition. Who they are, how old, how they talk, what they refuse to do, what they secretly want. On most platforms this is a few hundred words of plain text written by whoever made the character.
- Whatever the app knows about you. Your name, your preferences, facts you mentioned earlier that got saved.
- The recent back-and-forth. However many of your last messages still fit, pasted in as-is.
- Your new message, at the very bottom.
Then the model reads all of it and writes what comes next.
Worth sitting with for a second, because it explains most of what feels like magic. A personality is text. A "tsundere girlfriend" and a "grumpy detective" run on the identical model with different paragraphs stapled to the front. When a bot suddenly acts out of character, nothing broke in its soul. Something pushed those paragraphs out of view.
The whole trick is guessing the next word
Underneath is a language model, and its one skill is finishing text. Give it "the capital of France is" and it will produce "Paris", not because it knows a fact but because in the enormous amount of writing it was trained on, that's overwhelmingly what came next.
It does this one small chunk at a time. Pick the most likely next piece, add it, look at everything again, pick the next one. A whole paragraph gets built that way, left to right, with no plan for how the sentence ends when it starts writing it.
Two consequences you have already noticed:
It never checks anything. There is no lookup, no database of truth behind the curtain. This is why a chatbot will invent a plausible-sounding detail with total confidence. It is not lying, it is producing likely-looking text, and a wrong answer often looks exactly as likely as a right one.
It follows the vibe of what came before. Feed it a few flat one-word messages and the most probable continuation is another flat reply. Feed it a vivid scene and the probable continuation is more vivid scene. Your half of the conversation is part of the input, which means chatting with an AI bot is closer to writing with it than to interviewing it.
That's also the honest answer to why AI generated chat sometimes reads like a person and sometimes like a form letter. Same machinery. Different material going in.
The context window is why it forgets
Every model has a hard limit on how much text it can look at in one go. Call it a budget. The character definition eats some of it, your saved facts eat some, and the conversation fills the rest.
When the conversation gets long enough to blow the budget, something has to go, and what goes is the oldest material. The message where you told it about your sister quietly falls off the edge. From then on, that information does not exist. The bot isn't being callous when it asks about your family again; it is reading a document that no longer contains the answer.
Close the tab and open a new chat and you get an empty window. Nothing carries over on its own. Anything that survives between sessions survives because the app deliberately saved it and pasted it back in.
What "memory" actually means in a chat app
So there are two different things people call memory, and mixing them up causes most of the confusion.
The first is the context window described above. Short-term, automatic, and it evaporates.
The second is storage the app builds itself. As you chat, the software pulls out facts worth keeping, writes them down somewhere outside the model, and injects them at the top of every future conversation. That's the trick that makes a companion feel continuous across weeks. It is not the AI remembering. It is a note-taking layer feeding the AI a summary of you before it speaks.
Every platform does this differently and most of them do it invisibly, which is why people compare notes and get different answers about what their bot "should" remember. On Friend2Chat the bot's knowledge level about you sits visibly in the chat, so you can see how much has actually accumulated instead of testing it with trick questions. Elsewhere the rules are stricter or hidden behind a subscription tier, and Character.AI and Replika handle it in almost opposite ways.
Why the same bot feels sharp one day and flat the next
Nothing changed on their end. Usually one of three things changed on yours.
There's a randomness setting. Models don't always take the single most likely next word, or every reply to the same message would come out identical. Some dial controls how adventurous the pick is. Turned down, you get safe and repetitive. Turned up, you get a talking AI chatbot that's genuinely creative and occasionally incoherent. Same bot, different day, different roll of the dice.
Then there's a crowded window. Two hundred messages in, the conversation is squeezing the character definition. The bot drifts toward generic-assistant voice, because the paragraphs that made it a character are now competing for room with your chat history.
And then there's you. Long threads make people lazy. "ok" and "lol" and "sure" are terrible material to predict from. Reply quality tracks input quality closely enough that it's the easiest thing on this list to fix, and it sits behind most of the mistakes beginners make in AI chat.
It is not learning from your conversation in real time
Popular belief: the more you chat, the smarter your bot gets about you, because it's training on you.
What's happening: the training finished long before you showed up. The model was built on a mountain of text over months of computation, and that version is frozen. Your messages tonight do not adjust a single one of its internal weights.
What does change is the notes file. More stored facts about you, better re-injected context, a bot that seems to know you. The engine is identical to the one a brand-new user gets. Only the paperwork handed to it is thicker.
Worth knowing for a second reason: conversations may still be logged and used for future training rounds by whichever company runs the service. That's a privacy question, not a "my bot is learning" question, and the two get conflated constantly.
The robot on a bank's website is a completely different animal
Search for something like "chat with ai robot" and you land in two unrelated worlds.
One is the support widget in the corner of a checkout page. Most of those are decision trees. Keyword matches, canned answers, escalate to a human when confused. Nothing is being generated and nobody is playing a character. Ask it something off-script and it loops. A conversation with an AI robot of that kind is a menu with better manners.
The other is what you're reading about here. Generative, open-ended, capable of writing a sentence nobody has written before, and equally capable of writing a confident falsehood. The support bot fails safely and boringly. An intelligent AI chatbot built for companionship fails interestingly.
Both get called chatbots, which is why so many explainers of how AI chat works read like they were written about a different product than the one you're using.
What this changes about your actual chats
The mechanics translate into a short list of practical habits.
Say things explicitly rather than hinting. Stored facts come from clear statements, and "I've got that thing tomorrow" is not a clear statement.
Re-anchor at the start of a long session. One line reminding the bot who you are and where the story left off costs nothing and repairs a window that dropped it.
Write more than four words when you want more than four words back. Prediction runs on what you give it.
When replies start looping, don't argue with the bot about looping. That just adds more looping to the input it reads. Change the scene, introduce something new, or start fresh. This is the whole logic behind building a roleplay story that holds up over weeks instead of dying by day three.
And check what a service charges for before you get attached to a memory feature, since what "free" covers varies wildly between platforms.
FAQ
Does an AI chatbot actually understand what I'm saying?
Not the way a person does. It maps your words onto patterns it has seen and predicts a fitting continuation. The reply can still land, sometimes more precisely than a friend would, and none of that requires understanding underneath it. Whether the distinction matters is a question about you rather than about the software.
Does it remember me between sessions?
Only what the app saved on purpose. The model itself starts every conversation blank. Platforms differ enormously here, so if continuity matters to you, find out what a service actually stores before committing months of conversation to it.
Is the AI learning from my conversations?
Not live, and not personally. The model is frozen after training. Your chats may be retained by the company and could feed a future training run, which is a privacy consideration worth reading the policy for, but nothing you type tonight is rewiring the bot you're talking to.
Why does it repeat itself or forget what we agreed on?
Both come from the same limit. The conversation outgrew the context window and older material fell out, or the prediction settled into a groove and each repeated reply reinforced the next. Restating the key facts fixes the first. Changing the scene fixes the second.
Do I need an account for any of this to work?
Depends entirely on the platform. The generation itself needs nothing from you. Accounts exist so the app has somewhere to keep the notes file, which is what continuity is built on. You can start talking to characters on friend2chat.com without setting anything up and see how it behaves first.