![]() |
ThalamOS
a powerful Flask web application designed to enhance your storage management.
|
Public Member Functions | |
__init__ (self, str sql_database) | |
run (self, List[str] queries) | |
__str__ (self) | |
Public Attributes | |
connection = sqlite3.connect(f"file:{sql_database}?mode=ro", uri=True) | |
A component to execute SQL queries on the SQLite database. Attributes: connection (sqlite3.Connection): The connection to the SQLite database. Methods: run(queries: List[str]) -> dict: Executes the provided SQL queries and returns the results.
Definition at line 88 of file ollama_manager.py.
ollama_manager.SQLQuery.__init__ | ( | self, | |
str | sql_database ) |
Definition at line 99 of file ollama_manager.py.
ollama_manager.SQLQuery.__str__ | ( | self | ) |
Definition at line 125 of file ollama_manager.py.
ollama_manager.SQLQuery.run | ( | self, | |
List[str] | queries ) |
Executes the provided SQL queries and returns the results. Tests if the SQL queries are valid before execution. Args: queries (List[str]): A list of SQL queries to be executed. Returns: dict: A dictionary containing the results of the executed queries and the original queries.
Definition at line 103 of file ollama_manager.py.
ollama_manager.SQLQuery.connection = sqlite3.connect(f"file:{sql_database}?mode=ro", uri=True) |
Definition at line 100 of file ollama_manager.py.