Class DatabaseProviderAITools
java.lang.Object
com.vaadin.flow.component.ai.provider.DatabaseProviderAITools
Factory for creating reusable database
LLMProvider.ToolSpec
instances. These tools can be used by any controller that works with a
DatabaseProvider.- Author:
- Vaadin Ltd
-
Method Summary
Modifier and TypeMethodDescriptionstatic List<LLMProvider.ToolSpec> createAll(DatabaseProvider provider) Creates all database provider tools for the given provider.static LLMProvider.ToolSpecgetDatabaseSchema(DatabaseProvider provider) Creates a tool that retrieves the database schema from theDatabaseProvider.
-
Method Details
-
getDatabaseSchema
Creates a tool that retrieves the database schema from theDatabaseProvider.- Parameters:
provider- the database provider, notnull- Returns:
- the tool definition, never
null
-
createAll
Creates all database provider tools for the given provider.- Parameters:
provider- the database provider, notnull- Returns:
- a list of all database provider tools, never
null
-