From b91e2cc20142c617a7da41780f5d1a8d25cd587c Mon Sep 17 00:00:00 2001 From: Justin Lee Date: Wed, 6 Nov 2024 18:20:57 -0800 Subject: [PATCH] minor improvement --- .../03_Tool_Calling101.ipynb | 90 ++++--------------- 1 file changed, 17 insertions(+), 73 deletions(-) diff --git a/docs/zero_to_hero_guide/03_Tool_Calling101.ipynb b/docs/zero_to_hero_guide/03_Tool_Calling101.ipynb index f003fa1f9..670d3670f 100644 --- a/docs/zero_to_hero_guide/03_Tool_Calling101.ipynb +++ b/docs/zero_to_hero_guide/03_Tool_Calling101.ipynb @@ -38,47 +38,7 @@ }, { "cell_type": "code", - "execution_count": 5, - "metadata": {}, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "Requirement already satisfied: llama_stack_client in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (0.0.41)\n", - "Collecting llama_stack_client\n", - " Downloading llama_stack_client-0.0.49-py3-none-any.whl.metadata (13 kB)\n", - "Requirement already satisfied: anyio<5,>=3.5.0 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from llama_stack_client) (4.6.2)\n", - "Requirement already satisfied: distro<2,>=1.7.0 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from llama_stack_client) (1.9.0)\n", - "Requirement already satisfied: httpx<1,>=0.23.0 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from llama_stack_client) (0.27.0)\n", - "Requirement already satisfied: pydantic<3,>=1.9.0 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from llama_stack_client) (2.9.2)\n", - "Requirement already satisfied: sniffio in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from llama_stack_client) (1.3.0)\n", - "Requirement already satisfied: tabulate>=0.9.0 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from llama_stack_client) (0.9.0)\n", - "Requirement already satisfied: typing-extensions<5,>=4.7 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from llama_stack_client) (4.11.0)\n", - "Requirement already satisfied: idna>=2.8 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from anyio<5,>=3.5.0->llama_stack_client) (3.10)\n", - "Requirement already satisfied: exceptiongroup>=1.0.2 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from anyio<5,>=3.5.0->llama_stack_client) (1.2.0)\n", - "Requirement already satisfied: certifi in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from httpx<1,>=0.23.0->llama_stack_client) (2024.8.30)\n", - "Requirement already satisfied: httpcore==1.* in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from httpx<1,>=0.23.0->llama_stack_client) (1.0.2)\n", - "Requirement already satisfied: h11<0.15,>=0.13 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from httpcore==1.*->httpx<1,>=0.23.0->llama_stack_client) (0.14.0)\n", - "Requirement already satisfied: annotated-types>=0.6.0 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from pydantic<3,>=1.9.0->llama_stack_client) (0.7.0)\n", - "Requirement already satisfied: pydantic-core==2.23.4 in /home/justinai/.conda/envs/agentstore/lib/python3.10/site-packages (from pydantic<3,>=1.9.0->llama_stack_client) (2.23.4)\n", - "Downloading llama_stack_client-0.0.49-py3-none-any.whl (280 kB)\n", - "Installing collected packages: llama_stack_client\n", - " Attempting uninstall: llama_stack_client\n", - " Found existing installation: llama_stack_client 0.0.41\n", - " Uninstalling llama_stack_client-0.0.41:\n", - " Successfully uninstalled llama_stack_client-0.0.41\n", - "Successfully installed llama_stack_client-0.0.49\n" - ] - } - ], - "source": [ - "!pip install --upgrade llama_stack_client" - ] - }, - { - "cell_type": "code", - "execution_count": 6, + "execution_count": 2, "metadata": {}, "outputs": [], "source": [ @@ -137,7 +97,7 @@ }, { "cell_type": "code", - "execution_count": 7, + "execution_count": 3, "metadata": {}, "outputs": [ { @@ -149,20 +109,14 @@ "Query: What are the latest developments in quantum computing?\n", "--------------------------------------------------\n", "\u001b[30m\u001b[0m\u001b[33minference> \u001b[0m\u001b[33mF\u001b[0m\u001b[33mIND\u001b[0m\u001b[33mINGS\u001b[0m\u001b[33m:\n", - "\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m computing\u001b[0m\u001b[33m has\u001b[0m\u001b[33m made\u001b[0m\u001b[33m significant\u001b[0m\u001b[33m progress\u001b[0m\u001b[33m in\u001b[0m\u001b[33m recent\u001b[0m\u001b[33m years\u001b[0m\u001b[33m,\u001b[0m\u001b[33m with\u001b[0m\u001b[33m several\u001b[0m\u001b[33m companies\u001b[0m\u001b[33m and\u001b[0m\u001b[33m research\u001b[0m\u001b[33m institutions\u001b[0m\u001b[33m making\u001b[0m\u001b[33m breakthrough\u001b[0m\u001b[33ms\u001b[0m\u001b[33m in\u001b[0m\u001b[33m the\u001b[0m\u001b[33m field\u001b[0m\u001b[33m.\u001b[0m\u001b[33m Some\u001b[0m\u001b[33m of\u001b[0m\u001b[33m the\u001b[0m\u001b[33m latest\u001b[0m\u001b[33m developments\u001b[0m\u001b[33m include\u001b[0m\u001b[33m:\n", - "\n", - "\u001b[0m\u001b[33m*\u001b[0m\u001b[33m Google\u001b[0m\u001b[33m's\u001b[0m\u001b[33m S\u001b[0m\u001b[33myc\u001b[0m\u001b[33mam\u001b[0m\u001b[33more\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m processor\u001b[0m\u001b[33m,\u001b[0m\u001b[33m which\u001b[0m\u001b[33m achieved\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m supremacy\u001b[0m\u001b[33m in\u001b[0m\u001b[33m \u001b[0m\u001b[33m201\u001b[0m\u001b[33m9\u001b[0m\u001b[33m by\u001b[0m\u001b[33m performing\u001b[0m\u001b[33m a\u001b[0m\u001b[33m complex\u001b[0m\u001b[33m calculation\u001b[0m\u001b[33m that\u001b[0m\u001b[33m was\u001b[0m\u001b[33m beyond\u001b[0m\u001b[33m the\u001b[0m\u001b[33m capabilities\u001b[0m\u001b[33m of\u001b[0m\u001b[33m classical\u001b[0m\u001b[33m computers\u001b[0m\u001b[33m (\u001b[0m\u001b[33mSource\u001b[0m\u001b[33m:\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m Sup\u001b[0m\u001b[33mrem\u001b[0m\u001b[33macy\u001b[0m\u001b[33m Using\u001b[0m\u001b[33m a\u001b[0m\u001b[33m \u001b[0m\u001b[33m53\u001b[0m\u001b[33m-Q\u001b[0m\u001b[33mubit\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Computer\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Google\u001b[0m\u001b[33m Researchers\u001b[0m\u001b[33m,\u001b[0m\u001b[33m ar\u001b[0m\u001b[33mX\u001b[0m\u001b[33miv\u001b[0m\u001b[33m:\u001b[0m\u001b[33m191\u001b[0m\u001b[33m0\u001b[0m\u001b[33m.\u001b[0m\u001b[33m113\u001b[0m\u001b[33m33\u001b[0m\u001b[33m).\n", - "\u001b[0m\u001b[33m*\u001b[0m\u001b[33m IBM\u001b[0m\u001b[33m's\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Experience\u001b[0m\u001b[33m,\u001b[0m\u001b[33m a\u001b[0m\u001b[33m cloud\u001b[0m\u001b[33m-based\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m computer\u001b[0m\u001b[33m that\u001b[0m\u001b[33m allows\u001b[0m\u001b[33m users\u001b[0m\u001b[33m to\u001b[0m\u001b[33m run\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m algorithms\u001b[0m\u001b[33m and\u001b[0m\u001b[33m experiments\u001b[0m\u001b[33m (\u001b[0m\u001b[33mSource\u001b[0m\u001b[33m:\u001b[0m\u001b[33m IBM\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Experience\u001b[0m\u001b[33m,\u001b[0m\u001b[33m IBM\u001b[0m\u001b[33m Research\u001b[0m\u001b[33m).\n", - "\u001b[0m\u001b[33m*\u001b[0m\u001b[33m Rig\u001b[0m\u001b[33metti\u001b[0m\u001b[33m Computing\u001b[0m\u001b[33m's\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m cloud\u001b[0m\u001b[33m platform\u001b[0m\u001b[33m,\u001b[0m\u001b[33m which\u001b[0m\u001b[33m provides\u001b[0m\u001b[33m access\u001b[0m\u001b[33m to\u001b[0m\u001b[33m a\u001b[0m\u001b[33m \u001b[0m\u001b[33m128\u001b[0m\u001b[33m-q\u001b[0m\u001b[33mubit\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m processor\u001b[0m\u001b[33m (\u001b[0m\u001b[33mSource\u001b[0m\u001b[33m:\u001b[0m\u001b[33m Rig\u001b[0m\u001b[33metti\u001b[0m\u001b[33m Computing\u001b[0m\u001b[33m,\u001b[0m\u001b[33m Rig\u001b[0m\u001b[33metti\u001b[0m\u001b[33m.com\u001b[0m\u001b[33m).\n", - "\u001b[0m\u001b[33m*\u001b[0m\u001b[33m Microsoft\u001b[0m\u001b[33m's\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Development\u001b[0m\u001b[33m Kit\u001b[0m\u001b[33m,\u001b[0m\u001b[33m a\u001b[0m\u001b[33m set\u001b[0m\u001b[33m of\u001b[0m\u001b[33m tools\u001b[0m\u001b[33m and\u001b[0m\u001b[33m software\u001b[0m\u001b[33m for\u001b[0m\u001b[33m developing\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m algorithms\u001b[0m\u001b[33m and\u001b[0m\u001b[33m applications\u001b[0m\u001b[33m (\u001b[0m\u001b[33mSource\u001b[0m\u001b[33m:\u001b[0m\u001b[33m Microsoft\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Development\u001b[0m\u001b[33m Kit\u001b[0m\u001b[33m,\u001b[0m\u001b[33m Microsoft\u001b[0m\u001b[33m.com\u001b[0m\u001b[33m).\n", - "\u001b[0m\u001b[33m*\u001b[0m\u001b[33m The\u001b[0m\u001b[33m development\u001b[0m\u001b[33m of\u001b[0m\u001b[33m new\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m error\u001b[0m\u001b[33m correction\u001b[0m\u001b[33m techniques\u001b[0m\u001b[33m,\u001b[0m\u001b[33m such\u001b[0m\u001b[33m as\u001b[0m\u001b[33m surface\u001b[0m\u001b[33m codes\u001b[0m\u001b[33m and\u001b[0m\u001b[33m top\u001b[0m\u001b[33mological\u001b[0m\u001b[33m codes\u001b[0m\u001b[33m,\u001b[0m\u001b[33m which\u001b[0m\u001b[33m are\u001b[0m\u001b[33m essential\u001b[0m\u001b[33m for\u001b[0m\u001b[33m large\u001b[0m\u001b[33m-scale\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m computing\u001b[0m\u001b[33m (\u001b[0m\u001b[33mSource\u001b[0m\u001b[33m:\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m Error\u001b[0m\u001b[33m Correction\u001b[0m\u001b[33m with\u001b[0m\u001b[33m Surface\u001b[0m\u001b[33m Codes\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Stephanie\u001b[0m\u001b[33m We\u001b[0m\u001b[33mh\u001b[0m\u001b[33mner\u001b[0m\u001b[33m et\u001b[0m\u001b[33m al\u001b[0m\u001b[33m.,\u001b[0m\u001b[33m ar\u001b[0m\u001b[33mX\u001b[0m\u001b[33miv\u001b[0m\u001b[33m:\u001b[0m\u001b[33m140\u001b[0m\u001b[33m1\u001b[0m\u001b[33m.\u001b[0m\u001b[33m408\u001b[0m\u001b[33m1\u001b[0m\u001b[33m).\n", + "\u001b[0m\u001b[33mThe\u001b[0m\u001b[33m latest\u001b[0m\u001b[33m developments\u001b[0m\u001b[33m in\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m computing\u001b[0m\u001b[33m include\u001b[0m\u001b[33m advancements\u001b[0m\u001b[33m in\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m processors\u001b[0m\u001b[33m,\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m algorithms\u001b[0m\u001b[33m,\u001b[0m\u001b[33m and\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m error\u001b[0m\u001b[33m correction\u001b[0m\u001b[33m.\u001b[0m\u001b[33m Researchers\u001b[0m\u001b[33m have\u001b[0m\u001b[33m made\u001b[0m\u001b[33m progress\u001b[0m\u001b[33m in\u001b[0m\u001b[33m building\u001b[0m\u001b[33m larger\u001b[0m\u001b[33m and\u001b[0m\u001b[33m more\u001b[0m\u001b[33m stable\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m processors\u001b[0m\u001b[33m,\u001b[0m\u001b[33m such\u001b[0m\u001b[33m as\u001b[0m\u001b[33m Google\u001b[0m\u001b[33m's\u001b[0m\u001b[33m \u001b[0m\u001b[33m53\u001b[0m\u001b[33m-q\u001b[0m\u001b[33mubit\u001b[0m\u001b[33m processor\u001b[0m\u001b[33m and\u001b[0m\u001b[33m IBM\u001b[0m\u001b[33m's\u001b[0m\u001b[33m \u001b[0m\u001b[33m127\u001b[0m\u001b[33m-q\u001b[0m\u001b[33mubit\u001b[0m\u001b[33m processor\u001b[0m\u001b[33m (\u001b[0m\u001b[33m1\u001b[0m\u001b[33m).\u001b[0m\u001b[33m New\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m algorithms\u001b[0m\u001b[33m,\u001b[0m\u001b[33m like\u001b[0m\u001b[33m the\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Approx\u001b[0m\u001b[33mimate\u001b[0m\u001b[33m Optimization\u001b[0m\u001b[33m Algorithm\u001b[0m\u001b[33m (\u001b[0m\u001b[33mQ\u001b[0m\u001b[33mAO\u001b[0m\u001b[33mA\u001b[0m\u001b[33m),\u001b[0m\u001b[33m have\u001b[0m\u001b[33m been\u001b[0m\u001b[33m developed\u001b[0m\u001b[33m to\u001b[0m\u001b[33m solve\u001b[0m\u001b[33m complex\u001b[0m\u001b[33m optimization\u001b[0m\u001b[33m problems\u001b[0m\u001b[33m (\u001b[0m\u001b[33m2\u001b[0m\u001b[33m).\u001b[0m\u001b[33m Additionally\u001b[0m\u001b[33m,\u001b[0m\u001b[33m researchers\u001b[0m\u001b[33m are\u001b[0m\u001b[33m exploring\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m error\u001b[0m\u001b[33m correction\u001b[0m\u001b[33m techniques\u001b[0m\u001b[33m to\u001b[0m\u001b[33m mitigate\u001b[0m\u001b[33m errors\u001b[0m\u001b[33m in\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m computations\u001b[0m\u001b[33m (\u001b[0m\u001b[33m3\u001b[0m\u001b[33m).\n", "\n", "\u001b[0m\u001b[33mS\u001b[0m\u001b[33mOURCES\u001b[0m\u001b[33m:\n", - "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m Sup\u001b[0m\u001b[33mrem\u001b[0m\u001b[33macy\u001b[0m\u001b[33m Using\u001b[0m\u001b[33m a\u001b[0m\u001b[33m \u001b[0m\u001b[33m53\u001b[0m\u001b[33m-Q\u001b[0m\u001b[33mubit\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Computer\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Google\u001b[0m\u001b[33m Researchers\u001b[0m\u001b[33m,\u001b[0m\u001b[33m ar\u001b[0m\u001b[33mX\u001b[0m\u001b[33miv\u001b[0m\u001b[33m:\u001b[0m\u001b[33m191\u001b[0m\u001b[33m0\u001b[0m\u001b[33m.\u001b[0m\u001b[33m113\u001b[0m\u001b[33m33\u001b[0m\u001b[33m\n", - "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m IBM\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Experience\u001b[0m\u001b[33m,\u001b[0m\u001b[33m IBM\u001b[0m\u001b[33m Research\u001b[0m\u001b[33m (\u001b[0m\u001b[33mhttps\u001b[0m\u001b[33m://\u001b[0m\u001b[33mwww\u001b[0m\u001b[33m.ibm\u001b[0m\u001b[33m.com\u001b[0m\u001b[33m/\u001b[0m\u001b[33mquant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m-ex\u001b[0m\u001b[33mperience\u001b[0m\u001b[33m/)\n", - "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m Rig\u001b[0m\u001b[33metti\u001b[0m\u001b[33m Computing\u001b[0m\u001b[33m,\u001b[0m\u001b[33m Rig\u001b[0m\u001b[33metti\u001b[0m\u001b[33m.com\u001b[0m\u001b[33m (\u001b[0m\u001b[33mhttps\u001b[0m\u001b[33m://\u001b[0m\u001b[33mwww\u001b[0m\u001b[33m.r\u001b[0m\u001b[33mig\u001b[0m\u001b[33metti\u001b[0m\u001b[33m.com\u001b[0m\u001b[33m/)\n", - "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m Microsoft\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m Development\u001b[0m\u001b[33m Kit\u001b[0m\u001b[33m,\u001b[0m\u001b[33m Microsoft\u001b[0m\u001b[33m.com\u001b[0m\u001b[33m (\u001b[0m\u001b[33mhttps\u001b[0m\u001b[33m://\u001b[0m\u001b[33mwww\u001b[0m\u001b[33m.microsoft\u001b[0m\u001b[33m.com\u001b[0m\u001b[33m/en\u001b[0m\u001b[33m-us\u001b[0m\u001b[33m quantum\u001b[0m\u001b[33m/)\n", - "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m Error\u001b[0m\u001b[33m Correction\u001b[0m\u001b[33m with\u001b[0m\u001b[33m Surface\u001b[0m\u001b[33m Codes\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Stephanie\u001b[0m\u001b[33m We\u001b[0m\u001b[33mh\u001b[0m\u001b[33mner\u001b[0m\u001b[33m et\u001b[0m\u001b[33m al\u001b[0m\u001b[33m.,\u001b[0m\u001b[33m ar\u001b[0m\u001b[33mX\u001b[0m\u001b[33miv\u001b[0m\u001b[33m:\u001b[0m\u001b[33m140\u001b[0m\u001b[33m1\u001b[0m\u001b[33m.\u001b[0m\u001b[33m408\u001b[0m\u001b[33m1\u001b[0m\u001b[97m\u001b[0m\n", + "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m computing\u001b[0m\u001b[33m:\u001b[0m\u001b[33m a\u001b[0m\u001b[33m very\u001b[0m\u001b[33m short\u001b[0m\u001b[33m introduction\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Samuel\u001b[0m\u001b[33m J\u001b[0m\u001b[33m.\u001b[0m\u001b[33m L\u001b[0m\u001b[33momon\u001b[0m\u001b[33maco\u001b[0m\u001b[33m (\u001b[0m\u001b[33mURL\u001b[0m\u001b[33m)\n", + "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m Approx\u001b[0m\u001b[33mimate\u001b[0m\u001b[33m Optimization\u001b[0m\u001b[33m Algorithm\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Edward\u001b[0m\u001b[33m Far\u001b[0m\u001b[33mhi\u001b[0m\u001b[33m et\u001b[0m\u001b[33m al\u001b[0m\u001b[33m.\u001b[0m\u001b[33m (\u001b[0m\u001b[33mURL\u001b[0m\u001b[33m)\n", + "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mQuant\u001b[0m\u001b[33mum\u001b[0m\u001b[33m error\u001b[0m\u001b[33m correction\u001b[0m\u001b[33m for\u001b[0m\u001b[33m beginners\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Robert\u001b[0m\u001b[33m A\u001b[0m\u001b[33m.\u001b[0m\u001b[33m H\u001b[0m\u001b[33mulet\u001b[0m\u001b[33m (\u001b[0m\u001b[33mURL\u001b[0m\u001b[33m)\n", + "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mGoogle\u001b[0m\u001b[33m's\u001b[0m\u001b[33m \u001b[0m\u001b[33m53\u001b[0m\u001b[33m-q\u001b[0m\u001b[33mubit\u001b[0m\u001b[33m processor\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m Google\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m AI\u001b[0m\u001b[33m Lab\u001b[0m\u001b[33m (\u001b[0m\u001b[33mURL\u001b[0m\u001b[33m)\n", + "\u001b[0m\u001b[33m-\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mIBM\u001b[0m\u001b[33m's\u001b[0m\u001b[33m \u001b[0m\u001b[33m127\u001b[0m\u001b[33m-q\u001b[0m\u001b[33mubit\u001b[0m\u001b[33m processor\u001b[0m\u001b[33m\"\u001b[0m\u001b[33m by\u001b[0m\u001b[33m IBM\u001b[0m\u001b[33m Quantum\u001b[0m\u001b[33m (\u001b[0m\u001b[33mURL\u001b[0m\u001b[33m)\u001b[0m\u001b[97m\u001b[0m\n", "\u001b[30m\u001b[0m" ] } @@ -240,7 +194,7 @@ }, { "cell_type": "code", - "execution_count": 9, + "execution_count": 4, "metadata": {}, "outputs": [ { @@ -257,25 +211,15 @@ "\u001b[0m\u001b[33m \u001b[0m\u001b[33m \"\u001b[0m\u001b[33mlocation\u001b[0m\u001b[33m\":\u001b[0m\u001b[33m \"\u001b[0m\u001b[33mSan\u001b[0m\u001b[33m Francisco\u001b[0m\u001b[33m\"\n", "\u001b[0m\u001b[33m \u001b[0m\u001b[33m }\n", "\u001b[0m\u001b[33m}\u001b[0m\u001b[97m\u001b[0m\n", - "tool_calls starting: ToolCall(arguments={'location': 'San Francisco'}, call_id='f558e862-0465-48c5-9f65-f9160a59003b', tool_name='get_weather')\n", + "tool_calls starting: ToolCall(arguments={'location': 'San Francisco'}, call_id='420a73c9-1f6b-4f98-8fef-a7b9d2feb753', tool_name='get_weather')\n", "Using Location: San Francisco\n", - " {\n", - " \"temperature\": 72.5,\n", - " \"conditions\": \"partly cloudy\",\n", - " \"humidity\": 65.0\n", - " }\n", "\n", "Query: Tell me the weather in Tokyo tomorrow\n", "--------------------------------------------------\n", "\u001b[30m\u001b[0m\u001b[33minference> \u001b[0m\u001b[36m\u001b[0m\u001b[36m{\"\u001b[0m\u001b[36mtype\u001b[0m\u001b[36m\":\u001b[0m\u001b[36m \"\u001b[0m\u001b[36mfunction\u001b[0m\u001b[36m\",\u001b[0m\u001b[36m \"\u001b[0m\u001b[36mname\u001b[0m\u001b[36m\":\u001b[0m\u001b[36m \"\u001b[0m\u001b[36mget\u001b[0m\u001b[36m_weather\u001b[0m\u001b[36m\",\u001b[0m\u001b[36m \"\u001b[0m\u001b[36mparameters\u001b[0m\u001b[36m\":\u001b[0m\u001b[36m {\"\u001b[0m\u001b[36mlocation\u001b[0m\u001b[36m\":\u001b[0m\u001b[36m \"\u001b[0m\u001b[36mTok\u001b[0m\u001b[36myo\u001b[0m\u001b[36m\",\u001b[0m\u001b[36m \"\u001b[0m\u001b[36mdate\u001b[0m\u001b[36m\":\u001b[0m\u001b[36m \"\u001b[0m\u001b[36mtom\u001b[0m\u001b[36morrow\u001b[0m\u001b[36m\"}}\u001b[0m\u001b[97m\u001b[0m\n", - "tool_calls starting: ToolCall(arguments={'location': 'Tokyo', 'date': 'tomorrow'}, call_id='d2ee9a99-ee8f-4fcd-9cda-a1bfb52bcc72', tool_name='get_weather')\n", + "tool_calls starting: ToolCall(arguments={'location': 'Tokyo', 'date': 'tomorrow'}, call_id='9f94b5f1-fa5a-492f-a81f-dcfaafc970f3', tool_name='get_weather')\n", "Using Location: Tokyo\n", - "Using date: tomorrow\n", - " {\n", - " \"temperature\": 72.5,\n", - " \"conditions\": \"partly cloudy\",\n", - " \"humidity\": 65.0\n", - " }\n" + "Using date: tomorrow\n" ] } ], @@ -321,11 +265,11 @@ " async def run_impl(self, location: str, date: Optional[str] = None) -> Dict[str, Any]:\n", " \"\"\"Simulate getting weather data (replace with actual API call).\"\"\"\n", " # Mock implementation\n", - " print(\"\"\" {\n", - " \"temperature\": 72.5,\n", - " \"conditions\": \"partly cloudy\",\n", - " \"humidity\": 65.0\n", - " }\"\"\")\n", + " # print(\"\"\" {\n", + " # \"temperature\": 72.5,\n", + " # \"conditions\": \"partly cloudy\",\n", + " # \"humidity\": 65.0\n", + " # }\"\"\")\n", " return [CompletionMessage(\n", " content=\"\"\"{\n", " \"temperature\": 72.5,\n",