Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -4,18 +4,14 @@
|
|
| 4 |
# Import Necessary Libraries
|
| 5 |
import requests, json
|
| 6 |
import os
|
| 7 |
-
from dotenv import load_dotenv, find_dotenv
|
| 8 |
import gradio as gr
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
-
# reads local .env file
|
| 13 |
-
_ = load_dotenv(find_dotenv())
|
| 14 |
-
|
| 15 |
# load api key and endpoints
|
| 16 |
-
hf_api_key = os.environ
|
| 17 |
-
sum_endpoint = os.environ
|
| 18 |
-
ner_endpoint = os.environ
|
| 19 |
|
| 20 |
|
| 21 |
|
|
|
|
| 4 |
# Import Necessary Libraries
|
| 5 |
import requests, json
|
| 6 |
import os
|
|
|
|
| 7 |
import gradio as gr
|
| 8 |
|
| 9 |
|
| 10 |
|
|
|
|
|
|
|
|
|
|
| 11 |
# load api key and endpoints
|
| 12 |
+
hf_api_key = os.environ.get('HUGGINGFACEHUB_API_TOKEN')
|
| 13 |
+
sum_endpoint = os.environ.get("API_URL_SUMMARIZE") # summarization endpoint
|
| 14 |
+
ner_endpoint = os.environ.get("API_URL_NER") # named entity recognization endpoint
|
| 15 |
|
| 16 |
|
| 17 |
|