Goal

Branch logic and trigger routing logic if the seller signature is missing.

Input

Tensorlake structured parsing output.

Output

A printed message or a webhook to trigger a human review queue.
def route_to_manual_review():
    print("Routing document to human review queue...")

seller = data["outputs"]["structured_data"]["pages"][0]["data"].get("seller", {})
if not seller.get("seller_signed"):
    route_to_manual_review()