Back to Projects
AI Engineering

FreightDesk

An AI-powered knowledge assistant that helps freight and logistics teams find answers from their company documents.

Role
Solo Developer
Year
2026
Type
RAG Document Assistant
The FreightDesk chat answering a question about carrier services
01

The problem.

At work, I noticed the same questions coming up again and again. Someone might ask a manager about a shipping procedure one week, only for another person to ask the same question the next. The answers often already exist somewhere in company documents, but finding them isn't always quick or easy. I wanted to build something that could make that knowledge easier to access without always having to rely on a colleague or manager for the answer.

SOPsFormsManualsTrainingFormsWhere can I findthis information?
02

The solution.

FreightDesk lets users ask questions in natural language and get accurate, source-based answers from company documents. It uses RAG (Retrieval Augmented Generation) to find relevant information and provides clear, structured responses with references.

An illustration of a FreightDesk answer: the question “What documents are required for a US shipment?”, a structured reply, and the source document it cites.

What documents are required for a US shipment?

For a US shipment, you typically need the following documents:

  • Commercial Invoice
  • Packing List
  • Bill of Lading (BOL)
  • Certificate of Origin (if applicable)

You can find more details in the Shipping Procedure Manual (Section 4.2).

Shipping Procedure Manual.pdf
Section 4.2 · Page 12
03

How it works.

Two simple processes working together.

01

Document Ingestion

Runs once per upload.
  1. Upload Documents

    Add PDFs and other documents through the app.

    e.g. PDF, DOCX, etc.
  2. Split into Chunks

    The document is broken into smaller, meaningful text chunks.

    e.g. Chunking strategy
  3. Create Embeddings

    Each chunk is converted into a vector using an embedding model.

    e.g. OpenAI embeddings
  4. Store & Index

    Store the chunks and their vectors in PostgreSQL with pgvector for fast similarity search.

    e.g. PostgreSQL + pgvector
02

Question & Answer

Runs on every question.
  1. User Question

    The user asks a question in natural language.

    e.g. “How do I…?”
  2. Search Knowledge

    The question is searched using both vector similarity and keyword search, then the results are fused together.

    e.g. Hybrid search · pgvector + PostgreSQL FTS
  3. Rerank Results

    The fused results are re-scored to find the most relevant chunks before they're sent to the AI.

    e.g. Cross-encoder reranking
  4. Build Context

    The best chunks are combined and sent to the AI as context.

    e.g. Relevant excerpts
  5. Generate Answer

    The AI answers from that context and cites its sources so every claim can be verified.

    e.g. Grounded answer + sources
04

The tech stack.

Tools and technologies I used to build FreightDesk.

Frontend

  • React
  • TypeScript
  • Vite
  • Tailwind CSS
  • shadcn/ui

Backend

  • Django
  • Django REST Framework
  • SimpleJWT
  • Celery

Database

  • PostgreSQL
  • pgvector

AI / LLM

  • OpenAI API
  • Embeddings
  • RAG

Deployment

  • Vercel
  • Neon
  • Cloudflare
05

Key features.

More than just a chatbot.

01 / 06

Chat Interface

Ask questions in plain English and get streamed answers grounded in company documents, with citations you can inspect.

06

What I learned.

FreightDesk taught me that building an AI application is about much more than connecting an LLM. I learned how retrieval quality, document processing, streaming, and the surrounding product all have to work together to produce answers users can actually trust.

  • Building a RAG pipeline: chunking, embeddings, and vector search with pgvector
  • Improving retrieval quality with hybrid search (vector + full-text) and cross-encoder reranking
  • Building streaming AI responses, tool calling, and grounded citations
  • Document visibility rules, authentication, and per-user usage controls
  • Deploying a multi-service full-stack application to production
07

What’s next?

FreightDesk works, but a few of its edges are deliberate v1 shortcuts. The next step is closing them. Moving expensive work into the background, making insight detection smarter, and widening the permission model past its current admin / member split.

  • Background task queueA task queue for ingestion and long agent runs, so large uploads and AI work stop holding the request open.
  • Smarter insight detectionEmbedding-based detection of repeated and poorly answered questions, rather than matching on the wording itself.
  • Richer role-based permissionsMore granular roles and per-document access control, beyond the current admin / member split.
Large documentsUpload & processFreightDeskSmarter insightsFind similar questionsusing embeddingsFlexible permissionsMore granular rolesand access controlAdminMemberBackground queueDocument processing& long agent runs