LlamaRisk

Overview

Function index8 functions

This section documents the externally callable contracts configured or invoked directly by the Pendle PT implementation. Chainlink infrastructure and the Aave contracts that receive an approved action remain documented by their respective projects.

AbstractCreReceiver is inherited by the router, so its workflow-authentication functions appear in the router reference rather than on a separate page.

PT implementation contracts

PTParameterRegistry

Stores the governed parameters shared by the three PT workflows. Each PT address maps to an enable flag, model version, EMA controls, discount deviation threshold, risk-model reference multiplier, and eligible eMode IDs.

The registry uses two-step ownership and a separate updater role for day-to-day parameter changes. See the PTParameterRegistry reference and Parameters and configuration.

LlamaguardRiskOracleRouter

Routes the market-state record into LlamaGuardOracle and the two executable recommendation types into BGD's RiskOracle. The recommendation routes may invoke their AgentHub execution paths; the EMA route does not. Route controls include enablement, publication selector, minimum delay, scalar maximum step, and report age.

See the LlamaguardRiskOracleRouter reference.

Oracle stores

LlamaGuardOracle

Stores EmaImpliedRateUpdate, including its PT market key, smoothed values, source provenance, and publication deadline. The downstream workflows use its latest accepted record as shared state.

See the LlamaGuardOracle reference.

RiskOracle

Stores executable PendleDiscountRateUpdate and EModeCategoryUpdate recommendations. It authorizes publishers and update types, maintains history, and exposes the latest record by type and market.

See the RiskOracle reference.

Execution components

AgentHub

Coordinates registered Aave agents. It tracks whether an agent is enabled, its minimum delay, and the last update injected for a market.

See the AgentHub reference.

RangeValidationModule

Defines directional maximum increases and decreases. A range can be absolute or relative, and a market-specific range can override the default for an update type.

The workflows read these ranges before publication so their recommendation is already inside the active execution envelope. The agent validates again on-chain.

See the RangeValidationModule reference.

AaveDiscountRateAgent

Consumes PendleDiscountRateUpdate. It validates the typed scalar recommendation and applies it to the PT price-cap adapter resolved through Aave's oracle configuration.

See the AaveDiscountRateAgent reference.

AaveEModeAgent

Consumes EModeCategoryUpdate, decodes (LTV, LT, LB), validates the Aave parameter invariants, and applies the category collateral configuration.

See the AaveEModeAgent reference.

Publication and failure behavior

StageFailure behavior
CRE identity validationRevert before routing
Router replay or throttle validationRevert before publication
RiskOracle publicationRevert the router transaction
AgentHub check or executionEmit failure while preserving the accepted recommendation

The stored update therefore remains inspectable and can be reconsidered by the execution system even when the first AgentHub attempt does not change Aave.

See Architecture and safety for the reusable responsibilities and Update schemas for the exact PT payloads.

On this page