Skip to main content
Glama

Boncourant

Analyser une facture résidentielle

analyze_bill
Read-onlyIdempotent

Évalue une facture résidentielle déjà extraite (extract_energy_document) ; sans facture, appelez simulate. Recommandation prospective, pas contrôle des lignes facturées : verdict stay/switch, jamais une offre plus chère que le contrat actuel.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "conso_annuelle_kwh": "<conso_annuelle_kwh>",
      "puissance_kva": "<puissance_kva>",
      "postal_code": "<postal_code>"
    },
    "name": "analyze_bill"
  }
}

Input Schema

NameRequiredDescriptionDefault
optionNoOption tarifaire, comme retournée par extract_energy_document.
postal_codeYesCode postal du logement ; demandez-le, ne l'inventez jamais.
conso_kwh_hcNokWh annuels en heures creuses ; requis pour hp_hc.
conso_kwh_hpNokWh annuels en heures pleines ; requis pour hp_hc.
current_offerNoOffre actuelle, si connue.
puissance_kvaYesPuissance souscrite en kVA.
current_supplierNoFournisseur actuel, si connu.
conso_annuelle_kwhYesConsommation annuelle en kWh, mesurée ou déclarée.
current_annual_cost_eurNoCoût annuel TTC actuel en euros, sur la même consommation.

Output Schema

