Stacks/E-commerce analytics

LangGraph ecommerce analyst with daily reports (HN)

HN user prohobo runs a production LangGraph ecommerce analyst: daily BullMQ-queued reports, gpt-5-nano for trial users and gpt-5-mini for paying ones, a memory checkpointer, and RAG over a 30-day window of store data. Reliability advice is to keep graphs small and nodes atomic — a lesson learned after a four-job reporting node that could not be prompted into consistency.

prohoboAug 14, 2025Original writeup ↗
Use case
An AI ecommerce analyst with a report-builder mode and a chatbot: it consumes API data and visitor sessions, builds a large report, and compresses it into actionable insights for online store owners. The report runs once a day per customer.
Category
E-commerce analytics
Team size
not stated
Orchestrator / framework
LangGraph, chosen as the most robust option in the author's research about six months earlier, with a small graph, concise prompts, and atomic nodes and tools. Daily reports are queued with BullMQ. The author avoids parallel tool calling for most agents because it added instability. A reporting node that tried to do four jobs at once was split into four single-task nodes after weeks of prompt iteration at temperature 0 still failed inconsistently.
Memory
A memory checkpointer after every state change. Reports can be re-run at negligible cost; chats do not need persistent thread storage, with persistence instead managed through RAG entries. Vector DB for RAG, a normal DB for everything else — sometimes the same Postgres for both. A 30-day rolling window of raw store data, with distilled information kept as permanent context whose lifecycle the AI can create, update, and delete.
Evals
The author has not found a good prompt-eval tool yet. Sentiment analysis is run on chats the AI deems 'interesting,' using a thematic summary rather than original messages, to see if people are complaining.
Observability
Sentiment analysis on interesting chats. No dedicated tracing product is named. The author has not found a good eval tool for prompts.
Monthly cost
not stated
Observability tools
not stated
Other tools
Vector database (sometimes pgvector in Postgres)PII filtering on reportsRate limits and message-length limits on chats

Related

More like this