MF.
ESEN
Back to the portfolio

Case study / Applied AI · Operational assistance

MAX Assistant

Business knowledge turned into operational support.

A web/PWA assistant for couriers that separates conversations, knowledge retrieval, decisions, generation and operational tools.

Technologies used
Angular PWA · NestJS · TypeScript · PostgreSQL · Prisma · pgvector · OpenAI · TypeSafe / Jev · Chatwoot · Docker

The problem

Couriers need procedures and operational context without repeatedly interrupting supervisors. A useful assistant must use approved knowledge, respect permissions and escalate when available information is insufficient.

My contribution

I build an Angular PWA and an independent NestJS backend. I design Knowledge, Conversation Core, hybrid retrieval and isolated decision/generation contracts alongside authentication, cost controls and MVP operational integration.

What the product enables

Conversations with identity and continuity

Assistant-owned sessions over courier authentication and private conversations. Messages have ordering and idempotent identity; users retain context when support passes to a human operator through Chatwoot.

Approved, retrievable knowledge

Knowledge organizes procedures, conditions, prohibitions and escalation criteria. Versioned articles are chunked and indexed with embeddings; retrieval combines lexical and vector signals in PostgreSQL/pgvector.

Support with operational boundaries

The orchestrator combines classification, retrieval and generation within bounded context. MVP tools query authorized shipment data; they do not modify operations. Insufficient context and human escalation have explicit routes.

How the pieces fit together

The PWA communicates with its own API, separate from AMXpress Core. Conversation Core preserves conversations and messages; Knowledge owns official content. DecisionProvider classifies the route, the Retriever gathers evidence and GenerationProvider writes from that context. The orchestrator controls read-only tools and handoff through adapters. Chatwoot is isolated with its own database and Redis in Docker.

MVP component relationships
  1. Angular PWA
    JWT · idempotent messages
    Conversation Core
  2. Orchestrator → DecisionProvider
    Classification · no permissions or actions
    Validated route
  3. Knowledge / pgvector
    Approved evidence · bounded context
    Retriever → GenerationProvider
  4. Orchestrator
    Authorized reads / human escalation
    Tools / Chatwoot

Engineering decisions

Separate retrieval, decision and generation

An operational query should not be handled by an unrestricted model call. A structured decision selects a route, retrieval supplies evidence and generation writes from it. The orchestrator validates contracts and results at every stage; classification does not grant permissions or execute tools by itself.

Version knowledge and preserve restrictions

Knowledge separates drafting, approval and indexing. Hybrid search merges lexical and vector rankings with RRF and retains versions and references. Fragments preserve conditions, prohibitions and escalation; evidence is revalidated before a response is published.

Keep authority and continuity in the backend

Conversation Core retains ownership, sequence and message identity; runs record stages and consumption. The backend enforces permissions, limits and timeouts, restricting MVP tools to authorized read-only queries. Insufficient evidence and human escalation have explicit paths: neither the model nor the support channel replaces system authority.

Challenges addressed

Conversation concurrency

Conversation Core controls owner-scoped creation, sequencing and races between closure and messages. A repeated key only recovers the same message for the same owner; different content produces a conflict.

Evaluate before promising autonomy

Decision and generation are evaluated separately with explicit contracts, datasets and boundaries. Valid references do not prove semantic correctness. The product reserves human support for queries it cannot resolve with sufficient evidence.

Demonstrable capabilities

AI integrated into an operational system

Conversations, Knowledge versions and provider metadata trace the evidence used at each stage.

Visible boundaries and human control

Operational queries are read-only. Insufficient evidence leads to abstention or escalation; accuracy, savings and autonomy require evaluation of the final product.