Line Item Extraction

Extract detailed line item data from invoices with our advanced AI technology (Pro feature)

Item Details
Descriptions & codes
Quantities
Units & amounts
Pricing
Unit & total prices
Tax Details
Line-level taxes

Line Item Data Fields

Basic Line Item Fields
  • description:Product or service name
  • quantity:Number of units
  • unitPrice:Price per unit (in cents)
  • amount:Total line amount (in cents)
  • taxAmount:Tax for this line (in cents)
Technical Details
  • All monetary values stored in cents for precision
  • Position field maintains line item order
  • Links to parent extracted data record
  • Handles complex table structures
  • Validates quantity × unit price = amount

Line Item Extraction by Plan

Free Plan

AI Consensus (3 Models)

Basic Fields Only
  • No line item extraction
  • Header fields only
  • Total amounts without breakdown
Pro Plan

AI Agents (5 Models)

Full Extraction
  • Complete line item extraction
  • Table detection & parsing
  • Mathematical validation
  • Multi-page table support
Developer Plan

AI Agents + API Access

Pro + API
  • All Pro features
  • API access to line items
  • Programmatic data access
  • Webhook notifications

AI Technology for Line Item Extraction

1

Table Detection

AWS Textract + GPT-4o

AI identifies and locates table structures within the invoice, even across multiple pages

2

Column Recognition

GPT-4o structured outputs

Analyzes table headers and structure to understand what each column contains

3

Data Extraction

AI Agent orchestration

Extracts each row with proper field mapping: description, quantity, prices, totals

4

Validation & Correction

Multi-agent validation

Validates mathematical consistency (quantity × unit price = amount) and corrects errors

Line Item Data Structure

Database Schema

How line items are stored in our system

// Line Items Table Schema
{
  id: serial().primaryKey(),
  extractedDataId: integer().references(extractedData.id),
  description: text(),          // "Web Development Services"
  quantity: integer(),          // 40 (hours)
  unitPrice: integer(),         // 7500 (cents = $75.00)
  amount: integer(),            // 300000 (cents = $3000.00)
  taxAmount: integer(),         // 30000 (cents = $300.00)
  position: integer()           // 1, 2, 3... (order)
}

// Example extracted line item:
{
  "description": "Web Development Services",
  "quantity": 40,
  "unitPrice": 7500,     // $75.00 in cents
  "amount": 300000,      // $3000.00 in cents
  "taxAmount": 30000,    // $300.00 in cents
  "position": 1
}

Common Line Item Challenges

Challenging Cases
  • Complex multi-page tables
  • Merged cells and spanning rows
  • Mixed currencies in same table
  • Poor scan quality affecting table structure
  • Non-standard table layouts
Our Solutions
  • Advanced table detection algorithms
  • Context-aware field mapping
  • Mathematical validation rules
  • Multi-model consensus approach
  • Continuous learning from corrections

Accessing Line Item Data

Dashboard View
  • Detailed line item table
  • Editable fields for corrections
  • Mathematical validation indicators
Export Formats
  • CSV with line item details
  • Excel with separate line sheet
  • Google Sheets integration
API Access
  • REST API endpoints
  • JSON formatted responses
  • Developer plan required

Ready for Detailed Line Item Extraction?

Upgrade to Pro or Developer plan to unlock comprehensive line item extraction with our advanced AI agents.

Related Articles

Sortpay - Zero Manual Data Entry