feat: add supplier scoring and UPC file analysis functionality
- Implemented supplier scoring logic in `supplier-scoring.ts` with functions to compute demand score, competition penalty, and overall supplier product score. - Created unit tests for supplier scoring in `supplier-scoring.test.ts` to validate scoring logic against various scenarios. - Developed UPC file analysis tool in `upc-file-analysis.ts` to process UPCs in batches, fetch product data from Keepa and SP-API, and generate supplier results. - Added UPC input reading functionality in `upc-file-reader.ts` to handle XLSX and XLS files, including validation for UPC formats. - Introduced a command-line tool in `upc-lookup.ts` for looking up UPCs and displaying detailed results or mappings to ASINs. - Enhanced error handling and logging throughout the new modules for better traceability and user feedback.
This commit is contained in:
12
package.json
12
package.json
@@ -4,13 +4,13 @@
|
||||
"type": "module",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"bestsellers": "bun run src/bestsellers-by-category.ts",
|
||||
"monthly-sold": "bun run src/top-monthly-sold-by-category.ts",
|
||||
"mid-range": "bun run src/mid-range-sellers-by-category.ts",
|
||||
"stalker": "bun run src/stalker.ts",
|
||||
"bestsellers": "bun run src/categories/bestsellers-by-category.ts",
|
||||
"monthly-sold": "bun run src/categories/top-monthly-sold-by-category.ts",
|
||||
"mid-range": "bun run src/categories/mid-range-sellers-by-category.ts",
|
||||
"stalker": "bun run src/stalker/stalker.ts",
|
||||
"search-offers": "bun run src/asin-offer-search.ts",
|
||||
"upc": "bun run src/upc-lookup.ts",
|
||||
"upc-file": "bun run src/upc-file-analysis.ts",
|
||||
"upc": "bun run src/supplier/upc-lookup.ts",
|
||||
"upc-file": "bun run src/supplier/upc-file-analysis.ts",
|
||||
"start": "bun run src/index.ts",
|
||||
"start:web": "bun --hot src/server.ts",
|
||||
"build:web": "bun build src/web/index.html --outdir dist",
|
||||
|
||||
Reference in New Issue
Block a user