Home > Technology peripherals > AI > body text

Generative Agent - Declaration of Independence from NPCs

WBOY
Release: 2023-04-12 14:55:21
forward
1762 people have browsed it

Have you seen all the NPCs in the game?

No matter what the NPC does, whether they have tasks to take, or those who don’t have tasks to chat with, their common characteristic is that they keep repeating those few sentences over and over again.

The reason is also very simple, these NPCs are not smart enough.

In other words, traditional NPCs arrange the script for them first, arrange the speaking skills, and say what words they need to go to.

With the emergence of ChatGPT, the dialogues of these game characters can be self-generated by inputting only key information.

This is what researchers at Stanford and Google are doing - using artificial intelligence to create generative agents.

How to generate a generative agent?

The mechanism of this thing is actually very simple and can be summarized simply with a picture.

Generative Agent - Declaration of Independence from NPCs

The leftmost Perceive is like the initial input, and the agent begins to receive various types of information.

The big frame in the middle is the most important part. It reveals how the generative agent "generates" content and spontaneously reaches the last step of "Act" .

The main feature of the generative agent is that it has a Memory Stream, which is a memory stream.

Just like the traditional NPCs mentioned above, their actions and words are prescribed and there is no room for free play.

And if you want to play freely, you must have your own "library". This "library" contains the things that AI records and thinks about in daily life. Only in this way can we further "Act".

AI must learn.

The steps of retrieving memory, planning, and reflection are the steps in which AI processes memory. AI can not only remember what happened every day, but also reflect on these events and make plans for each day.

At the same time, they will also remember the new feedback caused by the AI's behavior and treat it as new material to continue a new round of processing.

Generative Agent - Declaration of Independence from NPCs

Observation is each character’s observation of the surrounding environment, people and things, Reflection is the observation of these Thinking about phenomena.

The characters then generate plans based on these contents.

In the beginning, they made a rough plan themselves, and then slowly refined it. First make an hourly plan, and then make a short-term plan of 5-15 minutes.

Moreover, the characters will also modify their plans according to changes in the surrounding environment. Completely imitating human behavior, who doesn't crazily revise their plans from day to day?

In this way, we see the charm of generative agents.

Generative Agent - Declaration of Independence from NPCs

We can see that the complete generative agent (including three parts: observation, thinking, and planning) The performance is much better than the architecture lacking either or both.

cute little person Emoji

In the scenario designed by Google and Stanford researchers, there are a total of 25 little AI people living in this in a map.

Generative Agent - Declaration of Independence from NPCs

The researchers set up a total of 25 characters, and set basic basics such as name and occupation for each character. information.

For example, John Lin is a drugstore clerk who is very helpful. He's always thinking about how to make it easier for his customers to get their medications.

In terms of life, John lives with his wife Mei Lin, who is a university professor. Their son Eddy Lin is studying music theory.

At the same time, the initial relationship network between the characters was also established, such as John’s relationship with his neighbor, his views on the neighbor, and his relationship with his colleagues in the pharmacy, and what he usually likes to talk about. etc.

Generative Agent - Declaration of Independence from NPCs

Each character has such a preset text, which initially outlines the character framework and triggers subsequent interactions. .

The rest is up to the AI ​​itself.

The behavior of each character will be represented by emoji and will be summarized in one sentence in the system. For example, if someone is writing a diary, he will use

Generative Agent - Declaration of Independence from NPCs

to express it.

One day, Isabella and Tom met. They chatted about the campaign.

You must know that characters can communicate with each other using complete and clear natural language. And each character can sense other nearby characters and decide whether to pass by or start a conversation based on their respective personalities and character relationships.

Generative Agent - Declaration of Independence from NPCs

Isabella: "I'm still thinking about who I should vote for. But I talked to Sam Moore about running. What do you think of him?"

Tom: "To be honest, I don't like Sam very much. I think he is a bit out of touch with our community and will not work to maximize our interests. Consider it."

And for experimental purposes, researchers can also intervene. However, this intervention differs from traditional input scripts. Instead, it exerts a little force on the direction of some branches, and the rest is left to the AI ​​itself.

As for daily life, each character will have its own "routine", and this "routine" is preset.

The following is a day in the life of pharmacy boy John Lin. As for what new things will happen every day, that is the most interesting part.

Generative Agent - Declaration of Independence from NPCs

Finally, let’s take a look at some interesting interactions between AIs on Valentine’s Day.

Generative Agent - Declaration of Independence from NPCs

On Valentine's Day, the researchers gave each of the two characters Isabella and Maria a preset message telling them Isabella is going to throw a party and tell Maria that she likes Klaus.

Then, the two characters began to play on their own.

Isabella wanders around the map and invites people to her party when she sees them.

Generative Agent - Declaration of Independence from NPCs

This includes Maria. Maria would definitely not miss this opportunity to get along with Klaus, so she found Klaus and invited him to go to Isabella's party.

#Isabella didn’t sit around after inviting everyone. She went to the coffee shop to decorate the venue and invited Maria to help.

Generative Agent - Declaration of Independence from NPCs

The above picture shows the relationship between these AIs and the interactions caused by the party.

Then a group of people AI happily started the party at five o'clock in the afternoon.

The picture below details how the party was spontaneously guided by AI. Involves memory retrieval, reflection from observations of the environment, and decision-making.

Generative Agent - Declaration of Independence from NPCs

The left side is the environmental content observed by Isabella, such as idle refrigerators, beds, shelves, desks, wardrobes, etc. Wait, and then make decisions about decorations, invitations, party design, etc. based on the environment and the intention of hosting the party.

In this way, the whole process seems very full.

Science fiction becomes reality?

The above scenes seem simple and fun, but the more they develop, the more they can show different powers.

Pete said on Twitter that this result can be applied in many ways in the future.

Generative Agent - Declaration of Independence from NPCs

For example, if it is applied in the VR world, with this kind of generative agent acting as an NPC, it must be like in Westworld Envisioned scenarios are no longer out of reach.

"In Western World, every NPC has its own thoughts, personality, plans, and interpersonal relationships. Even more things are generated independently."

And this thing made by researchers from Google and Stanford is a mini Q version of Westworld.

References:

https://twitter.com/nonmayorpete/status/1645355225157615616 https://www.reddit.com/r/MachineLearning/comments/ 12hluz1/r_generative_agents_interactive_simulacra_of/

The above is the detailed content of Generative Agent - Declaration of Independence from NPCs. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:51cto.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!