Spaces:
Sleeping
Sleeping
Upload app.py
Browse files
app.py
CHANGED
@@ -18,14 +18,6 @@ import yaml
|
|
18 |
import pandas as pd
|
19 |
import numpy as np
|
20 |
|
21 |
-
import azureml.core
|
22 |
-
from azureml.core import Workspace, Datastore, ComputeTarget
|
23 |
-
from azure.identity import DefaultAzureCredential
|
24 |
-
from azure.ai.ml import MLClient
|
25 |
-
from azure.ai.ml import command
|
26 |
-
from azure.ai.ml import Input, Output
|
27 |
-
from azure.ai.ml import load_component
|
28 |
-
from azure.ai.ml.entities import Environment, Data, PipelineJob, Job, Schedule
|
29 |
from datetime import datetime, timedelta
|
30 |
|
31 |
# perspective generation
|
@@ -47,18 +39,8 @@ with open('./curify_api.yaml', 'r') as yaml_file:
|
|
47 |
data = yaml.safe_load(yaml_file)
|
48 |
|
49 |
# Access the API keys and other configuration data
|
50 |
-
weaviate_url = data.get('weaviate').get('url')
|
51 |
-
weaviate_api_key = data.get('weaviate').get('api_key')
|
52 |
-
cohere_api_key = data.get('cohere').get('api_key')
|
53 |
openai_api_key = data.get('openai').get('api_key')
|
54 |
-
serper_api_key = data.get('serper').get('api_key')
|
55 |
-
|
56 |
os.environ["OPENAI_API_KEY"] = openai_api_key
|
57 |
-
os.environ["SERPER_API_KEY"] = serper_api_key
|
58 |
-
SUBSCRIPTION = data.get('azure').get('subscription_id')
|
59 |
-
RESOURCE_GROUP = data.get('azure').get('resource_group_name')
|
60 |
-
WS_NAME = data.get('azure').get('workspace_name')
|
61 |
-
|
62 |
|
63 |
# In[18]:
|
64 |
|
|
|
18 |
import pandas as pd
|
19 |
import numpy as np
|
20 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
21 |
from datetime import datetime, timedelta
|
22 |
|
23 |
# perspective generation
|
|
|
39 |
data = yaml.safe_load(yaml_file)
|
40 |
|
41 |
# Access the API keys and other configuration data
|
|
|
|
|
|
|
42 |
openai_api_key = data.get('openai').get('api_key')
|
|
|
|
|
43 |
os.environ["OPENAI_API_KEY"] = openai_api_key
|
|
|
|
|
|
|
|
|
|
|
44 |
|
45 |
# In[18]:
|
46 |
|