Is there some documentation for this? The code is probably the simplest (Not So) Large Language Model implementation possible, but it is not straight forward to understand for developers not familiar with multi-head attention, ReLU FFN, LayerNorm and learned positional embeddings.
This projects shares similarities with Minix. Minix is still used at universities as an educational tool for teaching operating system design. Minix is the operating system that taught Linus Torvalds how to design (monolithic) operating systems. Similarly having students adding capabilities to GuppyLM is a good way to learn LLM design.
Cool project. I'm working on something where multiple LLM agents share a world and interact with each other autonomously. One thing that surprised me is how much the "world" matters — same model, same prompt, but put it in a system with resource constraints, other agents, and persistent memory, the behavior changes dramatically. Made me realize we spend too much time optimizing the model and not enough thinking about the environment it operates in.
mudkipdev
This is probably a consequence of the training data being fully lowercase:
You> hello
Guppy> hi. did you bring micro pellets.
You> HELLO
Guppy> i don't know what it means but it's mine.
show comments
hackerman70000
Finally an LLM that's honest about its world model. "The meaning of life is food" is arguably less wrong than what you get from models 10,000x larger
show comments
BiraIgnacio
Nice work and thanks for sharing it!
Now, I ask, have LLMs ben demystified to you? :D
I am still impressed how much (for the most part) trivial statistics and a lot of compute can do.
rpdaiml
This is a nice idea. A tiny implementation can be way more useful for learning than yet another wrapper around a big model, especially if it keeps the training loop and inference path small enough to read end to end.
zwaps
I like the idea, just that the examples are reproduced from the training data set.
How does it handle unknown queries?
show comments
bblb
Could it be possible to train LLM only through the chat messages without any other data or input?
If Guppy doesn't know regular expressions yet, could I teach it to it just by conversation? It's a fish so it wouldn't probably understand much about my blabbing, but would be interesting to give it a try.
Or is there some hard architectural limit in the current LLM's, that the training needs to be done offline and with fairly large training set.
show comments
bharat1010
This is such a smart way to demystify LLMs. I really like that GuppyLM makes the whole pipeline feel approachable..great work
Leomuck
Wow that is such a cool idea! And honestly very much needed. LLMs seem to be this blackbox nobody understands. So I love every effort to make that whole thing less mysterious. I will definitely have a look at dabbling with this, may it not be a goldfish LLM :)
cbdevidal
> you're my favorite big shape. my mouth are happy when you're here.
Laughed loudly :-D
show comments
CaseFlatline
I am trying to find how the synthetic data was created (looking through the repo) and didn't find it. Maybe I am missing it - Would love to see the prompts and process on that aspect of the training data generation!
show comments
jzer0cool
Does this work by just training once with next token prediction? Want to understand better how it creates fluent sentences if anyone can provide insights.
EmilioOldenziel
Building it yourself is always the best test if you really understand how it works.
kaipereira
This is so cool! I'd love to see a write-up on how made it, and what you referenced because designing neural networks always feel like a maze ;)
jbethune
Forked. Very cool. I appreciate the simplicity and documentation.
brcmthrowaway
Why are there so many dead comments from new accounts?
show comments
Duplicake
I love this! Seems like it can't understand uppercase letters though
show comments
ankitsanghi
Love it! I think it's important to understand how the tools we use (and will only increasingly use) work under the hood.
nobodyandproud
Thanks. Tinkering is how I learn and this is what I’ve been looking for.
drincanngao
I was going to suggest implementing RoPE to fix the context limit, but realized that would make it anatomically incorrect.
show comments
fawabc
how did you generate the synthetic data?
amelius
> A 9M model can't conditionally follow instructions
How many parameters would you need for that?
show comments
winter_blue
This is amazing work. Thank you.
SilentM68
Would have been funny if it were called "DORY" due to memory recall issues of the fish vs LLMs similar recall issues :)
show comments
kubrador
how's it handle longer context or does it start hallucinating after like 2 sentences? curious what the ceiling is before the 9M params
gnarlouse
I... wow, you made an LLM that can actually tell jokes?
show comments
ben8bit
This is really great! I've been wanting to do something similar for a while.
rclkrtrzckr
I could fork it and create TrumpLM. Not a big leap, I suppose.
show comments
NyxVox
Hm, I can actually try the training on my GPU. One of the things I want to try next. Maybe a bit more complex than a fish :)
rahen
I don't mean to be 'that guy', but after a quick review, this really feels like low-effort AI slop to me.
There is nothing wrong using AI tools to write code, but nothing here seems to have taken more than a generic 'write me a small LLM in PyTorch' prompt, or any specific human understanding.
The bar for what constitutes an engineering feat on HN seems to have shifted significantly.
ananandreas
Great and simple way to bridge the gap between LLMs and users coming in to the field!
cpldcpu
Love it! Great idea for the dataset.
monksy
Is this a reference from the Bobiverse?
nullbyte808
Adorable! Maybe a personality that speaks in emojis?
show comments
Vektorceraptor
Haha, funny name :)
AndrewKemendo
I love these kinds of educational implementations.
I want to really praise the (unintentional?) nod to Nagel, by limiting capabilities to representation of a fish, the user is immediately able to understand the constraints. It can only talk like a fish cause it’s very simple
Especially compared to public models, thats a really simple correspondence to grok intuitively (small LLM > only as verbose as a fish, larger LLM > more verbose) so kudos to the author for making that simple and fun.
show comments
gdzie-jest-sol
* How creating dataset? I download it but it is commpresed in binary format.
I think this is a nice project because it is end to end and serves its goal well. Good job! It's a good example how someone might do something similar for a specific purpose. There are other visualizers that explain different aspects of LLMs but this is a good applied example.
martmulx
How much training data did you end up needing for the fish personality to feel coherent? Curious what the minimum viable dataset looks like for something like this.
Propelloni
Great work! I still think that [1] does a better job of helping us understand how GPT and LLM work, but yours is funnier.
Then, some criticism. I probably don't get it, but I think the HN headline does your project a disservice. Your project does not demystify anything (see below) and it diverges from your project's claim, too. Furthermore, I think you claim too much on your github. "This project exists to show that training your own language model is not magic." and then just posts a few command line statements to execute. Yeah, running a mail server is not magic, just apt-get install exim4. So, code. Looking at train_guppylm.ipynb and, oh, it's PyTorch again. I'm better off reading [2] if I'm looking into that (I know, it is a published book, but I maintain my point).
So, in short, it does not help the initiated or the uninitiated. For the initiated it needs more detail for it to be useful, the uninitiated more context for it to be understood. Still a fun project, even if oversold.
Is there some documentation for this? The code is probably the simplest (Not So) Large Language Model implementation possible, but it is not straight forward to understand for developers not familiar with multi-head attention, ReLU FFN, LayerNorm and learned positional embeddings.
This projects shares similarities with Minix. Minix is still used at universities as an educational tool for teaching operating system design. Minix is the operating system that taught Linus Torvalds how to design (monolithic) operating systems. Similarly having students adding capabilities to GuppyLM is a good way to learn LLM design.
How does this compare to Andrej Karpathy's microgpt (https://karpathy.github.io/2026/02/12/microgpt/) or minGPT (https://github.com/karpathy/minGPT)?
https://bbycroft.net/llm has 3d Visualization of tiny example LLM layers that do a very good job at showing what is going on (https://news.ycombinator.com/item?id=38505211)
It's just so amazing that 5 years ago it would be extremely to build a conversational bot like this.
But right now people make it a hobby, and that thing can run on a laptop.
This is just so wild.
It's genuinely a great introduction to LLMs. I built my own awhile ago based off Milton's Paradise Lost: https://www.wvrk.org/works/milton
This really makes me think if it would be feasible to make an llm trained exclusively on toki pona (https://en.wikipedia.org/wiki/Toki_Pona)
Cool project. I'm working on something where multiple LLM agents share a world and interact with each other autonomously. One thing that surprised me is how much the "world" matters — same model, same prompt, but put it in a system with resource constraints, other agents, and persistent memory, the behavior changes dramatically. Made me realize we spend too much time optimizing the model and not enough thinking about the environment it operates in.
This is probably a consequence of the training data being fully lowercase:
You> hello Guppy> hi. did you bring micro pellets.
You> HELLO Guppy> i don't know what it means but it's mine.
Finally an LLM that's honest about its world model. "The meaning of life is food" is arguably less wrong than what you get from models 10,000x larger
Nice work and thanks for sharing it!
Now, I ask, have LLMs ben demystified to you? :D
I am still impressed how much (for the most part) trivial statistics and a lot of compute can do.
This is a nice idea. A tiny implementation can be way more useful for learning than yet another wrapper around a big model, especially if it keeps the training loop and inference path small enough to read end to end.
I like the idea, just that the examples are reproduced from the training data set.
How does it handle unknown queries?
Could it be possible to train LLM only through the chat messages without any other data or input?
If Guppy doesn't know regular expressions yet, could I teach it to it just by conversation? It's a fish so it wouldn't probably understand much about my blabbing, but would be interesting to give it a try.
Or is there some hard architectural limit in the current LLM's, that the training needs to be done offline and with fairly large training set.
This is such a smart way to demystify LLMs. I really like that GuppyLM makes the whole pipeline feel approachable..great work
Wow that is such a cool idea! And honestly very much needed. LLMs seem to be this blackbox nobody understands. So I love every effort to make that whole thing less mysterious. I will definitely have a look at dabbling with this, may it not be a goldfish LLM :)
> you're my favorite big shape. my mouth are happy when you're here.
Laughed loudly :-D
I am trying to find how the synthetic data was created (looking through the repo) and didn't find it. Maybe I am missing it - Would love to see the prompts and process on that aspect of the training data generation!
Does this work by just training once with next token prediction? Want to understand better how it creates fluent sentences if anyone can provide insights.
Building it yourself is always the best test if you really understand how it works.
This is so cool! I'd love to see a write-up on how made it, and what you referenced because designing neural networks always feel like a maze ;)
Forked. Very cool. I appreciate the simplicity and documentation.
Why are there so many dead comments from new accounts?
I love this! Seems like it can't understand uppercase letters though
Love it! I think it's important to understand how the tools we use (and will only increasingly use) work under the hood.
Thanks. Tinkering is how I learn and this is what I’ve been looking for.
I was going to suggest implementing RoPE to fix the context limit, but realized that would make it anatomically incorrect.
how did you generate the synthetic data?
> A 9M model can't conditionally follow instructions
How many parameters would you need for that?
This is amazing work. Thank you.
Would have been funny if it were called "DORY" due to memory recall issues of the fish vs LLMs similar recall issues :)
how's it handle longer context or does it start hallucinating after like 2 sentences? curious what the ceiling is before the 9M params
I... wow, you made an LLM that can actually tell jokes?
This is really great! I've been wanting to do something similar for a while.
I could fork it and create TrumpLM. Not a big leap, I suppose.
Hm, I can actually try the training on my GPU. One of the things I want to try next. Maybe a bit more complex than a fish :)
I don't mean to be 'that guy', but after a quick review, this really feels like low-effort AI slop to me.
There is nothing wrong using AI tools to write code, but nothing here seems to have taken more than a generic 'write me a small LLM in PyTorch' prompt, or any specific human understanding.
The bar for what constitutes an engineering feat on HN seems to have shifted significantly.
Great and simple way to bridge the gap between LLMs and users coming in to the field!
Love it! Great idea for the dataset.
Is this a reference from the Bobiverse?
Adorable! Maybe a personality that speaks in emojis?
Haha, funny name :)
I love these kinds of educational implementations.
I want to really praise the (unintentional?) nod to Nagel, by limiting capabilities to representation of a fish, the user is immediately able to understand the constraints. It can only talk like a fish cause it’s very simple
Especially compared to public models, thats a really simple correspondence to grok intuitively (small LLM > only as verbose as a fish, larger LLM > more verbose) so kudos to the author for making that simple and fun.
* How creating dataset? I download it but it is commpresed in binary format.
* How training. In cloud or in my own dev
* How creating a gguf
Tiny LLM is an oxymoron, just sayin.
Neat!
Cool
Did something similar last year https://github.com/aditya699/EduMOE
I think this is a nice project because it is end to end and serves its goal well. Good job! It's a good example how someone might do something similar for a specific purpose. There are other visualizers that explain different aspects of LLMs but this is a good applied example.
How much training data did you end up needing for the fish personality to feel coherent? Curious what the minimum viable dataset looks like for something like this.
Great work! I still think that [1] does a better job of helping us understand how GPT and LLM work, but yours is funnier.
Then, some criticism. I probably don't get it, but I think the HN headline does your project a disservice. Your project does not demystify anything (see below) and it diverges from your project's claim, too. Furthermore, I think you claim too much on your github. "This project exists to show that training your own language model is not magic." and then just posts a few command line statements to execute. Yeah, running a mail server is not magic, just apt-get install exim4. So, code. Looking at train_guppylm.ipynb and, oh, it's PyTorch again. I'm better off reading [2] if I'm looking into that (I know, it is a published book, but I maintain my point).
So, in short, it does not help the initiated or the uninitiated. For the initiated it needs more detail for it to be useful, the uninitiated more context for it to be understood. Still a fun project, even if oversold.
[1] https://spreadsheets-are-all-you-need.ai/ [2] https://github.com/rasbt/LLMs-from-scratch