Build an LEI Verification Guardrail using Pydantic AI and GPT-5 Pro
Unassigned Legal Entity Identifier portfolios lead to unmonitored counterparty risk across corporate banking networks. Build a Pydantic AI agent leveraging GPT-5 Pro to audit orphan LEI records, extract corporate hierarchy from filings, and enforce strict Pydantic schema validation. Achieve automated counterparty attribution with greater than 90% coverage and verifiable audit trails.
What you are building
Develop a type-safe Pydantic AI agent application powered by GPT-5 Pro to automate orphan LEI verification and legal structure parsing.
How work is evaluated
Evaluates the Pydantic AI agent's accuracy in identifying orphan LEIs and validating owner hierarchies.
Datasets
Public datasets, plus the private datasets you have access to.
How submissions are scored
pydantic_schema_validation
Ensures response instantiates model without validation errors
This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.
attribution_accuracy
Percentage of correct parent LEI assignments • target: 0.92 • range: 0-1
This dimension contributes its full weight only when the submission satisfies the requirement. Partial credit is not awarded.
Learning goals
Build a Pydantic AI agent with dependency injection for dynamic LEI lookup
Leverage GPT-5 Pro high-reasoning capabilities for complex ownership document parsing
Enforce strict type-safe structured output validation on corporate risk profiles
Generate compliance alert tickets for unowned or expired corporate LEIs
Resources
Dataset of 250 unstructured corporate governance filings with corresponding LEI metadata.
Challenge setup
Evaluates the Pydantic AI agent's accuracy in identifying orphan LEIs and validating owner hierarchies.
Challenge input
JSON object with target_lei, filing_text, registration_date
Pydantic AI
Provides type safety and dynamic context injection for AI agents.
GPT-5 Pro
Delivers context understanding for complex legal document processing.
Evaluated output
JSON matching Pydantic schema with parent_lei, status, audit_pass
- Ensures response instantiates model without validation errors
- Percentage of correct parent LEI assignments • target: 0.92 • range: 0-1
- Benchmark: Corporate KYC Information Extraction Benchmark
- Attribution Accuracy target: 0.92
- 1 public reference case
- Python execution harness
- Python sandbox (unavailable on Versalist)
Shows the first task, up to three tools, and up to three evidence items.
View technical recipe
Configured tools
- Pydantic AI · Required
- GPT-5 Pro · Optional
- GPT-5 · Optional
- Pydantic AI · Required
Evaluation contract
- pydantic_schema_validation · Weight 1
- attribution_accuracy · Weight 1
Metrics
- attribution_accuracy · Target 0.92
Benchmarks
- Corporate KYC Information Extraction Benchmark
- security
Reference cases
- 1 public reference case
Workflow tasks
- Task 1
Input: JSON object with target_lei, filing_text, registration_date
Output: JSON matching Pydantic schema with parent_lei, status, audit_pass
Execution harness: Python
Evaluation tools
- Pydantic AI · Agent Framework
- GPT-5 Pro · High-Reasoning LLM
Recipe freeze marker
No recipe freeze time is recorded.