CoolFace
Apppublic

Yuvalos/sweet-spec-recommender

sourceHugging Faceupdated 8mo agoView on Hugging Face
0likes
App README

🍬 SweetSpec — Semantic Sales Offer Recommender Overview

SweetSpec is an AI-powered semantic recommendation application designed to support Sales, Pricing, and FP&A teams by surfacing historically similar B2B sales offers based on free-text customer requests.

The application demonstrates a complete end-to-end data science workflow, starting from synthetic data generation and exploratory data analysis, through embedding model evaluation and similarity search, and ending with a deployed interactive user interface.

All data used in this project is fully synthetic and was created exclusively for educational and demonstration purposes.

Business Use Case

Commercial teams frequently receive unstructured customer inquiries such as:

“Distributor in EU looking for sugar-free vegan gummy vitamins, lemon flavor, MOQ 500kg.”

Responding accurately requires access to prior experience and institutional knowledge. In many organizations, similar past offers are fragmented across emails, spreadsheets, or internal systems, making reuse difficult.

SweetSpec addresses this challenge by allowing users to enter a free-text request and instantly retrieve the most semantically similar historical offers. These results serve as decision support for pricing, feasibility assessment, and negotiation preparation.

The system is intentionally designed to assist human decision-makers rather than replace them.

How the AI Engine Works

Each sales offer is represented by a combined textual description that includes both the buyer request and the seller response. These texts are converted into vector embeddings using the sentence-transformers/all-MiniLM-L6-v2 model.

When a user submits a new request, the request is embedded using the same model and compared to all existing offer embeddings using cosine similarity. The system then returns the Top-K most similar offers.

In order to improve usability, lightweight re-ranking bonuses may be applied when metadata such as region or product type explicitly matches the user’s intent. Numeric values like MOQ are treated as soft preferences rather than strict constraints, reflecting realistic commercial workflows.

Dataset

The application is powered by a dataset of 10,000 fully synthetic B2B sales offers. Each row represents a fictional offer and includes structured attributes such as region, customer type, product category, MOQ, lead time, packaging, and dietary tags, along with free-text buyer and seller descriptions.

The dataset was generated using a hybrid approach that combines a Hugging Face pretrained language model with structured templates to ensure both realism and scalability. The full dataset, generation code, and exploratory data analysis are published separately on Hugging Face Datasets.

Application Features

The SweetSpec application supports free-text semantic search with adjustable Top-K results. It includes one-click example queries to demonstrate typical usage scenarios and presents results in a clean, modern interface built with Gradio. Similarity scores are displayed to provide transparency and interpretability.

Interpretation of Results

Returned offers are ranked by semantic similarity rather than exact rule-based matching. As a result, offers with different numeric parameters such as MOQ may appear if they strongly match the overall intent of the request. This behavior is deliberate and mirrors real-world sales decision-making, where offers are adapted rather than copied exactly.

Privacy and Ethics

All data used in this application is synthetic. No real customers, products, prices, or proprietary business information are included. The project was explicitly designed to be safe for public release and inspection.

Technical Stack

The application is built using Hugging Face Datasets and Spaces, Sentence Transformers for text embeddings, cosine similarity for retrieval, FAISS-style indexing for efficient search, Gradio for the user interface, and Python libraries including pandas and numpy.

Educational Context

SweetSpec was developed as a final project for a Data Science and AI course. It demonstrates core concepts taught during the semester, including synthetic data generation, exploratory data analysis, embedding model selection, similarity-based recommendation pipelines, and deployment of a real AI application.

Disclaimer

This application and its underlying dataset are provided for educational and demonstration purposes only. All content is fictional and does not represent real companies, customers, products, or pricing.