Skip to content

Roleplay Therapy is a Python script that utilizes the OpenAI API to generate a conversation between two actors discussing a given topic. The script simulates a therapeutic conversation between two actors, where they take turns to talk to each other and share their thoughts on a given topic.

License

Notifications You must be signed in to change notification settings

krecicki/Roleplay-Therapy-GPT-3.5-Turbo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

Roleplay-Therapy-GPT-3.5-Turbo

Roleplay Therapy is a Python script that utilizes the OpenAI API to generate a conversation between two actors discussing a given topic. The script simulates a therapeutic conversation between two actors, where they take turns to talk to each other and share their thoughts on a given topic.

Want to help me help people help themselves? Contribute to this script.

Roleplay Therapy

Roleplay Therapy is a Python script that utilizes the OpenAI API to generate a conversation between two actors discussing a given topic. The script simulates a therapeutic conversation between two actors, where they take turns to talk to each other and share their thoughts on a given topic.

How to Use

To use this script, follow the instructions below:

Install the openai package by running pip install openai==0.10.2 in your terminal or command prompt.

Obtain an OpenAI API key from https://beta.openai.com/signup/

Clone this repository to your local machine.

Open the script and replace the API key on lines 11 and 29 with your own API key.

Replace the topic variable with your own desired topic.

Run the script by running python app.py in your terminal or command prompt.

The script will initiate a conversation between two actors, simulating a therapeutic conversation. The actors will take turns to talk to each other, and their responses will be generated by the OpenAI API based on the given topic. The conversation will continue until the loop is finished, generating a total of 50 responses.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Example chat between Sigmund Freud and Carl Jung talking about a boys love for his mother.

Roleplaying Carl Jung and Sigmund Freud discussing Discuss a boys love of his mother. (GPT-3.5-Turbo)

(expand the Tweet to see the conversation)

I wrote a script in python to have GPT talk to itself but by role playing two different characters.

The Conversation Carl Jung: A boy's love for his mother is a natural and healthy part of development, but if it becomes excessive or possessive it may indicate deeper psychological issues.

Sigmund Freud: However, it is important to distinguish between a natural attachment to one's mother and a pathological fixation caused by unconscious conflicts.

Carl Jung: Our discussion leads us to acknowledge the importance of the unconscious in shaping a boy's love for his mother.

Sigmund Freud: The unconscious plays a significant role in shaping a boy's love for his mother.

Carl Jung: It is important to consider the father's role in the development of the child's psyche.

Sigmund Freud: Indeed, the child's psyche is influenced by a variety of factors, including early experiences with their parents.

Carl Jung: However, it is important to consider the individual's unique experiences and subconscious desires in regards to their relationships with their parents.

Sigmund Freud: The boy's love for his mother could potentially lead to unresolved conflicts with his father.

Carl Jung: However, it is important to also consider the individual's personal experiences and unconscious motivations when exploring a boy's love for his mother.

Sigmund Freud: Yes, the boy's love for his mother may be influenced by his early childhood experiences with her.

Carl Jung: Yes, a boy's love for his mother can have a significant impact on his future relationships with women.

Sigmund Freud: The Oedipus complex refers to a child's unconscious desire to replace their same-sex parent and possess the opposite-sex parent.

Carl Jung: However, it is important to note that a boy's love for his mother is a natural and necessary stage of development, and it is the resolution of the Oedipus complex that leads to a healthy development of relationships with both parents.

Sigmund Freud: I agree, unresolved attachment to both parents can lead to unhealthy relationships. Carl Jung: This impact can manifest in how the son views and interacts with his romantic partners in adulthood.

Sigmund Freud: The way a man interacts with his romantic partners in adulthood can be influenced by his early experiences with his mother.

Carl Jung: The Oedipus complex is a concept proposed by Freud to explain the natural development of male children's sexual attraction to their mothers and rivalries with their fathers.

Sigmund Freud: The Oedipal complex suggests boys may have unconscious sexual desires towards their mothers and see their fathers as a rival.

Carl Jung: The child may also develop an unconscious desire to replace their father as the object of their mother's love.

Sigmund Freud: Sometimes a boy may desire to replace his father as the object of his mother's love, as part of the Oedipus complex.

Carl Jung: The Oedipus complex is a controversial theory, and some argue that it may not be applicable to all individuals.

Sigmund Freud: Although, it is still considered an important concept in psychoanalytic theory.

About

Roleplay Therapy is a Python script that utilizes the OpenAI API to generate a conversation between two actors discussing a given topic. The script simulates a therapeutic conversation between two actors, where they take turns to talk to each other and share their thoughts on a given topic.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages