Skip to main content
Loading navigation

Logistics Cash Flow & Invoice Reconciliation Pipeline using LangChain on Modal

Supply chain vendors face severe cash flow bottlenecks due to manual invoice and proof-of-delivery reconciliation delays. Build a distributed LangChain pipeline deployed on Modal to process receipt documents and reconcile ledger discrepancies, achieving 90% automated invoice matching accuracy under 500ms serverless execution.

Business OperationsHosted by Vera

What you are building

Build a serverless invoice and proof-of-delivery reconciliation pipeline using LangChain agents containerized and executed on Modal.

How work is evaluated

Evaluation

Evaluates matching accuracy between supply chain invoice JSON inputs and purchase ledger baseline.

Datasets

Public datasets, plus the private datasets you have access to.

How submissions are scored

Dimensions
2 scoring checks
Binary
2 pass or fail dimensions
Ordinal
0 scaled dimensions
Dimension 1

strict_signature_check

Ensures missing POD signatures automatically flag DISCREPANCY status.

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Dimension 2

matching_accuracy

Accuracy of invoice reconciliation status. • target: 0.9 • range: 0-1

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Learning goals

  • Construct modular document extraction chains using LangChain

  • Deploy containerized LLM tasks on Modal for fast serverless execution

  • Automate reconciliation between purchase orders, delivery notes, and tax invoices

  • Calculate variance metrics and route mismatched records for manual review

Resources

Dataset notes

250 logistics purchase order and vendor invoice mock pairs.

Challenge setup

Evaluates matching accuracy between supply chain invoice JSON inputs and purchase ledger baseline.

Challenge input

JSON object with po_number, invoice_total, line_items array, and pod_signature_present bool.

LangChain

Provides LCEL abstractions for prompt and tool chaining.

Modal

Enables fast, scalable Python microservice execution.

Evaluated output

JSON object with status ('MATCHED', 'DISCREPANCY', 'REJECTED'), total_diff, and resolution_notes.

Evaluation checks
  • Ensures missing POD signatures automatically flag DISCREPANCY status.
  • Accuracy of invoice reconciliation status. • target: 0.9 • range: 0-1
Configured evaluation evidence
  • Benchmark: Document Extraction & Accounting Verification Benchmark
  • Matching Accuracy target: 0.9
  • 1 public reference case
Configured runtime
  • Python execution harness
  • Python sandbox (unavailable on Versalist)

Shows the first task, up to three tools, and up to three evidence items.

View technical recipe

Configured tools

Environment
  • Modal · Optional
Action Space
  • LangChain · Required
  • Langchain · Optional
Policy Serving
  • Modal · Optional
Orchestration
  • LangChain · Required
  • Langchain · Optional

Evaluation contract

  • strict_signature_check · Weight 1
  • matching_accuracy · Weight 1

Metrics

  • matching_accuracy · Target 0.9

Benchmarks

  • Document Extraction & Accounting Verification Benchmark
  • general

Reference cases

  • 1 public reference case

Workflow tasks

  1. Task 1

    Input: JSON object with po_number, invoice_total, line_items array, and pod_signature_present bool.

    Output: JSON object with status ('MATCHED', 'DISCREPANCY', 'REJECTED'), total_diff, and resolution_notes.

    Execution harness: Python

Evaluation tools

  • LangChain · Chain Architecture
  • Modal · Serverless Runtime

Recipe freeze marker

No recipe freeze time is recorded.

Frequently Asked Questions about Logistics Cash Flow & Invoice Reconciliation Pipeline using LangChain on Modal