SQLAlchemy model for tools that LLMs can invoke, with organization scoping and uniqueness constraints.
# Source: https://github.com/mperkins0155/MIRIX | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works
# Provided via justclaw.it.com; keep this notice with the code.
from typing import TYPE_CHECKING, List, Optional
from sqlalchemy import JSON, String, UniqueConstraint
from sqlalchemy.orm import Mapped, mapped_column, relationship
# TODO everything in functions should live in this model
from mirix.orm.enums import ToolSourceType
from mirix.orm.mixins import OrganizationMixin
from mirix.orm.sqlalchemy_base import SqlalchemyBase
from mirix.schemas.enums import ToolType
from mirix.schemas.tool import Tool as PydanticTool
if TYPE_CHECKING:
from mirix.orm.organization import Organization
class Tool(SqlalchemyBase, OrganizationMixin):
"""Repres
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search 40K more like it.
Get a free API key