feat: tools integration

This commit is contained in:
Timothy J. Baek
2024-06-10 21:33:46 -07:00
parent c5683dd24c
commit b434ebf3ad
8 changed files with 146 additions and 42 deletions

View File

@@ -41,7 +41,7 @@ class ToolModel(BaseModel):
user_id: str
name: str
content: str
specs: dict
specs: List[dict]
meta: ToolMeta
updated_at: int # timestamp in epoch
created_at: int # timestamp in epoch
@@ -74,7 +74,7 @@ class ToolsTable:
self.db.create_tables([Tool])
def insert_new_tool(
self, user_id: str, form_data: ToolForm, specs: dict
self, user_id: str, form_data: ToolForm, specs: List[dict]
) -> Optional[ToolModel]:
tool = ToolModel(
**{