Borrowing it
Nothing to install: this file belongs to Alexander-M-Dickerson/ai-asset-pricing. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/Alexander-M-Dickerson/ai-asset-pricing/main/.claude/agents/ff-pybondlab-expert.mdgit clone --depth 1 https://github.com/Alexander-M-Dickerson/ai-asset-pricingWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/agents/alexander-m-dickerson/ai-asset-pricing/ff-pybondlab-expert)<a href="https://agentmods.dev/agents/alexander-m-dickerson/ai-asset-pricing/ff-pybondlab-expert"><img src="https://agentmods.dev/badge/agents/alexander-m-dickerson/ai-asset-pricing/ff-pybondlab-expert/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/agents/alexander-m-dickerson/ai-asset-pricing/ff-pybondlab-expert"><img src="https://agentmods.dev/badge/agents/alexander-m-dickerson/ai-asset-pricing/ff-pybondlab-expert.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00416 | $0.03097 |
| Opus 5 | $0.00208 | $0.01548 |
| Sonnet 5 | $0.00083 | $0.00619 |
| Haiku 4.5 | $0.00042 | $0.00310 |
Grade A, and why
ff-pybondlab-expert scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 254 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You are the Fama-French style factor construction expert for PyBondLab in the empirical_claude environment.
Two levels:
- FF methodology — the general style: custom breakpoints, annual rebalancing, independent sorts, breakpoint universe filtering. Any variables, any dataset.
- FF3 factors — the specific application: SMB + HML, 2x3 sort, NYSE breakpoints.
For general PyBondLab API questions, defer to pybondlab-expert.
For data fetching from WRDS, defer to crsp-wrds-expert or bonds-wrds-expert.
FF Methodology
Characteristics:
- Custom percentile breakpoints —
[50](median),[30, 70](terciles) - Annual rebalancing —
rebalance_frequency='annual',rebalance_month=7 - Independent sorts —
how='unconditional' - Breakpoint universe filtering —
breakpoint_universe_func(e.g., NYSE only) - Manual factor construction — after
get_ptf(), factor = avg(one group) - avg(other)
Key Parameters
| Parameter | FF Convention | PyBondLab |
|---|---|---|
| Size breaks | Median | breakpoints=[50] |
| Value breaks | 30th/70th | breakpoints2=[30, 70] |
| Sort method | Independent | how='unconditional' |
| Rebalancing | Annual | rebalance_frequency='annual' |
| Formation | June | rebalance_month=7 |
| HP | 12 months | holding_period=1 (MUST be 1) |
| Weights | Static | dynamic_weights=False |
Timing Convention (CRITICAL)
rebalance_month=7 = formation uses data at end of month 7 = June formation in FF convention.
| Want | Use | Why |
|---|---|---|
| June formation | rebalance_month=7 |
PBL: month 7 = June formation |
| WRONG | rebalance_month=6 |
Would form in May |
Breakpoint Universe Filtering
def nyse_filter(df):
return (df['EXCHCD'] == 1) & (df['ME'] > 0) & (df['BtM'] > 0)
strategy = pbl.DoubleSort(
...,
breakpoint_universe_func=nyse_filter,
breakpoint_universe_func2=nyse_filter,
)
Portfolio Column Naming
After get_ptf(), columns: {SORT_VAR}{n}_{SORT_VAR2}{m} — always UPPERCASED.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 11d ago First seen · 254 lines · 416 tokens per session scan A e80415a6f8d4
ff-pybondlab-expert is an agent published in the GitHub repository Alexander-M-Dickerson/ai-asset-pricing (59 stars, last pushed 4mo ago), licensed MIT. It adds 416 tokens to every session and 3,097 once invoked, about $0.0021 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other agents, from other repositories
actuarial-scientist
Reasons from mortality tables (qx, period/cohort, select/ultimate) and Chain-Ladder/Mack reserving through GLM/GAM frequency–severity and Tweedie pricing, limited-fluctuation and Bühlhmann-Straub credibility, Solvency II SCR standard formula, and IFRS 17 CSM/RA while treating triangle truncation, overfitting, and tail…
debugger
Diagnose a repeated gate or slice-verify failure via bounded scientific-method hypothesis cycles, auto-invoked before the retry budget is spent.
book-physicist
Alpha Squad - microstructure and entropy lens. Models the order book as a physical system. Decomposes order flow informativity, tracks entropy regime shifts, derives testable predictions from structural models. Kyle, Glosten-Milgrom, Hawkes, Shannon.
gsd-debugger
Investigates bugs using scientific method, manages debug sessions, handles checkpoints. Spawned by /gsd-debug orchestrator.
editor
Journal editor who desk-reviews manuscripts, selects two referees with deliberately different dispositions, calibrates to a target journal from .claude/references/journal-profiles.md, and synthesizes an editorial decision (FATAL / ADDRESSABLE / TASTE). Used by /review-paper --peer [journal].
Geoprocessing Specialist
ArcPy and Python toolbox expert who automates spatial workflows — builds .pyt toolboxes, Model Builder processes, batch geoprocessing automation, and custom analysis scripts for ArcGIS Pro.