ianb / llm-garden

A number of experiments using GPT-3, delivered in a web app
https://llm.ianbicking.org
48 stars 8 forks source link

Miniature text adventure #3

Open ianb opened 1 year ago

ianb commented 1 year ago

Kind of like AI Dungeon, but with smaller scope and more infrastructure.

There would be a specific initial scope. You can ask the LLM to manufacture this context. Like maybe you say:

> make a list of rooms in a castle

Great hall
Banquet hall
Throne room
Guard room
Kitchen
Dining room
Drawing room
Library
Armory
Bedchambers

Now you remember that list and use it in the prompt. Then when you go into a room you do:

> List all the things you can see in a castle drawing room

Sofas and chairs
Tables
Fireplace
Tapestries and paintings
Chandeliers or other lighting fixtures
Books and other reading materials
Musical instruments
Games and entertainment equipment
Window seats with views of the castle grounds
Decorative objects and art pieces
Rugs or carpets on the floor.

(Not sure if there's any real purpose to a list of things)

> Write a literary description of the castle drawing room

The castle drawing room was a grand and elegant space, filled with luxurious furnishings and rich with history. The walls were adorned with tapestries and paintings, and the room was illuminated by sparkling chandeliers that cast a warm, inviting light. A cozy fireplace provided a gathering place for guests, and comfortable sofas and chairs invited them to sit and relax. Books and other reading materials were available for those who wished to engage in quiet pursuits, and musical instruments stood ready for anyone who felt inspired to make music. The room was also equipped with games and entertainment equipment, and several window seats offered breathtaking views of the castle grounds. Overall, the drawing room was a welcoming and comfortable space that invited guests to relax and enjoy the company of others.

Now that description can be saved, and recalled based on your location.

I'm not sure how to actually keep track of the location. I can imagine having the LLM say where you are located as part of the resulting statement, but how do you get it to do that? There's a similar issue if we want it to emit time spans so we can track other things happening elsewhere. I imagine (but am skeptical) that you could ask it to emit that data and then use regexes to try to capture it. (But what if it's not found? Do you assume the person didn't move, or some fallback amount of time?)


To actually try this I think it'll be easiest to develop one fixed environment. I'm thinking something like a prison escape or limited dungeon crawl. Maybe a murder mystery?

ianb commented 1 year ago

I like this prompt:

make a list of characters from a murder mystery set in 1960s Detroit

Here is a list of possible characters for a murder mystery set in 1960s Detroit:

Detective Jack Brown: a tough and experienced detective who has seen it all in the streets of Detroit.

Mr. Frank Thompson: a wealthy and ruthless businessman who is found dead in his office, with a bullet hole in his head.

Mrs. Sarah Thompson: the victim's wife, who is known for her expensive taste and explosive temper.

Mr. Mike Williams: the victim's business partner, who is rumored to have had a falling out with the victim over a deal gone wrong.

Miss Jessica Jones: a young and ambitious secretary who worked for the victim.

Mr. Tom Williams: the victim's younger brother, who is a struggling artist with a troubled past.

Mrs. Anna Thompson: the victim's mother, who is a devout Catholic and a devout socialite.

Mr. David Jones: the victim's chief accountant, who is known for his sharp mind and shady deals.

Miss Emily Williams: the victim's daughter, who is a rebellious teenager with a wild streak.

Mr. Joe Brown: a corrupt police officer who is on the take from the victim's business.