
stockpilot
Inventory management and supplier price comparison for small businesses.
StockPilot is an inventory tool for SMEs with a NestJS and Prisma REST API over PostgreSQL and a Next.js frontend. Search falls back from exact matching to trigram similarity in PostgreSQL and offers a "did you mean?" suggestion, with no separate search service. The CSV importer maps arbitrary column headers through aliases and fuzzy keyword matching and pulls weights out of columns, headers, values, or product names. Supplier offers are normalised to price per 100g, per 100ml, or per piece so that different pack sizes compare fairly.
technologies
- next.js
- nestjs
- prisma
- postgresql
- typescript
- swr
- zod
- recharts
key highlights
- Three-tier search: substring, pg_trgm similarity across name, SKU, brand and category, then suggestions
- Schema-agnostic CSV import tested against Shopify, WooCommerce, QuickBooks, POS and wholesale exports
- Weight extraction cascading from paired columns to header units, value units and product names
- Idempotent imports that upsert by SKU in batched transactions
- Supplier price normalisation with best/worst offer and savings per product
- Validation in three layers: Zod forms, API DTOs and database constraints
next project
prompt patrol