To select an instrument with Amazon Nova Models

[ad_1]
In many AI tests, the largest language model (llm) as Amazon Nova is used to answer the user question or model in the model itself. However, as cases of mature use, the power to obtain access to the tools or structures that can be without the modeling fitness framework is very important. This can be API, the operations of the code, or schemas and structures required by your final application. This power has been developed to what is referred to as Use of tools or To call.
In addition to the clean controlling control of how to use the tools used, we have issued the Amazon Nova models selection tool. Instead of depending on the instant engineer, the selection of tools forces a local setting model.
In this post, we discuss the use of tools and a new feature of the selection tool, for example use charges.
Tool Use by Amazon Nova
Showing the idea of using the tool, we can consider the situation where we provide different Amazon tools based on the user question, Amazon Nova will select the appropriate tool and tell you how to use it. For example, if the user asks “What is the weather in Seattle?” Amazon Nova will use the weather tool.
The following drawing is indicating the impression of the example between the Amazon Nova model, its available tools, and external related resources.
The use of tools in the main environment for the designation of the tool and its parameters. Obligation to make foreign performance to apply or developer. After the tool is performed by the app, you can take the results to the last generation model.
Let us examine some examples about many details. The following drawing is indicating the Amazon Nova Model Model to access the weather API, and return the answer to the user.
The following drawing is indicating the action of the Amazon Nova model using the phone to access the calculator tool.
To select an instrument with Amazon Nova
This page toolChoice API parameter allows you to control the device. There are three supported options for this parameter:
- Any – by choosing the tool
AnyThe model will select at least one of the tools available each time: - Tool – by choosing the tool
ToolThe model will always use the requested instrument: - Play – to select a tool
AutoIs automatic behavior and will leave the selection of tools to achieve model:
A famous plan to develop model consulting skills to use a series of thought. When using the selection of tools for autoAmazon Nova will use a series of thought and the model feedback will include both reasons and tool selected.
This behavior will vary in terms of the application. When tool or any It is selected as selection of tools, Amazon Nova will only remove the tools and not release of the thought.
Use charges
At this stage, we examine different cases of use to the tool activation.
Output / JSON mode
In some cases, you may want Amazon Nova to use a particular tool to answer the user's question, whether Amazon Nova believes that you can give the answer without using the tool. The general charge of the use of this method enables exit / JSON mode. It is usually very important that the llms is returned to formal exit, because this enables the capacity of the river to effectively use and process the results produced. In these cases, employed tools do not need to be the customer service – can be used whenever model is required to hold a pre-defined schema, thus enforcing the Amazon Nova to use the specified tool.
When using the correct compelling tools, you give one tool with a descriptive JSON inputSchema. You specify the tool with {"tool" : {"name" : "Your tool name"}}. The model will transfer tool to install tool, so the tool name and its meaning should be in a model view.
For example, consider the food web site. If you are provided for a container, a website can issue a receptive details, such as the cooktime, ingredients, the new reservation, and the difficulty of the level, to facilitate users' search and sorting skills. See the following model code:
We can provide a detailed proposal as text entry:
We can force Amazon Nova to use a tool extract_recipewhich will produce a JSS systematic effect that sticks to the pre-defined schema provided as a SCHEMA Tool:
Sentence
Another common situation requires Amazon Nova that you have chosen tool from available options even if the current user's one. One instance for this is the election of the end of the API end. In this case, we do not know how a tool will use, and we allow the model to choose between the available.
For the selection of tools for anyYou can be sure that the model will always use at least one of the tools available. As a result, we offer a tool that can be used when API does not work. Another example can be to provide a tool that allows the specific questions.
In this example, it provides model for two different apis, with an informal API tool to choose based on the user question:
User installation of “You can get all products available?” will issue the following:
And “can you get my most recent orders?” will issue the following:
Discuss search
The last option of tool selection option auto. This is the default behavior, so it is compatible with the choice of tool choices at all.
Using this tool selection will allow the option to use the tool or to extract the text. If the model selects a tool, there will be the toolbar and the text block. If the model responds with no tool, only a block is returned. In the following example, we want to allow model to respond to the user or to drive the tool if necessary:
User installation of “What weather is in San Francisco?” It can lead to a tool call:
When asked the model a direct question such as “How many months per year?” You will respond with the text's response to the user:
Consideration
There are a few of the best ways to use the tool calling Nova models. The first is to use Greed is greed parameters. With the Amazon Nova model, you need to put the temperature, at the top of P, and top k 1. You can view examples of previous code for how you can set this. Using Coffin Times for Coubleng that force models to produce decent answers and improve the quality of payment of the tool.
The second consideration is JSON Schema that you use for the tools. During the writing, Amazon Nova Models support a limited set of Jon Schemas, so may not be taken as the model expected. Normal fields will be $def including $ref fields. Make sure your schema has higher top fields set: type (must object), propertiesbeside required.
Finally, to find a big impact on the success of a tool for driving tool, you must improve the configuration of your tools. Definitions and words should be clear. If there are nuances where one tool should be called over another, make sure it is directly listed in the tool of tools.
Store
Using the tool to select the tool to drive work is a disabled way to control how the model urges tools. Instead of depending on the instant engineer, the selection of tools forces a local setting model. However, there is difficulties to call the tool; For more information, refer to tools for tools (call call) with Amazon Nova, Tools Tools, Calls for Problem Tools.
Check out the Amazon Nova models can improve your charges for AI today.
About the authors
Jean farmer Is the construction of the AI solutions made from the Amazon Artificial General Intelligence (Agi) a group, special to Agentic applications. Based on Seattle, Washington, works in the communication of the independent AI and practical business systems, helps sharing the future of AGI in Amazon.
Sharon Li Is the construction of the AI / ML solutions on cutting technology in cutting, Sharon is advanced in developing and fining new AI solutions on the AWS Cloud.
Lulu Wong Ai ux designer in Amazon Artificial General Intelligence (Agi) team. Back in computer science, learning design, and user experience, binding technical and creative backgrounds AIs, and creating AI products readily available to users.
[ad_2]
Source link



