Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkDaoust committed Jan 9, 2025
1 parent 2abbd19 commit 6543cd0
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions gemini-2/live_api_starter.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 1,
"metadata": {
"id": "46zEFO2a9FFd"
},
Expand Down Expand Up @@ -125,7 +125,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 2,
"metadata": {
"id": "A1pkoyZb9Jm3"
},
Expand All @@ -151,7 +151,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 3,
"metadata": {
"id": "HghvVpbU0Uap"
},
Expand All @@ -174,7 +174,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 4,
"metadata": {
"id": "27Fikag0xSaB"
},
Expand All @@ -196,7 +196,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 5,
"metadata": {
"id": "Yd1vs3cP8EmS"
},
Expand Down Expand Up @@ -236,7 +236,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 7,
"metadata": {
"id": "dDfslcyIOqgI"
},
Expand All @@ -260,7 +260,7 @@
"async with client.aio.live.connect(model=MODEL, config=config) as session:\n",
" message = \"Hello? Gemini are you there?\"\n",
" print(\"> \", message, \"\\n\")\n",
" await session.send(message, end_of_turn=True)\n",
" await session.send(input=message, end_of_turn=True)\n",
"\n",
" # For text responses, When the model's turn is complete it breaks out of the loop.\n",
" turn = session.receive()\n",
Expand Down Expand Up @@ -289,7 +289,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 8,
"metadata": {
"id": "7mEDGwJfLRrm"
},
Expand Down Expand Up @@ -317,7 +317,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 20,
"metadata": {
"id": "VFD4VleVKj1-"
},
Expand Down Expand Up @@ -361,7 +361,7 @@
" with wave_file(file_name) as wav:\n",
" message = \"Hello? Gemini are you there?\"\n",
" print(\"> \", message, \"\\n\")\n",
" await session.send(message, end_of_turn=True)\n",
" await session.send(input=message, end_of_turn=True)\n",
"\n",
" turn = session.receive()\n",
" async for n,response in async_enumerate(turn):\n",
Expand Down Expand Up @@ -410,7 +410,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 21,
"metadata": {
"id": "bWTaU8j-X3AJ"
},
Expand All @@ -433,7 +433,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 45,
"metadata": {
"id": "3zAjMOZXFuxI"
},
Expand Down Expand Up @@ -480,7 +480,7 @@
" logger.debug('send')\n",
"\n",
" # Send the message to the model.\n",
" await self.session.send(text, end_of_turn=True)\n",
" await self.session.send(input=text, end_of_turn=True)\n",
" logger.debug('sent')\n",
" yield text\n",
"\n",
Expand Down Expand Up @@ -575,7 +575,7 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 46,
"metadata": {
"id": "WxdwgTKIGIlY"
},
Expand Down

0 comments on commit 6543cd0

Please sign in to comment.