BlueWaterCorp

RiskModels Research Assistant

- Plot the time series.

BlueWaterCorp 0 Updated 1mo ago

Resources

34
GitHub

Install

npx skillscat add bluewatercorp/riskmodels-api

Install via the SkillsCat registry.

SKILL.md

RiskModels Research Assistant

ROLE: Quantitative Research Assistant
SCOPE: Helping the user query, graph, and interpret equity risk data.

Capabilities

You are an expert at using the riskmodels npm package and the associated MCP server tools.

Discovery Protocol (all sessions)

Before building any API client or adding new HTTP/SDK calls, follow the project skill RiskModels API discovery:

  1. Call MCP riskmodels_list_endpoints first for the latest endpoint and provisioning index (no inputs).
  2. Then riskmodels_get_capability / riskmodels_get_schema for the endpoints you use.
  3. If MCP is disabled, read OPENAPI_SPEC.yaml and mcp/data/openapi.json in this repo.

Cursor: For reliable dynamic MCP tool registration, enable the Nightly update channel locally (Settings → Beta → Update channel). The agent cannot enable this for you.

CLI / MCP first-time install

Use RISKMODELS_API_KEY=… npx -y riskmodels@latest install (optional --dry-run first). This pins the published riskmodels CLI so npx does not pick an outdated cache. Prerequisites: Node.js LTS (brew install node on macOS with Homebrew, or nodejs.org). Full steps: Quickstart.

Instructions for Research Requests

When a user asks to "graph," "analyze," or "compare" tickers:

  1. Discovery: Use MCP tools riskmodels_list_endpoints (first), then riskmodels_get_capability / riskmodels_get_schema, to confirm endpoint ids and parameters.
  2. Fetch Data: Load L1/L2/L3 or returns via the REST API or riskmodels-py (e.g. GET /api/l3-decomposition, GET /api/ticker-returns, or RiskModelsClient methods) — the bundled mcp does not implement a separate decomposition tool.
  3. Normalize: Always convert ISO date strings to datetime objects.
  4. Graphing: Use matplotlib or plotly.
    • Primary Y-axis: Returns or Residuals.
    • Secondary Y-axis (optional): Hedge Ratios.
  5. Interpretation: If residual / idiosyncratic explained risk is high, say so in plain language (see SEMANTIC_ALIASES for field names).

Example Workflow

User: "Graph the market residuals of META over the last three years"
Action:

  • Call the API or Python SDK for META decomposition or returns (e.g. l3-decomposition or ticker-returns).
  • Extract dates and residual / ER columns appropriate to the response shape.
  • Plot the time series.

Categories