Documentation Index
Fetch the complete documentation index at: https://docs.heychocolate.com/llms.txt
Use this file to discover all available pages before exploring further.
The Comparison module enables side-by-side evaluation of products or scenarios on sustainability parameters. Ideal for product detail pages, procurement tools, and decision-support interfaces.
Comparing products
query {
compareProducts(
productIds: ["prod_abc123", "prod_def456", "prod_ghi789"]
metrics: [CO2_EQUIVALENT, MKI_SCORE, WATER_FOOTPRINT]
) {
products {
id
name
sectorTag
scores {
metric
value
unit
rank
}
}
winner {
metric
productId
productName
}
summary {
bestOverall
description
}
}
}
Response:
{
"data": {
"compareProducts": {
"products": [
{
"id": "prod_abc123",
"name": "Standard Window Frame",
"sectorTag": "HIGHTECH_MANUFACTURING",
"scores": [
{ "metric": "CO2_EQUIVALENT", "value": 24.8, "unit": "kg_co2e", "rank": 3 },
{ "metric": "MKI_SCORE", "value": 1.74, "unit": "EUR", "rank": 3 },
{ "metric": "WATER_FOOTPRINT", "value": 320, "unit": "liters", "rank": 2 }
]
},
{
"id": "prod_def456",
"name": "Bio-based Window Frame",
"sectorTag": "HIGHTECH_MANUFACTURING",
"scores": [
{ "metric": "CO2_EQUIVALENT", "value": 12.4, "unit": "kg_co2e", "rank": 1 },
{ "metric": "MKI_SCORE", "value": 0.87, "unit": "EUR", "rank": 1 },
{ "metric": "WATER_FOOTPRINT", "value": 280, "unit": "liters", "rank": 1 }
]
}
],
"winner": [
{ "metric": "CO2_EQUIVALENT", "productId": "prod_def456", "productName": "Bio-based Window Frame" },
{ "metric": "MKI_SCORE", "productId": "prod_def456", "productName": "Bio-based Window Frame" }
]
}
}
}
Comparing scenarios
Compare multiple what-if scenarios against a baseline:
query {
compareScenarios(input: {
baseProductId: "prod_abc123"
quantity: 100
scenarios: [
{ name: "Current", overrides: [] },
{ name: "Bio-based", overrides: [{ parameter: MATERIAL, value: "bio_based" }] },
{ name: "Recycled", overrides: [{ parameter: RECYCLED_CONTENT, value: "80" }] }
]
metrics: [CO2_EQUIVALENT, MKI_SCORE]
}) {
scenarios {
name
scores { metric value unit }
deltaFromBaseline { metric percentageChange }
}
}
}
Available comparison metrics
| Metric | Description | Unit |
|---|
CO2_EQUIVALENT | Total greenhouse gas emissions | kg CO2e |
MKI_SCORE | Environmental cost indicator | EUR |
WATER_FOOTPRINT | Total water consumption | liters |
ENERGY_USE | Total energy consumption | kWh |
RECYCLED_CONTENT | Percentage of recycled material | % |
TRANSPORT_IMPACT | Transport-related emissions only | kg CO2e |
CIRCULARITY_SCORE | Product circularity rating | 0-100 |
Use cases
- Product detail pages: “Compare with similar products” widget
- MKI marketplace: Side-by-side comparison like Insert Marktplaats
- Procurement: Evaluate supplier alternatives on sustainability
- Reporting: Benchmark products against industry averages