Skip to main content
Glama

Borrow and deposit math

morpho_loop
Read-onlyIdempotent

Work out the net result over a year of borrowing USDG against a stock token on Morpho and putting it in a USDG vault, and the price at which the loan would be liquidated. A calculation at current rates, not advice: nothing is built or sent.

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": {
      "ticker": "<ticker>",
      "usd": "<usd>"
    },
    "name": "morpho_loop"
  }
}

Input Schema

NameRequiredDescriptionDefault
usdYesDollars of the stock token used as collateral.
tickerYesTicker of the stock token to borrow against, like NVDA.
borrow_pctNoUSDG to borrow, as a percent of the collateral value. Must stay below the market’s LLTV. 50 by default.

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 establish readOnly, idempotent, non-destructive behavior, and the description reinforces that with 'nothing is built or sent.' It adds real value beyond the annotations by disclosing the time horizon (one year) and the two outputs produced: net result and liquidation price.

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?

Two sentences, front-loaded with the core action and followed by the important non-advice/no-side-effect caveat. The first sentence is somewhat long with chained clauses, but every clause carries necessary scope information, so little 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 no output schema, the description does the needed work of naming what comes back (annual net result and liquidation price) for a read-only simulation tool with fully documented parameters. It leaves some modeling assumptions unstated but is sufficient for an agent to select and call it correctly.

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 all three parameters (usd, ticker, borrow_pct, including the LLTV constraint and default) are already documented. The prose only alludes to the collateral/borrow concepts already in the schema and adds no new format or constraint detail, so baseline 3 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?

The description names a specific verb ('work out') and a concrete resource set: a year-long loop of borrowing USDG against a stock token, depositing into a USDG vault, plus the resulting liquidation price. That scope clearly separates it from siblings like build_morpho_deposit (which constructs something) and morpho_rates (which only reports rates).

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?

It gives a strong implicit routing signal: 'A calculation at current rates, not advice: nothing is built or sent,' which tells the agent this is for what-if analysis rather than executing a position. It stops short of naming the build/execute sibling explicitly, so the exclusion is inferable rather than stated.

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.

Resources