Backend & Applied AI Engineer @ Drivetrain.ai

Shahbaz Hasan.
Raja

Backend engineer building LLM systems, MCP servers and the platforms they run on. At Drivetrain.ai I built Heimdall, an MCP server used by nearly half the company with 65K+ tool calls, the message classifier behind the customer-support bot, which scores 100% on a 172-conversation eval, and Kickstart, which turns one intake form into a ready customer workspace. Before that, I built backends at WeWork India, including an internal tool that replaced a licensed product and saved INR 1 Cr a year.

core stackPostgreSQLPythonOAuth 2.0JavaClaude APILLM Evals

leetcode0 solved

01 / TRACK_RECORD

Where I've shipped.

Backend and AI work across fintech SaaS, proptech and logistics, on systems 100K+ people use every day.

  1. Software Engineer - 2

    ·Oct 2025 – Present
    • Support Bot: LLM Classifier with Evals

      Built the message classifier of Drivetrain's customer-support bot across ~200 customer channels on Slack and Teams, plus an n8n pipeline that turns support@ emails into Linear tickets and syncs replies back to the thread. The bot has answered 130+ customer questions straight from the handbook since mid-May and files ~200+ tickets a month. Each message is classified first by TypeSafe's Jev model, and Claude Sonnet runs only on the uncertain ~9%, which cut Claude calls by ~90% and median triage latency from over 4s to ~0.33s. A production decision log feeds disagreements back into the eval, which scores 100% on 172 real, hand-labelled conversations, including a held-out split.

      PythonClaude APILLM EvalsPostgreSQLn8nSlack API
    • Heimdall: MCP Gateway for Company Data

      Built the MCP server that gives Claude access to Drivetrain's internal data: sales and customer calls, product usage, solver performance, connector health and support messages. Okta OAuth with Dynamic Client Registration, per-tool access control, tenant-scoped customer data, a Postgres audit log of every call, and region-aware routing for EU tenants. Adopted by nearly half the company, with 65K+ production tool calls since launch, doubling to ~20K a month within three months, at 67ms p50.

      MCPPythonFastAPIOAuth 2.0ClickHousePostgreSQL
    • Garage: Internal Tools Platform

      Built Garage, Drivetrain's internal tools platform: a Flask backend and a React app. On it, built Kickstart, which turns one customer-facing intake form into a ready customer workspace: database, encryption keys, data pipelines and SSO in the right US or EU region, plus Linear, Slack, Monday and HubSpot set up, replacing about 12 manual steps. Registration is all-or-nothing, and provisioning runs through a transactional outbox onto SQS, so each step is idempotent. ~20 real customer kickoffs in its first quarter. Also built North Star, a per-consultant board of support tickets that flags SLA risk, stalled and blocked work, failing data pipelines and open sales-call action items.

      PythonFlaskReactTypeScriptAWS SQSPostgreSQLJava
    • Platform & Backend: RBAC, Connector Sync, MCP OAuth

      Built multi-tenant platform features in Drivetrain's product, used by 500+ tenants and 4K+ users. RBAC audit logging tracks permission changes across 13 resource types, with filterable changelog APIs, CSV export and a read-only Security Auditor role. Connector sync scheduling adds multi-schedule APIs with server-side cron generation and row-level locking, gated per pricing tier. Cross-version metric cloning resolves dependencies and rewrites formulas to safely reuse 500K+ planning variables. Also built user memory for Drivetrain's AI assistant, so it remembers each user's saved preferences in every chat, and OAuth for the Drivetrain MCP server across SSO and non-SSO logins.

      JavaSpring BootPostgreSQLOAuth 2.0BigQuery
  2. WeWork India

    Bengaluru

    Software Development Engineer - 2 (Backend)

    ·Apr 2024 – Aug 2025
    • SpaceOps

      Built and shipped SpaceOps, an internal space-operations tool that replaced a licensed product, saving INR 1 Cr/year, used by 300 internal users across 70+ centres. Cut a critical API's response time from 4s to 800ms with concurrent execution, DB indexing and in-memory lookups.

      NestJSPostgresPerformance
    • Locations & F&B Modules

      Designed the Locations module on Google Maps, PostgreSQL, Redis and OpenSearch, with write-through caching, serving 70+ centres and 100K+ users. Built a community-café ordering system with SSO and Server-Sent Events for real-time order tracking, used by 3K people a day.

      NestJSRedisOpenSearchSSEGoogle Maps
    • Help & Support Module

      Built an LLM ticket classifier on the OpenAI API that reached 85% accuracy and cut triage time by 40%. Added a BullMQ webhook pipeline that ingests 10K+ Salesforce updates a month.

      OpenAIBullMQSalesforce
  3. LetsTransport

    Bengaluru

    Software Development Engineer - 1 (Backend)

    ·Jul 2022 – Apr 2024
    • Trip Lifecycle & API Migration

      Owned the trip APIs (start, end, cancel), the core workflow for driver-partner operations. Refactored and migrated 8 endpoints across microservices with the Template Method pattern, halving response time, and added middleware validation so P0 APIs only return tenant-scoped data.

      Node.jsTypeScriptDesign Patterns
    • Bidding, Rate Card & Margin Config

      Built partner bidding with per-lane controlled rollouts, a Rate Card module that digitised commercial contracts, and Margin Config, which lets leadership set target gross margins per client, lane and vehicle to reduce revenue leakage.

      Node.jsPostgres
    • Infrastructure & Data Pipelines

      Built a WhatsApp chatbot on Meta webhooks for order tracking. Moved Redis to Sentinel for high availability and secrets to GCP Secret Manager, split the FE and BE pipelines to cut builds from 30 to 5 minutes, and built Airflow DAGs warehousing 20+ MongoDB collections into PostgreSQL for BI.

      AirflowRedis SentinelGCPMeta Webhooks

