Functional DemoAutomation System

AFIN — Autonomous Freight Intelligence Network

An autonomous freight brokerage that models the freight market as a probabilistic graph and runs loads end-to-end under a governing AI control layer.

AFIN Freight OS landing page headlined 'The command center for a modern freight brokerage,' with a live agent-council preview panel and capability chips for the load lifecycle.
AFIN Freight OS landing page

What it solves

Freight brokerage is a fragmented, manual business: demand arrives as unstructured noise across emails, load boards, spreadsheets, and phone calls, while matching, pricing, negotiation, dispatch, and settlement happen across disconnected tools and human judgment. Local optimization of individual deals leaves system-wide profit, reliability, and risk unmanaged. Fraud, compliance failures, and mid-transit disruptions are caught late, if at all.

Built for Freight brokerages and logistics operators seeking to automate load acquisition, carrier matching, pricing, and settlement.

Overview

AFIN models the freight economy as a continuously evolving, event-driven graph of loads, carriers, lanes, shippers, and shipments. A set of specialized engines handle load acquisition, market intelligence, carrier intelligence, pricing and margin optimization, negotiation, dispatch, tracking, risk and compliance, and financial settlement. A Master Control orchestration layer governs which engine acts and resolves conflicts under a fixed hierarchy of safety over financial accuracy over optimization over speed, with graduated autonomy from manual to fully autonomous. The system boots through a defined activation sequence, proves the flow with an end-to-end demo that carries a load from acquisition through settlement, and handles fraud-detection, disruption self-healing, and global risk-override scenarios. State is durable via SQLite, and external services sit behind adapter interfaces with offline mocks so the core runs fully offline on deterministic formulas.

What this demonstrates

It proves a multi-engine autonomous system with a real orchestration layer that sequences subsystems and resolves conflicts deterministically, plus a spec-driven boot sequence with a pre-activation health gate that routes to a safe mode on failure. The domain logic is implemented as pure deterministic formulas (pricing, matching, trust, financial) with an extensive test suite, and external integrations (carrier registry, load board, telematics, payment rail) live behind swappable adapter interfaces with money-moving operations double-gated. It also layers on multi-tenant SaaS workspaces, subscription billing, an optional real-LLM reasoning path, and notification delivery.

What makes it different

Most logistics systems manage freight as a workflow. AFIN treats it as a probabilistic market graph and brokers it autonomously — acquiring, pricing, negotiating, dispatching, and settling loads end to end.

  • Freight is a dynamic market graphA continuously evolving, weighted, probabilistic graph of supply, demand, and constraints — not a workflow system.
  • Everything is an entity, relationship, or eventThe system reality model reduces to things that exist, how they interact, and how they change.
  • Time is a first-class dimensionEvery object supports historical, current, and predicted future state.
  • Autonomy is graduated, not binaryOperates across manual, assisted, semi-autonomous, and full-autonomous modes.
  • Local optima are forbidden without global validationNo single engine's decision is final until validated against system-wide objectives.
  • Safety over optimizationThe orchestration layer enforces the conflict hierarchy SAFETY > FINANCIAL > OPTIMIZATION > SPEED.

Core engines · 18

  • Load Acquisition & Demand Ingestion

    Sources loads from the board and ingests demand into the market graph.

  • Market Intelligence & Prediction

    Multi-horizon price forecasting with seasonality, macro, and competitor modeling, arbitrage, and lane positioning.

  • Carrier Intelligence & Supply Graph

    Carrier-lane run history, capacity density, availability forecasts, reliability scoring, and empty-mile optimization.

  • Pricing & Margin Optimization

    Risk-adjusted, capacity, and time-decay pricing pipeline with closed-loop error calibration.

  • Profit Surface EngineProfit-optimal bidding

    Samples bid, probability-of-accept, and expected profit, then returns the expected-profit-optimal bid.

  • Lane Strategy Engine

    Chooses penetration, margin-maximization, or balancing posture per lane.

  • Negotiation & Communication AI

    Autonomous negotiation loop with strategy selection, sentiment inference, and deterministic message transcripts.

  • Route Optimization

    Optimized route plans with ETA and time-window feasibility checks.

  • Dispatch & Execution

    Route, time-window, and risk-gated carrier assignment, re-dispatch, and delivery confirmation.

  • Tracking & Exception ManagementSelf-healing re-dispatch

    Live shipment state, dynamic ETA, deviation detection, failure prediction, and a self-healing loop.

  • Risk, Compliance & Trust

    Multi-dimensional risk, compliance validation, trust decay, and the transaction safety gate.

  • Fraud Detection

    Detectors for double brokering, fake identity, stolen authority, ghost shipments, and rate manipulation.

  • Financial Settlement & Profit Intelligence

    True-cost reconciliation, realized-vs-predicted margin, anomaly detection, and system financial health.

  • Invoice Generation

    Shipper invoice, carrier payment statement, and broker-fee breakdown.

  • Payment Processing

    Carrier payment, shipper collection, escrow release, and cash-flow health.

  • Master Control OrchestrationGlobal risk override

    Governs conflict resolution, resource allocation, autonomy gating, and the global risk override.

  • Integration Gateway

    Adapter seam for load boards, carrier registry, ELD telematics, and payment rails behind clean interfaces.

  • Global State Memory Engine

    Durable system-of-record state, audit, and global-state snapshot behind one repository interface.

