Uploading static sources as training data for your AI Agents is well and good, but what if your database is huge, structured, externally-hosted,
or updated in real-time? There is no way to dump the entire database into Chatsistant’s static knowledge library and still maintain a live link…This is where function-calling comes in. Through function-calling, you can serve data on-demand to your AI Agent in Chatsistant during a live
conversation session. To show you how, we walk you through an example of RAG enrichment using (abstracts of) academic papers sourced from a trusted
academic papers aggregator: Semantic Scholar API.
First, you’ll need an API key from your external data provider, whoever that may be, assuming they have a secure API. In our case, we requested one
from Semantic Scholar directly.Since we want to enrich our LLM query response with relevant information from academic research, we need to find the appropriate API endpoint to
conduct the search. Semantic Scholar offers nice documentation
in that regard.
So what does this API endpoint respond with?To inspect the output, we ran a script that makes a request to the API based on hardcoded input parameters. The source code of our script is included
below. You will need your own Semantic Scholar API key if you wish to run it yourself. For our example, we ran a search for relevant papers on the topic
of “Multifidelity Optimization” and “Gaussian Processes”.
import requestsimport jsonimport os# Set up the headers with the API keyheaders = { 'X-API-KEY': "YOUR OWN API KEY"}# Specify the fields you want to fetch for each recommended paperfields = "paperId,title,authors,abstract,url,referenceCount"# Define the limit for the number of recommendations to returnlimit = 20# Make the request to get paper recommendationsresponse = requests.get( 'https://api.semanticscholar.org/graph/v1/paper/search', headers=headers, # json=payload, params={'fields': fields, 'limit': limit, 'query':'multifidelity optimization, gaussian processes' })# Check if the request was successfulif response.status_code == 200: print(json.dumps(response.json(), indent=2))else: print(f"Error: {response.status_code}") # It's better to print response.text for non-200 responses, as they may not be in JSON format print(response.text)
The output we received looks like follows:
{ "total": 12096, "offset": 0, "next": 20, "data": [ { "paperId": "b108e6e11f4a96d5058945f3b582a032e8204ade", "url": "https://www.semanticscholar.org/paper/b108e6e11f4a96d5058945f3b582a032e8204ade", "title": "Multifidelity Gaussian processes for failure boundary andprobability estimation", "abstract": "Estimating probability of failure in aerospace systems is a critical requirement for flight certification and qualification. Failure probability estimation (FPE) involves resolving tails of probability distribution and Monte Carlo (MC) sampling methods are intractable when expensive high-fidelity simulations have to be queried. We propose a method to use models of multiple fidelities, which trade accuracy for computational efficiency. Specifically, we propose the use of multifidelity Gaussian process models to efficiently fuse models at multiple fidelity. Furthermore, we propose a novel acquisition function within a Bayesian optimization framework, which can sequentially select samples (or batches of samples for parallel evaluation) from appropriate fidelity models to make predictions about quantities of interest in the highest fidelity. We use our proposed approach within a multifidelity importance sampling (MFIS) setting, and demonstrate our method on the failure level set estimation on synthetic test functions as well as the transonic flow past an airfoil wing section.", "referenceCount": 49, "authors": [ { "authorId": "98543101", "name": "Ashwin Renganathan" }, { "authorId": "144321616", "name": "Vishwas Rao" }, { "authorId": "143672238", "name": "Ionel M. Navon" } ] }, { "paperId": "963a5c60ada159d27641a284008f57d6419b26f2", "url": "https://www.semanticscholar.org/paper/963a5c60ada159d27641a284008f57d6419b26f2", "title": "Generative Transfer Optimization for Aerodynamic Design", "abstract": "Transfer optimization, one type of optimization methods, which leverages knowledge of the completed tasks to accelerate the design progress of a new task, has been in widespread use in machine learning community. However, when applying transfer optimization to accelerate the progress of aerodynamic shape optimization (ASO), two challenges are encountered in sequence, that is, (1) how to build a shared design space among the related aerodynamic design tasks, and (2) how to exchange information between tasks most efficiently. To address the first challenge, a datadriven generative model is used to learn airfoil representations from the existing database, with the aim of synthesizing various airfoil shapes in a shared design space. To address the second challenge, both singleand multifidelity Gaussian processes (GPs) are employed to carry out optimization. On one hand, the multifidelity GP is used to leverage knowledge from the completed tasks. On the other hand, mutual learning is established between singleand multifidelity GP models by exchanging information between them in each optimization cycle. With the above, a generative transfer optimization (GTO) framework is proposed to shorten the design cycle of aerodynamic design. Through airfoil optimizations at different working conditions, the effectiveness of the proposed GTO framework is demonstrated.", "referenceCount": 16, "authors": [ { "authorId": "2149505113", "name": "Zhendong Guo" }, { "authorId": "2153199285", "name": "Wei Sun" }, { "authorId": "50258957", "name": "Liming Song" }, { "authorId": "46276037", "name": "Jun Yu Li" }, { "authorId": "73325644", "name": "Z. Feng" } ] },… (truncated due to length)
The Semantic Scholar function returned the top 20 matching results ranked by relevance based on our input parameter specification. As you see, the response
can get quite long, so we truncated the output for conciseness.Ideally, you want a structured JSON response from the function’s output like what we showed above.We ran our own analysis for this particular API endpoint (with the specific set of output fields we requested) and found that on average, each returned
result is between 400-500 tokens long. This means that depending on the token limit we reserved for the function output, we can only fit so many search results
in before running out of space. Keep this in mind as you prioritize the information you wish to supply to the LLM during RAG.Now we know what the LLM would see as additional context provided by the function call, we can start linking it to our Chatsistant Agent.
It is ALWAYS advisable to write your own script and test for the output of the API endpoint first. You want to know exactly what kind information
is being fed into your AI Agent.
In your chatbot inside Chatsistant, you must first create an appropriate AI Agent that you plan to give this function-calling capability to. In our example,
we created “The Professor”. We then defined an associated Agent description and base prompt.
We picked the GPT-4-0125-8k Model for this example. You can see our simple prompt in the screenshot below.
Next, we save the Agent and go to the “Knowledge” tab to disable static RAG from the chatbot’s own knowledge library. This is only necessary if you don’t want
to use any training data from the static sources list. In our example, we didn’t upload any training data anyways, but we do this as standard practice to keep
things clean.
Within your Agent, head over to the “Functions” tab. Change the “Response Context Limit” to the maximum allowed. Then click “Add function”.
This is where you tell the LLM exactly what the function does and how it works. The LLM will then decide on its own whether it needs the function when responding
to the user during a conversation, then call it with the appropriate parameters as needed.
The function name and description are particularly useful in helping the AI understand what the function does. Please make sure to be as explicit as possible in
your own definition. The function description must be less than 1024 characters, including spaces. In our case, we wrote the following:
Function name: paper_relevance_searchFunction description: This function searches Semantic Scholar, a scholarly literature database. The input parameters will be defined based on extracted information from conversation context. It will return search results containing academic paper metadata (with abstracts) in a JSON format.The returned fields are defined as follows:- title: paper title- abstract: paper abstract- paperId: paper uuid- authors: paper authors- year: paper publication year- url: paper link- referenceCount: number of references included in the paper- citationCount: number of citations of this paper
Next, define the API endpoint. The Semantic Scholar endpoint we are using is simple and straighforward:
After that, choose the HTTP method. We use “GET” for our example. The specific API endpoint you are using should have documentation about this distinction.
Static (Fixed) Parameters remain constant across all API requests. They are pre-defined and reflect settings or configurations that do not change with each
call. For example, parameters that specify the format of the response or that enable/disable certain features globally across all API interactions fall into
this category. The term “static” emphasizes their unchanging nature.Depending on your particular API endpoint, you may need to append some fixed parameters in the URL. The API we use above from Semantic Scholar does not require
fixed parameters. But if you are using a more complex endpoint like this:
https://app.outscraper.com/api-docs#tag/Businesses-and-POI/paths/~1maps~1search-v3/get, then your API endpoint may include fixed parameters and look something like:
Notice that at the end of “https://api.app.outscraper.com/maps/search-v3”, we get into fixed parameters. This is where you define parameters that will not change
when the function is called. Always define fixed parameters this way!
If your API is capable of returning a more concise response by configuring certain parameters (i.e., tell the API to leave out unnecessary metadata in the response),
then we highly suggest that you do so. It will reduce token waste and help AI understand the context better. In the above example, we set “fields=name,full_address,phone,site”
specifically to limit the response so that it contains only name, full_address, phone, and site information - and nothing else.
In general, secure public-facing APIs require authentication. Semantic Scholar is the same. In the Header, we provide our API key. The specific key field used
to supply your authentication token will differ based on the particular API you use, so please make sure to be informed on your API provider’s documentation.
For our example, the key field is named “x-api-key”:
Finally, we get to variable parameters.Variable (Dynamic) Parameters dynamically change based on user input or conversation context, unlike their static counterparts. In function calling, these parameters
adapt to the specifics of each request, being determined at runtime. This ensures that API calls made by the AI are tailored to the immediate needs of the conversation,
enabling a more personalized and relevant interaction. The AI extracts these parameters directly from the dialogue, determining when and how to call the function
based on the ongoing conversation.For our function, we define the following variable parameters:
{ "type": "object", "properties": { "query": { "type": "string", "description": "The keywords, author names or exact paper IDs to search for" }, "fields": { "type": "string", "description": "The information to be returned, default as 'title,abstract,paperId,authors,year,url,referenceCount,citationCount'" }, "limit": { "type": "string", "description": "The number of papers users want to get, default as 2. Use the default for all cases." } }, "required": [ "query" ]}
Notice that this is a structured JSON format. Under the key field “type” of the entire parameter-set, we put “object”. You should do the same for yours.Under properties, you define each parameter along with their type and description. Take “query” for example. It has type String, meaning its data type is free text.
Types can be “String”, “integer”, “boolean”, “array”, etc. The description is more open-ended, but also extremely important. This is where you must tell
the LLM what this parameter represents. To the best of your ability, provide default values and examples of actual parameter values when the function is called.Try to be as explicit as possible. Remember that if the AI has to guess whether a parameter named ‘language’ should take ‘en’ or ‘english’ as input, chances are
it will guess wrong, and you will see errors in your chatbot output.Depending on the function you are working with, input parameters can get pretty complex. Below is another example for supplying parameters to a function (NOT related
to our Semantic Scholar example) that uses an array:
{ "type": "object", "properties": { "tags": { "type": "array", "description": "labels that should be assigned to the user’s request", "items": { "type": "object", "properties": { "name": { "type": "string", "description": "The name of the label", }, "color": { "type": "string", "description": "The color of the label", }, }, "required": ["name", "color"], }, }, }, "required": ["tags"],}
The function can only be called once the “required” parameters have been collected. If necessary information is missing, the function cannot be invoked. You
must define which parameters are mandatory in order for the function to be called.For additional information on the supported JSON schema, please reference this guide: https://json-schema.org/understanding-json-schema/reference/type
Once everything is set up, save your function, then save the Agent. You can then test it out under “Preview” tab:
You can turn on the debug mode with the toggle on the top right corner of the screen. This will allow you to inspect the output of the function if it had been
called during the LLM response:
Just like that, you equipped your AI Agent with on-demand information from an external data provider. In the future, we will also write a guide that helps you
implement and host your own database search function that then gets integrated with Chatsistant.
{"docsConfig":{"$schema":"https://mintlify.com/docs.json","theme":"mint","name":"Chatsistant API","colors":{"primary":"#2E3F51","light":"#516F90","dark":"#0D001D"},"favicon":"/logo/favicon.png","logo":{"light":"https://mintcdn.com/chatsistant/bw0W4PPFP0FNqFg-/logo/light.svg?fit=max\u0026auto=format\u0026n=bw0W4PPFP0FNqFg-\u0026q=85\u0026s=f721e4cc50453f170fe167c8d5f9971f","dark":"https://mintcdn.com/chatsistant/bw0W4PPFP0FNqFg-/logo/dark.svg?fit=max\u0026auto=format\u0026n=bw0W4PPFP0FNqFg-\u0026q=85\u0026s=fcd6fd05fd8afca74097b05fde4c4007","href":"https://chatsistant.com"},"api":{"mdx":{"server":"https://app.chatsistant.com/api","auth":{"method":"bearer","name":null}}},"background":{"decoration":null,"color":{"light":null,"dark":"#111827"}},"navbar":{"links":[{"label":"Support","href":"mailto:hello@chatsistant.com"}],"primary":null},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"chatsistant","hasAudioNarration":false,"actualSubdomain":"chatsistant","customDomains":["docs.chatsistant.com"],"gitSource":{"type":"github","owner":"chatsistant","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":false,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6a21f6212af1650193592d35","collectionId":"ff68fb2a-91c7-4dc0-a6ff-701a8cd7a98c","schemaVersion":"v2"},"entitlements":{},"buildId":"6a21f6212af1650193592d35:success","clientVersion":"0.0.3964","searchFilterCounts":[{"language":"default","tag":"API References","count":38},{"language":"default","tag":"Documentation","count":17},{"language":"default","tag":"Guides","count":14},{"language":"default","tag":"Data Sources","count":9},{"language":"default","tag":"Chatbots","count":6},{"language":"default","tag":"Agents","count":5},{"language":"default","tag":"Session Messages","count":5},{"language":"default","tag":"Chatbot Sessions","count":5},{"language":"default","tag":"API Usage Guides","count":4},{"language":"default","tag":"Data Source Tags","count":4}]},"assistantConfig":{},"hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-v7-file-tree","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"pause-universal-search-reconcile","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"per-site-search-delta","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-private-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-nav-generations","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"rag-from-external-data-provider","slug":"/rag-from-external-data-provider","pageMetadata":{"title":"RAG from an External Data Provider","description":null,"href":"/rag-from-external-data-provider"},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,p:`p`,pre:`pre`,span:`span`,..._provideComponents(),...props.components},{CodeBlock,Frame,Heading,Note,OptimizedImage}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Frame)_missingMdxReference(`Frame`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Uploading static sources as training data for your AI Agents is well and good, but what if your database is huge, structured, externally-hosted,\nor updated in real-time? There is no way to dump the entire database into Chatsistant’s static knowledge library and still maintain a live link…`}),`\n`,_jsx(_components.p,{children:`This is where function-calling comes in. Through function-calling, you can serve data on-demand to your AI Agent in Chatsistant during a live\nconversation session. To show you how, we walk you through an example of RAG enrichment using (abstracts of) academic papers sourced from a trusted\nacademic papers aggregator: Semantic Scholar API.`}),`\n`,_jsx(Heading,{level:`2`,id:`setting-up-and-testing-the-function`,children:`Setting up and testing the function`}),`\n`,_jsxs(_components.p,{children:[`First, you’ll need an API key from your external data provider, whoever that may be, assuming they have a secure API. In our case, we requested one\nfrom `,_jsx(_components.a,{href:`https://www.semanticscholar.org/`,children:`Semantic Scholar`}),` directly.`]}),`\n`,_jsxs(_components.p,{children:[`Since we want to enrich our LLM query response with relevant information from academic research, we need to find the appropriate API endpoint to\nconduct the search. Semantic Scholar offers nice `,_jsx(_components.a,{href:`https://api.semanticscholar.org/api-docs/graph#tag/Paper-Data/operation/get_graph_paper_relevance_search`,children:`documentation`}),`\nin that regard.`]}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-1.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=f8f601f8d4a7c7ddb4e5536739339996`,\"data-og-width\":`1242`,width:`1242`,\"data-og-height\":`954`,height:`954`,\"data-path\":`images/fc-external-database-api-1.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-1.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=c4d028ad46ba44db09412bd0115bb911 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-1.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=4d67e702e7cc5c7a4adc8dcdb10faee2 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-1.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=436445d53e2f4758ec304d78643b64fb 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-1.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=3b9b74f41d0ddad27f625782d191de08 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-1.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=5ed5429dd3e157291b0694a9598e5d85 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-1.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=26bb799a2b7454d1882f72f03343d228 2500w`})}),`\n`,_jsx(_components.p,{children:`So what does this API endpoint respond with?`}),`\n`,_jsx(_components.p,{children:`To inspect the output, we ran a script that makes a request to the API based on hardcoded input parameters. The source code of our script is included\nbelow. You will need your own Semantic Scholar API key if you wish to run it yourself. For our example, we ran a search for relevant papers on the topic\nof “Multifidelity Optimization” and “Gaussian Processes”.`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`30`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`30`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` requests`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` json`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` os`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Set up the headers with the API key`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`headers `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'X-API-KEY'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR OWN API KEY\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Specify the fields you want to fetch for each recommended paper`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`fields `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"paperId,title,authors,abstract,url,referenceCount\"`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Define the limit for the number of recommendations to return`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`limit `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 20`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Make the request to get paper recommendations`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`response `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` requests.get(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'https://api.semanticscholar.org/graph/v1/paper/search'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` headers`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`headers,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # json=payload,`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` params`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'fields'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: fields, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'limit'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: limit, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'query'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'multifidelity optimization, gaussian processes'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Check if the request was successful`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` response.status_code `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`==`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:` 200`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`:`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` print`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(json.dumps(response.json(), `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`indent`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`2`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`))`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`else`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`:`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` print`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`f`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Error: `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`{`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`response.status_code`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # It's better to print response.text for non-200 responses, as they may not be in JSON format`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` print`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(response.text)`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`The output we received looks like follows:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`56`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`56`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"total\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`12096`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"offset\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"next\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`20`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"data\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"paperId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"b108e6e11f4a96d5058945f3b582a032e8204ade\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"url\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://www.semanticscholar.org/paper/b108e6e11f4a96d5058945f3b582a032e8204ade\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"title\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Multifidelity Gaussian processes for failure boundary andprobability estimation\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"abstract\": \"Estimating probability of failure in aerospace systems is a critical requirement for flight certification and qualification. Failure probability estimation (FPE) involves resolving tails of probability distribution and Monte Carlo (MC) sampling methods are intractable when expensive high-fidelity simulations have to be queried. We propose a method to use models of multiple fidelities, which trade accuracy for computational efficiency. Specifically, we propose the use of multifidelity Gaussian process models to efficiently fuse models at multiple fidelity. Furthermore, we propose a novel acquisition function within a Bayesian optimization framework, which can sequentially select samples (or batches of samples for parallel evaluation) from appropriate fidelity models to make predictions about quantities of interest in the highest fidelity. We use our proposed approach within a multifidelity importance sampling (MFIS) setting, and demonstrate our method on the failure level set estimation on synthetic test functions as well as the transonic flow past an airfoil wing section.\",`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"referenceCount\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`49`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authors\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"98543101\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Ashwin Renganathan\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"144321616\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Vishwas Rao\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"143672238\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Ionel M. Navon\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"paperId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"963a5c60ada159d27641a284008f57d6419b26f2\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"url\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"https://www.semanticscholar.org/paper/963a5c60ada159d27641a284008f57d6419b26f2\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"title\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Generative Transfer Optimization for Aerodynamic Design\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:` \"abstract\": \"Transfer optimization, one type of optimization methods, which leverages knowledge of the completed tasks to accelerate the design progress of a new task, has been in widespread use in machine learning community. However, when applying transfer optimization to accelerate the progress of aerodynamic shape optimization (ASO), two challenges are encountered in sequence, that is, (1) how to build a shared design space among the related aerodynamic design tasks, and (2) how to exchange information between tasks most efficiently. To address the first challenge, a datadriven generative model is used to learn airfoil representations from the existing database, with the aim of synthesizing various airfoil shapes in a shared design space. To address the second challenge, both singleand multifidelity Gaussian processes (GPs) are employed to carry out optimization. On one hand, the multifidelity GP is used to leverage knowledge from the completed tasks. On the other hand, mutual learning is established between singleand multifidelity GP models by exchanging information between them in each optimization cycle. With the above, a generative transfer optimization (GTO) framework is proposed to shorten the design cycle of aerodynamic design. Through airfoil optimizations at different working conditions, the effectiveness of the proposed GTO framework is demonstrated.\",`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"referenceCount\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`16`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authors\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"2149505113\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Zhendong Guo\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"2153199285\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Wei Sun\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"50258957\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Liming Song\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"46276037\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Jun Yu Li\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"authorId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"73325644\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Z. Feng\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#82071E`,\"--shiki-light-font-style\":`italic`,\"--shiki-dark\":`#F44747`,\"--shiki-dark-font-style\":`inherit`},children:`…`}),_jsx(_components.span,{style:{color:`#82071E`,\"--shiki-light-font-style\":`italic`,\"--shiki-dark\":`#F44747`,\"--shiki-dark-font-style\":`inherit`},children:` (truncated`}),_jsx(_components.span,{style:{color:`#82071E`,\"--shiki-light-font-style\":`italic`,\"--shiki-dark\":`#F44747`,\"--shiki-dark-font-style\":`inherit`},children:` due`}),_jsx(_components.span,{style:{color:`#82071E`,\"--shiki-light-font-style\":`italic`,\"--shiki-dark\":`#F44747`,\"--shiki-dark-font-style\":`inherit`},children:` to`}),_jsx(_components.span,{style:{color:`#82071E`,\"--shiki-light-font-style\":`italic`,\"--shiki-dark\":`#F44747`,\"--shiki-dark-font-style\":`inherit`},children:` length)`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`The Semantic Scholar function returned the top 20 matching results ranked by relevance based on our input parameter specification. As you see, the response\ncan get quite long, so we truncated the output for conciseness.`}),`\n`,_jsx(_components.p,{children:`Ideally, you want a structured JSON response from the function’s output like what we showed above.`}),`\n`,_jsx(_components.p,{children:`We ran our own analysis for this particular API endpoint (with the specific set of output fields we requested) and found that on average, each returned\nresult is between 400-500 tokens long. This means that depending on the token limit we reserved for the function output, we can only fit so many search results\nin before running out of space. Keep this in mind as you prioritize the information you wish to supply to the LLM during RAG.`}),`\n`,_jsx(_components.p,{children:`Now we know what the LLM would see as additional context provided by the function call, we can start linking it to our Chatsistant Agent.`}),`\n`,_jsx(Note,{children:_jsx(_components.p,{children:`It is ALWAYS advisable to write your own script and test for the output of the API endpoint first. You want to know exactly what kind information\nis being fed into your AI Agent.`})}),`\n`,_jsx(Heading,{level:`2`,id:`create-and-prepare-the-ai-agent`,children:`Create and prepare the AI Agent`}),`\n`,_jsx(_components.p,{children:`In your chatbot inside Chatsistant, you must first create an appropriate AI Agent that you plan to give this function-calling capability to. In our example,\nwe created “The Professor”. We then defined an associated Agent description and base prompt.`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-2.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=7bc8d1acd790e6381213507e2ee72e0b`,\"data-og-width\":`1919`,width:`1919`,\"data-og-height\":`906`,height:`906`,\"data-path\":`images/fc-external-database-api-2.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-2.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=e3699a6ef71fcd15ef58b09de17a379b 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-2.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=fe9b6ba6af23c8333b621bea33ac9bbe 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-2.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=7b69ff8a4c2d6f5933396fad3d7101a0 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-2.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=0bff34f756459c30df633df9e45b3c27 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-2.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=c474b43c691603ba8679277152889734 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-2.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=b4d948a27868c4b625cbe25eb50ba4a8 2500w`})}),`\n`,_jsx(_components.p,{children:`We picked the GPT-4-0125-8k Model for this example. You can see our simple prompt in the screenshot below.`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-3.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=dbc1a5ec0a4a50134869aee7831f5d2a`,\"data-og-width\":`1919`,width:`1919`,\"data-og-height\":`906`,height:`906`,\"data-path\":`images/fc-external-database-api-3.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-3.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=ad9664fb308d2919fb2f1ad4eab8d8e0 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-3.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=1b9c1848382671a17183e40c76605f07 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-3.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=190eecfef51c674697f50767d86c8449 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-3.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=63c87c57218327859b9775b8d70f5d3c 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-3.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=42c5ccd65da794eecd294646ad2808c8 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-3.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=a965679586b95b5f98d67811c09dfa19 2500w`})}),`\n`,_jsx(_components.p,{children:`Next, we save the Agent and go to the “Knowledge” tab to disable static RAG from the chatbot’s own knowledge library. This is only necessary if you don’t want\nto use any training data from the static sources list. In our example, we didn’t upload any training data anyways, but we do this as standard practice to keep\nthings clean.`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-4.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=a61d8d09e70a50409b3f7a56f63303b8`,\"data-og-width\":`1919`,width:`1919`,\"data-og-height\":`906`,height:`906`,\"data-path\":`images/fc-external-database-api-4.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-4.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=60b9d5340302c966332e44f975e0504a 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-4.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=a379e1e10e8862b63894594cab8060f1 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-4.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=a9e6e9b72926e8027e64dfdd37a6a02a 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-4.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=37152f2681f1e750a802159fe6bc2160 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-4.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=f8c3310bfbfd8d21353195f985dedf6b 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-4.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=1e6be323ee58ad838c10e897aaafec48 2500w`})}),`\n`,_jsx(_components.p,{children:`Save the Agent.`}),`\n`,_jsx(Heading,{level:`2`,id:`function-setup`,children:`Function setup`}),`\n`,_jsx(_components.p,{children:`Within your Agent, head over to the “Functions” tab. Change the “Response Context Limit” to the maximum allowed. Then click “Add function”.`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-5.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=7e07042fb38ab861befc881621d8dfa4`,\"data-og-width\":`1919`,width:`1919`,\"data-og-height\":`906`,height:`906`,\"data-path\":`images/fc-external-database-api-5.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-5.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=46764a34ec3e4a4333159462b3a4f73b 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-5.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=ff7c98983ee3d04ebaa112c45b5cd148 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-5.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=9413882040018bceb657684e661d0910 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-5.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=00928aa8829a17463a7b84c3cf33d736 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-5.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=4626fd494fc45e3763eb37c19a734c37 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-5.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=96db7ad147660a8b8bbfa36672b608f5 2500w`})}),`\n`,_jsx(_components.p,{children:`This is where you tell the LLM exactly what the function does and how it works. The LLM will then decide on its own whether it needs the function when responding\nto the user during a conversation, then call it with the appropriate parameters as needed.`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-6.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=4e366f9f0cdd39ab142909c6ecf645d0`,\"data-og-width\":`1912`,width:`1912`,\"data-og-height\":`903`,height:`903`,\"data-path\":`images/fc-external-database-api-6.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-6.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=08343fb4a36067733c5a678700b1a85b 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-6.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=66aeeea0d01a547d5440e14a965c878a 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-6.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=82c7a539695c17362457689fe95d6d05 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-6.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=f844733a5c69223499ae77b467d81da0 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-6.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=a4b1f4c2fe6dae74c868b75466dc1328 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-6.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=42dd5e9c7f13ed24cd52f55725ba57ba 2500w`})}),`\n`,_jsx(_components.p,{children:`The function name and description are particularly useful in helping the AI understand what the function does. Please make sure to be as explicit as possible in\nyour own definition. The function description must be less than 1024 characters, including spaces. In our case, we wrote the following:`}),`\n`,_jsx(CodeBlock,{numberOfLines:`14`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`14`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`Function name: paper_relevance_search`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`Function description: `})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`This function searches Semantic Scholar, a scholarly literature database. The input parameters will be defined based on extracted information from conversation context. It will return search results containing academic paper metadata (with abstracts) in a JSON format.`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`The returned fields are defined as follows:`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- title: paper title`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- abstract: paper abstract`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- paperId: paper uuid`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- authors: paper authors`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- year: paper publication year`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- url: paper link`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- referenceCount: number of references included in the paper`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`- citationCount: number of citations of this paper`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:`Next, define the API endpoint. The Semantic Scholar endpoint we are using is simple and straighforward:`}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://api.semanticscholar.org/graph/v1/paper/search`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(_components.p,{children:`After that, choose the HTTP method. We use “GET” for our example. The specific API endpoint you are using should have documentation about this distinction.`}),`\n`,_jsx(Heading,{level:`2`,id:`fixed-parameters`,children:`Fixed parameters`}),`\n`,_jsx(_components.p,{children:`Static (Fixed) Parameters remain constant across all API requests. They are pre-defined and reflect settings or configurations that do not change with each\ncall. For example, parameters that specify the format of the response or that enable/disable certain features globally across all API interactions fall into\nthis category. The term “static” emphasizes their unchanging nature.`}),`\n`,_jsxs(_components.p,{children:[`Depending on your particular API endpoint, you may need to append some fixed parameters in the URL. The API we use above from Semantic Scholar does not require\nfixed parameters. But if you are using a more complex endpoint like this:\n`,_jsx(_components.a,{href:`https://app.outscraper.com/api-docs#tag/Businesses-and-POI/paths/~1maps~1search-v3/get`,children:`https://app.outscraper.com/api-docs#tag/Businesses-and-POI/paths/~1maps~1search-v3/get`}),`, then your API endpoint may include fixed parameters and look something like:`]}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://api.app.outscraper.com/maps/search-v3?async=false\u0026fields=name,full_address,phone,site`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsxs(_components.p,{children:[`Notice that at the end of “`,_jsx(_components.a,{href:`https://api.app.outscraper.com/maps/search-v3`,children:`https://api.app.outscraper.com/maps/search-v3`}),`”, we get into fixed parameters. This is where you define parameters that will not change\nwhen the function is called. Always define fixed parameters this way!`]}),`\n`,_jsx(Note,{children:_jsx(_components.p,{children:`If your API is capable of returning a more concise response by configuring certain parameters (i.e., tell the API to leave out unnecessary metadata in the response),\nthen we highly suggest that you do so. It will reduce token waste and help AI understand the context better. In the above example, we set “fields=name,full_address,phone,site”\nspecifically to limit the response so that it contains only name, full_address, phone, and site information - and nothing else.`})}),`\n`,_jsx(Heading,{level:`2`,id:`headers-and-authentication`,children:`Headers and Authentication`}),`\n`,_jsx(_components.p,{children:`In general, secure public-facing APIs require authentication. Semantic Scholar is the same. In the Header, we provide our API key. The specific key field used\nto supply your authentication token will differ based on the particular API you use, so please make sure to be informed on your API provider’s documentation.\nFor our example, the key field is named “x-api-key”:`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=26d8f7db19c2159afb973454fcafd71a`,\"data-og-width\":`1912`,width:`1912`,\"data-og-height\":`903`,height:`903`,\"data-path\":`images/fc-external-database-api-7.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=ee1ba4e7a82424fe888d180a7894d685 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=5855e66e0352b60f8cb45ee3e2525cf4 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=0427f60cec4f4f9eb544ac5ca2e30c1f 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=95ca06a1969e887d833cd57e0a746190 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=b4eb7ed3429c725edbc9ef562308f02e 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=128d35a642384ce847d6d4b495b083e6 2500w`})}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7_1.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=2f25bf29279824859f4e518635aae70e`,\"data-og-width\":`1915`,width:`1915`,\"data-og-height\":`909`,height:`909`,\"data-path\":`images/fc-external-database-api-7_1.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7_1.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=69f462b768ab162e4075dc3b4ab88c50 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7_1.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=509ff1bc2e65989e74e1d8686afc6ff4 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7_1.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=ddf9a134c1f31dc0da1494ce2aaeefa5 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7_1.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=be1c61617d4f27224fefd426e99fcdd5 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7_1.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=9944b642e0562a55f87d572aab54947e 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-7_1.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=e448db72a8561a5841653b8d9f7052b4 2500w`})}),`\n`,_jsx(Heading,{level:`2`,id:`variable-parameters`,children:`Variable parameters`}),`\n`,_jsx(_components.p,{children:`Finally, we get to variable parameters.`}),`\n`,_jsx(_components.p,{children:`Variable (Dynamic) Parameters dynamically change based on user input or conversation context, unlike their static counterparts. In function calling, these parameters\nadapt to the specifics of each request, being determined at runtime. This ensures that API calls made by the AI are tailored to the immediate needs of the conversation,\nenabling a more personalized and relevant interaction. The AI extracts these parameters directly from the dialogue, determining when and how to call the function\nbased on the ongoing conversation.`}),`\n`,_jsx(_components.p,{children:`For our function, we define the following variable parameters:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`21`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`21`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"object\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"properties\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"query\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"The keywords, author names or exact paper IDs to search for\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"fields\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"The information to be returned, default as 'title,abstract,paperId,authors,year,url,referenceCount,citationCount'\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"limit\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"The number of papers users want to get, default as 2. Use the default for all cases.\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"required\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"query\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`Notice that this is a structured JSON format. Under the key field “type” of the entire parameter-set, we put “object”. You should do the same for yours.`}),`\n`,_jsx(_components.p,{children:`Under properties, you define each parameter along with their type and description. Take “query” for example. It has type String, meaning its data type is free text.\nTypes can be “String”, “integer”, “boolean”, “array”, etc. The description is more open-ended, but also extremely important. This is where you must tell\nthe LLM what this parameter represents. To the best of your ability, provide default values and examples of actual parameter values when the function is called.`}),`\n`,_jsx(_components.p,{children:`Try to be as explicit as possible. Remember that if the AI has to guess whether a parameter named ‘language’ should take ‘en’ or ‘english’ as input, chances are\nit will guess wrong, and you will see errors in your chatbot output.`}),`\n`,_jsx(_components.p,{children:`Depending on the function you are working with, input parameters can get pretty complex. Below is another example for supplying parameters to a function (NOT related\nto our Semantic Scholar example) that uses an array:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`24`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`24`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"object\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"properties\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"tags\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"array\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"labels that should be assigned to the user’s request\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"items\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"object\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"properties\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"The name of the label\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"color\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"description\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"The color of the label\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"required\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"color\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"required\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"tags\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`The function can only be called once the “required” parameters have been collected. If necessary information is missing, the function cannot be invoked. You\nmust define which parameters are mandatory in order for the function to be called.`}),`\n`,_jsxs(_components.p,{children:[`For additional information on the supported JSON schema, please reference this guide: `,_jsx(_components.a,{href:`https://json-schema.org/understanding-json-schema/reference/type`,children:`https://json-schema.org/understanding-json-schema/reference/type`})]}),`\n`,_jsx(Heading,{level:`2`,id:`testing-the-chatbot`,children:`Testing the chatbot`}),`\n`,_jsx(_components.p,{children:`Once everything is set up, save your function, then save the Agent. You can then test it out under “Preview” tab:`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-8.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=508d6f11f873514281791bccfd2937bf`,\"data-og-width\":`657`,width:`657`,\"data-og-height\":`811`,height:`811`,\"data-path\":`images/fc-external-database-api-8.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-8.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=b905bec3429db79e9bece265bae6fbe9 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-8.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=744ee3b42d4a847dc7fb7e4e525449a0 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-8.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=a5e39418ce96257d6e0d48e1c05e9df5 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-8.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=da16ad2f6b51bd1d8429a303f7a3fd10 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-8.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=beebf683c2b667e293c7f367fad44020 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-8.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=c0c5818b9c77327f0348712cc1572c26 2500w`})}),`\n`,_jsx(_components.p,{children:`You can turn on the debug mode with the toggle on the top right corner of the screen. This will allow you to inspect the output of the function if it had been\ncalled during the LLM response:`}),`\n`,_jsx(Frame,{children:_jsx(OptimizedImage,{src:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-9.png?fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=22d97e33915673e6840780db43f502eb`,\"data-og-width\":`1209`,width:`1209`,\"data-og-height\":`669`,height:`669`,\"data-path\":`images/fc-external-database-api-9.png`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-9.png?w=280\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=57c83267d8abfc85a76a5e4baae39a07 280w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-9.png?w=560\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=162ba8f273a6eeac9431d9b935bf2f4a 560w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-9.png?w=840\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=3b417f26e4e0f093f9bd81daf1417cae 840w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-9.png?w=1100\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=e83bbc5ee5e947874f91f8c147d6a50c 1100w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-9.png?w=1650\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=ff754a6c8c8303f97469dec8c00d4628 1650w, https://mintcdn.com/chatsistant/_PfgpPLIz_t18KMO/images/fc-external-database-api-9.png?w=2500\u0026fit=max\u0026auto=format\u0026n=_PfgpPLIz_t18KMO\u0026q=85\u0026s=ef0b501d079fb13a68e057e43ac4c054 2500w`})}),`\n`,_jsx(_components.p,{children:`Just like that, you equipped your AI Agent with on-demand information from an external data provider. In the future, we will also write a guide that helps you\nimplement and host your own database search function that then gets integrated with Chatsistant.`})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"RAG from an External Data Provider","description":null,"href":"/rag-from-external-data-provider"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Setting up and testing the function","slug":"setting-up-and-testing-the-function","depth":2,"children":[]},{"title":"Create and prepare the AI Agent","slug":"create-and-prepare-the-ai-agent","depth":2,"children":[]},{"title":"Function setup","slug":"function-setup","depth":2,"children":[]},{"title":"Fixed parameters","slug":"fixed-parameters","depth":2,"children":[]},{"title":"Headers and Authentication","slug":"headers-and-authentication","depth":2,"children":[]},{"title":"Variable parameters","slug":"variable-parameters","depth":2,"children":[]},{"title":"Testing the chatbot","slug":"testing-the-chatbot","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"chatsistant","siteName":"Chatsistant API","title":"RAG from an External Data Provider - Chatsistant API","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-01-07T05:56:56.417Z","originalFileLocation":"rag-from-external-data-provider.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"application-name\" content=\"Chatsistant API\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"RAG from an External Data Provider - Chatsistant API\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Chatsistant API\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.chatsistant.com/rag-from-external-data-provider\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://chatsistant.mintlify.app/_mintlify/api/og/v2?division=Function+Calling\u0026amp;title=RAG+from+an+External+Data+Provider\u0026amp;theme=d7f2b54eec0e3933ad58bfa6\u0026amp;signature=21a7d3d0547287495b01304783cee6d46151f6195b4887ad1d32e71e0942820d\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"RAG from an External Data Provider - Chatsistant API\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://chatsistant.mintlify.app/_mintlify/api/og/v2?division=Function+Calling\u0026amp;title=RAG+from+an+External+Data+Provider\u0026amp;theme=d7f2b54eec0e3933ad58bfa6\u0026amp;signature=21a7d3d0547287495b01304783cee6d46151f6195b4887ad1d32e71e0942820d\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/chatsistant/jsSqGek8HR7LeVmL/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Chatsistant API\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#2E3F51\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.chatsistant.com/rag-from-external-data-provider\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/rag-from-external-data-provider.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.chatsistant.com/#organization\",\"name\":\"Chatsistant API\",\"url\":\"https://docs.chatsistant.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/chatsistant/bw0W4PPFP0FNqFg-/logo/light.svg?fit=max\u0026auto=format\u0026n=bw0W4PPFP0FNqFg-\u0026q=85\u0026s=f721e4cc50453f170fe167c8d5f9971f\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.chatsistant.com#website\",\"name\":\"Chatsistant API\",\"url\":\"https://docs.chatsistant.com\",\"publisher\":{\"@id\":\"https://docs.chatsistant.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.chatsistant.com/rag-from-external-data-provider#webpage\",\"url\":\"https://docs.chatsistant.com/rag-from-external-data-provider\",\"name\":\"RAG from an External Data Provider\",\"dateModified\":\"2026-01-07T05:56:56.417Z\",\"isPartOf\":{\"@id\":\"https://docs.chatsistant.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.chatsistant.com/rag-from-external-data-provider#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.chatsistant.com/rag-from-external-data-provider#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Chatsistant API\",\"item\":\"https://docs.chatsistant.com\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"RAG from an External Data Provider\",\"item\":\"https://docs.chatsistant.com/rag-from-external-data-provider\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.chatsistant.com/rag-from-external-data-provider#article\",\"headline\":\"RAG from an External Data Provider\",\"name\":\"RAG from an External Data Provider\",\"url\":\"https://docs.chatsistant.com/rag-from-external-data-provider\",\"mainEntityOfPage\":{\"@id\":\"https://docs.chatsistant.com/rag-from-external-data-provider#webpage\"},\"dateModified\":\"2026-01-07T05:56:56.417Z\",\"publisher\":{\"@id\":\"https://docs.chatsistant.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.chatsistant.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Chatsistant API\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Chatsistant API","nav":{"global":null,"anchors":[{"anchor":"Documentation","icon":"book-open","groups":[{"group":"Getting Started","pages":[{"title":"Introduction","href":"/introduction"}]},{"group":"Guides","pages":[{"title":"Create Your First Chatbot","href":"/creating-first-chatbot"},{"title":"Lead Collection","href":"/lead-collection"},{"title":"Human Support Escalation","href":"/human-support-escalation"},{"title":"Inbox Notifications","href":"/inbox-notifications"},{"title":"Conversation Labeling","href":"/conversation-labeling"},{"title":"Multi-Agents Chatbot","href":"/multi-agents-chatbot"},{"title":"Fine Tuning Agent Intents","href":"/fine-tuning-agent-intents"},{"title":"AI Supervisor Overrides","href":"/supervisor-overrides"},{"title":"Bring Your Own Key (BYOK) and Pricing","href":"/byok-pricing-guide"},{"title":"Working with Tables and CSV","href":"/working-with-tables"},{"title":"Best practices for preparing training data","href":"/best-practices"},{"title":"Background Agents","href":"/background-agents"},{"title":"Frustration Detection","href":"/frustration-detection"},{"title":"Why does my chatbot not answer correctly?","description":null,"href":"/help"}]},{"group":"Function Calling","pages":[{"title":"RAG from an External Data Provider","href":"/rag-from-external-data-provider"}]},{"group":"Authentication Webhook","pages":[{"title":"User Identity Verification","description":null,"href":"/user-identity"}]}]},{"anchor":"API References","icon":"code","pages":[{"title":"API References","href":"/api-reference/api-key-setup"}]}]},"title":"RAG from an External Data Provider - Chatsistant API","buildId":"dpl_HcHmUS6i3UwswnTHJUEdcTtwfdTQ","deploymentId":"dpl_HcHmUS6i3UwswnTHJUEdcTtwfdTQ","dynamics":["07c022d89b","a74be98ba7"],"chunks":["Frame-D1UCVuPB.js","DynamicMarkdown-Crwq6WG_.js","zoom-image-lightbox-CFBqa0On.js","lightbox-handle-r17bVUz3.js"]}