Hacker News new | past | comments | ask | show | jobs | submit login
Show HN: LLM-driven Tamagotchi built with JavaScript and local model (github.com/ykhli)
2 points by ykhli on Dec 8, 2023 | hide | past | favorite | 1 comment
Hi HN!

This is a local-ready LLM-generated and LLM-driven tamagotchi with thoughts and feelings. 100% Javascript and costs $0 to run.

- Try here https://github.com/ykhli/AI-tamago

This is a personal project I've been hacking on and off for a few months - all ASCII art animation generated from chatgpt.

I have been fascinated by how LLMs transformed app logic, so I thought: what’s the simplest game I could build after ai town? A tamagotchi comes to mind - and it’s a perfect study of how to work with LLMs as a programmer. Some interesting things that stood out while building this:

- it’s really hard to version control the app logic when you have prompts that return somewhat unpredictable things in the app. Sure, we can put guardrails round the returned result, but there are always corner cases that don’t quite work. Sometimes the JSON output doesn’t return all the required fields, and once in a while it returns empty strings as part of values…

- I love that LLMs sometimes outputs crazy things for the tamagotchi. Here are some examples: - It somehow became self aware? “I haven't had any food that I liked in a while and I've been cooped up in this virtual environment for a while now.” - It got confused and thought it fed ME: “I had a good day! I played with my owner and fed them tamago (which they love)” … This is when bugs are actually features :)

Would love to hear your thoughts!




did you also compare how it runs with a larger model like GPT4?

I'm curious if the experience was significantly different for confined use-cases like this




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: