Tools
Tools are side-effectful operations that a model can invoke to perform actions or retrieve information. They are defined by a name, description, and a list of parameters they accept.
In Infragate, tools are simply interfaces that are mapped to underlying data sources using a mapping template. The mapping template takes many forms. In the context of database data sources, the mapping template is a SQL query. In the context of data sources that are APIs, the mapping template is an HTTP request. The parameters are then mapped to variables in the SQL query or HTTP request. In the context of custom functions however, the input parameters are provided as a composite object.
A tool can only be mapped to one data source. However, a data source can have multiple tools mapped to it. For example, a SQL database data source can have multiple tools mapped to it, each with a different SQL query.