02 / SHIPPED

Stuff I've built for fun.

Things I've built outside of work, mostly to learn something new or scratch an itch.

Self-hosted platform behind this site: portfolio and CMS, a life-tracking app, and an MCP server that lets Claude read and edit both.

  • ▸ MCP server (aleph) with typed tools so Claude can read and edit portfolio and Forge data
  • ▸ FastAPI LLM service with Groq and Gemini fallback chains and pydantic-typed tool inputs and outputs
  • ▸ Custom OAuth 2.0 authorization server built from the RFCs (DCR, PKCE S256, revocation, discovery), later retired for Clerk
NestJSTypeScriptPythonFastAPINext.jsPostgreSQLRedisBullMQ

Video-intelligence backend: map-reduce summarization, distributed Whisper transcription, HLS streaming.

  • ▸ Outbox Pattern for exactly-once Kafka publishing
  • ▸ Map-reduce summarization of long transcripts
  • ▸ Bloom Filters for transcript dedup
NestJSFastAPIKafkaPostgreSQLRedisOpenAIOpenSearchCelery

03 / SOURCE_CODE

What the work actually looks like.

Two slices from live repos: the matching-engine loop and the transactional outbox pattern.

Price-time priority with partial fills

java

Core of the exchange: walks incoming orders against the counter book, trades at the maker price, restores time priority for partially filled counters.

public MatchResult matchOrder(Order incoming) {
    if (incoming.getRemaining().compareTo(BigDecimal.ZERO) <= 0) {
        return MatchResult.empty(incoming);
    }

    // BUY matches against SELL book; SELL matches against BUY.
    OrderSide counterSide = incoming.getSide() == OrderSide.BUY
            ? OrderSide.SELL : OrderSide.BUY;

    List<Order> toUpdate = new ArrayList<>();
    List<Trade> trades = new ArrayList<>();
    toUpdate.add(incoming);

    while (incoming.getRemaining().compareTo(BigDecimal.ZERO) > 0) {
        Order counter = book.pollBest(counterSide);
        if (counter == null) break;

        // Price compatibility: bid >= ask for BUY, ask <= bid for SELL.
        if (!priceMatch(incoming, counter.getPrice())) {
            book.addFirst(counter);   // restore time priority
            break;
        }

        BigDecimal qty   = incoming.getRemaining().min(counter.getRemaining());
        BigDecimal price = counter.getPrice();  // maker wins

        incoming.setRemaining(incoming.getRemaining().subtract(qty));
        counter.setRemaining(counter.getRemaining().subtract(qty));
        incoming.setStatus(incoming.getRemaining().signum() == 0
                ? OrderStatus.FILLED : OrderStatus.PARTIAL);
        counter.setStatus(counter.getRemaining().signum() == 0
                ? OrderStatus.FILLED : OrderStatus.PARTIAL);

        trades.add(buildTrade(incoming, counter, qty, price));
        toUpdate.add(counter);

        // Partial counter stays at the front of its price level.
        if (counter.getStatus() == OrderStatus.PARTIAL) {
            book.addFirst(counter);
        }
    }

    return new MatchResult(incoming, toUpdate, trades);
}

src/main/java/.../engine/MatchingEngine.java

04 / LOADOUT

Tools of the trade.

What I reach for day to day: not everything, just what I've actually shipped with.

Languages

  • Java
  • Python
  • C++
  • TypeScript
  • JavaScript

Frameworks & Libraries

  • Spring Boot
  • JPA / Hibernate
  • NestJS
  • FastAPI
  • Flask
  • Node.js

GenAI & AI Tooling

  • Claude Agent SDK
  • MCP
  • Claude API
  • LLM Evals
  • LangChain / LangGraph
  • OpenAI API
  • Prompt Engineering
  • RAG

Databases & Search

  • PostgreSQL
  • MongoDB
  • Redis
  • OpenSearch
  • ClickHouse
  • Firebase

Infrastructure & Cloud

  • AWS
  • GCP
  • Apache Airflow
  • Docker

Messaging & Eventing

  • Kafka
  • BullMQ
  • AWS SQS
  • Server-Sent Events

Design & Architecture

  • System Design
  • Microservices
  • Event-driven Architecture
  • API Design
  • DB Schema Design
  • OAuth 2.0 / OIDC
  • OOP

05 / CREDENTIALS

Where I studied.

Jul 2018 – Jun 2022 · Bhubaneswar, India

Kalinga Institute of Industrial Technology.

Bachelor of Technology·Electronics & Computer Science·GPA 9.15 / 10

  • Ranked #1 in university on GeeksforGeeks

06 / FLAGS

Some things I'm proud of.

  • WeWork India

    Moonshot Award: WeWork Annual Awards

    Recognized for technical innovation in SpaceOps development.

  • WeWork India

    Most Innovative Engineer

    Named Most Innovative Engineer by the Head of Engineering at WeWork India.

  • LeetCode

    LeetCode Knight: 2000+ Rating

    Top 2% globally on LeetCode. 114 contests, ranked top 2.53% of 869K+ participants.

  • GeeksforGeeks

    #1 in University on GeeksforGeeks

    Ranked first at Kalinga Institute of Industrial Technology on GFG problem-solving.