Type 2 - Simulation - Environment

Search for a command to run...

No comments yet. Be the first to comment.
What is a "virtual world"? I want to make it clear that when I describe a virtual world, I do not mean a digital world. Imagine Harry Potter. Hogwarts is a virtual world. It isn't virtual because it i

Motivation: Monet currently lives inside my MacBook. It suspends itself when my MacBook is closed. I like the design but whenever I'm walking around, I really wish I can have Monet alive. Problem: Mon

I'm trying out the AI Avatar feature on https://dreamia.capcut.com. As input, we are providing Monet's idle pose. Then asking it to produce video. The character says: Hey Jin, how is it going today

Problem: When I ask Monet about her favorite food, she answers "I've never tasted anything." Analysis: This isn't a bug. It is the expected behavior. AI agents never actually tasted anything. They hav

I've been in travel mode for the past few weeks, so I haven't written anything in a while. I want to get back into the habit of documenting my thoughts as I build Sprited. Here are today's thoughts. T

Sprited
298 posts
In previous post, we discussed roadblocks on building Type 2 Harness UI.
One of the issues was that we needed to build a environment to simulate our digital beings, and we decided to use the Celeste-like environment.
So, we built tile based environment like Celeste.
Map Definition:
<?xml version='1.0' encoding='UTF-8'?>
<map>
<levels>
<level
name="lvl-0"
width="448"
height="184"
x="-48"
y="0"
>
<solids offsetX="0" offsetY="0">
;
;
;
;
;
;
;
;
00000000000000000000000000111100000000000000000000000000;
00000000000000000000000000000000000000000000000000000000;
00000000000000000000000000000000000000000000000000000000;
00000000000000000011110000000000000000000000000000000000;
00000000000000000000000000000000000000010000000000000000;
00000000000000000000000000000000000000010000000000000000;
00000000001111000000000000000000000000011111110000000000;
00000000000000000000000000000000000000000000000000000000;
00000000000000000000000000000000000000000000000000000000;
00000000000000001111111111111111111111110000000000000000;
00000000000000011111111111111111111111111000000000000000;
00000000000000011111111111111111111111111000000000000000;
00000000000001111111111111111111111111111110000000000000;
00000000000011111111111111111111111111111111000000000000;
00000000011111111111111111111111111111111111111000000000;
</solids>
<entities offsetX="0" offsetY="0">
<player id="4" x="224" y="136" />
<strawberry id="1" x="338" y="108" spawnAfter="2000" />
</entities>
<bg offsetX="0" offsetY="0">
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
;
</bg>
</level>
</levels>
</map>
Now, the entity can stand and even navigate to adjacent levels.
Basic physics has been implemented as well. If they fall off the cliff, they die.
At this time, they can be controlled using keyboard Left Right Up Down and Space (Jump).
Figure 1: Manual Control
We also realized that we would want basic path finding system. The path finding in the platformer world is not obvious but we got to a satisfactory solution.
Basically, for each standable tile, we do simulations to check reachable other tiles to create a reachability graph (along with movements that can get you there). Then rest is path finding.
Figure 2: Path finding demo. AI controls the character to get from point A to point B.
I think I got too engrossed in this and really need to focus back on to simulating digital being.
However, the key is that we have a world that we can place our digital being on top of and that we solved waypoint navigation.
So, we can ask LLM to just say desired XY position, and we can have our agent move their on it s own.
Next thing to focus on is to migrate this code over to new "anima" repo and add body simulation to it.
We won't be working on making this pretty at this point in time. The goal of agent is going to be to stay alive. I think we will make the food spawn randomly at a location and have LLM determine next action based on current state. For the LLM, we will start with few-shot prompting on OpenAI APIs.
Tricky thing is that we are not sure how to provide a challenging enough scenario.
It would be good to have something that requires world knowledge like grabbing a key and then opening a door. Or something like adding adversary to make it so that character can run away.
-- Sprited Dev 🐛