Skip to main content
Glama

pyeconomics

Cost of capital and beta

corporate_cost_of_capital
Read-onlyIdempotent

CAPM, WACC with preferred equity, Hamada unlevering/relevering, and country risk premium. Runs Cost of capital and beta (corporate.cost_of_capital, version 1) on the given inputs and returns its canonical result: the validated inputs, the outputs, the warnings and the manifest. The required calculation field selects one of: capm, country_risk_premium, relever_beta, unlever_beta, wacc. Every number carries its unit in the input schema; rates are decimals.

Input Schema

NameRequiredDescriptionDefault

No arguments

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/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 is covered; the description adds real context by stating the response envelope (validated inputs, outputs, warnings, manifest) and the critical convention that rates are decimals. It does not discuss validation failures or how warnings should be interpreted, so it stops short of a 5.

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?

Capabilities are front-loaded in the first sentence, followed by the execution/return contract and the mode list. The middle sentence is somewhat boilerplate ("version 1", "its canonical result"), but every sentence carries information and nothing is redundant with the schema.

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 a full output schema, 100% parameter coverage and explicit annotations, the description supplies everything needed to call the tool correctly. The only unstated detail is that fields outside the selected calculation variant are rejected (additionalProperties: false), which could cause an agent to over-send parameters.

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, but the description adds two genuinely useful signals: the calculation field is required and acts as the mode selector across the five variants, and all numeric units/decimals are declared in the schema. That unit-convention note is the kind of clarification the schema alone (x-unit keys) does not spell out in prose.

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?

Opens with the specific models covered (CAPM, WACC with preferred equity, Hamada unlevering/relevering, country risk premium) and names the five calculation modes the discriminator accepts. An agent can tell this is a corporate cost-of-capital calculator, distinct from the equity, derivatives and fixed-income siblings, 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 Guidelines3/5

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

Usage is implied rather than stated: the agent learns which calculation values exist, but not when to pick this tool over e.g. run_model or describe_model, and there are no exclusions or prerequisites. The mode enumeration does implicitly route the agent to the right sub-calculation, which keeps it above a 2.

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.