Update text_generator.py
Browse files- text_generator.py +1 -1
text_generator.py
CHANGED
@@ -15,7 +15,7 @@ class TextGenerationTool(Tool):
|
|
15 |
|
16 |
def __call__(self, prompt: str):
|
17 |
API_URL = "https://api-inference.huggingface.co/models/mistralai/Mistral-7B-v0.1"
|
18 |
-
headers = {"Authorization":
|
19 |
|
20 |
def query(payload):
|
21 |
response = requests.post(API_URL, headers=headers, json=payload)
|
|
|
15 |
|
16 |
def __call__(self, prompt: str):
|
17 |
API_URL = "https://api-inference.huggingface.co/models/mistralai/Mistral-7B-v0.1"
|
18 |
+
headers = {"Authorization": os.environ['hf']}
|
19 |
|
20 |
def query(payload):
|
21 |
response = requests.post(API_URL, headers=headers, json=payload)
|