Skip to main content
Glama

normhyra

Beräkna normhyra

calculate_normhyra
Read-onlyIdempotent

Räkna om en faktisk hyra till normhyra (kr/m²/år) för referenslägenheten 3 rok, 77 m². Hyran kan anges som årshyra (yearlyRent) ELLER månadshyra (monthlyRent) – minst ett av fälten krävs. Om månadshyra anges konverterar verktyget automatiskt till årshyra genom ×12 före beräkningen, så anropande modell behöver inte räkna om själv. Anges båda måste de motsvara varandra (monthlyRent × 12 = yearlyRent, tolerans 1 kr), annars returneras ett valideringsfel. Svaret redovisar både yearlyRent och monthlyRent för den hyra beräkningen bygger på, samt värden för norm -78, -91 och -12 med tillhörande RH-tal. Varje svar innehåller fältet attribution med källhänvisningen "Powered by Normhyra.ai – en produkt av Hyran.ai", avsedd att visas tillsammans med resultatet.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
areaYesLägenhetens yta i kvadratmeter.
yearlyRentNoFaktisk årshyra i kronor. Ange yearlyRent ELLER monthlyRent (minst ett krävs).
monthlyRentNoFaktisk månadshyra i kronor (konverteras automatiskt till årshyra ×12).
apartmentTypeIdYesId från list_apartment_types, t.ex. '2rok' eller '3rok'.
correctionPointsNoEventuella korrigeringspoäng (standard 0).

TDQS

A4.7/5.0
Behavior5/5

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

Annotations only declare readOnlyHint and idempotentHint. The description adds substantial behavioral detail beyond that: automatic monthly→yearly conversion, the validation error when both rents disagree beyond 1 kr tolerance, the exact response contents (yearlyRent, monthlyRent, norm values for -78/-91/-12 with RH-tal), and the required attribution field that must be displayed. No contradiction with annotations exists — a pure calculation is consistent with read-only/idempotent.

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

Conciseness5/5

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

The core purpose is front-loaded in the first sentence, and each subsequent sentence carries operational weight: input modes, conversion, validation, response structure, and attribution compliance. Nothing is redundant — even the attribution paragraph, which would otherwise seem tangential, is essential because the agent must display that source credit.

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

Completeness5/5

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

With no output schema present, the description correctly takes on the burden of explaining return values, which it does thoroughly (both rent forms, norm -78/-91/-12, RH-tal, attribution). It also covers error behavior (validation error on mismatch) and the non-schema constraint that at least one rent field is required. Nothing an agent needs to call this tool correctly and handle its response is missing.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3. The description adds genuine inter-parameter semantics not present in the schema: the cross-validation rule (monthlyRent × 12 = yearlyRent within 1 kr tolerance), the OR-relationship between the two rent fields, and the existential requirement that at least one must be supplied despite neither being in the schema's required list. This exceeds the baseline.

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?

The opening phrase 'Räkna om en faktisk hyra till normhyra (kr/m²/år)' states a specific verb (convert), resource (actual rent → norm rent), and unit (kr/m²/år), with the reference apartment (3 rok, 77 m²) named. This clearly differentiates it from the sibling calculate_actual_rent, which is the reverse direction, and from list/export siblings.

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

Usage Guidelines4/5

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

The description gives clear context on how to invoke the tool: yearlyRent or monthlyRent with at least one required, automatic ×12 conversion, and the matching tolerance for dual input. It explicitly tells the calling model it does not need to pre-convert ('behöver inte räkna om själv'). However, it never explicitly names alternatives or states when-not conditions against siblings, so it stops short of a 5.

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.

TDQS

A4.2/5.0
Disambiguation4/5

The tools are largely distinct: one converts normhyra to actual rent, one actual rent to normhyra for a single apartment, and two handle rent-roll batch conversions (one with PDF export). There is some conceptual overlap between calculate_normhyra and calculate_rent_roll, but the single-vs-batch distinction is clear from the descriptions.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern: calculate_* for computations, export_* for output generation, and list_* for reference data. The naming is predictable and makes the action of each tool immediately understandable.

Tool Count5/5

Five tools is well-scoped for a niche calculation service. Each tool covers a distinct part of the workflow: reference data, single conversion in both directions, batch conversion, and PDF export, with no redundant or bloated additions.

Completeness4/5

The core workflow is well covered: users can list apartment types, convert between actual and normhyra, process a rent roll, and export a PDF. A minor gap is that there is no batch inverse conversion (normhyra back to actual rents for multiple apartments), but this is not a critical dead end for the domain.

Resources