A production-focused inventory intelligence and sales search platform for Genesis of Manchester.
Genesis Inventory Intelligence is a private-purpose dealership sales tool that turns public Genesis of Manchester and shared pre-owned inventory into a fast, searchable working inventory for salespeople.
The project combines two independent layers:
- Validated inventory collection using Playwright to discover public vehicle detail pages, normalize vehicle data, enforce quality gates, and preserve the last known-good dataset when a scrape is incomplete.
- Inventory search application using Next.js with natural-language search, voice search, inventory-aware voice normalization, conventional filters, model grouping, live inventory health, and direct vehicle-detail access.
The production application is available at genesis-manchester.vercel.app.
- Natural-language inventory search designed around dealership phrasing
- Voice search with automotive and Genesis-specific transcript normalization
- Inventory-aware correction for model names and common speech-recognition errors
- VIN and stock-number lookup
- New, pre-owned, and certified inventory filtering
- In-stock and in-transit filtering
- Model year, body style, drivetrain, EV, color, price, and mileage constraints
- Engine-displacement searches such as
GV70 2.5,GV70 2.5L, andGV70 2.5T - Exterior-color intent separated from interior-color intent
- AWD/FWD/RWD/4WD normalization across multiple source formats
- New inventory grouped by model with newest model years first
- Direct links to the source vehicle detail page
- Copy VIN / stock actions for fast salesperson workflows
- Inventory-health status based on the last successful validated refresh
- Fail-closed data collection so bad scrapes never replace production inventory
The parser is intentionally built around the way a salesperson is likely to ask for inventory:
Show me new black GV80s in stock under $80k
Find in-transit GV70 AWD models
Used AWD SUVs under 30k miles
Show me certified Genesis vehicles
GV70 2.5L
Lexus
black interior GV80
An unqualified natural-language search searches across all stock types. Explicit terms such as new, used, or certified set the corresponding stock-type filter.
Supported browsers use the Web Speech API for transcription. Before a voice transcript reaches the search engine, the application normalizes dealership-specific language and common recognition errors.
Examples include:
gavi eighty -> GV80
gee vee seventy -> GV70
all wheel drive -> AWD
rear wheel drive -> RWD
30 thousand miles -> 30k miles
certified pre owned -> certified
The application can display both what it heard and what it is searching, making voice interpretation visible instead of silently changing the request.
| Inventory | Public source |
|---|---|
| New Genesis | https://www.genesisofmanchester.com/new-inventory/index.htm |
| Shared pre-owned | https://www.autofairhyundai.com/used-inventory/index.htm |
| Genesis Certified | https://www.genesisofmanchester.com/certified-inventory/index.htm |
The collector reads the AutoFair Hyundai source directly for the shared pre-owned pool because the Genesis shared-inventory proxy does not consistently expose the complete paginated inventory.
Public inventory pages
|
v
VDP discovery and pagination
|
v
Concurrent Playwright collection
|
v
Normalization and deduplication
|
v
Validation quality gates
|
+---- failure ----> keep previous validated dataset
|
success
|
v
inventory.json / inventory.csv / changes.json / history.json
|
v
Git commit -> runtime inventory fetch -> production search app
| File | Purpose |
|---|---|
data/inventory.json |
Current normalized inventory consumed by the application |
data/inventory.csv |
Spreadsheet-friendly representation of current inventory |
data/changes.json |
Vehicles added, removed, and price changes since the previous successful run |
data/history.json |
Observation history used for scraper continuity |
history.json records observation history only. It is not presented as dealer-reported days in stock.
The scraper fails closed. A bad or incomplete collection never replaces the last successful production dataset.
Validation protects against:
- unexpected total, new, or pre-owned inventory drops
- incomplete discovered-VDP coverage
- missing VINs
- weak critical-field completeness
- invalid stock numbers, years, makes, or models
- incorrect Genesis model normalization
- suspicious availability gaps
- malformed location data
- invalid or generic vehicle images
- obviously incorrect ICE powertrain fields on electric Genesis models
VIN is the preferred vehicle identifier, followed by stock number and then source VDP URL.
For active shared-used and certified listing sources, listing membership can serve as an in-stock fallback when the individual VDP omits an explicit availability value. New Genesis vehicles do not receive that fallback because new inventory can legitimately include in-transit units.
The Next.js application reads the latest validated data/inventory.json from GitHub at request time. If the live fetch is temporarily unavailable, it falls back to the validated inventory bundled with the deployed build.
The default view opens to New inventory, grouped by model and sorted with the newest model year first. Natural-language searches synchronize relevant visible filters so the parser and dropdown state do not contradict one another.
For new inventory, MSRP is the primary price when available. If Dealer.com exposes a different website price, it is shown separately rather than being silently treated as MSRP.
The interface also includes a customer-facing reminder:
Always verify before proceeding forward with your customer
GitHub Actions handles collection, validation, and application verification.
| Workflow | Responsibility |
|---|---|
.github/workflows/inventory-sync.yml |
Scheduled inventory collection and validated data commits |
.github/workflows/scraper-ci.yml |
Scraper syntax and unit tests |
.github/workflows/app-ci.yml |
Search tests, production Next.js build, and Playwright smoke testing |
.github/workflows/inventory-freshness-watch.yml |
Repository freshness recovery plus production-delivery verification |
Vercel deploys application code changes from main. Inventory-only commits no longer depend on a Vercel deployment because the production application loads the latest validated inventory at request time.
The UI communicates freshness based on the most recent successful inventory timestamp:
- Inventory current: up to 26 hours old
- Inventory refresh delayed: more than 26 and up to 36 hours old
- Inventory may be stale: more than 36 hours old
If a collection fails validation, the previous validated inventory remains live rather than publishing an unreliable replacement.
See OPERATIONS.md for the operational runbook.
- Node.js 22.x
- npm
- Playwright Chromium for scraper and end-to-end workflows
npm ci
npm run dev
npm run build
npm start
npm run check
npm test
npm run test:e2e
npm run scrape
app/ Next.js application shell and global presentation
components/ Inventory explorer UI and interaction logic
lib/search.js Natural-language inventory parser and matcher
lib/inventorySource.js Runtime live-inventory loader with validated fallback
lib/voiceNormalize.js Voice transcript normalization
scraper/ Discovery, collection, normalization, and validation
data/ Current and historical generated inventory artifacts
e2e/ Production-style browser smoke tests
.github/workflows/ CI and scheduled inventory automation
public/images/ Application imagery and hero assets
OPERATIONS.md Operational runbook
The collector reads only publicly accessible dealership pages. It does not attempt authentication, CAPTCHA bypass, session impersonation, or access to dealer-only systems.
The application is configured with noindex / nofollow metadata. It should still be treated as reachable by anyone who knows the production URL unless deployment-level authentication is enabled.
- Frontend: Next.js 16, React 19
- Inventory collection: Playwright
- Runtime: Node.js 22
- Testing: Node test runner and Playwright end-to-end checks
- Automation: GitHub Actions
- Deployment: Vercel
- Data model: JSON and CSV generated artifacts committed after successful validation
Michael Palmer
Automotive retail technology, software engineering, AI-assisted workflows, and dealership systems.
Genesis Inventory Intelligence
Built by Michael Palmer for faster, more accurate dealership inventory discovery.
