Skip to main content
Glama

Score opportunity

score_opportunity
Read-onlyIdempotent

Compute the full multi-factor risk-adjusted score for a single opportunity from list_yields.

Chain: pass list_yields opportunities[].id as poolId, opportunityId, or id (same DefiLlama pool UUID; id is the canonical list field).

Returns APY breakdown (base/reward/total), factor scores with rationales, net yield after gas/bridge, exitRisk heuristic (TVL vs notional + liq conf only; medium ≠ small pool; not queues/caps/transfer whitelist/eligibility/on-chain withdraw; do not treat low as free exit when knownIssues mention transfer/eligibility), warnings, and sources. sourceChainKey is ethereum|base|arbitrum only — unknown keys (foo, solana) are VALIDATION_ERROR; no invented bridge fee.

Research estimates only — non-custodial.

Example (any one id field): { "id": "43641cf5-a92e-416b-bce9-27113d3c0db6", "horizonDays": 30, "notionalUsd": 10000 } Also accepts poolId or opportunityId with the same value.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoSame as list_yields opportunities[].id (canonical response field name).
poolIdNoAlias for list_yields opportunities[].id (historical tool field). Same DefiLlama pool UUID. Example: "43641cf5-a92e-416b-bce9-27113d3c0db6"
horizonDaysNoHolding horizon in days for gas/bridge amortization (default 30). Example: 30
notionalUsdNoNotional USD size for net-yield cost amortization and exitRisk TVL multiples (default 10000). Example: 10000
opportunityIdNoAlias for list_yields opportunities[].id (same pool key as poolId / id).
sourceChainKeyNoAgent's current chain for bridge cost estimate: ethereum | base | arbitrum (aliases: eth, ETH, Ethereum, arb, ARB, BASE). Blank/whitespace is VALIDATION_ERROR (omit the field to default). Unknown keys (solana, foo) return VALIDATION_ERROR — no invented bridge fee.

TDQS

A4.7/5.0
Behavior5/5

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

The description discloses return details (APY breakdown, factor scores, net yield, exitRisk heuristic with constraints, warnings, sources) and error conditions (sourceChainKey unknown keys return VALIDATION_ERROR, no invented bridge fee). It also states 'Research estimates only — non-custodial', adding trust context. This goes well beyond the readOnlyHint/idempotentHint annotations.

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?

The description is well-structured with clear sections (purpose, chaining, returns, example) and packs essential details. It is slightly verbose due to repeated constraints (e.g., sourceChainKey rules appear in both description and schema), but the redundancy is minimal and serves emphasis.

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?

The description covers inputs (with aliases and defaults), outputs (detailed return components), error conditions, and caveats (research estimates, non-custodial). It even provides an example call. Given the complexity and lack of an output schema, this is comprehensively complete.

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

Parameters5/5

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

The schema descriptions are already detailed, but the overall description adds extra meaning: for poolId/opportunityId it clarifies they are aliases for the same canonical id, and for sourceChainKey it reiterates the valid values and error behavior. The example ties parameters together. This exceeds the baseline of 3 for high schema coverage.

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 explicitly states the tool computes a multi-factor risk-adjusted score for a single opportunity from list_yields. It clearly distinguishes from siblings like compare_opportunities (single vs. compare) and explain_score (compute vs. explain). The verb 'Compute' and resource 'multi-factor risk-adjusted score' are specific.

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 indicates this is for a single opportunity and provides chaining guidance (pass list_yields opportunities[].id). It does not explicitly state when not to use it versus alternatives like compare_opportunities, but the context of 'single' and the return type make the usage reasonably clear. An explicit when-not would earn 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 mostly distinct: list_yields for ranking, score_opportunity for detailed scoring of one, explain_score for explaining a score, compare_opportunities for side-by-side comparison, get_protocol_risk for protocol-level risk, and health for connectivity. However, score_opportunity and explain_score have overlapping purposes (both return factor scores and rationale), which could cause some confusion, though they serve different output formats.

Naming Consistency4/5

The naming pattern is mostly consistent using verb_noun (e.g., list_yields, get_protocol_risk, explain_score, compare_opportunities, score_opportunity). One deviation: 'health' is a single-word name that breaks the verb_noun pattern, but it's a minor deviation and still readable.

Tool Count5/5

With 6 tools, this is well-scoped for a yield research server. Each tool has a distinct role: listing, scoring, explaining, comparing, protocol risk, and health check. The count feels appropriate for the domain, not overly heavy or thin.

Completeness3/5

The server covers core research needs: listing opportunities, detailed scoring, explanation, comparison, protocol risk, and health check. However, there are some minor gaps: no direct way to filter by specific pool ID without first listing, no tool to get historical trends or detailed market info beyond the scoring. But the domain is research-only non-custodial, so a full CRUD lifecycle isn't expected; still, a tool to fetch specific opportunity details without scoring could be missing.