From 9dce2223d1792810cd23a4b07fcb1d7988c6472f Mon Sep 17 00:00:00 2001 From: Sanyam Bhutani <sanyambhutani@meta.com> Date: Thu, 17 Oct 2024 12:40:17 -0700 Subject: [PATCH] Fixed comments --- recipes/quickstart/agents/Agents_101/Tool_Calling_101.ipynb | 6 +++--- recipes/quickstart/agents/README.md | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 recipes/quickstart/agents/README.md diff --git a/recipes/quickstart/agents/Agents_101/Tool_Calling_101.ipynb b/recipes/quickstart/agents/Agents_101/Tool_Calling_101.ipynb index 11806f9e..7641f9df 100644 --- a/recipes/quickstart/agents/Agents_101/Tool_Calling_101.ipynb +++ b/recipes/quickstart/agents/Agents_101/Tool_Calling_101.ipynb @@ -6,7 +6,7 @@ "source": [ "# Tool Calling 101:\n", "\n", - "Note: If you are looking for `3.2` Featherlight Model (1B and 3B) instructions, please scroll to the bottom\n", + "Note: If you are looking for `3.2` Featherlight Model (1B and 3B) instructions, please see the respective notebook, this one covers 3.1 models\n", "\n", "This is part (1/2) in the tool calling series, this notebook will cover the basics of what tool calling is and how to perform it with `Llama 3.1 models`\n", "\n", @@ -544,10 +544,10 @@ "fn_name = re.search(r'<\\|python_tag\\|>(\\w+)\\.', output).group(1)\n", "\n", "# Extract the method\n", - "fn_call_method = re.search(r'\\.(\\w+)\\(', string).group(1)\n", + "fn_call_method = re.search(r'\\.(\\w+)\\(', output).group(1)\n", "\n", "# Extract the arguments\n", - "fn_call_args = re.search(r'=\\s*([^)]+)', string).group(1)\n", + "fn_call_args = re.search(r'=\\s*([^)]+)', output).group(1)\n", "\n", "print(f\"Function name: {fn_name}\")\n", "print(f\"Method: {fn_call_method}\")\n", diff --git a/recipes/quickstart/agents/README.md b/recipes/quickstart/agents/README.md new file mode 100644 index 00000000..9b4bd1d5 --- /dev/null +++ b/recipes/quickstart/agents/README.md @@ -0,0 +1 @@ +## Agents and Tool Calling \ No newline at end of file -- GitLab