Skip to main content

tools_for_database

Function tools_for_database 

Source
pub fn tools_for_database(db_path: impl Into<String>) -> Vec<Box<dyn DynTool>>
Expand description

Create a set of SQLite tools restricted to a specific database.

The returned tools will only access the specified database, ignoring any db_path parameter in tool inputs.

§Example

ⓘ
use mixtape_tools::sqlite;

let agent = Agent::builder()
    .add_tools(sqlite::tools_for_database("/data/app.db"))
    .build()
    .await?;