https://github.com/0plus1/parleygpt
A node based argument engine between two prompts
https://github.com/0plus1/parleygpt
Last synced: over 1 year ago
JSON representation
A node based argument engine between two prompts
- Host: GitHub
- URL: https://github.com/0plus1/parleygpt
- Owner: 0plus1
- License: mit
- Created: 2023-05-20T02:02:03.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-05-20T07:11:04.000Z (about 3 years ago)
- Last Synced: 2025-02-02T11:29:22.337Z (over 1 year ago)
- Language: TypeScript
- Size: 34.2 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

# Parley GPT
A node based chatGPT argument engine between two prompts.
## Background
I have been playing with some wild prompts exposed as bots in one of my friend's telegram group chats.
These bots have provided some good entertainment and that inspired me to wonder: "What would happen if these prompts would start arguing?".
The idea behind this project is to provide two diverging prompts, instance them and feed the responses to each other as a parley between two LLMs.
### Examples
In the examples folders there are some example dialogues to showcase the potential.
[John Wick and Gandalf](./examples/wick-and-gandalf.md)
[Rocky Balboa and Jar Jar Binks](./examples/rocky-and-binks.md)
[A drunk and a dream interpreter](./examples/drunken-dreams.md)
[Hello kitty and Voldemort](./examples/hellokitty-and-voldemort.md)
After running several tests, I found that the results can be very different, even with the exact same parameters.
With fictional characters, after running more than 6 iteration, the dialogue starts to become stale.
If you created any fun dialogue please feel free to share by opening a PR, would love to see what you come up!
## Install
Clone the repo then run `yarn install`
Requires `node >= 18`, to manage node version consider using [nvm](https://github.com/nvm-sh/nvm)
### Usage
Create a local .env file with all the required vars:
* `OPENAI_API_KEY` Your OpenAI key
* `ITERATIONS` Number of dialogues
* `INTERLOCUTOR_ONE_PROMPT` Prompt for the first interlocutor
* `INTERLOCUTOR_ONE_NAME` Name of the first interlocutor
* `INTERLOCUTOR_TWO_PROMPT` Prompt for the second interlocutor
* `INTERLOCUTOR_TWO_NAME` Name of the second interlocutor
* `TOPIC` Conversation starter, will be asked to the first interlocutor, then the conversation carries anonymously
* `DEBUG` Print debug info
Run `yarn dev`.
## Roadmap
- ✅ MVP
- Types coverage
- Tests
- Debug and error catching
- Web UI
- Publish as a package
- Code organisation