Agent 02 / 04

Sourcing Intelligence

Demand planning with product × month gap matrix, AI-powered sourcing recommendations with capacity scenarios and PDF export, LP cost optimization, supplier pipeline & capacity analytics, and forecast accuracy auditing.

Package @efi/sourcing
Port localhost:3002
Fetchers 10 Data API
Solver HiGHS (WASM)

Overview

The Sourcing Gap Agent aggregates demand from three channels (contracts, open orders, and sales rep forecasts), compares against sourced supply (purchase orders) and current inventory via the centralized Data API, and computes the gap — the unmet demand that needs to be sourced. A daily digest email automatically summarizes key sourcing actions and gap changes.

Three filter dimensions: Warehouse (BAL, OAK, TAC, HOU, SAV), Packaging (Bags, Totes, Bulk), and Customer. Filters narrow all data sources simultaneously — demand, supply, inventory, and gap calculations all reflect the selected filters.

How Data Flows Between Components

ContractsFirm demand
Open OrdersPending demand
ForecastsRep estimates
Purchase OrdersSourced supply
InventoryOn-hand stock
Demand Tiers Audit corrections applied: deltaRatio scales unsold, confidencePenalty reduces accuracy
💡

The forecast audit feeds into recommendations, not the gap matrix display. The gap matrix shows raw numbers. But when computing demand tiers for the rules engine and optimizer, audit corrections are applied: deltaRatio scales unsold demand and confidencePenalty reduces forecast accuracy. This means recommendations are based on corrected data, while the matrix shows the unadjusted picture for transparency.