import{s as Ke,o as De,n as Ve}from"../chunks/scheduler.889ebb13.js";import{S as Oe,i as et,g as m,s,r as f,m as D,A as tt,h as u,f as l,c as i,j as Ie,u as g,x as d,n as O,k as ee,y as We,a as n,v as y,d as b,t as w,w as M}from"../chunks/index.ca18042b.js";import{T as ke}from"../chunks/Tip.b8116e3c.js";import{C as ne}from"../chunks/CodeBlock.1db71023.js";import{H as oe}from"../chunks/Heading.3daa581c.js";import{E as lt}from"../chunks/EditOnGithub.2e95618d.js";function nt(j){let r,o,h="this notebook",c;return{c(){r=D("You can follow the code in "),o=m("a"),o.textContent=h,c=D(" that you can run using Google Colab."),this.h()},l(a){r=O(a,"You can follow the code in "),o=u(a,"A",{href:!0,target:!0,"data-svelte-h":!0}),d(o)!=="svelte-1oi8dw1"&&(o.textContent=h),c=O(a," that you can run using Google Colab."),this.h()},h(){ee(o,"href","https://huggingface.co/agents-course/notebooks/blob/main/unit2/llama-index/tools.ipynb"),ee(o,"target","_blank")},m(a,$){n(a,r,$),n(a,o,$),n(a,c,$)},p:Ve,d(a){a&&(l(r),l(o),l(c))}}}function ot(j){let r,o,h="Function Calling Guide",c,a,$="Function Calling Learning Guide",T;return{c(){r=D("When using an agent or LLM with function calling, the tool selected (and the arguments written for that tool) rely strongly on the tool name and description of the purpose and arguments of the tool. Learn more about function calling in the "),o=m("a"),o.textContent=h,c=D(" and "),a=m("a"),a.textContent=$,T=D("."),this.h()},l(p){r=O(p,"When using an agent or LLM with function calling, the tool selected (and the arguments written for that tool) rely strongly on the tool name and description of the purpose and arguments of the tool. Learn more about function calling in the "),o=u(p,"A",{href:!0,"data-svelte-h":!0}),d(o)!=="svelte-kqlt1w"&&(o.textContent=h),c=O(p," and "),a=u(p,"A",{href:!0,"data-svelte-h":!0}),d(a)!=="svelte-4p3bp7"&&(a.textContent=$),T=O(p,"."),this.h()},h(){ee(o,"href","https://docs.llamaindex.ai/en/stable/module_guides/deploying/agents/modules/function_calling.html"),ee(a,"href","https://docs.llamaindex.ai/en/stable/understanding/agent/function_calling.html")},m(p,v){n(p,r,v),n(p,o,v),n(p,c,v),n(p,a,v),n(p,T,v)},p:Ve,d(p){p&&(l(r),l(o),l(c),l(a),l(T))}}}function at(j){let r,o,h="LlamaHub";return{c(){r=D("You can find toolspecs and utility tools on the "),o=m("a"),o.textContent=h,this.h()},l(c){r=O(c,"You can find toolspecs and utility tools on the "),o=u(c,"A",{href:!0,"data-svelte-h":!0}),d(o)!=="svelte-b92hie"&&(o.textContent=h),this.h()},h(){ee(o,"href","https://llamahub.ai/")},m(c,a){n(c,r,a),n(c,o,a)},p:Ve,d(c){c&&(l(r),l(o))}}}function st(j){let r,o,h,c,a,$,T,p=`<strong>Defining a clear set of Tools is crucial to performance.</strong> As we discussed in <a href="../../unit1/tools">unit 1</a>, clear tool interfaces are easier for LLMs to use.
Much like a software API interface for human engineers, they can get more out of the tool if it’s easy to understand how it works.`,v,G,Be="There are <strong>four main types of tools in LlamaIndex</strong>:",ae,U,Le='<img src="https://huggingface.co/datasets/agents-course/course-images/resolve/main/en/unit2/llama-index/tools.png" alt="Tools"/>',se,C,Re="<li><code>FunctionTool</code>: Convert any Python function into a tool that an agent can use. It automatically figures out how the function works.</li> <li><code>QueryEngineTool</code>: A tool that lets agents use query engines. Since agents are built on query engines, they can also use other agents as tools.</li> <li><code>Toolspecs</code>: Sets of tools created by the community, which often include tools for specific services like Gmail.</li> <li><code>Utility Tools</code>: Special tools that help handle large amounts of data from other tools.</li>",ie,I,He="We will go over each of them in more detail below.",re,W,ce,Z,me,k,Ee=`A FunctionTool provides a simple way to wrap any Python function and make it available to an agent.
You can pass either a synchronous or asynchronous function to the tool, along with optional <code>name</code> and <code>description</code> parameters.
The name and description are particularly important as they help the agent understand when and how to use the tool effectively.
Let’s look at how to create a FunctionTool below and then call it.`,ue,V,de,x,pe,B,he,L,Ne=`The <code>QueryEngine</code> we defined in the previous unit can be easily transformed into a tool using the <code>QueryEngineTool</code> class.
Let’s see how to create a <code>QueryEngineTool</code> from a <code>QueryEngine</code> in the example below.`,fe,R,ge,H,ye,E,Se=`Think of <code>ToolSpecs</code> as collections of tools that work together harmoniously - like a well-organized professional toolkit.
Just as a mechanic’s toolkit contains complementary tools that work together for vehicle repairs, a <code>ToolSpec</code> combines related tools for specific purposes.
For example, an accounting agent’s <code>ToolSpec</code> might elegantly integrate spreadsheet capabilities, email functionality, and calculation tools to handle financial tasks with precision and efficiency.`,be,J,te,Ye="Install the Google Toolspec",Ce,N,we,S,Fe="And now we can load the toolspec and convert it to a list of tools.",Me,Y,Te,F,Xe="To get a more detailed view of the tools, we can take a look at the <code>metadata</code> of each tool.",$e,X,ve,Q,je,q,Qe=`Oftentimes, directly querying an API <strong>can return an excessive amount of data</strong>, some of which may be irrelevant, overflow the context window of the LLM, or unnecessarily increase the number of tokens that you are using.
Let’s walk through our two main utility tools below.`,Ze,A,qe="<li><code>OnDemandToolLoader</code>: This tool turns any existing LlamaIndex data loader (BaseReader class) into a tool that an agent can use. The tool can be called with all the parameters needed to trigger <code>load_data</code> from the data loader, along with a natural language query string. During execution, we first load data from the data loader, index it (for instance with a vector store), and then query it ‘on-demand’. All three of these steps happen in a single tool call.</li> <li><code>LoadAndSearchToolSpec</code>: The LoadAndSearchToolSpec takes in any existing Tool as input. As a tool spec, it implements <code>to_tool_list</code>, and when that function is called, two tools are returned: a loading tool and then a search tool. The load Tool execution would call the underlying Tool, and the index the output (by default with a vector index). The search Tool execution would take in a query string as input and call the underlying index.</li>",xe,_,Je,P,Ae="Now that we understand the basics of agents and tools in LlamaIndex, let’s see how we can <strong>use LlamaIndex to create configurable and manageable workflows!</strong>",_e,z,Ge,le,Ue;return a=new oe({props:{title:"Using Tools in LlamaIndex",local:"using-tools-in-llamaindex",headingTag:"h1"}}),W=new oe({props:{title:"Creating a FunctionTool",local:"creating-a-functiontool",headingTag:"h2"}}),Z=new ke({props:{$$slots:{default:[nt]},$$scope:{ctx:j}}}),V=new ne({props:{code:"ZnJvbSUyMGxsYW1hX2luZGV4LmNvcmUudG9vbHMlMjBpbXBvcnQlMjBGdW5jdGlvblRvb2wlMEElMEFkZWYlMjBnZXRfd2VhdGhlcihsb2NhdGlvbiUzQSUyMHN0ciklMjAtJTNFJTIwc3RyJTNBJTBBJTIwJTIwJTIwJTIwJTIyJTIyJTIyVXNlZnVsJTIwZm9yJTIwZ2V0dGluZyUyMHRoZSUyMHdlYXRoZXIlMjBmb3IlMjBhJTIwZ2l2ZW4lMjBsb2NhdGlvbi4lMjIlMjIlMjIlMEElMjAlMjAlMjAlMjBwcmludChmJTIyR2V0dGluZyUyMHdlYXRoZXIlMjBmb3IlMjAlN0Jsb2NhdGlvbiU3RCUyMiklMEElMjAlMjAlMjAlMjByZXR1cm4lMjBmJTIyVGhlJTIwd2VhdGhlciUyMGluJTIwJTdCbG9jYXRpb24lN0QlMjBpcyUyMHN1bm55JTIyJTBBJTBBdG9vbCUyMCUzRCUyMEZ1bmN0aW9uVG9vbC5mcm9tX2RlZmF1bHRzKCUwQSUyMCUyMCUyMCUyMGdldF93ZWF0aGVyJTJDJTBBJTIwJTIwJTIwJTIwbmFtZSUzRCUyMm15X3dlYXRoZXJfdG9vbCUyMiUyQyUwQSUyMCUyMCUyMCUyMGRlc2NyaXB0aW9uJTNEJTIyVXNlZnVsJTIwZm9yJTIwZ2V0dGluZyUyMHRoZSUyMHdlYXRoZXIlMjBmb3IlMjBhJTIwZ2l2ZW4lMjBsb2NhdGlvbi4lMjIlMkMlMEEpJTBBdG9vbC5jYWxsKCUyMk5ldyUyMFlvcmslMjIp",highlighted:`<span class="hljs-keyword">from</span> llama_index.core.tools <span class="hljs-keyword">import</span> FunctionTool

<span class="hljs-keyword">def</span> <span class="hljs-title function_">get_weather</span>(<span class="hljs-params">location: <span class="hljs-built_in">str</span></span>) -&gt; <span class="hljs-built_in">str</span>:
    <span class="hljs-string">&quot;&quot;&quot;Useful for getting the weather for a given location.&quot;&quot;&quot;</span>
    <span class="hljs-built_in">print</span>(<span class="hljs-string">f&quot;Getting weather for <span class="hljs-subst">{location}</span>&quot;</span>)
    <span class="hljs-keyword">return</span> <span class="hljs-string">f&quot;The weather in <span class="hljs-subst">{location}</span> is sunny&quot;</span>

tool = FunctionTool.from_defaults(
    get_weather,
    name=<span class="hljs-string">&quot;my_weather_tool&quot;</span>,
    description=<span class="hljs-string">&quot;Useful for getting the weather for a given location.&quot;</span>,
)
tool.call(<span class="hljs-string">&quot;New York&quot;</span>)`,wrap:!1}}),x=new ke({props:{$$slots:{default:[ot]},$$scope:{ctx:j}}}),B=new oe({props:{title:"Creating a QueryEngineTool",local:"creating-a-queryenginetool",headingTag:"h2"}}),R=new ne({props:{code:"ZnJvbSUyMGxsYW1hX2luZGV4LmNvcmUlMjBpbXBvcnQlMjBWZWN0b3JTdG9yZUluZGV4JTBBZnJvbSUyMGxsYW1hX2luZGV4LmNvcmUudG9vbHMlMjBpbXBvcnQlMjBRdWVyeUVuZ2luZVRvb2wlMEFmcm9tJTIwbGxhbWFfaW5kZXgubGxtcy5odWdnaW5nZmFjZV9hcGklMjBpbXBvcnQlMjBIdWdnaW5nRmFjZUluZmVyZW5jZUFQSSUwQWZyb20lMjBsbGFtYV9pbmRleC5lbWJlZGRpbmdzLmh1Z2dpbmdmYWNlJTIwaW1wb3J0JTIwSHVnZ2luZ0ZhY2VFbWJlZGRpbmclMEFmcm9tJTIwbGxhbWFfaW5kZXgudmVjdG9yX3N0b3Jlcy5jaHJvbWElMjBpbXBvcnQlMjBDaHJvbWFWZWN0b3JTdG9yZSUwQSUwQWVtYmVkX21vZGVsJTIwJTNEJTIwSHVnZ2luZ0ZhY2VFbWJlZGRpbmcoJTIyQkFBSSUyRmJnZS1zbWFsbC1lbi12MS41JTIyKSUwQSUwQWRiJTIwJTNEJTIwY2hyb21hZGIuUGVyc2lzdGVudENsaWVudChwYXRoJTNEJTIyLiUyRmFsZnJlZF9jaHJvbWFfZGIlMjIpJTBBY2hyb21hX2NvbGxlY3Rpb24lMjAlM0QlMjBkYi5nZXRfb3JfY3JlYXRlX2NvbGxlY3Rpb24oJTIyYWxmcmVkJTIyKSUwQXZlY3Rvcl9zdG9yZSUyMCUzRCUyMENocm9tYVZlY3RvclN0b3JlKGNocm9tYV9jb2xsZWN0aW9uJTNEY2hyb21hX2NvbGxlY3Rpb24pJTBBJTBBaW5kZXglMjAlM0QlMjBWZWN0b3JTdG9yZUluZGV4LmZyb21fdmVjdG9yX3N0b3JlKHZlY3Rvcl9zdG9yZSUyQyUyMGVtYmVkX21vZGVsJTNEZW1iZWRfbW9kZWwpJTBBJTBBbGxtJTIwJTNEJTIwSHVnZ2luZ0ZhY2VJbmZlcmVuY2VBUEkobW9kZWxfbmFtZSUzRCUyMlF3ZW4lMkZRd2VuMi41LUNvZGVyLTMyQi1JbnN0cnVjdCUyMiklMEFxdWVyeV9lbmdpbmUlMjAlM0QlMjBpbmRleC5hc19xdWVyeV9lbmdpbmUobGxtJTNEbGxtKSUwQXRvb2wlMjAlM0QlMjBRdWVyeUVuZ2luZVRvb2wuZnJvbV9kZWZhdWx0cyhxdWVyeV9lbmdpbmUlMkMlMjBuYW1lJTNEJTIyc29tZSUyMHVzZWZ1bCUyMG5hbWUlMjIlMkMlMjBkZXNjcmlwdGlvbiUzRCUyMnNvbWUlMjB1c2VmdWwlMjBkZXNjcmlwdGlvbiUyMik=",highlighted:`<span class="hljs-keyword">from</span> llama_index.core <span class="hljs-keyword">import</span> VectorStoreIndex
<span class="hljs-keyword">from</span> llama_index.core.tools <span class="hljs-keyword">import</span> QueryEngineTool
<span class="hljs-keyword">from</span> llama_index.llms.huggingface_api <span class="hljs-keyword">import</span> HuggingFaceInferenceAPI
<span class="hljs-keyword">from</span> llama_index.embeddings.huggingface <span class="hljs-keyword">import</span> HuggingFaceEmbedding
<span class="hljs-keyword">from</span> llama_index.vector_stores.chroma <span class="hljs-keyword">import</span> ChromaVectorStore

embed_model = HuggingFaceEmbedding(<span class="hljs-string">&quot;BAAI/bge-small-en-v1.5&quot;</span>)

db = chromadb.PersistentClient(path=<span class="hljs-string">&quot;./alfred_chroma_db&quot;</span>)
chroma_collection = db.get_or_create_collection(<span class="hljs-string">&quot;alfred&quot;</span>)
vector_store = ChromaVectorStore(chroma_collection=chroma_collection)

index = VectorStoreIndex.from_vector_store(vector_store, embed_model=embed_model)

llm = HuggingFaceInferenceAPI(model_name=<span class="hljs-string">&quot;Qwen/Qwen2.5-Coder-32B-Instruct&quot;</span>)
query_engine = index.as_query_engine(llm=llm)
tool = QueryEngineTool.from_defaults(query_engine, name=<span class="hljs-string">&quot;some useful name&quot;</span>, description=<span class="hljs-string">&quot;some useful description&quot;</span>)`,wrap:!1}}),H=new oe({props:{title:"Creating Toolspecs",local:"creating-toolspecs",headingTag:"h2"}}),N=new ne({props:{code:"cGlwJTIwaW5zdGFsbCUyMGxsYW1hLWluZGV4LXRvb2xzLWdvb2dsZQ==",highlighted:"pip install llama-index-tools-google",wrap:!1}}),Y=new ne({props:{code:"ZnJvbSUyMGxsYW1hX2luZGV4LnRvb2xzLmdvb2dsZSUyMGltcG9ydCUyMEdtYWlsVG9vbFNwZWMlMEElMEF0b29sX3NwZWMlMjAlM0QlMjBHbWFpbFRvb2xTcGVjKCklMEF0b29sX3NwZWNfbGlzdCUyMCUzRCUyMHRvb2xfc3BlYy50b190b29sX2xpc3QoKQ==",highlighted:`<span class="hljs-keyword">from</span> llama_index.tools.google <span class="hljs-keyword">import</span> GmailToolSpec

tool_spec = GmailToolSpec()
tool_spec_list = tool_spec.to_tool_list()`,wrap:!1}}),X=new ne({props:{code:"JTVCKHRvb2wubWV0YWRhdGEubmFtZSUyQyUyMHRvb2wubWV0YWRhdGEuZGVzY3JpcHRpb24pJTIwZm9yJTIwdG9vbCUyMGluJTIwdG9vbF9zcGVjX2xpc3QlNUQ=",highlighted:'[(tool.metadata.name, tool.metadata.description) <span class="hljs-keyword">for</span> tool <span class="hljs-keyword">in</span> tool_spec_list]',wrap:!1}}),Q=new oe({props:{title:"Utility Tools",local:"utility-tools",headingTag:"h2"}}),_=new ke({props:{$$slots:{default:[at]},$$scope:{ctx:j}}}),z=new lt({props:{source:"https://github.com/huggingface/agents-course/blob/main/units/en/unit2/llama-index/tools.mdx"}}),{c(){r=m("meta"),o=s(),h=m("p"),c=s(),f(a.$$.fragment),$=s(),T=m("p"),T.innerHTML=p,v=s(),G=m("p"),G.innerHTML=Be,ae=s(),U=m("p"),U.innerHTML=Le,se=s(),C=m("ol"),C.innerHTML=Re,ie=s(),I=m("p"),I.textContent=He,re=s(),f(W.$$.fragment),ce=s(),f(Z.$$.fragment),me=s(),k=m("p"),k.innerHTML=Ee,ue=s(),f(V.$$.fragment),de=s(),f(x.$$.fragment),pe=s(),f(B.$$.fragment),he=s(),L=m("p"),L.innerHTML=Ne,fe=s(),f(R.$$.fragment),ge=s(),f(H.$$.fragment),ye=s(),E=m("p"),E.innerHTML=Se,be=s(),J=m("details"),te=m("summary"),te.textContent=Ye,Ce=D(`
As introduced in the [section on the LlamaHub](llama-hub), we can install the Google toolspec with the following command:

	`),f(N.$$.fragment),we=s(),S=m("p"),S.textContent=Fe,Me=s(),f(Y.$$.fragment),Te=s(),F=m("p"),F.innerHTML=Xe,$e=s(),f(X.$$.fragment),ve=s(),f(Q.$$.fragment),je=s(),q=m("p"),q.innerHTML=Qe,Ze=s(),A=m("ol"),A.innerHTML=qe,xe=s(),f(_.$$.fragment),Je=s(),P=m("p"),P.innerHTML=Ae,_e=s(),f(z.$$.fragment),Ge=s(),le=m("p"),this.h()},l(e){const t=tt("svelte-u9bgzb",document.head);r=u(t,"META",{name:!0,content:!0}),t.forEach(l),o=i(e),h=u(e,"P",{}),Ie(h).forEach(l),c=i(e),g(a.$$.fragment,e),$=i(e),T=u(e,"P",{"data-svelte-h":!0}),d(T)!=="svelte-1y4sc3l"&&(T.innerHTML=p),v=i(e),G=u(e,"P",{"data-svelte-h":!0}),d(G)!=="svelte-jgrrn"&&(G.innerHTML=Be),ae=i(e),U=u(e,"P",{"data-svelte-h":!0}),d(U)!=="svelte-ir2ii4"&&(U.innerHTML=Le),se=i(e),C=u(e,"OL",{"data-svelte-h":!0}),d(C)!=="svelte-7bbi5a"&&(C.innerHTML=Re),ie=i(e),I=u(e,"P",{"data-svelte-h":!0}),d(I)!=="svelte-1hynje"&&(I.textContent=He),re=i(e),g(W.$$.fragment,e),ce=i(e),g(Z.$$.fragment,e),me=i(e),k=u(e,"P",{"data-svelte-h":!0}),d(k)!=="svelte-1ij77fk"&&(k.innerHTML=Ee),ue=i(e),g(V.$$.fragment,e),de=i(e),g(x.$$.fragment,e),pe=i(e),g(B.$$.fragment,e),he=i(e),L=u(e,"P",{"data-svelte-h":!0}),d(L)!=="svelte-wh1h60"&&(L.innerHTML=Ne),fe=i(e),g(R.$$.fragment,e),ge=i(e),g(H.$$.fragment,e),ye=i(e),E=u(e,"P",{"data-svelte-h":!0}),d(E)!=="svelte-1196szp"&&(E.innerHTML=Se),be=i(e),J=u(e,"DETAILS",{});var K=Ie(J);te=u(K,"SUMMARY",{"data-svelte-h":!0}),d(te)!=="svelte-8tnjrg"&&(te.textContent=Ye),Ce=O(K,`
As introduced in the [section on the LlamaHub](llama-hub), we can install the Google toolspec with the following command:

	`),g(N.$$.fragment,K),K.forEach(l),we=i(e),S=u(e,"P",{"data-svelte-h":!0}),d(S)!=="svelte-a37nc2"&&(S.textContent=Fe),Me=i(e),g(Y.$$.fragment,e),Te=i(e),F=u(e,"P",{"data-svelte-h":!0}),d(F)!=="svelte-piorhw"&&(F.innerHTML=Xe),$e=i(e),g(X.$$.fragment,e),ve=i(e),g(Q.$$.fragment,e),je=i(e),q=u(e,"P",{"data-svelte-h":!0}),d(q)!=="svelte-1s3291r"&&(q.innerHTML=Qe),Ze=i(e),A=u(e,"OL",{"data-svelte-h":!0}),d(A)!=="svelte-1el281h"&&(A.innerHTML=qe),xe=i(e),g(_.$$.fragment,e),Je=i(e),P=u(e,"P",{"data-svelte-h":!0}),d(P)!=="svelte-a13dju"&&(P.innerHTML=Ae),_e=i(e),g(z.$$.fragment,e),Ge=i(e),le=u(e,"P",{}),Ie(le).forEach(l),this.h()},h(){ee(r,"name","hf:doc:metadata"),ee(r,"content",it)},m(e,t){We(document.head,r),n(e,o,t),n(e,h,t),n(e,c,t),y(a,e,t),n(e,$,t),n(e,T,t),n(e,v,t),n(e,G,t),n(e,ae,t),n(e,U,t),n(e,se,t),n(e,C,t),n(e,ie,t),n(e,I,t),n(e,re,t),y(W,e,t),n(e,ce,t),y(Z,e,t),n(e,me,t),n(e,k,t),n(e,ue,t),y(V,e,t),n(e,de,t),y(x,e,t),n(e,pe,t),y(B,e,t),n(e,he,t),n(e,L,t),n(e,fe,t),y(R,e,t),n(e,ge,t),y(H,e,t),n(e,ye,t),n(e,E,t),n(e,be,t),n(e,J,t),We(J,te),We(J,Ce),y(N,J,null),n(e,we,t),n(e,S,t),n(e,Me,t),y(Y,e,t),n(e,Te,t),n(e,F,t),n(e,$e,t),y(X,e,t),n(e,ve,t),y(Q,e,t),n(e,je,t),n(e,q,t),n(e,Ze,t),n(e,A,t),n(e,xe,t),y(_,e,t),n(e,Je,t),n(e,P,t),n(e,_e,t),y(z,e,t),n(e,Ge,t),n(e,le,t),Ue=!0},p(e,[t]){const K={};t&2&&(K.$$scope={dirty:t,ctx:e}),Z.$set(K);const Pe={};t&2&&(Pe.$$scope={dirty:t,ctx:e}),x.$set(Pe);const ze={};t&2&&(ze.$$scope={dirty:t,ctx:e}),_.$set(ze)},i(e){Ue||(b(a.$$.fragment,e),b(W.$$.fragment,e),b(Z.$$.fragment,e),b(V.$$.fragment,e),b(x.$$.fragment,e),b(B.$$.fragment,e),b(R.$$.fragment,e),b(H.$$.fragment,e),b(N.$$.fragment,e),b(Y.$$.fragment,e),b(X.$$.fragment,e),b(Q.$$.fragment,e),b(_.$$.fragment,e),b(z.$$.fragment,e),Ue=!0)},o(e){w(a.$$.fragment,e),w(W.$$.fragment,e),w(Z.$$.fragment,e),w(V.$$.fragment,e),w(x.$$.fragment,e),w(B.$$.fragment,e),w(R.$$.fragment,e),w(H.$$.fragment,e),w(N.$$.fragment,e),w(Y.$$.fragment,e),w(X.$$.fragment,e),w(Q.$$.fragment,e),w(_.$$.fragment,e),w(z.$$.fragment,e),Ue=!1},d(e){e&&(l(o),l(h),l(c),l($),l(T),l(v),l(G),l(ae),l(U),l(se),l(C),l(ie),l(I),l(re),l(ce),l(me),l(k),l(ue),l(de),l(pe),l(he),l(L),l(fe),l(ge),l(ye),l(E),l(be),l(J),l(we),l(S),l(Me),l(Te),l(F),l($e),l(ve),l(je),l(q),l(Ze),l(A),l(xe),l(Je),l(P),l(_e),l(Ge),l(le)),l(r),M(a,e),M(W,e),M(Z,e),M(V,e),M(x,e),M(B,e),M(R,e),M(H,e),M(N),M(Y,e),M(X,e),M(Q,e),M(_,e),M(z,e)}}}const it='{"title":"Using Tools in LlamaIndex","local":"using-tools-in-llamaindex","sections":[{"title":"Creating a FunctionTool","local":"creating-a-functiontool","sections":[],"depth":2},{"title":"Creating a QueryEngineTool","local":"creating-a-queryenginetool","sections":[],"depth":2},{"title":"Creating Toolspecs","local":"creating-toolspecs","sections":[],"depth":2},{"title":"Utility Tools","local":"utility-tools","sections":[],"depth":2}],"depth":1}';function rt(j){return De(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class ft extends Oe{constructor(r){super(),et(this,r,rt,st,Ke,{})}}export{ft as component};
