Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

tools.py 396 B

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
  1. from typing import Literal, Optional
  2. from openai import OpenAI
  3. from openai._base_client import HttpxBinaryResponseContent
  4. from lib.configs import OPENAI_API_KEY
  5. __all__ = ["BaseTool"]
  6. class BaseTool:
  7. def __init__(self):
  8. pass
  9. def __call__(self, *args, **kwargs):
  10. return self.run(*args, **kwargs)
  11. def run(self, *args, **kwargs):
  12. raise NotImplementedError
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...