Download platform/model/topics/amazon_inventory.yml from fsanyoto/loopable: direct link, hf CLI and curl.
- Browser
- Download file 2.69 kB
-
https://huggingface.co/spaces/fsanyoto/loopable/resolve/main/platform/model/topics/amazon_inventory.yml
- Command line
-
hf download hf://spaces/fsanyoto/loopable/platform/model/topics/amazon_inventory.yml
-
curl -L -o amazon_inventory.yml https://huggingface.co/spaces/fsanyoto/loopable/resolve/main/platform/model/topics/amazon_inventory.yml
2.69 kB
| # An ENTITY topic for the Amazon inventory database (FBA inventory ledger summary, one row per | |
| # product, disposition and location per day). Amazon rows live in the connector store, not the | |
| # DuckDB mirror, so this topic has no `store:` block and no validated measure yet. | |
| key: amazon_inventory | |
| semantic: | |
| approved: [date, msku, fnsku, asin, disposition, location, starting_warehouse_balance, receipts, customer_shipments, customer_returns, ending_warehouse_balance] | |
| date_field: date | |
| scope: "FBA inventory ledger summary by day. Each day repeats the stock, so sum ending_warehouse_balance for one date only. Filter disposition SELLABLE for stock a customer can buy." | |
| measure_not_yet: | |
| - key: fba_units_on_hand | |
| cause: "Amazon inventory lives in the connector store, not the semantic mirror, and no metric reconciles it yet." | |
| fix: "Add an FBA units metric in model/metrics with a validate method that ties the ledger summary to the ledger detail, and register its validator in harness/semantic.py." | |
| purposes: | |
| date: "The ledger day of the row." | |
| msku: "The seller SKU. Join it to Amazon listings seller_sku." | |
| ending_warehouse_balance: "Units at the end of the day. Sum it for one date only." | |
| disposition: "SELLABLE is stock a customer can buy. Other values are damaged or held stock." | |
| synonyms: | |
| msku: [sku, seller sku] | |
| ending_warehouse_balance: [on hand, stock, units in stock] | |
| customer_shipments: [units shipped] | |
| choices: {} | |
| label: "Amazon inventory" | |
| entity: amazon.inventory_ledger_summary | |
| grid: ut_amzn_inventory | |
| subject: "amazon:inventory" | |
| grain: "one row per product, disposition and location per day" | |
| fields: | |
| - key: date | |
| label: "Date" | |
| type: date | |
| kind: data | |
| - key: msku | |
| label: "Msku" | |
| type: text | |
| kind: data | |
| - key: fnsku | |
| label: "Fnsku" | |
| type: text | |
| kind: data | |
| - key: asin | |
| label: "Asin" | |
| type: text | |
| kind: data | |
| - key: disposition | |
| label: "Disposition" | |
| type: text | |
| kind: data | |
| - key: location | |
| label: "Location" | |
| type: text | |
| kind: data | |
| - key: starting_warehouse_balance | |
| label: "Starting warehouse balance" | |
| type: int | |
| kind: data | |
| - key: receipts | |
| label: "Receipts" | |
| type: int | |
| kind: data | |
| - key: customer_shipments | |
| label: "Customer shipments" | |
| type: int | |
| kind: data | |
| - key: customer_returns | |
| label: "Customer returns" | |
| type: int | |
| kind: data | |
| - key: ending_warehouse_balance | |
| label: "Ending warehouse balance" | |
| type: int | |
| kind: data | |
| ai_context: > | |
| Amazon FBA stock by day. Sum ending_warehouse_balance on the latest date only, with disposition | |
| SELLABLE, for units a customer can buy. Never sum it across dates. | |