Spaces:
Runtime error
Runtime error
File size: 332 Bytes
5616713 5fe187e 5616713 5fe187e 5616713 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | def validate(data):
score = 100
calc_total = data["Taxable"] + data["CGST"] + data["SGST"] + data["IGST"]
if abs(calc_total - data["Total"]) > 2:
score -= 20
if not data["GSTIN"]:
score -= 15
if not data["Invoice No"]:
score -= 10
data["Confidence"] = f"{score}%"
return data
|