Live data from Hacker News

I built a low-latency AI companion that plays Skyrim with me

pantel.is

21–30 of 85 posts

Re: I built a low-latency AI companion that plays Skyrim with me

#21

Video game seem like the perfect fit for llm use and I don't understand why it hasn't happened already.

It depends on if you want samey games or anything creative.

You could have complex realistic dialogue for innkeeper #28917 in the little hamlet of ass backwards, but:

One: do you really want that? There is such a thing as too much realism in a video game.

Two: do you really want all NPCs in all games to speak nigerian business english?

Reminder for 2: https://www.theguardian.com/technology/2024/apr/16/techscape...

Re: I built a low-latency AI companion that plays Skyrim with me

#22
post #3

I like the approach here. It’s cleverer than just “dump context to LLM”. I couldn’t quite figure out if it genuinely runs purely locally though. If nothing else - this is how NPCs should work in games moving forward!

Hello, author here. I was intentionally a little vague about this because this is kind of the thing that makes the whole approach work. An LLM predicts the next token. If you're trying to predict the next token in a mathematics competition, or while playing a deep strategy game, being a much larger and more capable model helps enormously. To predict that next token correctly, the model effectively needs to model a bu…

What I don't understand is how are you passing the world state to the model?

Say for instance when you ask the dog to do an action when you launch an arrow upwards how is the LLM continuously tracking the state of the game to be able to respond?

Re: I built a low-latency AI companion that plays Skyrim with me

#25
This is the sort of thing that the GPT-Live model would excel at when it launches. I'm not sure you'd need the ALE model at all if they launch Live in the API with acceptable pricing as it solves the latency issues with voice entirely. It's an impressive piece of engineering that hasn't been discussed much yet, I guess because it's only a ChatGPT feature and not accessible to developers. The model can dispatch tools asynchronously while speaking which would be ideal for a game.

What you'd want is maybe some kind of Live model with voice warping so it can be given different Skyrim themed 'Nordic' voices, and then custom tools to interact with the game engine.

Re: I built a low-latency AI companion that plays Skyrim with me

#27

Earlier quoted context omitted.

Hello, author here. I was intentionally a little vague about this because this is kind of the thing that makes the whole approach work. An LLM predicts the next token. If you're trying to predict the next token in a mathematics competition, or while playing a deep strategy game, being a much larger and more capable model helps enormously. To predict that next token correctly, the model effectively needs to model a bu…

What I don't understand is how are you passing the world state to the model? Say for instance when you ask the dog to do an action when you launch an arrow upwards how is the LLM continuously tracking the state of the game to be able to respond?

At that point it's deterministic and doesn't need the LLM. Once a plan has been decomposed and evaluated, it becomes a sequence of actions. Actions can either wait on a trigger or flow from one to another.

For the arrow example: wait here -> bind: arrow event -> pick_up $target -> goto player -> drop $target.

A plan can bind to multiple steps and actions. eg you can tell the dog, "when I say apple you say banana" this creates a short lived "player has said %apple%" -> say "banana" rule. Hide and seek does "say: count to 10" (this then gets fed to llm that converts it to "one, two, three"). So, the plan decomposition is fuzzy, but it gets decomposed to concrete steps, these steps might invoke the LLM back if needed so, but mostly for color, not logic.

Where the LLM is used afterwards, is for evaluating the result. The dog might ask for a treat if it got right or get frustrated is it misses a beat, etc (depending on emotional state, hunger levels, etc).

Basically trying to use the best of each system (fuzzy/vague/emotional for LLM, "hard" game actions for determinism). You can think of Ale's output as a small flowchart.

I am using a pretty dumb model. It's great for speaking, terrible for thinking, so there's a need for creativity

Re: I built a low-latency AI companion that plays Skyrim with me

#29
post #21

Video game seem like the perfect fit for llm use and I don't understand why it hasn't happened already.

It depends on if you want samey games or anything creative. You could have complex realistic dialogue for innkeeper #28917 in the little hamlet of ass backwards, but: One: do you really want that? There is such a thing as too much realism in a video game. Two: do you really want all NPCs in all games to speak nigerian business english? Reminder for 2: https://www.theguardian.com/technology/2024/apr/16/techscape...

It's a simple thing:

Who wants to read AI-generated articles and respond to AI-generated comments? Probably not many. For same reason gamers mostly don't want to chat with AI-backed NPCs. More is only better when it has meaning.

Post reply on HN