Update process_data.py
Browse files- process_data.py +2 -1
process_data.py
CHANGED
|
@@ -14,7 +14,7 @@ from schema_classes import FarmActivities, Interactions, Trial, FarmActivitiesLi
|
|
| 14 |
os.environ["OPENAI_API_KEY"] = os.getenv("OPENAI_API_KEY")
|
| 15 |
client = OpenAI()
|
| 16 |
|
| 17 |
-
|
| 18 |
def generate_json(input_data, model_version):
|
| 19 |
"""
|
| 20 |
Function to prompt OpenAI API to generate structured JSON output.
|
|
@@ -187,6 +187,7 @@ def generate_json_pieces(specification, model_version, additional_json_creation_
|
|
| 187 |
# return output1, output2, output3
|
| 188 |
|
| 189 |
def process_specifications(input_data, parameters):
|
|
|
|
| 190 |
return generate_json(input_data, parameters["model_version"])
|
| 191 |
|
| 192 |
|
|
|
|
| 14 |
os.environ["OPENAI_API_KEY"] = os.getenv("OPENAI_API_KEY")
|
| 15 |
client = OpenAI()
|
| 16 |
|
| 17 |
+
|
| 18 |
def generate_json(input_data, model_version):
|
| 19 |
"""
|
| 20 |
Function to prompt OpenAI API to generate structured JSON output.
|
|
|
|
| 187 |
# return output1, output2, output3
|
| 188 |
|
| 189 |
def process_specifications(input_data, parameters):
|
| 190 |
+
# here is where parsing and other things will happen before
|
| 191 |
return generate_json(input_data, parameters["model_version"])
|
| 192 |
|
| 193 |
|