Update process_data.py
Browse files- process_data.py +9 -8
process_data.py
CHANGED
|
@@ -138,20 +138,21 @@ def generate_json_pieces(input_data, parameters):
|
|
| 138 |
print(specification)
|
| 139 |
print(model_version)
|
| 140 |
|
| 141 |
-
if parameters["pre_prompt"]
|
| 142 |
print("Pre prompt is true")
|
| 143 |
-
field_data_input = input_data["input_text_pieces"]["field_data_input"]
|
| 144 |
-
planting_data_input = input_data["input_text_pieces"]["planting_data_input"]
|
| 145 |
-
logs_data_input = input_data["input_text_pieces"]["logs_data_input"]
|
| 146 |
-
soil_data_input = input_data["input_text_pieces"]["soil_data_input"]
|
| 147 |
-
yield_data_input = input_data["input_text_pieces"]["yield_data_input"]
|
| 148 |
-
else:
|
| 149 |
-
print("Pre prompt is false")
|
| 150 |
field_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["field_data_input"]
|
| 151 |
planting_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["planting_data_input"]
|
| 152 |
logs_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["logs_data_input"]
|
| 153 |
soil_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["soil_data_input"]
|
| 154 |
yield_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["yield_data_input"]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 155 |
|
| 156 |
print("Setting prompts")
|
| 157 |
field_prompt = "Extract the field information."
|
|
|
|
| 138 |
print(specification)
|
| 139 |
print(model_version)
|
| 140 |
|
| 141 |
+
if parameters["pre_prompt"]:
|
| 142 |
print("Pre prompt is true")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 143 |
field_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["field_data_input"]
|
| 144 |
planting_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["planting_data_input"]
|
| 145 |
logs_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["logs_data_input"]
|
| 146 |
soil_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["soil_data_input"]
|
| 147 |
yield_data_input = input_data["input_text_pieces"]["pre_processed_pieces"]["yield_data_input"]
|
| 148 |
+
else:
|
| 149 |
+
print("Pre prompt is false")
|
| 150 |
+
field_data_input = input_data["input_text_pieces"]["field_data_input"]
|
| 151 |
+
planting_data_input = input_data["input_text_pieces"]["planting_data_input"]
|
| 152 |
+
logs_data_input = input_data["input_text_pieces"]["logs_data_input"]
|
| 153 |
+
soil_data_input = input_data["input_text_pieces"]["soil_data_input"]
|
| 154 |
+
yield_data_input = input_data["input_text_pieces"]["yield_data_input"]
|
| 155 |
+
|
| 156 |
|
| 157 |
print("Setting prompts")
|
| 158 |
field_prompt = "Extract the field information."
|