Refactor: Change class name, comment out code
This commit is contained in:
@@ -7,7 +7,7 @@
|
|||||||
"source": [
|
"source": [
|
||||||
"# Week 2 Day 1 - Conversation between three AI's\n",
|
"# Week 2 Day 1 - Conversation between three AI's\n",
|
||||||
"\n",
|
"\n",
|
||||||
"This notebook defines three classes (`ThreePartyChat`, `Participant` and `Model`) that implement a 3-party chat between different AI's. \n",
|
"This notebook defines three classes (`ThreeWayChat`, `Participant` and `Model`) that implement a 3-way conversation between different AI's. \n",
|
||||||
"\n",
|
"\n",
|
||||||
"At the bottom there is an example conversation between a Claude model and two GPT models.\n",
|
"At the bottom there is an example conversation between a Claude model and two GPT models.\n",
|
||||||
"\n",
|
"\n",
|
||||||
@@ -174,7 +174,7 @@
|
|||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"class ThreePartyChat:\n",
|
"class ThreeWayChat:\n",
|
||||||
" \"\"\"Make three Participants communicate.\"\"\"\n",
|
" \"\"\"Make three Participants communicate.\"\"\"\n",
|
||||||
" def __init__(self, participants, n_turns=4):\n",
|
" def __init__(self, participants, n_turns=4):\n",
|
||||||
" \"\"\"\n",
|
" \"\"\"\n",
|
||||||
@@ -311,12 +311,12 @@
|
|||||||
"p3 = Participant(name=name3, model=gpt_model, system_prompt=system3, initial_message=\"Hey guys\")\n",
|
"p3 = Participant(name=name3, model=gpt_model, system_prompt=system3, initial_message=\"Hey guys\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# To make a mock run without API calls:\n",
|
"# To make a mock run without API calls:\n",
|
||||||
"p1 = Participant(name=name1, system_prompt=system1, initial_message=\"Hello there\")\n",
|
"# p1 = Participant(name=name1, system_prompt=system1, initial_message=\"Hello there\")\n",
|
||||||
"p2 = Participant(name=name2, system_prompt=system2, initial_message=\"Good evening.\")\n",
|
"# p2 = Participant(name=name2, system_prompt=system2, initial_message=\"Good evening.\")\n",
|
||||||
"p3 = Participant(name=name3, system_prompt=system3, initial_message=\"Hey guys\")\n",
|
"# p3 = Participant(name=name3, system_prompt=system3, initial_message=\"Hey guys\")\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Create Chat\n",
|
"# Create Chat\n",
|
||||||
"chat = ThreePartyChat((p1, p2, p3))"
|
"chat = ThreeWayChat((p1, p2, p3))"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user