Spaces:
Sleeping
Sleeping
jonathanjordan21
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -252,13 +252,15 @@ def build_outputs(results, descriptions, result_details, plate_number):
|
|
252 |
out += f"{i+1}. {detail}\nRumus: {desc}\nDetail perhitungan: {desc.replace('harga_jual', harga_jual)} = {res}\n"
|
253 |
|
254 |
# out += "----------------------------\nEstimasi biaya: "
|
255 |
-
out += "\n\n\nEstimasi Biaya:"
|
256 |
|
257 |
if len(results) > 1:
|
258 |
out += " + ".join([f"Rp{x}" for x in results])
|
259 |
out += f" = {sum(results)}"
|
260 |
else:
|
261 |
out += str(results[0])
|
|
|
|
|
262 |
# out += "\n----------------------------\n\n--------------------------------"
|
263 |
return out
|
264 |
|
@@ -377,7 +379,7 @@ def respond(
|
|
377 |
result_details.append(result_detail)
|
378 |
out += "\n\n" + build_output_formula(descriptions, result_details)
|
379 |
elif vehicle_tax_info.get(plate):
|
380 |
-
out += "\n\n" + build_output_vehicle(
|
381 |
else:
|
382 |
# + request_code[6:] + f"\nConfidence score: {round(scores[s_max].tolist(),3)}"
|
383 |
out += "Request code number: " + request_code[:3] + "\nRequest detail: " + "\nPlate numbers: " + plate_numbers
|
|
|
252 |
out += f"{i+1}. {detail}\nRumus: {desc}\nDetail perhitungan: {desc.replace('harga_jual', harga_jual)} = {res}\n"
|
253 |
|
254 |
# out += "----------------------------\nEstimasi biaya: "
|
255 |
+
out += "\n\n\nEstimasi Biaya: "
|
256 |
|
257 |
if len(results) > 1:
|
258 |
out += " + ".join([f"Rp{x}" for x in results])
|
259 |
out += f" = {sum(results)}"
|
260 |
else:
|
261 |
out += str(results[0])
|
262 |
+
|
263 |
+
out += "\n\n----------------------------"
|
264 |
# out += "\n----------------------------\n\n--------------------------------"
|
265 |
return out
|
266 |
|
|
|
379 |
result_details.append(result_detail)
|
380 |
out += "\n\n" + build_output_formula(descriptions, result_details)
|
381 |
elif vehicle_tax_info.get(plate):
|
382 |
+
out += "\n\n" + build_output_vehicle(plate)
|
383 |
else:
|
384 |
# + request_code[6:] + f"\nConfidence score: {round(scores[s_max].tolist(),3)}"
|
385 |
out += "Request code number: " + request_code[:3] + "\nRequest detail: " + "\nPlate numbers: " + plate_numbers
|