Inspiration

Small business owners make dozens of inventory decisions every week. They must track product quantities, identify shortages, estimate demand, contact suppliers, calculate purchase costs, and decide what to reorder without exceeding their available cash.

For many small businesses, this process involves spreadsheets, manual calculations, and repetitive administrative work.

I wanted to build something that could turn those disconnected tasks into one simple workflow.

That idea became StockSense AI — Smart Inventory & Purchasing, a business operations assistant designed to help owners make faster, clearer, and more informed purchasing decisions.

What it does

StockSense AI is a browser-based inventory and purchasing management application that combines real database operations with explainable restocking logic.

Its main capabilities include:

  • Inventory Dashboard: Displays product quantities, inventory value, low-stock alerts, and stock-health indicators.
  • Smart Restock Decision Lab: Analyzes recent sales, available budgets, supplier lead times, and shelf-life assumptions to recommend purchasing quantities.
  • Budget-Aware Purchasing: Helps owners prioritize products under spending limits such as $50 or $150.
  • Supplier Delay Simulation: Lets owners explore how additional delivery delays affect inventory risks.
  • Inventory Management: Provides product search, supplier information, stock levels, and catalog management.
  • Purchase Order Management: Creates persistent SQLite purchase-order drafts, supports custom purchasing decisions, and requires explicit human approval.
  • Duplicate Order Protection: Helps identify overlapping purchasing requests before creating unnecessary orders.
  • Operations Brief: Brings purchasing priorities and inventory alerts together into a single actionable view.

The application also includes an Alexa+-inspired conversational interface and an OpenAI tool-calling agent architecture. Live AI conversation requires API configuration; the inventory and purchasing operations can function independently.

StockSense AI uses simulated sample business data. Supplier lead times and shelf lives are planning assumptions rather than live supplier information. Approving an order updates its local database status and does not send a real purchase or process payment.

How I built it

I developed StockSense AI using Python, Streamlit, and SQLite, focusing on making the application practical, understandable, and reproducible.

Streamlit powers the web interface, including the Dashboard, Inventory, AI Assistant, and Purchase Orders sections.

SQLite stores inventory records, product costs, supplier information, purchase-order drafts, and approval history.

The Smart Restock Decision Engine uses recent sales information to estimate days of stock coverage, compare that coverage with supplier delivery times, and recommend purchasing quantities within a specified budget. It also applies simulated shelf-life limits to perishable products.

The backend separates business calculations from the user interface. An adapter exposes reusable operations to both Streamlit and the AI agent, while the database enforces purchase-order constraints.

For the Alexa+ track, the project follows the permitted simulated-experience approach rather than claiming a connection to a physical Alexa device or a production Alexa+ service.

Challenges I ran into

One of my biggest challenges was integrating several separate systems into one working application.

I encountered Python virtual-environment issues, incompatible compiled dependencies, Streamlit rendering problems, and difficulties maintaining consistent interfaces between the frontend and backend.

Designing a safe purchasing workflow was another challenge. I needed to ensure that the application respected budgets, persisted orders correctly, and never approved or transmitted purchases without human authorization.

I also learned that building a working algorithm is only part of creating useful software. Making results understandable and giving owners control over recommendations are equally important.

Accomplishments that I'm proud of

I'm particularly proud of building a functional end-to-end purchasing workflow:

Inventory analysis → Restocking recommendation → Budget validation → Saved purchase-order draft → Human approval.

The system operates on real SQLite records rather than displaying hardcoded answers.

I also implemented supplier-delay scenarios, understandable risk explanations, and persistent purchasing history.

Another accomplishment was progressing from a basic Streamlit prototype to a more cohesive business management interface.

What I learned

This project taught me how to connect frontend development, databases, business rules, and AI-oriented software architecture.

I learned how important it is to validate financial calculations, prevent accidental database actions, keep API credentials secure, and separate simulated assumptions from verified business information.

Most importantly, I learned that useful automation should not remove human judgment. It should help people make better decisions with less repetitive effort.

What's next for StockSense AI

The next steps are completing and validating live conversational AI integration, improving demand forecasting using historical data, integrating real supplier information, supporting order receipt and inventory updates, and providing more detailed purchasing analytics.

The long-term vision is to make intelligent inventory operations accessible to small businesses without requiring complicated enterprise software.

StockSense AI aims to turn inventory uncertainty into clear, actionable purchasing decisions.

Built With

Share this project:

Updates

Submission history