Back to Projects
AI Systems Foundation · Backend & Database

PriceFlow-Agent — Dynamic Pricing Foundation

Backend architecture and relational database foundation for automated product price monitoring, historical trend analysis, and price drop notifications.

PythonFastAPISupabase PostgreSQLRedisDocker ComposePytestSQLAlchemy
View on GitHub

01 / Overview

Backend architecture and relational database foundation for automated product price monitoring, historical trend analysis, and price drop notifications.

02 / The Problem

E-commerce price volatility makes it challenging for consumers and purchasing agents to identify genuine discounts versus artificial markups before sales events.

03 / My Solution & Architecture

Built with Python and FastAPI, backed by Supabase PostgreSQL. Features modular scrapers, structured data models for historical price snapshots, and alert trigger rules based on statistical price moving averages.

Key Engineering Decisions & Trade-Offs

Normalized Relational Schema for Time-Series Price Points

Separating product metadata from chronological price logs allows efficient SQL indexing on timestamp and product_id for fast moving-average calculations.

Moving-Average Thresholds over Raw Dollar Drops

Raw price drops can be misleading due to baseline inflation. Comparing against a 30-day statistical moving average prevents deceptive markdown notifications.

Docker Compose Local Infrastructure

Bundling FastAPI, PostgreSQL, and Redis in a reproducible Compose environment simplifies onboarding and local testing.

04 / Technologies Used

PythonFastAPISupabase PostgreSQLRedisDocker ComposePytestSQLAlchemy

Every technology in this stack was chosen for direct architectural fitness, verifiable benchmarking ability, and clean maintainability in a production or research setting.

05 / How It Works & Interactive Visualizer

Here is a breakdown of how the system functions in practice:

  • FastAPI REST endpoints for product registration and price observation.
  • Supabase PostgreSQL relational schema with indexed historical price logs.
  • Docker Compose orchestration for multi-container local execution.
  • Pytest test suite validating data normalization and database transactions.
  • Statistical threshold alert evaluation algorithm.

Interactive Technical Visualizer

How to interact: Use the controls above to trigger live states, test inputs, and observe system data flow directly in your browser.

06 / Results & Verified Findings

  • Clean, maintainable backend foundation with 100% passing test coverage on core price calculation logic.
  • Accurate historical tracking preventing deceptive discount traps.
  • Strict schema validation preventing corrupted data ingestion.

07 / What I Learned & Direct Contributions

Key engineering responsibilities and lessons gained during this project:

  • Designed PostgreSQL schema on Supabase for products, historical price logs, and user alerts.
  • Built REST API endpoints for product registration, tracking status, and price history retrieval.
  • Created automated integration test suite with Pytest validating price parsing and database writes.
  • Documented modular architecture enabling plug-and-play scraping adapters.

08 / Future Improvements

Currently focused on core API and database architecture; autonomous LLM price trend summarization and automated email webhooks are in active development.

Email copied to clipboard