Back to selected work
Private product architecture

AI-Assisted Ecommerce & RAG Platform

Full-Stack & AI Commerce Engineer

March 2026 — Present

A private ecommerce product I built with Spree/Rails, a Next.js storefront, Elixir orchestration, pgvector retrieval, and AI assistance grounded in real catalog data.

Sanitized ecommerce storefront showing its promotional hero and featured collections
Owner-supplied private evidence prepared 2026-07-12
Redacted ecommerce administration dashboard showing navigation and financial-summary structure
Owner-supplied private evidence redacted 2026-07-12

01

Context

The project brings the commerce backend, storefront, administration, APIs, retrieval, and assistant into one working system. The deployment stays private, so this case study focuses on the decisions and sanitized product views.

02

Challenge

A useful shopping assistant cannot guess. It needs current product context, sensible model routing, fallbacks, and clear limits so inventory, pricing, and orders still come from the commerce backend.

03

My contribution

  • Built and maintained the Spree/Rails backend for products, variants, pricing, stock, orders, accounts, administration, and business rules.
  • Connected the Rails APIs, Next.js storefront, and Elixir assistant without blurring the responsibility of each service.
  • Implemented retrieval over product knowledge using PostgreSQL, embeddings, pgvector, and contextual response generation.
  • Integrated OpenAI, Claude, and Gemini through OpenRouter, choosing providers by compatibility, latency, cost, request type, and fallback needs.
  • Kept catalog, inventory, pricing, and orders under Rails rules while the assistant retrieves context and suggests only controlled actions.

Architecture

Spree and Rails own the commerce rules and data. Next.js delivers the shopping experience. Elixir coordinates retrieval and model calls, while PostgreSQL and pgvector provide structured product data and searchable context.

  1. 01

    Spree / Rails backend

    Catalog, variants, pricing, stock, orders, accounts, administration, and commerce rules.

  2. 02

    Next.js storefront

    Product discovery, comparison, and assistant presentation without blocking shopping flows.

  3. 03

    Elixir orchestration

    Context recovery, controlled tools, retrieval flow, model routing, fallbacks, and response coordination.

  4. 04

    PostgreSQL / pgvector

    Structured commerce data, embeddings, and grounded retrieval context.

  5. 05

    OpenRouter providers

    OpenAI, Claude, and Gemini selected by explicit routing policy.

05

Product outcome

  • The assistant can answer product questions, compare options, check inventory context, and recommend items using catalog-backed information.
  • Model routing and retrieval stay outside the storefront and core commerce rules, so providers can change without reshaping the whole product.
  • The sanitized storefront and admin previews show the product's scope without exposing private addresses, operator data, commercial values, or environments.

06

Technology

  • Spree Commerce
  • Ruby on Rails
  • Next.js
  • Elixir
  • PostgreSQL
  • pgvector
  • OpenRouter
  • RAG

Disclosure note

This is a private product. Live addresses, operator identity, dates, order counts, financial values, demo metrics, prompts, and internal implementation details are intentionally omitted or redacted.