Ali Wahaj
Open to backend and AI roles

AliWahaj

Backend engineer who makes slow systems fast and expensive ones cheap.

I build Python services on AWS Lambda, SQLAlchemy, Redis and SQS at LinkedMatrix, for a serverless U.S. laundry-care platform. Before that I tuned SQL Server and healthcare EDI workflows at CureMD. On my own time I build retrieval-augmented AI systems.

The kind of stack I run live simulation

Average response
… ms
Served from cache
…
Database queries in flight
…
Cache hit Database read Queued to SQS Turn the cache off to watch the database take the load.

Production wins

Same features, same data. The fixes were query shape, caching, and moving heavy work off the request path.

High-volume API endpointsLinkedMatrix · SQLAlchemy N+1 removal
Bulk data retrievalCureMD · 11x project query paths
EDI stored proceduresCureMD · duplicate handling removed
100K+

monthly Mapbox calls brought to near zero by storing reusable distance records.

−50%

proxy messaging cost, from number validation and stopping repeat texts to unresponsive numbers.

−30%

tax-processing cost after migrating from TaxJar to TaxCloud.

~8 h

of manual data checking saved each week with verification utilities at CureMD.

Things I've built

Two recent projects I can walk through end to end, from data loading to the last cache key. Both are open source.

Django API · 2026

Fuel Route Optimizer

Give it any two places in the U.S. and it plans where a truck with a 500-mile range should refuel, how many gallons to buy at each stop, and what the trip will cost.

Stops come from a dynamic program over station and fuel level, so the plan is cost-optimal rather than "fill up at the cheapest pump nearby".

  • One routing-provider call per new route and zero on a cache hit. Start and finish are geocoded locally from Census data.
  • Stations are matched to the route with a KD-tree over 3D unit vectors, so distances stay correct coast to coast.
  • 6,620 of 6,626 stations in the price feed geocoded; the loader reports the other 6.
  • Plans cached 24 hours in Redis, keyed by data version, so a new price file never serves a stale plan.
  • Tests replay saved provider responses and never hit the live API.
Python 3.12DjangoRedisOpenRouteServiceKD-tree searchLeaflet
View the code
POST /api/route/
# real response, trimmed
{ "start": "Dallas, TX", "finish": "Houston, TX" }

{
  "route_miles": 238.7,
  "fuel_stops": [{
    "name": "One9 #1248",
    "city": "Wilmer", "state": "TX",
    "route_point": { "mile_marker": 16.0 },
    "price": 2.756, "gallons": 23.89,
    "cost": 65.84
  }],
  "total_fuel_cost": 65.84,
  "meta": { "external_api_calls": 1, "elapsed_ms": 186.6 }
}

Measured response times, first call vs cached

Chicago to Los Angeles2,027 miles
1,410 ms
1.2 ms
New York to Miami1,289 miles
416 ms
1.1 ms
Dallas to Houston239 miles
187 ms
1.4 ms
RAG backend · in progress

Football Intelligence Platform

A research assistant for football analysts that answers tactical questions from real documents, like the 2025 UEFA Champions League technical report, and shows the passages behind every answer.

The RAG core works today. I treat it as the foundation for a longer build: measured retrieval first, then reranking, guardrails, memory, production hardening, an MCP interface and agents.

  • Three chunking strategies (fixed, paragraph, sentence-semantic) compared on the same queries.
  • Answers return their source passages, ranks and similarity scores; prompts are written to refuse unsupported claims.
  • Token usage and estimated model cost tracked on every request.
PythonFastAPIChromaDBOpenAI APIPydantic
View the code
  1. 1
    Load sourcesPDFs, text files and a built-in team-profiles dataset
  2. 2
    Chunk800-character chunks with 100 characters of overlap for the UEFA report
  3. 3
    Embed and storePersistent ChromaDB collections on disk
  4. 4
    RetrieveTop passages for the question, with similarity scores
  5. 5
    Answer with sourcesThe model answers only from those passages and cites them

Roadmap

  • RAG MVP
  • Evaluation baseline
  • Hybrid retrieval and reranking
  • Guardrails
  • Memory
  • Ingestion platform
  • Production engineering
  • Security
  • MCP interface
  • Agentic versions

Experience

Two years shipping backend work for U.S. operations and enterprise healthcare.

Apr 2025 – now

Backend Software Engineer

LinkedMatrix · Pakistan

Serverless platform for a U.S. laundry-care business: orders, pickup and delivery, worker operations, pricing, client accounts and masked customer-worker calls and texts.

  • Cut response time on high-volume endpoints by 70%, from 20 s to 6 s, by removing SQLAlchemy N+1 queries.
  • Brought 100K+ monthly Mapbox calls to near zero with reusable distance records that expire after 3 months.
  • Halved proxy messaging costs with phone-number validation and a stop on repeat messages to unresponsive numbers.
  • Added Redis caching to frequently read data, speeding up selected workflows by about 50%.
  • Moved heavy reports and worker image changes onto AWS SQS so they stop blocking the API and retry reliably.
  • Migrated tax calculation from TaxJar to TaxCloud for about 30% lower cost with the same compliance workflow.
  • Ran the AWS RDS MySQL 8.0 to 8.4 upgrade and the Keycloak 20 to 25 upgrade, with snapshots, validation and rollback plans.
  • Built Twilio Proxy phone masking for secure customer-worker SMS and calls.

Jul 2024 – Mar 2025

Associate Software Engineer

CureMD · Pakistan

Healthcare EDI modules for eligibility, ERA and claims processing in an enterprise practice-management product.

  • Rewrote stored procedures to drop duplicate data handling: 8 s to under 1 s.
  • Reduced large-volume retrieval on the 11x project from 17 s to under 3.5 s.
  • Built data-verification utilities that saved about 8 hours of manual checking a week.
  • Built reusable Angular components and cleaned up TypeScript business logic to reduce UI lag.

May – Jun 2023

Machine Learning Intern

TechnoColab · Remote

  • Cleaned and explored retail sales data, engineered features and compared several models to pick the best predictor.

Toolbox

What I reach for, grouped by the layer of the stack it lives in.

Backend

  • Python
  • FastAPI
  • Django
  • AWS Lambda
  • Serverless Framework
  • SQLAlchemy
  • .NET

Cloud and DevOps

  • AWS SQS
  • AWS RDS
  • Terraform
  • Docker
  • Kubernetes
  • GitHub Actions

Data and caching

  • MySQL
  • SQL Server
  • MongoDB
  • Redis

AI and retrieval

  • RAG
  • LangChain
  • ChromaDB
  • Vector search
  • Pyserini

Languages

  • Python
  • TypeScript
  • JavaScript
  • SQL
  • C++
  • YAML

Frontend

  • React
  • Angular
  • Tailwind
BS Computer Science, FAST-NUCES Islamabad2020 – 2024 · Software engineering concentration · CGPA 3.35 / 4
Machine Learning SpecializationDeepLearning.AI · December 2024
Azure Fundamentals (AZ-900)Microsoft · December 2023

Let's make it fast.

I'm looking for Python backend and AI engineering roles, remote or in Lahore and Islamabad. Email reaches me fastest.