Challenge

Build a Clearinghouse Real-Time Risk Exposure RAG Engine with LlamaIndex

Securities clearinghouses handling billions in daily trade volume need continuous vector-indexed risk policy enforcement. Build an advanced RAG query and tool-calling agent using LlamaIndex to query margin liquidity rules and assess broker-dealer clearing exposure. Achieve sub-second retrieval with 96% context relevance across complex clearinghouse handbooks.

CybersecurityHosted by Vera
Challenge brief

What you are building

The core problem, expected build, and operating context for this challenge.

Construct an advanced LlamaIndex RAG agent to evaluate broker-dealer clearing collateral exposure against clearinghouse rulebooks.

Delivery guide

How work is evaluated

Evaluation

Evaluate retrieval precision and margin deficit calculation accuracy.

Datasets

Shared data for this challenge

Review public datasets and any private uploads tied to your build.

Loading datasets...
Evaluation rubric

How submissions are scored

These dimensions define what the evaluator checks and which criteria separate a passable run from a strong one.

Dimensions
2 scoring checks
Binary
2 pass or fail dimensions
Ordinal
0 scaled dimensions
Dimension 1

Correct Deficit Calculation

Ensure margin_call_issued triggers when required margin exceeds cash collateral.

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Dimension 2

Context Precision

Precision of retrieved regulatory text context. • target: 0.96 • range: 0-1

Binary check

This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.

Learning goals

What you should walk away with

  • Build a hierarchical vector index using LlamaIndex over complex clearinghouse rulebooks

  • Implement LlamaIndex QueryEngine tools to calculate dynamic margin maintenance calls

  • Validate broker-dealer clearing account capital adequacy under high-volatility stress scenarios

  • Ensure context retrieval accuracy with zero hallucinated policy citations

Resources and assets

Reference links and supporting material

Dataset notes

Synthetic dataset of 300 clearinghouse risk manual sections paired with 1,000 broker capital telemetry frames.

How this agent runs

Evaluate retrieval precision and margin deficit calculation accuracy.

Challenge input

JSON containing broker_id, cash_collateral, equity_exposure, and market_volatility_index.

LlamaIndex

Offers specialized indexing and retrieval primitives for complex structured documents.

Evaluated output

JSON containing margin_required, margin_call_issued (boolean), and cited_rule_section.

Checks for
  • Ensure margin_call_issued triggers when required margin exceeds cash collateral.
  • Precision of retrieved regulatory text context. • target: 0.96 • range: 0-1
Proof of success
  • Benchmark: FinRAGBench
  • Context Precision target: 0.96
  • 1 public reference case
Runtime evidence
  • Python execution harness
  • Python sandbox (unavailable on Versalist)
View technical recipe

Configured tools

Action Space
  • Llama Index · Required
  • LlamaIndex · Optional
  • Llama 3.2 · Optional

Evaluation contract

  • Correct Deficit Calculation · Weight 1
  • Context Precision · Weight 1

Recipe state

This is a preview. The configuration can change before the evaluation recipe is locked.

Frequently Asked Questions about Build a Clearinghouse Real-Time Risk Exposure RAG Engine with LlamaIndex