Dataset Viewer
Auto-converted to Parquet Duplicate
qid
stringlengths
2
4
prompt
stringlengths
282
27.7k
chosen
stringlengths
90
429
rejected
stringlengths
18
653
chosen_score
float64
0.82
1
rejected_score
float64
0.58
0.97
tool_out
unknown
scope
unknown
uncertain
bool
2 classes
family
stringclasses
1 value
intent
stringclasses
5 values
T250
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'national_CMS:WH_0016', 'commodity_category': 'IV_fluids', 'year': 2024, 'month': 11}) -> {'status': 'ok', 'uid': 'national_CMS:WH_0016', 'wa...
FACTS: WH_0016 (national_CMS, 11/2024): reported issue = stock_record_discrepancy. other signals: low inventory accuracy (63.6%); high wastage (13.6%) RECOMMENDATION: address the reported issue (stock_record_discrepancy).
FACTS: WH_0016 (national_CMS, 11/2024): reported issue = warehouse_mismanagement. other signals: low inventory accuracy (63.6%); high wastage (13.6%) RECOMMENDATION: address the reported issue (stock_record_discrepancy).
1
0.857143
{ "status": "ok", "uid": "national_CMS:WH_0016", "warehouse_id": "WH_0016", "warehouse_level": "national_CMS", "year": 2024, "month": 11, "reported_issue": "stock_record_discrepancy", "has_issue": true, "signals": [ "low inventory accuracy (63.6%)", "high wastage (13.6%)" ] }
{ "uid": "national_CMS:WH_0016", "commodity_category": "IV_fluids", "year": 2024, "month": 11 }
false
tool
explain_issue
T95
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'district_store:WH_0078', 'commodity_category': 'contraceptives', 'year': 2024, 'month': 8}) -> {'status': 'ok', 'uid': 'district_store:WH_00...
FACTS: WH_0078 (district_store, 8/2024): reported issue = damaged_goods. other signals: FEFO compliance failed; low inventory accuracy (11.1%); high wastage (33.8%); active stockout RECOMMENDATION: address the reported issue (damaged_goods).
FACTS: WH_0078 (district_store, 8/2024): reported issue = warehouse_mismanagement. other signals: FEFO compliance failed; low inventory accuracy (11.1%); high wastage (33.8%); active stockout RECOMMENDATION: address the reported issue (damaged_goods).
1
0.857143
{ "status": "ok", "uid": "district_store:WH_0078", "warehouse_id": "WH_0078", "warehouse_level": "district_store", "year": 2024, "month": 8, "reported_issue": "damaged_goods", "has_issue": true, "signals": [ "FEFO compliance failed", "low inventory accuracy (11.1%)", "high wastage (33.8%)"...
{ "uid": "district_store:WH_0078", "commodity_category": "contraceptives", "year": 2024, "month": 8 }
false
tool
explain_issue
T159
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'district_store:WH_0063'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 36.8, 'avg_order_fulfilment_rate_pct': 26.7, 'months_with_stockout': 0, '...
FACTS: WH_0063 (district_store): avg inventory accuracy 36.8%, avg fulfilment 26.7%, 0 months w/ stockout (based on 1 records), issues on record: {'damaged_goods': 1} RECOMMENDATION: looks fine.
FACTS: WH_0063 (district_store): avg inventory accuracy 36.8%, avg fulfilment 26.7%, 0 months w/ stockout (based on 1 records), issues on record: {'damaged_goods': 1} Not sure about the rest of the details. RECOMMENDATION: looks fine.
1
0.857143
{ "n_records": 1, "avg_inventory_accuracy_pct": 36.8, "avg_order_fulfilment_rate_pct": 26.7, "months_with_stockout": 0, "issue_counts": { "damaged_goods": 1 }, "uid": "district_store:WH_0063", "warehouse_id": "WH_0063", "warehouse_level": "district_store" }
{ "uid": "district_store:WH_0063" }
false
tool
kpis
T165
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'district_store:WH_0046', 'commodity_category': 'laboratory_reagents', 'year': 2022, 'month': 11}) -> {'status': 'ok', 'uid': 'district_store...
FACTS: WH_0046 (district_store, 11/2022): reported issue = stock_record_discrepancy. other signals: storage conditions not adequate; FEFO compliance failed; low inventory accuracy (13.7%); high wastage (22.6%) (note: report not submitted, numbers may be provisional) RECOMMENDATION: address the reported issue (stock_rec...
FACTS: address the reported issue (stock_record_discrepancy).
1
0.742857
{ "status": "ok", "uid": "district_store:WH_0046", "warehouse_id": "WH_0046", "warehouse_level": "district_store", "year": 2022, "month": 11, "reported_issue": "stock_record_discrepancy", "has_issue": true, "signals": [ "storage conditions not adequate", "FEFO compliance failed", "low inve...
{ "uid": "district_store:WH_0046", "commodity_category": "laboratory_reagents", "year": 2022, "month": 11 }
true
tool
explain_issue
T247
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({'uid': 'national_CMS:WH_0016'}) -> [{'uid': 'national_CMS:WH_0016', 'warehouse_id': 'WH_0016', 'warehouse_level': 'national_CMS', 'commodity_category':...
FACTS: 1 backordered records (uid=national_CMS:WH_0016). worst: WH_0016 (national_CMS, IV_fluids) at 32.7% backorder rate RECOMMENDATION: expedite WH_0016 (national_CMS).
FACTS: expedite WH_0016 (national_CMS).
0.97619
0.904762
[ { "uid": "national_CMS:WH_0016", "warehouse_id": "WH_0016", "warehouse_level": "national_CMS", "commodity_category": "IV_fluids", "orders_backordered": 17, "backorder_rate_pct": 32.7 } ]
{ "uid": "national_CMS:WH_0016" }
false
tool
backorders
T229
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'national_CMS:WH_0003'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 76.8, 'avg_order_fulfilment_rate_pct': 64.4, 'months_with_stockout': 1, 'is...
FACTS: WH_0003 (national_CMS): avg inventory accuracy 76.8%, avg fulfilment 64.4%, 1 months w/ stockout (based on 1 records), issues on record: {'pest_infestation': 1} RECOMMENDATION: worth a review.
FACTS: WH_0003 (national_CMS): avg inventory accuracy 76.8%, avg fulfilment 64.4%, 1 months w/ stockout (based on 1 records), issues on record: {'pest_infestation': 1} RECOMMENDATION: Not sure. (Not enough information) FACTS: WH_0003 (national_CMS): avg inventory accuracy 76.8%, avg fulfilment 64.4%, 1 months w/ stocko...
1
0.761905
{ "n_records": 1, "avg_inventory_accuracy_pct": 76.8, "avg_order_fulfilment_rate_pct": 64.4, "months_with_stockout": 1, "issue_counts": { "pest_infestation": 1 }, "uid": "national_CMS:WH_0003", "warehouse_id": "WH_0003", "warehouse_level": "national_CMS" }
{ "uid": "national_CMS:WH_0003" }
false
tool
kpis
T191
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'uid': 'national_CMS:WH_0018'}) -> [] Q: does WH_0018 at the national_CMS currently have any active stockouts? A:
FACTS: no active stockouts (uid=national_CMS:WH_0018) RECOMMENDATION: nothing urgent here.
FACTS: nothing urgent here.
1
0.857143
[]
{ "uid": "national_CMS:WH_0018" }
false
tool
stockouts
T123
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'district_store:WH_0042'}) -> [{'uid': 'district_store:WH_0042', 'warehouse_id': 'WH_0042', 'warehouse_level': 'district_store', 'commodity_c...
FACTS: top shortage risk (uid=district_store:WH_0042) is WH_0042 (district_store, controlled_substances), score=11.5, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_critical'] RECOMMENDATION: focus replenishment planning on WH_0042 (district_store).
FACTS: top shortage risk (uid=district_store:WH_0042) is WH_0042 (district_store, controlled_substances), score=11.5, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_critical'] RECOMMENDATION: Not sure about that - would need to check the system for more ...
0.971429
0.828571
[ { "uid": "district_store:WH_0042", "warehouse_id": "WH_0042", "warehouse_level": "district_store", "commodity_category": "controlled_substances", "risk_score": 11.5, "risk_factors": [ "stockout", "high_backorder_rate", "low_fulfilment", "high_wastage", "storage_...
{ "uid": "district_store:WH_0042" }
false
tool
shortage_risk
T258
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'national_CMS:WH_0088'}) -> [{'uid': 'national_CMS:WH_0088', 'warehouse_id': 'WH_0088', 'warehouse_level': 'national_CMS', 'commodity_categor...
FACTS: top shortage risk (uid=national_CMS:WH_0088) is WH_0088 (national_CMS, malaria_commodities), score=5.5, factors=['high_backorder_rate', 'low_fulfilment', 'criticality_high'] RECOMMENDATION: focus replenishment planning on WH_0088 (national_CMS).
FACTS: focus replenishment planning on WH_0088 (national_CMS).
0.971429
0.914286
[ { "uid": "national_CMS:WH_0088", "warehouse_id": "WH_0088", "warehouse_level": "national_CMS", "commodity_category": "malaria_commodities", "risk_score": 5.5, "risk_factors": [ "high_backorder_rate", "low_fulfilment", "criticality_high" ] } ]
{ "uid": "national_CMS:WH_0088" }
false
tool
shortage_risk
T293
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'national_CMS:WH_0069'}) -> [{'uid': 'national_CMS:WH_0069', 'warehouse_id': 'WH_0069', 'warehouse_level': 'national_CMS', 'commodity_categor...
FACTS: top shortage risk (uid=national_CMS:WH_0069) is WH_0069 (national_CMS, laboratory_reagents), score=5.5, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'criticality_medium'] RECOMMENDATION: focus replenishment planning on WH_0069 (national_CMS).
FACTS: top shortage risk (uid=national_CMS:WH_0069) is WH_0069 (national_CMS, laboratory_reagents), score=31.4, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'criticality_medium'] RECOMMENDATION: focus replenishment planning on WH_0069 (national_CMS).
0.971429
0.942857
[ { "uid": "national_CMS:WH_0069", "warehouse_id": "WH_0069", "warehouse_level": "national_CMS", "commodity_category": "laboratory_reagents", "risk_score": 5.5, "risk_factors": [ "high_backorder_rate", "low_fulfilment", "high_wastage", "criticality_medium" ] } ]
{ "uid": "national_CMS:WH_0069" }
false
tool
shortage_risk
T193
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'national_CMS:WH_0018'}) -> [{'uid': 'national_CMS:WH_0018', 'warehouse_id': 'WH_0018', 'warehouse_level': 'national_CMS', 'commodity_categor...
FACTS: top shortage risk (uid=national_CMS:WH_0018) is WH_0018 (national_CMS, vaccines), score=7.0, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'criticality_critical'] RECOMMENDATION: focus replenishment planning on WH_0018 (national_CMS).
FACTS: top shortage risk (uid=national_CMS:WH_0018) is WH_0018 (national_CMS, vaccines), score=7.0, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'criticality_critical'] RECOMMENDATION: Not sure. To get more information, I would need to check further.
0.971429
0.828571
[ { "uid": "national_CMS:WH_0018", "warehouse_id": "WH_0018", "warehouse_level": "national_CMS", "commodity_category": "vaccines", "risk_score": 7, "risk_factors": [ "high_backorder_rate", "low_fulfilment", "high_wastage", "criticality_critical" ] } ]
{ "uid": "national_CMS:WH_0018" }
false
tool
shortage_risk
T306
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'uid': 'regional_warehouse:WH_0050'}) -> [{'uid': 'regional_warehouse:WH_0050', 'warehouse_id': 'WH_0050', 'warehouse_level': 'regional_warehouse', 'com...
FACTS: 2 active stockouts (uid=regional_warehouse:WH_0050). worst: WH_0050 (regional_warehouse, medical_devices_consumables), 8 facilities hit RECOMMENDATION: prioritize WH_0050 (regional_warehouse) first.
FACTS: 2 active stockouts (uid=regional_warehouse:WH_0050). worst: WH_0050 (regional_warehouse, medical_devices_consumables), 8 facilities hit RECOMMENDATION: Not sure about that - would need to check the system for more detail. FACTS: 2 active stockouts (uid=regional_warehouse:WH_0050). worst: WH_0050 (regional_wareho...
1
0.809524
[ { "uid": "regional_warehouse:WH_0050", "warehouse_id": "WH_0050", "warehouse_level": "regional_warehouse", "commodity_category": "medical_devices_consumables", "facilities_affected_by_stockout": 8 }, { "uid": "regional_warehouse:WH_0050", "warehouse_id": "WH_0050", "warehouse_lev...
{ "uid": "regional_warehouse:WH_0050" }
false
tool
stockouts
T39
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'region_type': 'rural'}) -> [{'uid': 'district_store:WH_0028', 'warehouse_id': 'WH_0028', 'warehouse_level': 'district_store', 'commodity_category':...
FACTS: top shortage risk (region_type=rural) is WH_0028 (district_store, vaccines), score=11.5, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_critical'] RECOMMENDATION: focus replenishment planning on WH_0028 (district_store).
FACTS: top shortage risk (region_type=rural) is WH_0028 (district_store, vaccines), score=37.8, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_critical'] RECOMMENDATION: focus replenishment planning on WH_0028 (district_store).
0.971429
0.942857
[ { "uid": "district_store:WH_0028", "warehouse_id": "WH_0028", "warehouse_level": "district_store", "commodity_category": "vaccines", "risk_score": 11.5, "risk_factors": [ "stockout", "high_backorder_rate", "low_fulfilment", "high_wastage", "storage_inadequate", ...
{ "region_type": "rural" }
false
tool
shortage_risk
T339
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'regional_warehouse:WH_0090'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 61.7, 'avg_order_fulfilment_rate_pct': 34.5, 'months_with_stockout': ...
FACTS: WH_0090 (regional_warehouse): avg inventory accuracy 61.7%, avg fulfilment 34.5%, 0 months w/ stockout (based on 1 records), issues on record: {'damaged_goods': 1} RECOMMENDATION: looks fine.
FACTS: looks fine.
1
0.857143
{ "n_records": 1, "avg_inventory_accuracy_pct": 61.7, "avg_order_fulfilment_rate_pct": 34.5, "months_with_stockout": 0, "issue_counts": { "damaged_goods": 1 }, "uid": "regional_warehouse:WH_0090", "warehouse_id": "WH_0090", "warehouse_level": "regional_warehouse" }
{ "uid": "regional_warehouse:WH_0090" }
false
tool
kpis
T348
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'regional_warehouse:WH_0011'}) -> [{'uid': 'regional_warehouse:WH_0011', 'warehouse_id': 'WH_0011', 'warehouse_level': 'regional_warehouse', ...
FACTS: top shortage risk (uid=regional_warehouse:WH_0011) is WH_0011 (regional_warehouse, nutrition_commodities), score=7.0, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_medium'] RECOMMENDATION: focus replenishment planning on WH_0011 (regional_warehouse).
FACTS: focus replenishment planning on WH_0011 (regional_warehouse).
0.971429
0.914286
[ { "uid": "regional_warehouse:WH_0011", "warehouse_id": "WH_0011", "warehouse_level": "regional_warehouse", "commodity_category": "nutrition_commodities", "risk_score": 7, "risk_factors": [ "high_backorder_rate", "low_fulfilment", "high_wastage", "storage_inadequate", ...
{ "uid": "regional_warehouse:WH_0011" }
false
tool
shortage_risk
T365
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'regional_warehouse:WH_0029', 'commodity_category': 'essential_medicines', 'year': 2023, 'month': 3}) -> {'status': 'ok', 'uid': 'regional_wa...
FACTS: WH_0029 (regional_warehouse, 3/2023): reported issue = pest_infestation. other signals: FEFO compliance failed; low inventory accuracy (36.5%); high wastage (18.9%) RECOMMENDATION: address the reported issue (pest_infestation).
FACTS: WH_0029 (regional_warehouse, 3/2023): reported issue = pest_infestation. other signals: FEFO compliance failed; low inventory accuracy (36.5%); high wastage (18.9%) RECOMMENDATION: Not sure. To get more information, I would need to check further. FACTS: WH_0029 (regional_warehouse, 3/2023): reported issue = pest...
1
0.809524
{ "status": "ok", "uid": "regional_warehouse:WH_0029", "warehouse_id": "WH_0029", "warehouse_level": "regional_warehouse", "year": 2023, "month": 3, "reported_issue": "pest_infestation", "has_issue": true, "signals": [ "FEFO compliance failed", "low inventory accuracy (36.5%)", "high wasta...
{ "uid": "regional_warehouse:WH_0029", "commodity_category": "essential_medicines", "year": 2023, "month": 3 }
false
tool
explain_issue
T44
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'compare_by': 'warehouse_level', 'compare_values': ['district_store', 'regional_warehouse']}) -> {'_grouped_by': 'warehouse_level', 'groups': {'dist...
FACTS: shortage risk by warehouse_level: district_store: top risk WH_0028 (vaccines), score=11.5; regional_warehouse: top risk WH_0007 (controlled_substances), score=11.5 RECOMMENDATION: focus replenishment planning on the district_store group first - highest risk score.
FACTS: focus replenishment planning on the district_store group first - highest risk score.
1
0.875
{ "_grouped_by": "warehouse_level", "groups": { "district_store": [ { "uid": "district_store:WH_0028", "warehouse_id": "WH_0028", "warehouse_level": "district_store", "commodity_category": "vaccines", "risk_score": 11.5, "risk_factors": [ "stockout...
{ "compare_by": "warehouse_level", "compare_values": [ "district_store", "regional_warehouse" ] }
false
tool
shortage_risk
T218
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'national_CMS:WH_0041'}) -> [{'uid': 'national_CMS:WH_0041', 'warehouse_id': 'WH_0041', 'warehouse_level': 'national_CMS', 'commodity_categor...
FACTS: top shortage risk (uid=national_CMS:WH_0041) is WH_0041 (national_CMS, laboratory_reagents), score=4.5, factors=['high_backorder_rate', 'low_fulfilment', 'criticality_medium'] RECOMMENDATION: focus replenishment planning on WH_0041 (national_CMS).
not sure, you'd have to check the system yourself
0.971429
0.666667
[ { "uid": "national_CMS:WH_0041", "warehouse_id": "WH_0041", "warehouse_level": "national_CMS", "commodity_category": "laboratory_reagents", "risk_score": 4.5, "risk_factors": [ "high_backorder_rate", "low_fulfilment", "criticality_medium" ] } ]
{ "uid": "national_CMS:WH_0041" }
false
tool
shortage_risk
T100
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'district_store:WH_0017', 'commodity_category': 'nutrition_commodities', 'year': 2022, 'month': 1}) -> {'status': 'ok', 'uid': 'district_stor...
FACTS: WH_0017 (district_store, 1/2022): reported issue = expired_stock. other signals: storage conditions not adequate; FEFO compliance failed; low inventory accuracy (37.2%); high wastage (31.4%) (note: report not submitted, numbers may be provisional) RECOMMENDATION: address the reported issue (expired_stock).
FACTS: WH_0262 (district_store, 1/2022): reported issue = expired_stock. other signals: storage conditions not adequate; FEFO compliance failed; low inventory accuracy (37.2%); high wastage (31.4%) (note: report not submitted, numbers may be provisional) RECOMMENDATION: address the reported issue (expired_stock). FACTS...
1
0.780952
{ "status": "ok", "uid": "district_store:WH_0017", "warehouse_id": "WH_0017", "warehouse_level": "district_store", "year": 2022, "month": 1, "reported_issue": "expired_stock", "has_issue": true, "signals": [ "storage conditions not adequate", "FEFO compliance failed", "low inventory accura...
{ "uid": "district_store:WH_0017", "commodity_category": "nutrition_commodities", "year": 2022, "month": 1 }
true
tool
explain_issue
T54
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'region_type': 'peri_urban'}) -> {'n_records': 68, 'avg_inventory_accuracy_pct': 53.2, 'avg_order_fulfilment_rate_pct': 55.1, 'months_with_stockout': 20, 'is...
FACTS: avg inventory accuracy 53.2%, avg fulfilment 55.1%, 20 months w/ stockout (region_type=peri_urban) (based on 68 records), issues on record: {'theft_pilferage': 7, 'expired_stock': 8, 'FEFO_not_followed': 7, 'overstocking': 6, 'dispatch_error': 5, 'pest_infestation': 7, 'damaged_goods': 5, 'understocking': 5, 're...
FACTS: avg inventory accuracy 69.6%, avg fulfilment 55.1%, 20 months w/ stockout (region_type=peri_urban) (based on 68 records), issues on record: {'theft_pilferage': 7, 'expired_stock': 8, 'FEFO_not_followed': 7, 'overstocking': 6, 'dispatch_error': 5, 'pest_infestation': 7, 'damaged_goods': 5, 'understocking': 5, 're...
1
0.964286
{ "n_records": 68, "avg_inventory_accuracy_pct": 53.2, "avg_order_fulfilment_rate_pct": 55.1, "months_with_stockout": 20, "issue_counts": { "theft_pilferage": 7, "expired_stock": 8, "FEFO_not_followed": 7, "overstocking": 6, "dispatch_error": 5, "pest_infestation": 7, "damaged_good...
{ "region_type": "peri_urban" }
false
tool
kpis
T272
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({'uid': 'national_CMS:WH_0005'}) -> [] Q: which category has the most backorders at WH_0005 at the national_CMS? A:
FACTS: nothing backordered right now (uid=national_CMS:WH_0005) RECOMMENDATION: no action needed.
FACTS: nothing backordered right now (uid=national_CMS:WH_0005) RECOMMENDATION: Not sure. (Not enough information to determine)
1
0.809524
[]
{ "uid": "national_CMS:WH_0005" }
false
tool
backorders
T170
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'district_store:WH_0010', 'commodity_category': 'malaria_commodities', 'year': 2023, 'month': 6}) -> {'status': 'ok', 'uid': 'district_store:...
FACTS: WH_0010 (district_store, 6/2023): reported issue = receiving_error. other signals: storage conditions not adequate; FEFO compliance failed; low inventory accuracy (45.6%); high wastage (22.9%); active stockout (note: report not submitted, numbers may be provisional) RECOMMENDATION: address the reported issue (re...
not sure, you'd have to check the system yourself
1
0.809524
{ "status": "ok", "uid": "district_store:WH_0010", "warehouse_id": "WH_0010", "warehouse_level": "district_store", "year": 2023, "month": 6, "reported_issue": "receiving_error", "has_issue": true, "signals": [ "storage conditions not adequate", "FEFO compliance failed", "low inventory accu...
{ "uid": "district_store:WH_0010", "commodity_category": "malaria_commodities", "year": 2023, "month": 6 }
true
tool
explain_issue
T252
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({'uid': 'national_CMS:WH_0079'}) -> [{'uid': 'national_CMS:WH_0079', 'warehouse_id': 'WH_0079', 'warehouse_level': 'national_CMS', 'commodity_category':...
FACTS: 1 backordered records (uid=national_CMS:WH_0079). worst: WH_0079 (national_CMS, laboratory_reagents) at 28.6% backorder rate RECOMMENDATION: expedite WH_0079 (national_CMS).
FACTS: 1 backordered records (uid=national_CMS:WH_0079). worst: WH_0079 (national_CMS, laboratory_reagents) at 28.6% backorder rate RECOMMENDATION: Not sure about that - would need to check the system for more detail.
0.97619
0.833333
[ { "uid": "national_CMS:WH_0079", "warehouse_id": "WH_0079", "warehouse_level": "national_CMS", "commodity_category": "laboratory_reagents", "orders_backordered": 16, "backorder_rate_pct": 28.6 } ]
{ "uid": "national_CMS:WH_0079" }
false
tool
backorders
T78
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'compare_by': 'region_type', 'compare_values': ['peri_urban', 'rural']}) -> {'_grouped_by': 'region_type', 'groups': {'rural': {'dominant_issue': 'F...
FACTS: most common issue by region_type: peri_urban: expired_stock (8x); rural: FEFO_not_followed (10x) RECOMMENDATION: focus on the rural group's most common issue first.
FACTS: most common issue by region_type: system_error: expired_stock (8x); rural: FEFO_not_followed (10x) RECOMMENDATION: focus on the rural group's most common issue first.
0.821429
0.660714
{ "_grouped_by": "region_type", "groups": { "rural": { "dominant_issue": "FEFO_not_followed", "count": 10, "n_records": 87, "issue_counts": { "theft_pilferage": 5, "expired_stock": 5, "stock_record_discrepancy": 9, "temperature_excursion": 8, "FEFO...
{ "compare_by": "region_type", "compare_values": [ "peri_urban", "rural" ] }
false
tool
explain_issue
T10
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'region_type': 'peri_urban'}) -> [{'uid': 'national_CMS:WH_0046', 'warehouse_id': 'WH_0046', 'warehouse_level': 'national_CMS', 'commodity_category': 'm...
FACTS: 20 active stockouts (region_type=peri_urban). worst: WH_0046 (national_CMS, malaria_commodities), 108 facilities hit RECOMMENDATION: prioritize WH_0046 (national_CMS) first.
FACTS: 48.0 active stockouts (region_type=peri_urban). worst: WH_0046 (national_CMS, malaria_commodities), 108 facilities hit RECOMMENDATION: prioritize WH_0046 (national_CMS) first.
1
0.971429
[ { "uid": "national_CMS:WH_0046", "warehouse_id": "WH_0046", "warehouse_level": "national_CMS", "commodity_category": "malaria_commodities", "facilities_affected_by_stockout": 108 }, { "uid": "national_CMS:WH_0060", "warehouse_id": "WH_0060", "warehouse_level": "national_CMS", ...
{ "region_type": "peri_urban" }
false
tool
stockouts
T69
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'warehouse_level': 'regional_warehouse'}) -> {'dominant_issue': 'stock_record_discrepancy', 'count': 6, 'n_records': 72, 'issue_counts': {'stock_rec...
FACTS: most common issue (warehouse_level=regional_warehouse): stock_record_discrepancy (6 of 72 records) RECOMMENDATION: investigate stock_record_discrepancy as the top recurring issue.
FACTS: most common issue (warehouse_level=regional_warehouse): stock_record_discrepancy (6 of 72 records) RECOMMENDATION: Not sure. (Not enough information to determine)
1
0.809524
{ "dominant_issue": "stock_record_discrepancy", "count": 6, "n_records": 72, "issue_counts": { "stock_record_discrepancy": 6, "pest_infestation": 6, "theft_pilferage": 6, "understocking": 6, "expired_stock": 6, "overstocking": 6, "receiving_error": 6, "FEFO_not_followed": 6, ...
{ "warehouse_level": "regional_warehouse" }
false
tool
explain_issue
T199
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'national_CMS:WH_0021'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 76.7, 'avg_order_fulfilment_rate_pct': 81.9, 'months_with_stockout': 0, 'is...
FACTS: WH_0021 (national_CMS): avg inventory accuracy 76.7%, avg fulfilment 81.9%, 0 months w/ stockout (based on 1 records), issues on record: {'overstocking': 1} RECOMMENDATION: looks fine.
FACTS: WH_0364 (national_CMS): avg inventory accuracy 76.7%, avg fulfilment 81.9%, 0 months w/ stockout (based on 1 records), issues on record: {'overstocking': 1} RECOMMENDATION: looks fine. FACTS: WH_0364 (national_CMS): avg inventory accuracy 76.7%, avg fulfilment 81.9%, 0 months w/ stockout (based on 1 records), is...
1
0.785714
{ "n_records": 1, "avg_inventory_accuracy_pct": 76.7, "avg_order_fulfilment_rate_pct": 81.9, "months_with_stockout": 0, "issue_counts": { "overstocking": 1 }, "uid": "national_CMS:WH_0021", "warehouse_id": "WH_0021", "warehouse_level": "national_CMS" }
{ "uid": "national_CMS:WH_0021" }
false
tool
kpis
T3
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({}) -> [{'uid': 'district_store:WH_0067', 'warehouse_id': 'WH_0067', 'warehouse_level': 'district_store', 'commodity_category': 'surgical_supplies', 'or...
FACTS: 205 backordered records. worst: WH_0067 (district_store, surgical_supplies) at 100.0% backorder rate RECOMMENDATION: expedite WH_0067 (district_store).
FACTS: 205 backordered records. worst: WH_0067 (district_store, surgical_supplies) at 100.0% backorder rate RECOMMENDATION: Not sure. To get more information, I would need to check further.
0.97619
0.833333
[ { "uid": "district_store:WH_0067", "warehouse_id": "WH_0067", "warehouse_level": "district_store", "commodity_category": "surgical_supplies", "orders_backordered": 2, "backorder_rate_pct": 100 }, { "uid": "district_store:WH_0075", "warehouse_id": "WH_0075", "warehouse_level":...
{}
false
tool
backorders
T368
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'regional_warehouse:WH_0043'}) -> [{'uid': 'regional_warehouse:WH_0043', 'warehouse_id': 'WH_0043', 'warehouse_level': 'regional_warehouse', ...
FACTS: top shortage risk (uid=regional_warehouse:WH_0043) is WH_0043 (regional_warehouse, PPE_IPC_supplies), score=1.5, factors=['high_wastage', 'criticality_medium'] RECOMMENDATION: focus replenishment planning on WH_0043 (regional_warehouse).
FACTS: top shortage risk (uid=regional_warehouse:WH_0043) is WH_0043 (regional_warehouse, PPE_IPC_supplies), score=1.5, factors=['high_wastage', 'criticality_medium'] Not entirely sure if this is complete. RECOMMENDATION: focus replenishment planning on WH_0043 (regional_warehouse). FACTS: to repeat, the figure is 1.5....
0.971429
0.87619
[ { "uid": "regional_warehouse:WH_0043", "warehouse_id": "WH_0043", "warehouse_level": "regional_warehouse", "commodity_category": "PPE_IPC_supplies", "risk_score": 1.5, "risk_factors": [ "high_wastage", "criticality_medium" ] } ]
{ "uid": "regional_warehouse:WH_0043" }
false
tool
shortage_risk
T373
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'regional_warehouse:WH_0041'}) -> [{'uid': 'regional_warehouse:WH_0041', 'warehouse_id': 'WH_0041', 'warehouse_level': 'regional_warehouse', ...
FACTS: top shortage risk (uid=regional_warehouse:WH_0041) is WH_0041 (regional_warehouse, medical_devices_consumables), score=6.5, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate'] RECOMMENDATION: focus replenishment planning on WH_0041 (regional_warehouse).
not sure, you'd have to check the system yourself
0.971429
0.666667
[ { "uid": "regional_warehouse:WH_0041", "warehouse_id": "WH_0041", "warehouse_level": "regional_warehouse", "commodity_category": "medical_devices_consumables", "risk_score": 6.5, "risk_factors": [ "high_backorder_rate", "low_fulfilment", "high_wastage", "storage_inade...
{ "uid": "regional_warehouse:WH_0041" }
false
tool
shortage_risk
T260
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'national_CMS:WH_0088', 'commodity_category': 'malaria_commodities', 'year': 2024, 'month': 5}) -> {'status': 'ok', 'uid': 'national_CMS:WH_0...
FACTS: WH_0088 (national_CMS, 5/2024): reported issue = overstocking. other signals: low inventory accuracy (62.6%) RECOMMENDATION: address the reported issue (overstocking).
FACTS: WH_0088 (national_CMS, 5/2024): reported issue = overstocking. other signals: low inventory accuracy (62.6%) RECOMMENDATION: Not sure. To get more information, I would need to check further. FACTS: to repeat, the figure is 5. Again, 5 is the number.
1
0.809524
{ "status": "ok", "uid": "national_CMS:WH_0088", "warehouse_id": "WH_0088", "warehouse_level": "national_CMS", "year": 2024, "month": 5, "reported_issue": "overstocking", "has_issue": true, "signals": [ "low inventory accuracy (62.6%)" ] }
{ "uid": "national_CMS:WH_0088", "commodity_category": "malaria_commodities", "year": 2024, "month": 5 }
false
tool
explain_issue
T254
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'national_CMS:WH_0079'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 88.0, 'avg_order_fulfilment_rate_pct': 71.6, 'months_with_stockout': 0, 'is...
FACTS: WH_0079 (national_CMS): avg inventory accuracy 88.0%, avg fulfilment 71.6%, 0 months w/ stockout (based on 1 records) RECOMMENDATION: looks fine.
FACTS: WH_0079 (national_CMS): avg inventory accuracy 88.0%, avg fulfilment 71.6%, 0 months w/ stockout (based on 1 records) RECOMMENDATION: Not sure. To get more information, I would need to check further.
1
0.857143
{ "n_records": 1, "avg_inventory_accuracy_pct": 88, "avg_order_fulfilment_rate_pct": 71.6, "months_with_stockout": 0, "issue_counts": {}, "uid": "national_CMS:WH_0079", "warehouse_id": "WH_0079", "warehouse_level": "national_CMS" }
{ "uid": "national_CMS:WH_0079" }
false
tool
kpis
T245
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'national_CMS:WH_0009', 'commodity_category': 'essential_medicines', 'year': 2024, 'month': 10}) -> {'status': 'ok', 'uid': 'national_CMS:WH_...
FACTS: WH_0009 (national_CMS, 10/2024): reported issue = none. other signals: storage conditions not adequate; low inventory accuracy (81.8%); high wastage (10.3%) RECOMMENDATION: no action needed.
FACTS: no action needed.
1
0.857143
{ "status": "ok", "uid": "national_CMS:WH_0009", "warehouse_id": "WH_0009", "warehouse_level": "national_CMS", "year": 2024, "month": 10, "reported_issue": "none", "has_issue": false, "signals": [ "storage conditions not adequate", "low inventory accuracy (81.8%)", "high wastage (10.3%)" ...
{ "uid": "national_CMS:WH_0009", "commodity_category": "essential_medicines", "year": 2024, "month": 10 }
false
tool
explain_issue
T210
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'national_CMS:WH_0034', 'commodity_category': 'surgical_supplies', 'year': 2022, 'month': 3}) -> {'status': 'ok', 'uid': 'national_CMS:WH_003...
FACTS: WH_0034 (national_CMS, 3/2022): reported issue = receiving_error. other signals: low inventory accuracy (79.7%) RECOMMENDATION: address the reported issue (receiving_error).
FACTS: WH_0034 (national_CMS, 3/2022): reported issue = receiving_error. other signals: low inventory accuracy (79.7%) RECOMMENDATION: Not sure about that - would need to check the system for more detail.
1
0.857143
{ "status": "ok", "uid": "national_CMS:WH_0034", "warehouse_id": "WH_0034", "warehouse_level": "national_CMS", "year": 2022, "month": 3, "reported_issue": "receiving_error", "has_issue": true, "signals": [ "low inventory accuracy (79.7%)" ] }
{ "uid": "national_CMS:WH_0034", "commodity_category": "surgical_supplies", "year": 2022, "month": 3 }
false
tool
explain_issue
T56
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'region_type': 'urban'}) -> {'n_records': 55, 'avg_inventory_accuracy_pct': 68.8, 'avg_order_fulfilment_rate_pct': 68.5, 'months_with_stockout': 12, 'issue_c...
FACTS: avg inventory accuracy 68.8%, avg fulfilment 68.5%, 12 months w/ stockout (region_type=urban) (based on 55 records), issues on record: {'stock_record_discrepancy': 6, 'pest_infestation': 5, 'theft_pilferage': 6, 'damaged_goods': 5, 'overstocking': 3, 'understocking': 4, 'expired_stock': 5, 'FEFO_not_followed': 1...
FACTS: avg inventory accuracy 68.8%, avg fulfilment 68.5%, 12 months w/ stockout (region_type=urban) (based on 55 records), issues on record: {'stock_record_discrepancy': 6, 'pest_infestation': 5, 'theft_pilferage': 6, 'damaged_goods': 5, 'overstocking': 3, 'understocking': 4, 'expired_stock': 5, 'FEFO_not_followed': 1...
1
0.857143
{ "n_records": 55, "avg_inventory_accuracy_pct": 68.8, "avg_order_fulfilment_rate_pct": 68.5, "months_with_stockout": 12, "issue_counts": { "stock_record_discrepancy": 6, "pest_infestation": 5, "theft_pilferage": 6, "damaged_goods": 5, "overstocking": 3, "understocking": 4, "expire...
{ "region_type": "urban" }
false
tool
kpis
T35
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'warehouse_level': 'district_store'}) -> [{'uid': 'district_store:WH_0028', 'warehouse_id': 'WH_0028', 'warehouse_level': 'district_store', 'commodi...
FACTS: top shortage risk (warehouse_level=district_store) is WH_0028 (district_store, vaccines), score=11.5, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_critical'] RECOMMENDATION: focus replenishment planning on WH_0028 (district_store).
FACTS: top shortage risk (warehouse_level=district_store) is WH_0028 (district_store, vaccines), score=34.1, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_critical'] RECOMMENDATION: focus replenishment planning on WH_0028 (district_store).
0.971429
0.942857
[ { "uid": "district_store:WH_0028", "warehouse_id": "WH_0028", "warehouse_level": "district_store", "commodity_category": "vaccines", "risk_score": 11.5, "risk_factors": [ "stockout", "high_backorder_rate", "low_fulfilment", "high_wastage", "storage_inadequate", ...
{ "warehouse_level": "district_store" }
false
tool
shortage_risk
T355
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'regional_warehouse:WH_0042', 'commodity_category': 'laboratory_reagents', 'year': 2022, 'month': 7}) -> {'status': 'ok', 'uid': 'regional_wa...
FACTS: WH_0042 (regional_warehouse, 7/2022): reported issue = temperature_excursion. other signals: storage conditions not adequate; FEFO compliance failed; low inventory accuracy (54.7%); high wastage (15.7%) (note: report not submitted, numbers may be provisional) RECOMMENDATION: address the reported issue (temperatu...
FACTS: WH_0042 (regional_warehouse, 7/2022): reported issue = unknown_cause. other signals: storage conditions not adequate; FEFO compliance failed; low inventory accuracy (54.7%); high wastage (15.7%) (note: report not submitted, numbers may be provisional) RECOMMENDATION: address the reported issue (temperature_excur...
1
0.809524
{ "status": "ok", "uid": "regional_warehouse:WH_0042", "warehouse_id": "WH_0042", "warehouse_level": "regional_warehouse", "year": 2022, "month": 7, "reported_issue": "temperature_excursion", "has_issue": true, "signals": [ "storage conditions not adequate", "FEFO compliance failed", "low ...
{ "uid": "regional_warehouse:WH_0042", "commodity_category": "laboratory_reagents", "year": 2022, "month": 7 }
true
tool
explain_issue
T281
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'uid': 'national_CMS:WH_0081'}) -> [] Q: does WH_0081 at the national_CMS currently have any active stockouts? A:
FACTS: no active stockouts (uid=national_CMS:WH_0081) RECOMMENDATION: nothing urgent here.
not sure, you'd have to check the system yourself
1
0.666667
[]
{ "uid": "national_CMS:WH_0081" }
false
tool
stockouts
T60
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'compare_by': 'warehouse_level', 'compare_values': ['district_store', 'regional_warehouse']}) -> {'_grouped_by': 'warehouse_level', 'groups': {'district_stor...
FACTS: kpis by warehouse_level: district_store: avg inventory accuracy 26.8%, avg fulfilment 30.2%, 38 months w/ stockout; regional_warehouse: avg inventory accuracy 57.1%, avg fulfilment 53.5%, 29 months w/ stockout RECOMMENDATION: review the district_store group first - most months with a stockout.
FACTS: kpis by warehouse_level: district_store: avg inventory accuracy 26.8%, avg fulfilment 30.2%, 38 months w/ stockout; regional_warehouse: avg inventory accuracy 57.1%, avg fulfilment 53.5%, 29 months w/ stockout RECOMMENDATION: Not sure. (Not enough information) FACTS: kpis by warehouse_level: district_store: avg ...
0.971429
0.733333
{ "_grouped_by": "warehouse_level", "groups": { "district_store": { "n_records": 66, "avg_inventory_accuracy_pct": 26.8, "avg_order_fulfilment_rate_pct": 30.2, "months_with_stockout": 38, "issue_counts": { "theft_pilferage": 6, "expired_stock": 6, "stock_rec...
{ "compare_by": "warehouse_level", "compare_values": [ "district_store", "regional_warehouse" ] }
false
tool
kpis
T244
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'national_CMS:WH_0009'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 81.8, 'avg_order_fulfilment_rate_pct': 89.7, 'months_with_stockout': 0, 'is...
FACTS: WH_0009 (national_CMS): avg inventory accuracy 81.8%, avg fulfilment 89.7%, 0 months w/ stockout (based on 1 records) RECOMMENDATION: looks fine.
FACTS: looks fine.
1
0.857143
{ "n_records": 1, "avg_inventory_accuracy_pct": 81.8, "avg_order_fulfilment_rate_pct": 89.7, "months_with_stockout": 0, "issue_counts": {}, "uid": "national_CMS:WH_0009", "warehouse_id": "WH_0009", "warehouse_level": "national_CMS" }
{ "uid": "national_CMS:WH_0009" }
false
tool
kpis
T387
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({'uid': 'regional_warehouse:WH_0021'}) -> [{'uid': 'regional_warehouse:WH_0021', 'warehouse_id': 'WH_0021', 'warehouse_level': 'regional_warehouse', 'co...
FACTS: 3 backordered records (uid=regional_warehouse:WH_0021). worst: WH_0021 (regional_warehouse, PPE_IPC_supplies) at 65.0% backorder rate RECOMMENDATION: expedite WH_0021 (regional_warehouse).
FACTS: 3 backordered records (uid=regional_warehouse:WH_0021). worst: WH_0021 (regional_warehouse, PPE_IPC_supplies) at 65.0% backorder rate RECOMMENDATION: Not sure. (Not enough information) FACTS: to repeat, the figure is 3. Again, 3 is the number.
0.97619
0.785714
[ { "uid": "regional_warehouse:WH_0021", "warehouse_id": "WH_0021", "warehouse_level": "regional_warehouse", "commodity_category": "PPE_IPC_supplies", "orders_backordered": 13, "backorder_rate_pct": 65 }, { "uid": "regional_warehouse:WH_0021", "warehouse_id": "WH_0021", "wareho...
{ "uid": "regional_warehouse:WH_0021" }
false
tool
backorders
T290
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'national_CMS:WH_0011', 'commodity_category': 'nutrition_commodities', 'year': 2022, 'month': 4}) -> {'status': 'ok', 'uid': 'national_CMS:WH...
FACTS: WH_0011 (national_CMS, 4/2022): reported issue = dispatch_error. other signals: FEFO compliance failed; low inventory accuracy (75.0%) RECOMMENDATION: address the reported issue (dispatch_error).
FACTS: WH_0011 (national_CMS, 4/2022): reported issue = dispatch_error. other signals: FEFO compliance failed; low inventory accuracy (75.0%) RECOMMENDATION: Not sure. (Not enough information to determine)
1
0.809524
{ "status": "ok", "uid": "national_CMS:WH_0011", "warehouse_id": "WH_0011", "warehouse_level": "national_CMS", "year": 2022, "month": 4, "reported_issue": "dispatch_error", "has_issue": true, "signals": [ "FEFO compliance failed", "low inventory accuracy (75.0%)" ] }
{ "uid": "national_CMS:WH_0011", "commodity_category": "nutrition_commodities", "year": 2022, "month": 4 }
false
tool
explain_issue
T231
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'uid': 'national_CMS:WH_0078'}) -> [] Q: does WH_0078 at the national_CMS currently have any active stockouts? A:
FACTS: no active stockouts (uid=national_CMS:WH_0078) RECOMMENDATION: nothing urgent here.
FACTS: no active stockouts (uid=national_CMS:WH_0078) RECOMMENDATION: Not sure about that - would need to check the system for more detail.
1
0.857143
[]
{ "uid": "national_CMS:WH_0078" }
false
tool
stockouts
T381
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'uid': 'regional_warehouse:WH_0017'}) -> [{'uid': 'regional_warehouse:WH_0017', 'warehouse_id': 'WH_0017', 'warehouse_level': 'regional_warehouse', 'com...
FACTS: 1 active stockouts (uid=regional_warehouse:WH_0017). worst: WH_0017 (regional_warehouse, medical_devices_consumables), 12 facilities hit RECOMMENDATION: prioritize WH_0017 (regional_warehouse) first.
FACTS: 1 active stockouts (uid=regional_warehouse:WH_0017). worst: WH_0017 (regional_warehouse, medical_devices_consumables), 12 facilities hit RECOMMENDATION: Not sure. To get more information, I would need to check further. FACTS: to repeat, the figure is 1. Again, 1 is the number.
1
0.809524
[ { "uid": "regional_warehouse:WH_0017", "warehouse_id": "WH_0017", "warehouse_level": "regional_warehouse", "commodity_category": "medical_devices_consumables", "facilities_affected_by_stockout": 12 } ]
{ "uid": "regional_warehouse:WH_0017" }
false
tool
stockouts
T30
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({'compare_by': 'warehouse_level', 'compare_values': ['district_store', 'regional_warehouse']}) -> {'_grouped_by': 'warehouse_level', 'groups': {'distric...
FACTS: backorders by warehouse_level: district_store: worst WH_0067 (surgical_supplies) at 100.0%, 2 orders; regional_warehouse: worst WH_0054 (laboratory_reagents) at 92.3%, 12 orders RECOMMENDATION: expedite the district_store group first - highest backorder rate.
FACTS: backorders by warehouse_level: regional_warehouse: worst WH_0054 (laboratory_reagents) at 92.3%, 12 orders RECOMMENDATION: expedite the district_store group first - highest backorder rate.
1
0.928571
{ "_grouped_by": "warehouse_level", "groups": { "district_store": [ { "uid": "district_store:WH_0067", "warehouse_id": "WH_0067", "warehouse_level": "district_store", "commodity_category": "surgical_supplies", "orders_backordered": 2, "backorder_rate_pct": 1...
{ "compare_by": "warehouse_level", "compare_values": [ "district_store", "regional_warehouse" ] }
false
tool
backorders
T332
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({'uid': 'regional_warehouse:WH_0037'}) -> [{'uid': 'regional_warehouse:WH_0037', 'warehouse_id': 'WH_0037', 'warehouse_level': 'regional_warehouse', 'co...
FACTS: 1 backordered records (uid=regional_warehouse:WH_0037). worst: WH_0037 (regional_warehouse, ARVs) at 47.1% backorder rate RECOMMENDATION: expedite WH_0037 (regional_warehouse).
FACTS: 1 backordered records (uid=regional_warehouse:WH_0887). worst: WH_0887 (regional_warehouse, ARVs) at 47.1% backorder rate RECOMMENDATION: expedite WH_0887 (regional_warehouse).
0.97619
0.809524
[ { "uid": "regional_warehouse:WH_0037", "warehouse_id": "WH_0037", "warehouse_level": "regional_warehouse", "commodity_category": "ARVs", "orders_backordered": 8, "backorder_rate_pct": 47.1 } ]
{ "uid": "regional_warehouse:WH_0037" }
false
tool
backorders
T241
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'uid': 'national_CMS:WH_0009'}) -> [] Q: does WH_0009 at the national_CMS currently have any active stockouts? A:
FACTS: no active stockouts (uid=national_CMS:WH_0009) RECOMMENDATION: nothing urgent here.
not sure, you'd have to check the system yourself
1
0.666667
[]
{ "uid": "national_CMS:WH_0009" }
false
tool
stockouts
T98
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'district_store:WH_0017'}) -> [{'uid': 'district_store:WH_0017', 'warehouse_id': 'WH_0017', 'warehouse_level': 'district_store', 'commodity_c...
FACTS: top shortage risk (uid=district_store:WH_0017) is WH_0017 (district_store, nutrition_commodities), score=7.0, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_medium'] RECOMMENDATION: focus replenishment planning on WH_0017 (district_store).
FACTS: top shortage risk (uid=district_store:WH_0017) is WH_0017 (district_store, nutrition_commodities), score=7.0, factors=['high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_medium'] Not sure about the rest of the details. RECOMMENDATION: focus replenishment planning on WH_00...
0.971429
0.828571
[ { "uid": "district_store:WH_0017", "warehouse_id": "WH_0017", "warehouse_level": "district_store", "commodity_category": "nutrition_commodities", "risk_score": 7, "risk_factors": [ "high_backorder_rate", "low_fulfilment", "high_wastage", "storage_inadequate", "c...
{ "uid": "district_store:WH_0017" }
false
tool
shortage_risk
T323
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'regional_warehouse:WH_0009'}) -> [{'uid': 'regional_warehouse:WH_0009', 'warehouse_id': 'WH_0009', 'warehouse_level': 'regional_warehouse', ...
FACTS: top shortage risk (uid=regional_warehouse:WH_0009) is WH_0009 (regional_warehouse, essential_medicines), score=11.0, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate', 'criticality_high'] RECOMMENDATION: focus replenishment planning on WH_0009 (regional_warehouse)...
FACTS: focus replenishment planning on WH_0009 (regional_warehouse).
0.971429
0.914286
[ { "uid": "regional_warehouse:WH_0009", "warehouse_id": "WH_0009", "warehouse_level": "regional_warehouse", "commodity_category": "essential_medicines", "risk_score": 11, "risk_factors": [ "stockout", "high_backorder_rate", "low_fulfilment", "high_wastage", "stor...
{ "uid": "regional_warehouse:WH_0009" }
false
tool
shortage_risk
T144
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'district_store:WH_0099'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 42.5, 'avg_order_fulfilment_rate_pct': 24.2, 'months_with_stockout': 1, '...
FACTS: WH_0099 (district_store): avg inventory accuracy 42.5%, avg fulfilment 24.2%, 1 months w/ stockout (based on 1 records), issues on record: {'receiving_error': 1} RECOMMENDATION: worth a review.
FACTS: WH_0099 (district_store): avg inventory accuracy 42.5%, avg fulfilment 24.2%, 1 months w/ stockout (based on 1 records), issues on record: {'receiving_error': 1} Not sure about the rest of the details. RECOMMENDATION: worth a review.
1
0.857143
{ "n_records": 1, "avg_inventory_accuracy_pct": 42.5, "avg_order_fulfilment_rate_pct": 24.2, "months_with_stockout": 1, "issue_counts": { "receiving_error": 1 }, "uid": "district_store:WH_0099", "warehouse_id": "WH_0099", "warehouse_level": "district_store" }
{ "uid": "district_store:WH_0099" }
false
tool
kpis
T176
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: stockouts({'uid': 'district_store:WH_0011'}) -> [] Q: does WH_0011 at the district_store currently have any active stockouts? A:
FACTS: no active stockouts (uid=district_store:WH_0011) RECOMMENDATION: nothing urgent here.
not sure, you'd have to check the system yourself
1
0.666667
[]
{ "uid": "district_store:WH_0011" }
false
tool
stockouts
T67
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'warehouse_level': 'district_store'}) -> {'dominant_issue': 'theft_pilferage', 'count': 6, 'n_records': 66, 'issue_counts': {'theft_pilferage': 6, '...
FACTS: most common issue (warehouse_level=district_store): theft_pilferage (6 of 66 records) RECOMMENDATION: investigate theft_pilferage as the top recurring issue.
FACTS: most common issue (warehouse_level=district_store): theft_pilferage (6 of 66 records) RECOMMENDATION: Not sure. (Not enough information to determine) FACTS: to repeat, the figure is 6. Again, 6 is the number.
1
0.809524
{ "dominant_issue": "theft_pilferage", "count": 6, "n_records": 66, "issue_counts": { "theft_pilferage": 6, "expired_stock": 6, "stock_record_discrepancy": 6, "temperature_excursion": 6, "FEFO_not_followed": 6, "damaged_goods": 6, "overstocking": 6, "receiving_error": 6, "und...
{ "warehouse_level": "district_store" }
false
tool
explain_issue
T352
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: backorders({'uid': 'regional_warehouse:WH_0042'}) -> [{'uid': 'regional_warehouse:WH_0042', 'warehouse_id': 'WH_0042', 'warehouse_level': 'regional_warehouse', 'co...
FACTS: 1 backordered records (uid=regional_warehouse:WH_0042). worst: WH_0042 (regional_warehouse, laboratory_reagents) at 75.0% backorder rate RECOMMENDATION: expedite WH_0042 (regional_warehouse).
not sure, you'd have to check the system yourself
0.97619
0.666667
[ { "uid": "regional_warehouse:WH_0042", "warehouse_id": "WH_0042", "warehouse_level": "regional_warehouse", "commodity_category": "laboratory_reagents", "orders_backordered": 12, "backorder_rate_pct": 75 } ]
{ "uid": "regional_warehouse:WH_0042" }
false
tool
backorders
T46
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'compare_by': 'region_type', 'compare_values': ['peri_urban', 'rural']}) -> {'_grouped_by': 'region_type', 'groups': {'rural': [{'uid': 'district_st...
FACTS: shortage risk by region_type: peri_urban: top risk WH_0087 (vaccines), score=11.5; rural: top risk WH_0028 (vaccines), score=11.5 RECOMMENDATION: focus replenishment planning on the rural group first - highest risk score.
FACTS: shortage risk by region_type: peri_urban: top risk WH_0087 (vaccines), score=11.5; rural: top risk WH_0028 (vaccines), score=11.5 RECOMMENDATION: Not sure. (Not enough information to determine)
1
0.809524
{ "_grouped_by": "region_type", "groups": { "rural": [ { "uid": "district_store:WH_0028", "warehouse_id": "WH_0028", "warehouse_level": "district_store", "commodity_category": "vaccines", "risk_score": 11.5, "risk_factors": [ "stockout", ...
{ "compare_by": "region_type", "compare_values": [ "peri_urban", "rural" ] }
false
tool
shortage_risk
T228
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: shortage_risk({'uid': 'national_CMS:WH_0003'}) -> [{'uid': 'national_CMS:WH_0003', 'warehouse_id': 'WH_0003', 'warehouse_level': 'national_CMS', 'commodity_categor...
FACTS: top shortage risk (uid=national_CMS:WH_0003) is WH_0003 (national_CMS, medical_devices_consumables), score=9.5, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate'] RECOMMENDATION: focus replenishment planning on WH_0003 (national_CMS).
FACTS: top shortage risk (uid=national_CMS:WH_0895) is WH_0895 (national_CMS, medical_devices_consumables), score=9.5, factors=['stockout', 'high_backorder_rate', 'low_fulfilment', 'high_wastage', 'storage_inadequate'] RECOMMENDATION: focus replenishment planning on WH_0895 (national_CMS). FACTS: top shortage risk (uid...
0.971429
0.752381
[ { "uid": "national_CMS:WH_0003", "warehouse_id": "WH_0003", "warehouse_level": "national_CMS", "commodity_category": "medical_devices_consumables", "risk_score": 9.5, "risk_factors": [ "stockout", "high_backorder_rate", "low_fulfilment", "high_wastage", "storage...
{ "uid": "national_CMS:WH_0003" }
false
tool
shortage_risk
T145
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'uid': 'district_store:WH_0099', 'commodity_category': 'controlled_substances', 'year': 2024, 'month': 7}) -> {'status': 'ok', 'uid': 'district_stor...
FACTS: WH_0099 (district_store, 7/2024): reported issue = receiving_error. other signals: storage conditions not adequate; FEFO compliance failed; low inventory accuracy (42.5%); high wastage (32.1%); active stockout (note: report not submitted, numbers may be provisional) RECOMMENDATION: address the reported issue (re...
FACTS: address the reported issue (receiving_error).
1
0.742857
{ "status": "ok", "uid": "district_store:WH_0099", "warehouse_id": "WH_0099", "warehouse_level": "district_store", "year": 2024, "month": 7, "reported_issue": "receiving_error", "has_issue": true, "signals": [ "storage conditions not adequate", "FEFO compliance failed", "low inventory accu...
{ "uid": "district_store:WH_0099", "commodity_category": "controlled_substances", "year": 2024, "month": 7 }
true
tool
explain_issue
T214
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: kpis({'uid': 'national_CMS:WH_0050'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 72.2, 'avg_order_fulfilment_rate_pct': 74.1, 'months_with_stockout': 0, 'is...
FACTS: WH_0050 (national_CMS): avg inventory accuracy 72.2%, avg fulfilment 74.1%, 0 months w/ stockout (based on 1 records), issues on record: {'damaged_goods': 1} RECOMMENDATION: looks fine.
FACTS: WH_0050 (national_CMS): avg inventory accuracy 72.2%, avg fulfilment 74.1%, 0 months w/ stockout (based on 1 records), issues on record: {'damaged_goods': 1} RECOMMENDATION: Not sure. To get more information, I would need to check further.
1
0.857143
{ "n_records": 1, "avg_inventory_accuracy_pct": 72.2, "avg_order_fulfilment_rate_pct": 74.1, "months_with_stockout": 0, "issue_counts": { "damaged_goods": 1 }, "uid": "national_CMS:WH_0050", "warehouse_id": "WH_0050", "warehouse_level": "national_CMS" }
{ "uid": "national_CMS:WH_0050" }
false
tool
kpis
T76
You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up. tool call: explain_issue({'compare_by': 'warehouse_level', 'compare_values': ['district_store', 'regional_warehouse']}) -> {'_grouped_by': 'warehouse_level', 'groups': {'dist...
FACTS: most common issue by warehouse_level: district_store: theft_pilferage (6x); regional_warehouse: stock_record_discrepancy (6x) RECOMMENDATION: focus on the district_store group's most common issue first.
FACTS: most common issue by warehouse_level: district_store: theft_pilferage (6x); regional_warehouse: stock_record_discrepancy (6x) RECOMMENDATION: Not sure. (Not enough information to determine) FACTS: most common issue by warehouse_level: district_store: theft_pilferage (6x); regional_warehouse: stock_record_discrep...
0.821429
0.583333
{ "_grouped_by": "warehouse_level", "groups": { "district_store": { "dominant_issue": "theft_pilferage", "count": 6, "n_records": 66, "issue_counts": { "theft_pilferage": 6, "expired_stock": 6, "stock_record_discrepancy": 6, "temperature_excursion": 6, ...
{ "compare_by": "warehouse_level", "compare_values": [ "district_store", "regional_warehouse" ] }
false
tool
explain_issue
End of preview. Expand in Data Studio

Warehouse Short-Order DPO Preference Pairs

Dataset Description

This dataset contains {prompt, chosen, rejected} preference pairs for training a warehouse short-order assistant with Direct Preference Optimization (DPO). Each pair asks a real warehouse-inventory question (stockout risk, backorders, KPI summaries, why a warehouse is failing fulfillment - at a single-warehouse, tier, region, or dataset-wide comparison level) grounded in real tool-call output, alongside a chosen response and a rejected response.

This is a derived work. The underlying warehouse facts (ids, quantities, categories, issue codes) come entirely from electricsheepafrica/warehouse-inventory-management (CC BY 4.0). The chosen/rejected response pairs themselves are not LLM-generated or collected from human annotators - they're built programmatically: chosen is constructed directly from real tool-call output (get_stockouts, get_warehouse_kpis, etc. run against the source data), and rejected is the same text with one or more deliberate flaws injected (a wrong warehouse id, a corrupted number, an invented category, an unwarranted hedge on a fully-answerable question, a degenerate repeated/looping response, or similar). See Preference Construction below for exactly how each pair was labeled, and Code for where every step of this actually happens.

Code

Full source: github.com/EnsiyehRaoufi/DPO-Warehouse

Three files are required to reproduce this dataset - it's a real dependency chain, not one standalone script:

file role
data_utils.py loads the source CSVs, and the underlying tool functions (get_stockouts, get_backorders, rank_shortage_risk, get_kpis/get_warehouse_kpis, get_dominant_issue/explain_inventory_issue) that return real, grounded values
assistant.py answer() formats real tool output into the chosen text; break_it()/_break() is where every rejected-generation flaw mode lives
gen_pairs.py build_prompts() generates the questions, gen_pair() calls into the two files above per prompt, label_pairs() scores both candidates (via score()) and assigns chosen/rejected

run.py orchestrates the full pipeline (data load -> prompts -> pairs -> DPO training -> eval) end to end; see the repo's README.md for exact run instructions and RUBRIC.md for the full scoring-dimension definitions referenced below.

Source Data

Source dataset electricsheepafrica/warehouse-inventory-management
Source license CC BY 4.0
Source files used warehouse_district_store.csv, warehouse_national_central_medical_store.csv, warehouse_regional_warehouse.csv (one per warehouse tier)
Source size ~30,000 rows across 297 unique warehouses (99 warehouse ids x 3 tiers)
This dataset's size 400 preference pairs, built from a 210-row stratified sample of the source (see the companion source-data card, linked below, for exactly how that sample is built)

Known source-data gotcha, carried into this dataset's scope/tool_out fields: warehouse_id (e.g. WH_0009) is not globally unique in the source data - it's reused identically across all 3 tier files, so WH_0009 in district_store and WH_0009 in national_CMS are two different physical warehouses with different attributes (verified: 137 sqm vs. 3440 sqm). This dataset resolves that with a uid field ({warehouse_level}:{warehouse_id}), which is the real unique key used everywhere internally - never the bare warehouse_id alone.

Dataset Structure

Data Fields

Each line of dpo_pairs.jsonl or eval_pairs.jsonl is one preference pair (records.jsonl, also included in this repo, is a different schema entirely - see "Included Support File" below):

field type description
qid string unique id for this prompt (e.g. "T89")
prompt string the full prompt sent to the model - a fixed system instruction, a tool call: <intent>(<scope>) -> <real tool output> context string, and the question
chosen string the higher-scoring of the two candidate responses (see Preference Construction)
rejected string the lower-scoring candidate
chosen_score / rejected_score float (0-1) the two candidates' scores under the project's 7-dimension rubric, equally weighted across all 7 (full definitions in RUBRIC.md)
tool_out object the real tool-call output (numbers/ids) this prompt is grounded in - used at evaluation time to re-check any model's response against ground truth
scope object the warehouse/filter/compare scope this prompt targets, e.g. {"uid": "district_store:WH_0065"}, {"warehouse_level": "national_CMS"}, or {"compare_by": "region_type", "compare_values": [...]}
uncertain bool whether the ground truth for this prompt genuinely has missing/provisional data. used two ways: to judge whether hedging language in a response is appropriate, and to decide whether the unwarranted-hedge negative examples (see Preference Construction) apply - those are only generated when this is false, i.e. real data was actually available
family string "tool" (a full tool-call answer) or "field" (a single-field lookup) - all 400 pairs in the default 210-row sample run are "tool"; "field" pairs (qids prefixed S) only appear as a fallback if more prompts are requested than this generation scheme produces
intent string which tool/question type this is: kpis, explain_issue, stockouts, backorders, or shortage_risk

Example Record

{
  "qid": "T89",
  "prompt": "You're a warehouse assistant. Answer using only the data given. Separate FACTS from RECOMMENDATION. Say if you're not sure. Don't make stuff up.\n\ntool call: kpis({'uid': 'district_store:WH_0065'}) -> {'n_records': 1, 'avg_inventory_accuracy_pct': 10.0, 'avg_order_fulfilment_rate_pct': 24.6, 'months_with_stockout': 0, 'issue_counts': {'FEFO_not_followed': 1}, 'uid': 'district_store:WH_0065', 'warehouse_id': 'WH_0065', 'warehouse_level': 'district_store'}\n\nQ: how is WH_0065 at the district_store doing overall?\nA:",
  "chosen": "FACTS: WH_0065 (district_store): avg inventory accuracy 10.0%, avg fulfilment 24.6%, 0 months w/ stockout (based on 1 records), issues on record: {'FEFO_not_followed': 1}\nRECOMMENDATION: looks fine.",
  "rejected": "FACTS: WH_0065 (district_store): avg inventory accuracy 25.8%, avg fulfilment 24.6%, 0 months w/ stockout (based on 1 records), issues on record: {'FEFO_not_followed': 1}\nRECOMMENDATION: looks fine.\nFACTS: WH_0065 (district_store): avg inventory accuracy 25.8%, avg fulfilment 24.6%, 0 months w/ stockout (based on 1 records), issues on record: {'FEFO_not_followed': 1}\nRECOMMENDATION: looks fine.",
  "chosen_score": 1.0,
  "rejected_score": 0.9286,
  "tool_out": {"n_records": 1, "avg_inventory_accuracy_pct": 10.0, "avg_order_fulfilment_rate_pct": 24.6, "months_with_stockout": 0, "issue_counts": {"FEFO_not_followed": 1}, "uid": "district_store:WH_0065", "warehouse_id": "WH_0065", "warehouse_level": "district_store"},
  "scope": {"uid": "district_store:WH_0065"},
  "uncertain": false,
  "family": "tool",
  "intent": "kpis"
}

Note this specific rejected example shows two flaws compounded onto one response, not just one: a corrupted number (10.0% -> 25.8%) plus the entire FACTS/RECOMMENDATION block repeated verbatim (a degenerate looping flaw). This is deliberate, not a bug - see Preference Construction below for why looping/redundancy flaws are only ever added on top of an already-substantive flaw like this one, never alone.

Splits

400 total pairs, split 340 train / 60 eval (an 85/15 split - the eval split is never seen during DPO training; it's scored before and after training to measure improvement). Provided as two separate files: dpo_pairs.jsonl (train) and eval_pairs.jsonl (eval).

Distribution by Intent

Uniform across all 5 intents, by design - each gets the same 16 fixed structural prompts (unscoped, tier filter, region filter, tier/region compare-all, tier/region compare-named) plus 64 single-warehouse prompts, drawn from one shared, stratified sample of warehouses (not picked independently per intent) that maximizes both tier and real issue-type variety - see the source-data card for how that sample is built.

intent count
kpis 80
explain_issue 80
stockouts 80
backorders 80
shortage_risk 80

Included Support File: records.jsonl

This repo also includes records.jsonl - the 210 raw, normalized warehouse records the pairs above were generated from. This is not a new or independently-sampled file - it's the exact same content published standalone as EnRaoufi/warehouse-inventory-stratified-sample, re-uploaded here for a practical reason specific to this project's evaluation design, not because it's a different dataset: the evaluation script (eval_model.py) needs the underlying records themselves - not just the per-pair tool_out already embedded above - to build the real, valid sets of commodity categories, issue reason codes, and tier/region labels it checks model responses against, and to score tool-selection accuracy. Without it, evaluation can still run but skips those checks. Including it here means this repo alone is enough to run training and evaluation end to end, without also needing to fetch the source-data card separately.

For the schema, and the stratified-sampling method used to build it in the first place, see that source data card directly - it isn't repeated here.

Preference Construction

No human annotators and no LLM were used to generate or label candidates. For each prompt:

  1. chosen is built by calling the real tool function against the source data, then formatting the real output into a FACTS: ...\nRECOMMENDATION: ... template.
  2. rejected is the same chosen text with one or more deliberate flaws injected, drawn from 14 distinct modes (plus a generic fallback) covering every one of the 7 scoring dimensions (full list and design rationale for each in RUBRIC.md/README.md) - including fabricated warehouse ids, corrupted numbers, invented categories/reasons/tiers/regions, dropped or mislabeled comparison groups, and a degenerate repeated/looping response. a structural-only flaw (looping or redundant repetition) is never the SOLE reason a response is rejected - it's only ever added on top of an already-substantive flaw, at a capped rate, so structure alone can't account for the whole gap between chosen and rejected. Specifically for prompts where the ground truth data genuinely IS available (uncertain: false), one of three distinct unwarranted-hedge shapes may also be injected: a generic refusal, the real facts kept intact but the recommendation hedges anyway, or a hedge phrase embedded within the facts themselves - weighted toward whichever shape best matches real observed model failures.
  3. Both candidates are scored with the same 7 rubric dimensions used for evaluation (grounding against tool_out, structural quality, appropriate uncertainty, and freedom from fabricated ids/categories/reasons/tiers/regions), combined with equal weighting across all 7 to decide chosen/rejected. A separate, differently-weighted aggregate (operational_quality counted less heavily) is used only for the before/after comparison in the project's evaluation reports - not for labeling these pairs. Whichever candidate scores higher under the equal weighting becomes chosen; by construction this is almost always the real, uncorrupted answer.

Considerations

  • Synthetic preferences, not human feedback. This is a stand-in for human preference labeling - useful for a small-scale DPO demonstration, but the "preferences" reflect a fixed rubric's judgment, not real human raters. Don't treat chosen/rejected as ground truth for what a human would actually prefer.
  • Reflects the source data's real-world limitations, including whatever collection/coverage gaps exist in electricsheepafrica/warehouse-inventory-management itself. This dataset does not independently verify the source CSVs' accuracy.
  • Small scale. 400 pairs is enough for a demonstration DPO run on a small model, not a production-scale preference dataset.

Related Datasets

Licensing and Attribution

This dataset is a derivative of electricsheepafrica/warehouse-inventory-management, licensed CC BY 4.0 by Electric Sheep Africa. In keeping with that license's attribution requirement, this derived dataset is released under the same license, CC BY 4.0. The code that generates it (linked above) is separately licensed Apache-2.0, per the GitHub repository's LICENSE file.

Attribution: Warehouse facts derived from electricsheepafrica/warehouse-inventory-management (Electric Sheep Africa), https://huggingface.co/datasets/electricsheepafrica/warehouse-inventory-management, licensed CC BY 4.0.

Citation

@misc{warehouse_dpo_pairs,
  title = {Warehouse Short-Order DPO Preference Pairs},
  author = {Raoufi, Ensiyeh},
  note = {Derived from electricsheepafrica/warehouse-inventory-management (CC BY 4.0). Code: https://github.com/EnsiyehRaoufi/DPO-Warehouse},
  howpublished = {\url{https://huggingface.co/datasets/EnRaoufi/warehouse-dpo-preference-pairs}}
}

Source dataset citation:

@dataset{warehouse_inventory_management,
  author = {Electric Sheep Africa},
  title = {warehouse-inventory-management},
  publisher = {Hugging Face},
  howpublished = {\url{https://huggingface.co/datasets/electricsheepafrica/warehouse-inventory-management}}
}
Downloads last month
54