How the safety gate works

Transaction safety

  • Financial risk

    Payment-delay history and financial exposure of the counterparty.

  • Operational risk

    Execution reliability and delivery risk indicators.

  • Compliance risk

    Insurance, authority, HOS, and equipment validation status.

  • Fraud risk

    Aggregate signal across the five fraud schemes.

  • Behavioral risk

    Trust-graph anomalies and reputation shifts.

How it works

  1. Ingest a load from the load board
  2. Gate it through risk, compliance, and trust — safety first
  3. Forecast the market and position the lane
  4. Compute the profit-surface-optimal bid
  5. Negotiate the rate autonomously with the carrier
  6. Optimize the route and dispatch to the best carrier
  7. Track the shipment; detect and re-dispatch on exceptions
  8. Reconcile true cost and settle via invoice and payment
  9. Master Control governs conflicts and autonomy throughout

Data model

  • Load
  • Carrier
  • Lane
  • Shipper
  • Shipment
  • Financial
  • FraudAlert
  • Trust Graph

Screens · 8

AFIN marketing section titled 'A brokerage runs on too many calls, tabs, and judgment calls,' listing eight pain points like manual dispatch, carrier risk, and document chaos in two columns.
Brokerage pain-points section
AFIN 'Agent Council' marketing section with ten specialist AI-agent cards (Brokerage CEO, Load Intake, Pricing, Carrier Sourcing, Compliance, Dispatch, and more), each with a short role description.
The agent council — specialist AI agents
AFIN Command Center dashboard: KPI tiles (revenue $23,968, margin $1,261, 22 active loads), a revenue-and-margin line chart, a pipeline donut, top lanes, and a recent-settlements table.
Command Center dashboard
AFIN Carriers page listing a capacity network of 10 carriers in a table with MC/DOT numbers, equipment tags, home city, reliability bars, verification, and risk level.
Carriers — capacity network table
AFIN Financials page: margin and cost KPI tiles, a financial-forecast panel, a top-earning-carriers bar chart, and a settlements table with revenue, margin, and prediction accuracy.
Financials — settlements and forecast
AFIN 'Book a load' modal dialog with dropdowns for customer, lane (ATL→DAL, 780 mi), equipment, shipper offer, urgency, and execute-to, plus Cancel and Book load buttons.
Book a load dialog
AFIN System page for engine fleet and autonomy, showing the current Full Autonomous mode and four selectable operating-mode cards (Manual, Assisted, Supervised, Full Autonomous) with risk and approval settings.
System — autonomy operating modes
AFIN Market intelligence page listing 10 freight lanes in a table with average rate, supply/demand ratio, volatility bars, 7-day forecast, positioning tags, and realized margin.
Market — lane intelligence table

How it is built

The backend is a Python/FastAPI application whose lifespan boots the engine system to an active state; domain entities are Pydantic models and persistence is a repository interface backed by SQLite (or PostgreSQL via a DATABASE_URL). Engines are separate modules coordinated by a Master Control layer, with external services abstracted behind adapter interfaces that default to offline mocks. A lightweight static frontend provides marketing, sign-in/up, onboarding, and app pages, and the whole stack is containerized with Docker.

APIs and services

Anthropic
OpenAI
Stripe
Google Gemini
SendGrid
Twilio
FMCSA
DAT
Sentry

Classification

Industries
Logistics

Related work

Supplement Tracker

Functional Demo

Insurance supplement management for roofing contractors, with adjuster communication and AI.

AI Acquisition Hunter

In Development

An AI acquisition-intelligence platform that surfaces and scores off-market acquisition targets from public business signals.

Building something with similar AI Automation, Workflow Automation, Financial Modeling functionality?

Start a project and reference this one — the conversation begins with what you have already seen.

Start a project