NameRequiredDescriptionDefault
reasonNoSi grounded=false : aucun montant calculé.
sourcesNoSources publiques datées, à citer.
groundedNo
next_stepNo
confidenceNo
provenanceNo
referencesNo
assumptionsNo
alternativesNo
generated_atNo
baseline_kindNo
uncertaintiesNo
recommendationNo
trv_annual_eurNo
catalog_versionNo
offers_comparedNo
confidence_scaleNo
best_market_offerNo
option_comparisonNo
recommended_offerNo
simulator_versionNo
annual_savings_eurNo
calculation_statusNo
recommended_optionNo
baseline_annual_eurNo
recommended_supplierNo
recommended_annual_eurNo
current_contract_annual_eurNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedOutput schema / $schema
      Added value: +"https://json-schema.org/draft/2020-12/schema"
    • changedOutput schema / additionalProperties
      Previous value: -trueNew value: +{}
    • addedOutput schema / properties
      Added value: +{
      +  "alternatives": {
      +    "items": {
      +      "additionalProperties": {},
      +      "properties": {},
      +      "type": "object"
      +    },
      +    "type": "array"
      +  },
      +  "annual_savings_eur": {
      +    "anyOf": [
      +      {
      +        "type": "number"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "assumptions": {
      +    "items": {},
      +    "type": "array"
      +  },
      +  "baseline_annual_eur": {
      +    "anyOf": [
      +      {
      +        "type": "number"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "baseline_kind": {
      +    "anyOf": [
      +      {
      +        "enum": [
      +          "current_contract",
      +          "declared_contract",
      +          "trv",
      +          "trve",
      +          "none"
      +        ],
      +        "type": "string"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "best_market_offer": {
      +    "additionalProperties": {},
      +    "properties": {},
      +    "type": "object"
      +  },
      +  "calculation_status": {
      +    "anyOf": [
      +      {
      +        "enum": [
      +          "verified",
      +          "estimated",
      +          "needs_confirmation"
      +        ],
      +        "type": "string"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "catalog_version": {
      +    "type": "string"
      +  },
      +  "confidence": {
      +    "anyOf": [
      +      {
      +        "type": "number"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "confidence_scale": {
      +    "additionalProperties": {},
      +    "properties": {},
      +    "type": "object"
      +  },
      +  "current_contract_annual_eur": {
      +    "anyOf": [
      +      {
      +        "type": "number"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "generated_at": {
      +    "type": "string"
      +  },
      +  "grounded": {
      +    "type": "boolean"
      +  },
      +  "next_step": {
      +    "additionalProperties": {},
      +    "properties": {},
      +    "type": "object"
      +  },
      +  "offers_compared": {
      +    "anyOf": [
      +      {
      +        "type": "number"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "option_comparison": {
      +    "items": {},
      +    "type": "array"
      +  },
      +  "provenance": {
      +    "anyOf": [
      +      {
      +        "additionalProperties": {},
      +        "properties": {},
      +        "type": "object"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "reason": {
      +    "description": "Si grounded=false : aucun montant calculé.",
      +    "type": "string"
      +  },
      +  "recommendation": {
      +    "enum": [
      +      "stay",
      +      "switch"
      +    ],
      +    "type": "string"
      +  },
      +  "recommended_annual_eur": {
      +    "anyOf": [
      +      {
      +        "type": "number"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "recommended_offer": {
      +    "anyOf": [
      +      {
      +        "type": "string"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "recommended_option": {
      +    "anyOf": [
      +      {
      +        "type": "string"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "recommended_supplier": {
      +    "anyOf": [
      +      {
      +        "type": "string"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "references": {
      +    "items": {
      +      "type": "string"
      +    },
      +    "type": "array"
      +  },
      +  "simulator_version": {
      +    "type": "string"
      +  },
      +  "sources": {
      +    "description": "Sources publiques datées, à citer.",
      +    "items": {
      +      "additionalProperties": {},
      +      "properties": {
      +        "data_as_of": {
      +          "anyOf": [
      +            {
      +              "type": "string"
      +            },
      +            {
      +              "type": "null"
      +            }
      +          ]
      +        },
      +        "id": {
      +          "type": "string"
      +        },
      +        "note": {
      +          "type": "string"
      +        },
      +        "publisher": {
      +          "type": "string"
      +        },
      +        "title": {
      +          "type": "string"
      +        },
      +        "url": {
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "id",
      +        "publisher",
      +        "title",
      +        "url",
      +        "data_as_of"
      +      ],
      +      "type": "object"
      +    },
      +    "type": "array"
      +  },
      +  "trv_annual_eur": {
      +    "anyOf": [
      +      {
      +        "type": "number"
      +      },
      +      {
      +        "type": "null"
      +      }
      +    ]
      +  },
      +  "uncertainties": {
      +    "items": {
      +      "type": "string"
      +    },
      +    "type": "array"
      +  }
      +}
  2. Changed1 schema field changed
    • changedInput schema / properties / postal_code / description
      Previous value: -"Code postal français."New value: +"Code postal du logement ; demandez-le, ne l'inventez jamais."
  3. Changed9 schema fields changed
    • changedInput schema / properties / conso_annuelle_kwh / description
      Previous value: -"Consommation annuelle en kWh, mesurée ou explicitement déclarée."New value: +"Consommation annuelle en kWh, mesurée ou déclarée."
    • changedInput schema / properties / conso_kwh_hc / description
      Previous value: -"Consommation annuelle en heures creuses en kWh ; requise pour hp_hc."New value: +"kWh annuels en heures creuses ; requis pour hp_hc."
    • changedInput schema / properties / conso_kwh_hp / description
      Previous value: -"Consommation annuelle en heures pleines en kWh ; requise pour hp_hc."New value: +"kWh annuels en heures pleines ; requis pour hp_hc."
    • changedInput schema / properties / current_annual_cost_eur / description
      Previous value: -"Coût annuel TTC du contrat actuel en euros, sur la même consommation que la comparaison."New value: +"Coût annuel TTC actuel en euros, sur la même consommation."
    • changedInput schema / properties / current_offer / description
      Previous value: -"Nom de l’offre actuelle, si connu."New value: +"Offre actuelle, si connue."
    • changedInput schema / properties / current_supplier / description
      Previous value: -"Fournisseur du contrat actuel, si connu."New value: +"Fournisseur actuel, si connu."
    • changedInput schema / properties / option / description
      Previous value: -"Option tarifaire canonique : base, hp_hc ou tempo ; la même valeur est retournée par extract_energy_document."New value: +"Option tarifaire, comme retournée par extract_energy_document."
    • changedInput schema / properties / postal_code / description
      Previous value: -"Code postal français à cinq chiffres, fourni par le client."New value: +"Code postal français."
    • changedInput schema / properties / puissance_kva / description
      Previous value: -"Puissance souscrite du compteur en kVA."New value: +"Puissance souscrite en kVA."
  4. Changed24 schema fields changed
    • addedInput schema / $schema
      Added value: +"https://json-schema.org/draft/2020-12/schema"
    • changedInput schema / properties / conso_annuelle_kwh / description
      Previous value: -"Consommation annuelle en kWh (lue sur la facture)"New value: +"Consommation annuelle en kWh, mesurée ou explicitement déclarée."
    • addedInput schema / properties / conso_annuelle_kwh / exclusiveMinimum
      Added value: +0
    • addedInput schema / properties / conso_annuelle_kwh / maximum
      Added value: +1000000
    • changedInput schema / properties / conso_kwh_hc / description
      Previous value: -"Consommation en heures creuses (kWh), si option HP/HC"New value: +"Consommation annuelle en heures creuses en kWh ; requise pour hp_hc."
    • addedInput schema / properties / conso_kwh_hc / minimum
      Added value: +0
    • changedInput schema / properties / conso_kwh_hp / description
      Previous value: -"Consommation en heures pleines (kWh), si option HP/HC"New value: +"Consommation annuelle en heures pleines en kWh ; requise pour hp_hc."
    • addedInput schema / properties / conso_kwh_hp / minimum
      Added value: +0
    • changedInput schema / properties / current_annual_cost_eur / description
      Previous value: -"Coût annuel TTC du contrat actuel en euros (facultatif) — sert de référence pour l'économie"New value: +"Coût annuel TTC du contrat actuel en euros, sur la même consommation que la comparaison."
    • addedInput schema / properties / current_annual_cost_eur / exclusiveMinimum
      Added value: +0
    • addedInput schema / properties / current_annual_cost_eur / maximum
      Added value: +10000000
    • changedInput schema / properties / current_offer / description
      Previous value: -"Nom de l'offre actuelle (facultatif)"New value: +"Nom de l’offre actuelle, si connu."
    • addedInput schema / properties / current_offer / maxLength
      Added value: +300
    • addedInput schema / properties / current_offer / minLength
      Added value: +1
    • changedInput schema / properties / current_supplier / description
      Previous value: -"Fournisseur actuel (facultatif)"New value: +"Fournisseur du contrat actuel, si connu."
    • addedInput schema / properties / current_supplier / maxLength
      Added value: +200
    • addedInput schema / properties / current_supplier / minLength
      Added value: +1
    • changedInput schema / properties / option / description
      Previous value: -"Option tarifaire actuelle"New value: +"Option tarifaire canonique : base, hp_hc ou tempo ; la même valeur est retournée par extract_energy_document."
    • changedInput schema / properties / option / enum
      Previous value: -[
      -  "Base",
      -  "HP/HC",
      -  "Tempo"
      -]New value: +[
      +  "base",
      +  "hp_hc",
      +  "tempo"
      +]
    • changedInput schema / properties / postal_code / description
      Previous value: -"Code postal à 5 chiffres"New value: +"Code postal français à cinq chiffres, fourni par le client."
    • addedInput schema / properties / postal_code / pattern
      Added value: +"^\\d{5}$"
    • changedInput schema / properties / puissance_kva / description
      Previous value: -"Puissance souscrite en kVA"New value: +"Puissance souscrite du compteur en kVA."
    • addedInput schema / properties / puissance_kva / exclusiveMinimum
      Added value: +0
    • addedInput schema / properties / puissance_kva / maximum
      Added value: +36
  5. First observed

TDQS

A4.3/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so safety needs no restating. The description adds genuine behavioral content beyond them: the output is a prospective stay/switch verdict constrained so that no offer more expensive than the current contract is ever proposed. It stops short of describing how partial inputs are handled or what the verdict looks like, leaving a small gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

One tight sentence chain with the verb and resource front-loaded, then precondition, fallback, and the behavioral guarantee in priority order. The semicolon-and-colon compression makes it slightly telegraphic to read, but no clause is wasted.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With an output schema, full annotation coverage and 100% schema descriptions, the description carries only what structured fields cannot: the upstream dependency, the no-invoice fallback, and the recommendation framing. That is sufficient for a 9-parameter analysis tool, though it never hints at which inputs drive the verdict's accuracy.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so every parameter (including the hp_hc consumption split and the postal code warning) is already documented in structured form. The description adds no syntax, format, or conditional-requirement detail on top, so the baseline applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

"Évalue une facture résidentielle déjà extraite" states a specific verb and resource, and immediately binds it to the producing sibling (extract_energy_document). The final clause ("Recommandation prospective, pas contrôle des lignes facturées") explicitly separates it from invoice line-audit tools, so an agent can pick it without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives an explicit precondition (an already-extracted invoice), names the alternative to use when that precondition fails ("sans facture, appelez simulate"), and states what the tool does not do (line-by-line verification). When-to-use, when-not-to-use, and the fallback are all present in one sentence.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.