(self)
| 64 | """ This class host your own API backend. |
| 65 | """ |
| 66 | def __init__(self) -> None: |
| 67 | # define the root API server |
| 68 | self.api = fastapi.FastAPI( |
| 69 | title="BMTools", |
| 70 | description="Tools for bigmodels", |
| 71 | ) |
| 72 | self.loaded_tools = dict() |
| 73 | self.retriever = Retriever() |
| 74 | _bind_tool_server(self) |
| 75 | |
| 76 | def load_tool(self, name: str, config: Dict = {}): |
| 77 | if self.is_loaded(name): |
nothing calls this directly
no test coverage detected