Skip to content

SkyAGI: Emerging human-behavior simulation capability in LLM

License

Notifications You must be signed in to change notification settings

EvATive7/skyagi

 
 

Repository files navigation

SkyAGI: Emerging human-behavior simulation capability in LLM

SkyAGI.mp4

PyPI

SkyAGI is a python package that demonstrates LLM's emerging capability in simulating believable human behaviors. Specifically, SkyAGI implements the idea of Generative Agents and delivers a role-playing game that creates a very interesting user experience.

Different from previous AI based NPC systems, SkyAGI's NPC generates very believable human responses. The interesting observations in this demo show a huge potential for rethinking game development in many aspects, such as NPC script writing.

To demonstrate this, SkyAGI provides example characters from The Big Bang Theory and The Avengers as a starting point. Users could also define customized characters by creating config json files like customized_character.json For details about the interesting observations, refer to the observations section.

Quick Start

cd to /skyagi/src/skyagi
install packages needed via pip

pip install

create directory conf
cd to conf and create config.yaml like:

model: "openai-gpt-3.5-turbo"
#model: "openai-gpt-3.5-text-davinci-003"

openai-key:
  #- "sk-AjkPGmzC5zL1DczJ4bs75RDv49QZeH29Qb9p"
  - "sk-yWh1wDmWBQEGJxJIaZepq5xZxnCADxjXqR7"
  - "Only First Available (beta)"

NumberOfAgents: 2

#Current Dir is Running Dir
AgentFiles:
  - "conf/agent/kong.json"
  - "conf/agent/ying.json"

UserRole: 1
#UserRole: 0

#Index of the list expect the UserRole
#Examlple:
#Agent=['Kong','Ying'],UserRole=0 
# ->
#TalkToList=['Ying']
TalkTo: 0

then cd ..

python cli.py

after initializing, api will deploy at localhost:8765.

To use example agent configs, download it from here: https://github.com/litanlitudan/skyagi/tree/main/examples (pip install doesn't contain the agent configuration)

An example agent configuration (Sheldon) looks something like this:

{
    "name": "Sheldon",
    "age": 27,
    "personality": "Intelligent, rigid, socially challenged, quirky, and arrogant.",
    "memories": [
        "Sheldon is a theoretical physicist who works at Caltech.",
        "Sheldon has an eidetic memory and is highly intelligent, but struggles with social skills and sarcasm.",
        ...
        "Knock, knock, knock, Penny - This is the specific knock that Sheldon uses when he visits Penny's apartment, which he repeats three times.",
        "Bazinga! - This is Sheldon's catchphrase that he uses to indicate he was joking or playing a prank on someone."
    ],
    "current_status": "Sheldon is at the Cheesecake Factory"
}

Interesting observations in this demo

Here is a screenshot of a live demo using The Big Bang Theory example. demo From the conversation, we can observe three interesting points that have not been widely seen in previous systems:

  1. Leonard remembered that Penny had asked him to persuade Sheldon to go for a hike, which shows the capability of some kind of memory.
  2. Leonard changed his mind after Sheldon whispered to him and even tried to convince Penny to join the scientific effort, which shows that the agents had meaningful progress in the story even without human intervention.
  3. All the responses are quite human-like. As a user, it's quite hard to tell whether it's actually an AI behind the responses.

References

  1. https://arxiv.org/abs/2304.03442
  2. https://python.langchain.com/en/latest/use_cases/agent_simulations/characters.html#create-a-generative-character

About

SkyAGI: Emerging human-behavior simulation capability in LLM

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Svelte 34.7%
  • TypeScript 30.7%
  • Python 21.5%
  • JavaScript 8.6%
  • CSS 2.4%
  • Shell 1.4%
  • Other 0.7%