diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bd99041..648327b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,11 +24,17 @@ jobs: docs-checks: runs-on: ubuntu-latest + env: + CARGO_TERM_COLOR: always + PYO3_USE_ABI3_FORWARD_COMPATIBILITY: "1" steps: - uses: actions/checkout@v4 - uses: oven-sh/setup-bun@v2 with: bun-version: latest + # check:examples cargo-checks every documented Rust example against the + # real crate, so this job needs a toolchain as well as bun. + - uses: dtolnay/rust-toolchain@stable - name: Install docs dependencies run: bun install --frozen-lockfile working-directory: docs-site @@ -44,3 +50,6 @@ jobs: - name: Check content schema run: bun run check:content-schema working-directory: docs-site + - name: Check documented Rust examples compile + run: bun run check:examples + working-directory: docs-site diff --git a/docs-site/astro.config.mjs b/docs-site/astro.config.mjs index 3ba95df..6f923e6 100644 --- a/docs-site/astro.config.mjs +++ b/docs-site/astro.config.mjs @@ -48,9 +48,19 @@ export default defineConfig({ 'katex/dist/katex.min.css', './src/styles/starlight.css', ], + components: { + // Derives each page's status pill from its `status` frontmatter rather + // than from hand-written markup in `banner.content`. + Banner: './src/components/DocStatusBanner.astro', + }, social: [ { icon: 'github', label: 'GitHub', href: 'https://github.com/Open-Quant/openquant' }, ], + // Seven top-level groups. It was twenty, thirteen of them one AFML + // chapter each and five holding a single page, so a reader scrolled past + // a chapter menu to reach Reference, Governance and Coverage. The AFML + // chapters are still here — nested one level inside Modules, where a + // one-page chapter costs a line rather than a heading. sidebar: [ { label: 'Getting Started', @@ -64,144 +74,138 @@ export default defineConfig({ autogenerate: { directory: 'setup' }, }, { - label: 'Core Workflows', + label: 'Workflows', autogenerate: { directory: 'workflows' }, }, - // ── AFML Chapter-based module groups ── - { - label: 'Ch 2: Data Structures', - items: [ - { slug: 'modules/data-structures' }, - { slug: 'modules/filters' }, - { slug: 'modules/etf-trick' }, - ], - }, - { - label: 'Ch 3: Labeling', - items: [ - { slug: 'modules/labeling' }, - { slug: 'modules/bet-sizing' }, - ], - }, - { - label: 'Ch 4: Sample Weights', - items: [ - { slug: 'modules/sampling' }, - { slug: 'modules/sample-weights' }, - { slug: 'modules/sb-bagging' }, - ], - }, { - label: 'Ch 5: Fractional Differentiation', + label: 'Modules', items: [ - { slug: 'modules/fracdiff' }, - ], - }, - { - label: 'Ch 6: Ensemble Methods', - items: [ - { slug: 'modules/ensemble-methods' }, - ], - }, - { - label: 'Ch 7: Cross-Validation', - items: [ - { slug: 'modules/cross-validation' }, - ], - }, - { - label: 'Ch 8: Feature Importance', - items: [ - { slug: 'modules/feature-importance' }, - { slug: 'modules/fingerprint' }, - ], - }, - { - label: 'Ch 9: Hyperparameter Tuning', - items: [ - { slug: 'modules/hyperparameter-tuning' }, - ], - }, - { - label: 'Ch 10–12: Backtesting', - items: [ - { slug: 'modules/backtesting-engine' }, - { slug: 'modules/synthetic-backtesting' }, - ], - }, - { - label: 'Ch 14–15: Diagnostics & Risk', - items: [ - { slug: 'modules/backtest-statistics' }, - { slug: 'modules/risk-metrics' }, - { slug: 'modules/strategy-risk' }, - ], - }, - { - label: 'Ch 16: Portfolio Construction', - items: [ - { slug: 'modules/hrp' }, - { slug: 'modules/hcaa' }, - { slug: 'modules/onc' }, - { slug: 'modules/cla' }, - { slug: 'modules/portfolio-optimization' }, - ], - }, - { - label: 'Ch 17–19: Microstructure & Regimes', - items: [ - { slug: 'modules/structural-breaks' }, - { slug: 'modules/microstructural-features' }, - { slug: 'modules/codependence' }, - ], - }, - { - label: 'Ch 20–22: HPC & Advanced', - items: [ - { slug: 'modules/hpc-parallel' }, - { slug: 'modules/combinatorial-optimization' }, - { slug: 'modules/streaming-hpc' }, - ], - }, - { - label: 'Shared Utilities', - items: [ - { slug: 'modules/ef3m' }, - { slug: 'modules/util-fast-ewma' }, - { slug: 'modules/util-volatility' }, - ], - }, - // ── Python-only modules ── - { - label: 'Python Modules', - items: [ - { slug: 'modules/data' }, - { slug: 'modules/feature-diagnostics' }, - { slug: 'modules/pipeline' }, - { slug: 'modules/research' }, - { slug: 'modules/adapters' }, - { slug: 'modules/viz' }, + { label: 'All Modules', link: '/modules/' }, + { + label: 'Ch 2: Data Structures', + collapsed: true, + items: [ + { slug: 'modules/data-structures' }, + { slug: 'modules/filters' }, + { slug: 'modules/etf-trick' }, + ], + }, + { + label: 'Ch 3: Labeling', + collapsed: true, + items: [ + { slug: 'modules/labeling' }, + { slug: 'modules/bet-sizing' }, + ], + }, + { + label: 'Ch 4: Sample Weights', + collapsed: true, + items: [ + { slug: 'modules/sampling' }, + { slug: 'modules/sample-weights' }, + { slug: 'modules/sb-bagging' }, + ], + }, + { + label: 'Ch 5–7: Features & Validation', + collapsed: true, + items: [ + { slug: 'modules/fracdiff' }, + { slug: 'modules/ensemble-methods' }, + { slug: 'modules/cross-validation' }, + ], + }, + { + label: 'Ch 8–9: Importance & Tuning', + collapsed: true, + items: [ + { slug: 'modules/feature-importance' }, + { slug: 'modules/fingerprint' }, + { slug: 'modules/hyperparameter-tuning' }, + ], + }, + { + label: 'Ch 10–12: Backtesting', + collapsed: true, + items: [ + { slug: 'modules/backtesting-engine' }, + { slug: 'modules/synthetic-backtesting' }, + ], + }, + { + label: 'Ch 14–15: Diagnostics & Risk', + collapsed: true, + items: [ + { slug: 'modules/backtest-statistics' }, + { slug: 'modules/risk-metrics' }, + { slug: 'modules/strategy-risk' }, + ], + }, + { + label: 'Ch 16: Portfolio Construction', + collapsed: true, + items: [ + { slug: 'modules/hrp' }, + { slug: 'modules/hcaa' }, + { slug: 'modules/onc' }, + { slug: 'modules/cla' }, + { slug: 'modules/portfolio-optimization' }, + ], + }, + { + label: 'Ch 17–19: Microstructure & Regimes', + collapsed: true, + items: [ + { slug: 'modules/structural-breaks' }, + { slug: 'modules/microstructural-features' }, + { slug: 'modules/codependence' }, + ], + }, + { + label: 'Ch 20–22: HPC & Advanced', + collapsed: true, + items: [ + { slug: 'modules/hpc-parallel' }, + { slug: 'modules/combinatorial-optimization' }, + { slug: 'modules/streaming-hpc' }, + ], + }, + { + label: 'Shared Utilities', + collapsed: true, + items: [ + { slug: 'modules/ef3m' }, + { slug: 'modules/util-fast-ewma' }, + { slug: 'modules/util-volatility' }, + ], + }, + { + label: 'Python Modules', + collapsed: true, + items: [ + { slug: 'modules/data' }, + { slug: 'modules/feature-diagnostics' }, + { slug: 'modules/pipeline' }, + { slug: 'modules/research' }, + { slug: 'modules/adapters' }, + { slug: 'modules/viz' }, + ], + }, ], }, - // ── Reference ── { label: 'Reference', items: [ - { slug: 'module-reference/api-surfaces' }, { slug: 'module-reference/by-afml-chapter' }, - { slug: 'module-reference/indexing-and-discovery' }, - { label: 'All Modules', link: '/modules/' }, + { slug: 'examples/catalog' }, ], }, { - label: 'Examples', - autogenerate: { directory: 'examples' }, - }, - { - label: 'Governance & Release', + label: 'Governance', autogenerate: { directory: 'governance' }, }, - { label: 'Coverage Dashboard', link: '/coverage/' }, + { label: 'Coverage', link: '/coverage/' }, ], }), ], @@ -210,11 +214,14 @@ export default defineConfig({ '/guides': '/openquant/workflows/rust-core-workflow/', '/tutorials': '/openquant/workflows/python-core-workflow/', '/notebook-research-workflow': '/openquant/workflows/notebook-research-workflow/', - '/api-reference': '/openquant/module-reference/api-surfaces/', + // api-surfaces.md was merged into the module index as 'By language surface'. + '/api-reference': '/openquant/modules/', '/examples': '/openquant/examples/catalog/', // '/modules' intentionally absent: it shadowed the real modules/index.md page // and broke the homepage "Browse Modules" CTA. - '/search': '/openquant/module-reference/indexing-and-discovery/', + // indexing-and-discovery.md described the sidebar; its discovery paths now + // live on the home page. + '/search': '/openquant/', '/publishing': '/openquant/governance/versioning-and-release-policy/', '/performance': '/openquant/governance/benchmark-policy/', '/contributing': '/openquant/governance/support-and-escalation/', diff --git a/docs-site/scripts/check-content-schema.mjs b/docs-site/scripts/check-content-schema.mjs index f332990..33f11bb 100644 --- a/docs-site/scripts/check-content-schema.mjs +++ b/docs-site/scripts/check-content-schema.mjs @@ -74,6 +74,15 @@ function git(args, cwd) { return execFileSync('git', args, { cwd, encoding: 'utf8', stdio: ['ignore', 'pipe', 'pipe'] }); } +/** The checkout root, or null outside a git checkout (a release tarball, say). */ +const repoRoot = (() => { + try { + return git(['rev-parse', '--show-toplevel'], docsRoot).trim(); + } catch { + return null; + } +})(); + /** * Last date each doc actually changed — the newer of its last commit date and, * when the working tree copy differs from HEAD (or is untracked), its filesystem @@ -85,12 +94,17 @@ function git(args, cwd) { */ function lastChangedDates(files) { const dates = new Map(); - const mtimeDay = (file) => fs.statSync(file).mtime.toISOString().slice(0, 10); + // Local civil day, to match git's %cI: an mtime read in UTC would report + // tomorrow's date all evening west of Greenwich and fail every stamp made + // that day. + const mtimeDay = (file) => { + const d = fs.statSync(file).mtime; + return `${d.getFullYear()}-${String(d.getMonth() + 1).padStart(2, '0')}-${String( + d.getDate() + ).padStart(2, '0')}`; + }; - let repoRoot; - try { - repoRoot = git(['rev-parse', '--show-toplevel'], docsRoot).trim(); - } catch { + if (!repoRoot) { // Not a git checkout (a release tarball, say). Fall back to mtime for everything. for (const file of files) dates.set(file, mtimeDay(file)); return dates; @@ -131,6 +145,52 @@ function lastChangedDates(files) { return dates; } +/** A page's prose: everything below the frontmatter. */ +function bodyOf(text) { + return text.replace(/^---\n[\s\S]*?\n---\n?/, ''); +} + +/** + * The day a page's *prose* last changed, ignoring frontmatter-only edits. + * + * A stamp describes the body a human read, not the plumbing around it. Retiring + * a banner slot, adding an `audience` tag or renaming a sidebar key moves the + * file without moving one word a reader sees, and treating that as a content + * change would force a choice between a false re-review and a status downgrade + * — which is how a freshness gate teaches people to lie to it. + * + * Walks the page's history newest-first while the committed body still equals + * the working-tree body; the oldest such commit is when the prose last moved. + * Falls back to `naiveDay` when the body itself is uncommitted or the history + * is unreadable (a shallow clone, a release tarball), so the fallback is always + * the stricter answer. Only called for pages that would otherwise fail, so the + * extra `git show` calls cost nothing on a clean run. + */ +function lastBodyChangeDay(file, repoRoot, naiveDay) { + const rel = path.relative(repoRoot, file); + let log; + try { + log = git(['log', '--format=%H%x00%cI', '--', rel], repoRoot); + } catch { + return naiveDay; + } + const currentBody = bodyOf(fs.readFileSync(file, 'utf8')); + let day = null; + for (const line of log.split('\n')) { + if (!line.trim()) continue; + const [sha, iso] = line.split('\0'); + let text; + try { + text = git(['show', `${sha}:${rel}`], repoRoot); + } catch { + break; + } + if (bodyOf(text) !== currentBody) break; + day = iso.slice(0, 10); + } + return day ?? naiveDay; +} + const files = walk(docsRoot); const changed = lastChangedDates(files); const errors = []; @@ -159,16 +219,6 @@ for (const file of files) { continue; } - // The reader-facing badge is rendered from the page's own banner frontmatter, - // so it can drift from `status` unless something checks. This is that check. - const badge = frontmatter.match(/doc-status--([a-z]+)/)?.[1]; - if (badge && badge !== status) { - fail( - `status: ${status} but the reader-facing badge says '${badge}'. ` + - `Update the banner content so the badge matches the frontmatter status.` - ); - } - // Every date present must be a real ISO date, whether or not this status needs it. for (const field of DATE_FIELDS) { if (field in fm && !parseIsoDate(fm[field])) { @@ -200,7 +250,12 @@ for (const file of files) { // Without this, `status: validated` is just a string anyone can paste, and can // be bulk-applied to a whole corpus — which is exactly how this site ended up // with 59 pages sharing one hardcoded review date. - const changedOn = changed.get(file); + // Frontmatter-only edits do not invalidate a stamp, so a page that looks + // stale gets a second, body-aware reading of its history before it fails. + let changedOn = changed.get(file); + if (changedOn && changedOn > fm[dateField] && repoRoot) { + changedOn = lastBodyChangeDay(file, repoRoot, changedOn); + } if (changedOn && changedOn > fm[dateField]) { const what = status === 'generated' diff --git a/docs-site/scripts/generate-module-doc-pages.mjs b/docs-site/scripts/generate-module-doc-pages.mjs index f3ee94c..78e77bf 100644 --- a/docs-site/scripts/generate-module-doc-pages.mjs +++ b/docs-site/scripts/generate-module-doc-pages.mjs @@ -193,8 +193,6 @@ description: ${q(doc.summary)} status: generated generated_from: src/data/moduleDocs.ts last_generated: '${generatedOn}' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering @@ -211,6 +209,13 @@ ${sections.join('\n\n')} fs.writeFileSync(path.join(outDir, `${doc.slug}.md`), content, 'utf8'); } +// --- Index: the canonical module index ------------------------------------- +// This page is the one index of the 39 modules. It absorbed +// module-reference/api-surfaces.md (the 'By language surface' section below), +// which was a fourth hand-maintained listing of the same modules and had +// already drifted from the data; generating it here means it cannot drift +// again. + // --- Index: grouped by subject --- const bySubject = new Map(); for (const doc of moduleDocs) { @@ -233,14 +238,58 @@ const groupedIndex = [...bySubject.entries()] ) .join('\n\n'); +// --- Index: grouped by language surface --- +// `apiSurface` says which bindings a module is reachable through; `pythonApis` +// entries are namespace-qualified (`bet_sizing.get_signal`), so the Python half +// is grouped by the namespace a reader actually imports. +const rustModules = moduleDocs + .filter((doc) => doc.apiSurface !== 'python-only') + .sort((a, b) => a.module.localeCompare(b.module)); + +const byNamespace = new Map(); +for (const doc of moduleDocs) { + for (const api of doc.pythonApis ?? []) { + const dot = api.lastIndexOf('.'); + const namespace = dot === -1 ? doc.module : api.slice(0, dot); + const entry = byNamespace.get(namespace) || { slug: doc.slug, fns: [] }; + if (entry.slug !== doc.slug) { + throw new Error( + `moduleDocs.ts: python namespace "${namespace}" is claimed by both ` + + `${entry.slug} and ${doc.slug}. The index can only link it to one page — ` + + 'split the namespace or move the APIs onto one module.' + ); + } + entry.fns.push(api.slice(dot + 1)); + byNamespace.set(namespace, entry); + } +} + +const languageIndex = [ + '### Rust core', + '', + rustModules + .map((doc) => `- [\`${doc.module}\`](/modules/${doc.slug}/) — ${doc.summary}`) + .join('\n'), + '', + '### Python namespaces', + '', + [...byNamespace.entries()] + .sort(([a], [b]) => a.localeCompare(b)) + .map( + ([namespace, { slug, fns }]) => + `- [\`${namespace}\`](/modules/${slug}/) — ${[...new Set(fns)] + .map((fn) => `\`${fn}\``) + .join(', ')}` + ) + .join('\n'), +].join('\n'); + const indexContent = `--- title: "Module Reference Index" description: "Full OpenQuant module documentation index with AFML-aligned summaries." status: generated generated_from: src/data/moduleDocs.ts last_generated: '${generatedOn}' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering @@ -248,9 +297,20 @@ sidebar: order: 1 --- -This index contains one page per OpenQuant module with purpose, APIs, formulas, examples, and implementation notes. +This is the canonical index of every OpenQuant module: one page each, with +purpose, APIs, formulas, examples, and implementation notes. It lists the same +39 modules twice over — by subject, and by the language surface they are +reachable through — because those are the two questions readers arrive with. +For the AFML chapter each module implements, see +[By AFML Chapter](/module-reference/by-afml-chapter/). + +## By subject ${groupedIndex} + +## By language surface + +${languageIndex} `; fs.writeFileSync(path.join(outDir, 'index.md'), indexContent, 'utf8'); diff --git a/docs-site/src/components/DocStatusBanner.astro b/docs-site/src/components/DocStatusBanner.astro new file mode 100644 index 0000000..f9de0e4 --- /dev/null +++ b/docs-site/src/components/DocStatusBanner.astro @@ -0,0 +1,74 @@ +--- +/** + * Starlight `Banner` override — renders each page's status pill. + * + * Every doc page declares a `status` in its frontmatter (see + * src/content/config.ts). This component derives the reader-facing badge + * *from* that field, so the pill and the frontmatter cannot disagree: there is + * only one source of truth. It replaces an earlier arrangement in which each + * page hand-wrote the badge markup into `banner.content` and a rule in + * check-content-schema.mjs policed the two for drift. + * + * A page may still set `banner.content` of its own (index.md carries a + * Quickstart call to action); when it does, that text replaces the default + * sentence for the status and sits beside the pill. + * + * The markup is deliberately the same `.sl-banner` element Starlight's own + * Banner emits, so the palette in src/styles/starlight.css -- which keys off + * `.sl-banner:has(.doc-status--*)` and covers light and dark -- applies + * unchanged. + */ +const { entry } = Astro.locals.starlightRoute; +const status = entry.data.status; +const banner = entry.data.banner; + +const LABELS = { + generated: 'Generated', + draft: 'Draft', + reviewed: 'Reviewed', + validated: 'Validated', +}; + +const NOTES = { + generated: + 'Assembled automatically from moduleDocs.ts. No human has reviewed this page.', + draft: 'This page is known to be incomplete. Treat its contents as provisional.', + reviewed: + 'A human has read this page end to end. It has not been verified line by line against the code.', + validated: + 'A human has read this page end to end and checked it against the code.', +}; + +const label = status ? LABELS[status] : undefined; +const note = banner?.content ?? (status ? NOTES[status] : undefined); +--- + +{ + (label || note) && ( +
+ {label && {label}} + {note && } +
+ ) +} + + diff --git a/docs-site/src/content/docs/coverage.md b/docs-site/src/content/docs/coverage.md index 5157079..9b29cc6 100644 --- a/docs-site/src/content/docs/coverage.md +++ b/docs-site/src/content/docs/coverage.md @@ -2,8 +2,6 @@ title: Coverage Dashboard description: What is documented, what is not, and the commands that produce those numbers. status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/examples/catalog.md b/docs-site/src/content/docs/examples/catalog.md index 2bcc6f4..305fc44 100644 --- a/docs-site/src/content/docs/examples/catalog.md +++ b/docs-site/src/content/docs/examples/catalog.md @@ -2,8 +2,6 @@ title: Examples Catalog description: Runnable examples that ship in this repository, and what each one demonstrates. status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/governance/benchmark-policy.md b/docs-site/src/content/docs/governance/benchmark-policy.md index 6e70193..a58ad6f 100644 --- a/docs-site/src/content/docs/governance/benchmark-policy.md +++ b/docs-site/src/content/docs/governance/benchmark-policy.md @@ -2,8 +2,6 @@ title: Benchmark Policy description: Performance benchmarking and regression guardrails. status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/governance/methodology-and-leakage-controls.md b/docs-site/src/content/docs/governance/methodology-and-leakage-controls.md index 4d4a593..f4f5a4c 100644 --- a/docs-site/src/content/docs/governance/methodology-and-leakage-controls.md +++ b/docs-site/src/content/docs/governance/methodology-and-leakage-controls.md @@ -3,8 +3,6 @@ title: Methodology and Leakage Controls description: Required anti-leakage and methodology controls for OpenQuant research and evaluation. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/governance/reproducibility-and-artifact-contracts.md b/docs-site/src/content/docs/governance/reproducibility-and-artifact-contracts.md index 1dbe979..524f8cb 100644 --- a/docs-site/src/content/docs/governance/reproducibility-and-artifact-contracts.md +++ b/docs-site/src/content/docs/governance/reproducibility-and-artifact-contracts.md @@ -3,8 +3,6 @@ title: Reproducibility and Artifact Contracts description: Minimum artifact and metadata contract for reproducible research outcomes. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/governance/support-and-escalation.md b/docs-site/src/content/docs/governance/support-and-escalation.md index 7b8141e..f5fb3a2 100644 --- a/docs-site/src/content/docs/governance/support-and-escalation.md +++ b/docs-site/src/content/docs/governance/support-and-escalation.md @@ -2,8 +2,6 @@ title: Support and Escalation description: Operational support entry points and escalation expectations. status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/governance/versioning-and-release-policy.md b/docs-site/src/content/docs/governance/versioning-and-release-policy.md index 6ced98d..3322d42 100644 --- a/docs-site/src/content/docs/governance/versioning-and-release-policy.md +++ b/docs-site/src/content/docs/governance/versioning-and-release-policy.md @@ -2,8 +2,6 @@ title: Versioning and Release Policy description: Release and documentation versioning policy for OpenQuant. status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/index.md b/docs-site/src/content/docs/index.md index 9c6254c..4c9074f 100644 --- a/docs-site/src/content/docs/index.md +++ b/docs-site/src/content/docs/index.md @@ -3,7 +3,7 @@ title: OpenQuant Documentation description: Production-grade documentation for AFML-aligned quantitative research and portfolio engineering with OpenQuant. template: splash banner: - content: 'Reviewed New to OpenQuant? Start with the Quickstart guide →' + content: 'New to OpenQuant? Start with the Quickstart guide →' hero: title: OpenQuant Documentation tagline: Institutional-grade quantitative research documentation aligned to AFML chapters and production deployment controls. @@ -41,6 +41,17 @@ audience: 7. [Module Reference Index](/modules/) 8. [Methodology and Leakage Controls](/governance/methodology-and-leakage-controls/) +Three shorter paths, depending on why you are here: + +- **New engineer:** [Quickstart](/quickstart/) → [Local Build Setup](/setup/local-build/) → [Rust Core Workflow](/workflows/rust-core-workflow/) +- **Research user:** [Python Core Workflow](/workflows/python-core-workflow/) → [By AFML Chapter](/module-reference/by-afml-chapter/) → [Module Reference Index](/modules/) +- **Reviewer or risk lead:** [Methodology and Leakage Controls](/governance/methodology-and-leakage-controls/) → [Reproducibility and Artifact Contracts](/governance/reproducibility-and-artifact-contracts/) + +Site search rewards three kinds of query: module names (`cross_validation`, +`backtesting_engine`) when you need an API, AFML concepts (`purged`, `embargo`, +`CPCV`) when you are reviewing methodology, and outcome terms (`drawdown`, +`labeling`, `portfolio`) when you are looking for a workflow entry point. + ## Core Workflow Lanes ### Event-Driven Data and Labeling (AFML Chapters 2-3) diff --git a/docs-site/src/content/docs/module-reference/api-surfaces.md b/docs-site/src/content/docs/module-reference/api-surfaces.md deleted file mode 100644 index 799a5a5..0000000 --- a/docs-site/src/content/docs/module-reference/api-surfaces.md +++ /dev/null @@ -1,49 +0,0 @@ ---- -title: API Surfaces -description: High-level Rust and Python API surface map for core workflows. -status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' -audience: - - quant-dev - - platform-engineering -sidebar: - order: 1 ---- - -## Rust modules (core) - -- [`data_structures`](/modules/data-structures/) — bar construction (dollar, volume, tick, imbalance, run, time) -- [`filters`](/modules/filters/) — CUSUM and z-score event filters -- [`labeling`](/modules/labeling/) — triple-barrier and meta-labeling -- [`fracdiff`](/modules/fracdiff/) — fractional differentiation (FFD) -- [`sampling`](/modules/sampling/) — indicator matrix and sequential bootstrap -- [`sample_weights`](/modules/sample-weights/) — uniqueness and time-decay weighting -- [`cross_validation`](/modules/cross-validation/) — purged k-fold with embargo -- [`feature_importance`](/modules/feature-importance/) — MDI, MDA, single-feature importance -- [`backtesting_engine`](/modules/backtesting-engine/) — walk-forward, purged CV, CPCV -- [`backtest_statistics`](/modules/backtest-statistics/) — Sharpe, drawdown, holding period -- [`risk_metrics`](/modules/risk-metrics/) — VaR, Expected Shortfall, CDaR -- [`strategy_risk`](/modules/strategy-risk/) — strategy failure probability -- [`bet_sizing`](/modules/bet-sizing/) — probability-to-position conversion -- [`hrp`](/modules/hrp/), [`hcaa`](/modules/hcaa/), [`cla`](/modules/cla/), [`portfolio_optimization`](/modules/portfolio-optimization/) — portfolio construction -- [`structural_breaks`](/modules/structural-breaks/) — SADF, Chow, CUSUM variants -- [`microstructural_features`](/modules/microstructural-features/) — impact, spread, VPIN, entropy -- [`hpc_parallel`](/modules/hpc-parallel/), [`streaming_hpc`](/modules/streaming-hpc/), [`combinatorial_optimization`](/modules/combinatorial-optimization/) — HPC utilities - -## Python namespaces - -- [`data`](/modules/data/) — `load_ohlcv`, `clean_ohlcv`, `align_calendar`, `data_quality_report` -- [`bars`](/modules/data-structures/) — `build_time_bars`, `build_tick_bars`, `build_volume_bars`, `build_dollar_bars` -- [`feature_diagnostics`](/modules/feature-diagnostics/) — `mdi_importance`, `mda_importance`, `sfi_importance`, `orthogonalize_features_pca`, `substitution_effect_report` -- [`pipeline`](/modules/pipeline/) — `run_mid_frequency_pipeline`, `run_mid_frequency_pipeline_frames`, `summarize_pipeline` -- [`research`](/modules/research/) — `make_synthetic_futures_dataset`, `run_flywheel_iteration` -- [`adapters`](/modules/adapters/) — `to_polars_signal_frame`, `to_polars_event_frame`, `to_polars_backtest_frame`, `SignalStreamBuffer` -- [`viz`](/modules/viz/) — `prepare_feature_importance_payload`, `prepare_drawdown_payload`, `prepare_regime_payload`, `prepare_frontier_payload` -- `_core.labeling` — `triple_barrier_labels`, `meta_labels` (Rust bindings) -- `_core.filters` — `cusum_filter_indices`, `cusum_filter_timestamps` (Rust bindings) -- `_core.fracdiff` — `frac_diff_ffd`, `get_weights_ffd` (Rust bindings) -- `_core.sampling` — `seq_bootstrap`, `get_ind_matrix` (Rust bindings) -- `_core.sample_weights` — `get_weights_by_return`, `get_weights_by_time_decay` (Rust bindings) - -Full module docs: [All Modules](/modules/) diff --git a/docs-site/src/content/docs/module-reference/by-afml-chapter.md b/docs-site/src/content/docs/module-reference/by-afml-chapter.md index 32218bf..722badd 100644 --- a/docs-site/src/content/docs/module-reference/by-afml-chapter.md +++ b/docs-site/src/content/docs/module-reference/by-afml-chapter.md @@ -3,8 +3,6 @@ title: By AFML Chapter description: Map AFML concepts to concrete OpenQuant modules and workflows. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/module-reference/indexing-and-discovery.md b/docs-site/src/content/docs/module-reference/indexing-and-discovery.md deleted file mode 100644 index f653e18..0000000 --- a/docs-site/src/content/docs/module-reference/indexing-and-discovery.md +++ /dev/null @@ -1,32 +0,0 @@ ---- -title: Indexing and Discovery -description: Navigation model and search strategy for fast access to core OpenQuant capabilities. -status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' -audience: - - quant-dev - - platform-engineering -sidebar: - order: 3 ---- - -## Primary Navigation Model - -- **Getting started:** onboarding and initial validation. -- **Setup:** environment requirements, local build, troubleshooting. -- **Core workflows:** end-to-end Rust/Python paths. -- **Module reference:** detailed module pages. -- **Governance and release:** controls and operational policies. - -## Recommended Discovery Paths - -- New engineer: [Quickstart](/quickstart/) -> [Local Build Setup](/setup/local-build/) -> [Rust Core Workflow](/workflows/rust-core-workflow/) -- Research user: [Python Core Workflow](/workflows/python-core-workflow/) -> [By AFML Chapter](/module-reference/by-afml-chapter/) -> [Module Reference Index](/modules/) -- Reviewer/risk lead: [Methodology and Leakage Controls](/governance/methodology-and-leakage-controls/) -> [Reproducibility and Artifact Contracts](/governance/reproducibility-and-artifact-contracts/) - -## Search Best Practices - -- Search by module names (`cross_validation`, `backtesting_engine`) when you need APIs. -- Search by AFML concept (`purged`, `embargo`, `CPCV`, `deflated sharpe`) for methodology review. -- Search by outcome terms (`drawdown`, `labeling`, `portfolio`) for workflow entry points. diff --git a/docs-site/src/content/docs/modules/adapters.md b/docs-site/src/content/docs/modules/adapters.md index b08cba5..3629f35 100644 --- a/docs-site/src/content/docs/modules/adapters.md +++ b/docs-site/src/content/docs/modules/adapters.md @@ -4,8 +4,6 @@ description: "Polars DataFrame adapters for signals, events, weights, backtest c status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/backtest-statistics.md b/docs-site/src/content/docs/modules/backtest-statistics.md index 958525e..ab17647 100644 --- a/docs-site/src/content/docs/modules/backtest-statistics.md +++ b/docs-site/src/content/docs/modules/backtest-statistics.md @@ -4,8 +4,6 @@ description: "Performance diagnostics for strategy returns and position trajecto status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/backtesting-engine.md b/docs-site/src/content/docs/modules/backtesting-engine.md index 3c1b9bb..de80099 100644 --- a/docs-site/src/content/docs/modules/backtesting-engine.md +++ b/docs-site/src/content/docs/modules/backtesting-engine.md @@ -4,8 +4,6 @@ description: "Backtesting core with walk-forward, purged CV, and combinatorial p status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/bet-sizing.md b/docs-site/src/content/docs/modules/bet-sizing.md index ad43a3d..4e89619 100644 --- a/docs-site/src/content/docs/modules/bet-sizing.md +++ b/docs-site/src/content/docs/modules/bet-sizing.md @@ -4,8 +4,6 @@ description: "Transforms model confidence and constraints into executable positi status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/cla.md b/docs-site/src/content/docs/modules/cla.md index 525edb8..85bf593 100644 --- a/docs-site/src/content/docs/modules/cla.md +++ b/docs-site/src/content/docs/modules/cla.md @@ -4,8 +4,6 @@ description: "Critical Line Algorithm implementation for constrained mean-varian status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/codependence.md b/docs-site/src/content/docs/modules/codependence.md index a0a8596..bd2459b 100644 --- a/docs-site/src/content/docs/modules/codependence.md +++ b/docs-site/src/content/docs/modules/codependence.md @@ -4,8 +4,6 @@ description: "Dependence metrics beyond linear correlation for feature and asset status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/combinatorial-optimization.md b/docs-site/src/content/docs/modules/combinatorial-optimization.md index 363c2b9..92e6413 100644 --- a/docs-site/src/content/docs/modules/combinatorial-optimization.md +++ b/docs-site/src/content/docs/modules/combinatorial-optimization.md @@ -4,8 +4,6 @@ description: "AFML Chapter 21 integer-encoded optimization and trajectory state- status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/cross-validation.md b/docs-site/src/content/docs/modules/cross-validation.md index 5fe69cd..9f2d526 100644 --- a/docs-site/src/content/docs/modules/cross-validation.md +++ b/docs-site/src/content/docs/modules/cross-validation.md @@ -4,8 +4,6 @@ description: "Purged cross-validation utilities designed for label overlap and l status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/data-structures.md b/docs-site/src/content/docs/modules/data-structures.md index 7ea9edd..e777e32 100644 --- a/docs-site/src/content/docs/modules/data-structures.md +++ b/docs-site/src/content/docs/modules/data-structures.md @@ -4,8 +4,6 @@ description: "Constructs standard/time/run/imbalance bars from trade streams." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/data.md b/docs-site/src/content/docs/modules/data.md index fd06863..4d6d663 100644 --- a/docs-site/src/content/docs/modules/data.md +++ b/docs-site/src/content/docs/modules/data.md @@ -4,8 +4,6 @@ description: "OHLCV loading, cleaning, calendar alignment, and data quality repo status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/ef3m.md b/docs-site/src/content/docs/modules/ef3m.md index 4dc200b..ca64654 100644 --- a/docs-site/src/content/docs/modules/ef3m.md +++ b/docs-site/src/content/docs/modules/ef3m.md @@ -4,8 +4,6 @@ description: "Moment-based mixture fitting utilities for two-normal components." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/ensemble-methods.md b/docs-site/src/content/docs/modules/ensemble-methods.md index bdb0e94..fb0ef3b 100644 --- a/docs-site/src/content/docs/modules/ensemble-methods.md +++ b/docs-site/src/content/docs/modules/ensemble-methods.md @@ -4,8 +4,6 @@ description: "Bias/variance diagnostics and practical bagging-vs-boosting ensemb status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/etf-trick.md b/docs-site/src/content/docs/modules/etf-trick.md index bde679b..efa88b0 100644 --- a/docs-site/src/content/docs/modules/etf-trick.md +++ b/docs-site/src/content/docs/modules/etf-trick.md @@ -4,8 +4,6 @@ description: "Synthetic ETF and futures roll utilities for realistic PnL path co status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/feature-diagnostics.md b/docs-site/src/content/docs/modules/feature-diagnostics.md index 83687e5..3d392f0 100644 --- a/docs-site/src/content/docs/modules/feature-diagnostics.md +++ b/docs-site/src/content/docs/modules/feature-diagnostics.md @@ -4,8 +4,6 @@ description: "Feature importance diagnostics: MDI, MDA, SFI, PCA orthogonalizati status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/feature-importance.md b/docs-site/src/content/docs/modules/feature-importance.md index 7d079da..33c26f6 100644 --- a/docs-site/src/content/docs/modules/feature-importance.md +++ b/docs-site/src/content/docs/modules/feature-importance.md @@ -4,8 +4,6 @@ description: "Feature ranking methods: MDI, MDA, and single-feature importance w status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/filters.md b/docs-site/src/content/docs/modules/filters.md index a865532..5fe3aae 100644 --- a/docs-site/src/content/docs/modules/filters.md +++ b/docs-site/src/content/docs/modules/filters.md @@ -4,8 +4,6 @@ description: "CUSUM and z-score event filters for event-driven sampling." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/fingerprint.md b/docs-site/src/content/docs/modules/fingerprint.md index 0daa843..6429ad5 100644 --- a/docs-site/src/content/docs/modules/fingerprint.md +++ b/docs-site/src/content/docs/modules/fingerprint.md @@ -4,8 +4,6 @@ description: "Model fingerprinting for linear, non-linear, and pairwise feature status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/fracdiff.md b/docs-site/src/content/docs/modules/fracdiff.md index 919319f..2db2a03 100644 --- a/docs-site/src/content/docs/modules/fracdiff.md +++ b/docs-site/src/content/docs/modules/fracdiff.md @@ -4,8 +4,6 @@ description: "Fractional differentiation to improve stationarity while retaining status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/hcaa.md b/docs-site/src/content/docs/modules/hcaa.md index df889d8..763bc61 100644 --- a/docs-site/src/content/docs/modules/hcaa.md +++ b/docs-site/src/content/docs/modules/hcaa.md @@ -4,8 +4,6 @@ description: "Hierarchical Clustering Asset Allocation variant with cluster-leve status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/hpc-parallel.md b/docs-site/src/content/docs/modules/hpc-parallel.md index 337b8ae..64ccde0 100644 --- a/docs-site/src/content/docs/modules/hpc-parallel.md +++ b/docs-site/src/content/docs/modules/hpc-parallel.md @@ -4,8 +4,6 @@ description: "AFML Chapter 20 atom/molecule execution utilities with serial/thre status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/hrp.md b/docs-site/src/content/docs/modules/hrp.md index b1a5a00..a071f3b 100644 --- a/docs-site/src/content/docs/modules/hrp.md +++ b/docs-site/src/content/docs/modules/hrp.md @@ -4,8 +4,6 @@ description: "Hierarchical Risk Parity allocation with recursive bisection." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/hyperparameter-tuning.md b/docs-site/src/content/docs/modules/hyperparameter-tuning.md index fedd748..f5a2a52 100644 --- a/docs-site/src/content/docs/modules/hyperparameter-tuning.md +++ b/docs-site/src/content/docs/modules/hyperparameter-tuning.md @@ -4,8 +4,6 @@ description: "Leakage-aware grid/randomized hyper-parameter search with purged C status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/index.md b/docs-site/src/content/docs/modules/index.md index 35aafb0..403bddc 100644 --- a/docs-site/src/content/docs/modules/index.md +++ b/docs-site/src/content/docs/modules/index.md @@ -4,8 +4,6 @@ description: "Full OpenQuant module documentation index with AFML-aligned summar status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering @@ -13,7 +11,14 @@ sidebar: order: 1 --- -This index contains one page per OpenQuant module with purpose, APIs, formulas, examples, and implementation notes. +This is the canonical index of every OpenQuant module: one page each, with +purpose, APIs, formulas, examples, and implementation notes. It lists the same +39 modules twice over — by subject, and by the language surface they are +reachable through — because those are the two questions readers arrive with. +For the AFML chapter each module implements, see +[By AFML Chapter](/module-reference/by-afml-chapter/). + +## By subject ### Data Ingestion and Quality @@ -77,3 +82,77 @@ This index contains one page per OpenQuant module with purpose, APIs, formulas, - [`combinatorial_optimization`](/modules/combinatorial-optimization/) — AFML Chapter 21 integer-encoded optimization and trajectory state-space tooling with exact baselines and solver adapters. - [`hpc_parallel`](/modules/hpc-parallel/) — AFML Chapter 20 atom/molecule execution utilities with serial/threaded modes and partition diagnostics. - [`streaming_hpc`](/modules/streaming-hpc/) — AFML Chapter 22 streaming analytics utilities for low-latency early-warning metrics with bounded-memory incremental state. + +## By language surface + +### Rust core + +- [`backtest_statistics`](/modules/backtest-statistics/) — Performance diagnostics for strategy returns and position trajectories. +- [`backtesting_engine`](/modules/backtesting-engine/) — Backtesting core with walk-forward, purged CV, and combinatorial purged CV (CPCV) workflows. +- [`bet_sizing`](/modules/bet-sizing/) — Transforms model confidence and constraints into executable position sizes. +- [`cla`](/modules/cla/) — Critical Line Algorithm implementation for constrained mean-variance optimization. +- [`codependence`](/modules/codependence/) — Dependence metrics beyond linear correlation for feature and asset relationships. +- [`combinatorial_optimization`](/modules/combinatorial-optimization/) — AFML Chapter 21 integer-encoded optimization and trajectory state-space tooling with exact baselines and solver adapters. +- [`cross_validation`](/modules/cross-validation/) — Purged cross-validation utilities designed for label overlap and leakage control. +- [`data`](/modules/data/) — OHLCV loading, cleaning, calendar alignment, and data quality reporting. +- [`data_structures`](/modules/data-structures/) — Constructs standard/time/run/imbalance bars from trade streams. +- [`ef3m`](/modules/ef3m/) — Moment-based mixture fitting utilities for two-normal components. +- [`ensemble_methods`](/modules/ensemble-methods/) — Bias/variance diagnostics and practical bagging-vs-boosting ensemble utilities. +- [`etf_trick`](/modules/etf-trick/) — Synthetic ETF and futures roll utilities for realistic PnL path construction. +- [`feature_importance`](/modules/feature-importance/) — Feature ranking methods: MDI, MDA, and single-feature importance with PCA diagnostics. +- [`filters`](/modules/filters/) — CUSUM and z-score event filters for event-driven sampling. +- [`fingerprint`](/modules/fingerprint/) — Model fingerprinting for linear, non-linear, and pairwise feature effects. +- [`fracdiff`](/modules/fracdiff/) — Fractional differentiation to improve stationarity while retaining memory. +- [`hcaa`](/modules/hcaa/) — Hierarchical Clustering Asset Allocation variant with cluster-level constraints. +- [`hpc_parallel`](/modules/hpc-parallel/) — AFML Chapter 20 atom/molecule execution utilities with serial/threaded modes and partition diagnostics. +- [`hrp`](/modules/hrp/) — Hierarchical Risk Parity allocation with recursive bisection. +- [`hyperparameter_tuning`](/modules/hyperparameter-tuning/) — Leakage-aware grid/randomized hyper-parameter search with purged CV and weighted scoring. +- [`labeling`](/modules/labeling/) — Triple-barrier event labeling and metadata generation. +- [`microstructural_features`](/modules/microstructural-features/) — Price-impact, spread, entropy, and flow toxicity estimators. +- [`onc`](/modules/onc/) — Optimal Number of Clusters utilities for clustering stability and allocation workflows. +- [`pipeline`](/modules/pipeline/) — End-to-end AFML research pipeline: events → signals → portfolio → risk → backtest with leakage checks. +- [`portfolio_optimization`](/modules/portfolio-optimization/) — Mean-variance and constrained allocation methods with ergonomic APIs. +- [`risk_metrics`](/modules/risk-metrics/) — Portfolio and return-distribution risk measures for downside control. +- [`sample_weights`](/modules/sample-weights/) — Sample weighting utilities for overlapping event structure. +- [`sampling`](/modules/sampling/) — Indicator matrix and sequential bootstrap tooling. +- [`sb_bagging`](/modules/sb-bagging/) — Sequentially bootstrapped bagging classifiers/regressors. +- [`strategy_risk`](/modules/strategy-risk/) — AFML Chapter 15 strategy-viability diagnostics based on precision, payout asymmetry, and bet frequency. +- [`streaming_hpc`](/modules/streaming-hpc/) — AFML Chapter 22 streaming analytics utilities for low-latency early-warning metrics with bounded-memory incremental state. +- [`structural_breaks`](/modules/structural-breaks/) — Regime change and bubble diagnostics (Chow, CUSUM variants, SADF). +- [`synthetic_backtesting`](/modules/synthetic-backtesting/) — Synthetic-data OTR backtesting with O-U calibration, PT/SL mesh search, and stability diagnostics. +- [`util::fast_ewma`](/modules/util-fast-ewma/) — Fast EWMA primitive shared across feature and volatility routines. +- [`util::volatility`](/modules/util-volatility/) — Volatility estimators used across labeling and risk workflows. + +### Python namespaces + +- [`adapters`](/modules/adapters/) — `to_polars_signal_frame`, `to_polars_event_frame`, `to_polars_backtest_frame`, `to_polars_weights_frame`, `to_polars_indicator_matrix`, `to_polars_frontier_frame`, `SignalStreamBuffer`, `to_pandas` +- [`backtest_stats`](/modules/backtest-statistics/) — `sharpe_ratio`, `information_ratio`, `probabilistic_sharpe_ratio`, `deflated_sharpe_ratio`, `minimum_track_record_length`, `timing_of_flattening_and_flips`, `average_holding_period`, `bets_concentration`, `all_bets_concentration`, `drawdown_and_time_under_water` +- [`bars`](/modules/data-structures/) — `build_time_bars`, `build_tick_bars`, `build_volume_bars`, `build_dollar_bars`, `build_run_bars`, `build_imbalance_bars` +- [`bet_sizing`](/modules/bet-sizing/) — `get_signal`, `discrete_signal`, `bet_size`, `bet_size_sigmoid`, `bet_size_power`, `inv_price`, `inv_price_sigmoid`, `inv_price_power`, `get_w`, `get_w_sigmoid`, `get_w_power`, `get_target_pos`, `get_target_pos_sigmoid`, `get_target_pos_power`, `limit_price`, `limit_price_sigmoid`, `limit_price_power`, `avg_active_signals`, `bet_size_dynamic`, `cdf_mixture`, `single_bet_size_mixed`, `get_concurrent_sides`, `bet_size_budget`, `bet_size_probability`, `mp_avg_active_signals`, `bet_size_reserve`, `bet_size_reserve_with_fit`, `bet_size_reserve_full` +- [`cla`](/modules/cla/) — `allocate_cla` +- [`codependence`](/modules/codependence/) — `angular_distance`, `absolute_angular_distance`, `squared_angular_distance`, `distance_correlation`, `get_optimal_number_of_bins`, `get_mutual_info`, `variation_of_information_score` +- [`data`](/modules/data/) — `load_ohlcv`, `clean_ohlcv`, `align_calendar`, `data_quality_report`, `clean_ohlcv_df`, `quality_report_df`, `align_calendar_df` +- [`ef3m`](/modules/ef3m/) — `centered_moment`, `raw_moment`, `most_likely_parameters`, `fit_m2n` +- [`ensemble`](/modules/ensemble-methods/) — `bias_variance_noise`, `bootstrap_sample_indices`, `sequential_bootstrap_sample_indices`, `aggregate_regression_mean`, `aggregate_classification_vote`, `aggregate_classification_probability_mean`, `average_pairwise_prediction_correlation`, `bagging_ensemble_variance`, `recommend_bagging_vs_boosting` +- [`fast_ewma`](/modules/util-fast-ewma/) — `ewma` +- [`feature_diagnostics`](/modules/feature-diagnostics/) — `mdi_importance`, `mda_importance`, `sfi_importance`, `orthogonalize_features_pca`, `substitution_effect_report` +- [`filters`](/modules/filters/) — `cusum_filter_indices`, `cusum_filter_timestamps`, `z_score_filter_indices`, `z_score_filter_timestamps` +- [`fracdiff`](/modules/fracdiff/) — `get_weights`, `get_weights_ffd`, `frac_diff`, `frac_diff_ffd` +- [`hcaa`](/modules/hcaa/) — `allocate_hcaa` +- [`hrp`](/modules/hrp/) — `allocate_hrp` +- [`labeling`](/modules/labeling/) — `triple_barrier_labels`, `triple_barrier_events`, `meta_labels`, `add_vertical_barrier`, `get_events`, `get_bins`, `drop_labels` +- [`microstructural`](/modules/microstructural-features/) — `get_roll_measure`, `get_roll_impact`, `get_corwin_schultz_estimator`, `get_bekker_parkinson_vol`, `get_bar_based_kyle_lambda`, `get_bar_based_amihud_lambda`, `get_bar_based_hasbrouck_lambda`, `get_trades_based_kyle_lambda`, `get_trades_based_amihud_lambda`, `get_trades_based_hasbrouck_lambda`, `vwap`, `get_avg_tick_size`, `get_vpin`, `get_bvc_buy_volume`, `encode_tick_rule_array`, `quantile_mapping`, `sigma_mapping`, `encode_array`, `get_shannon_entropy`, `get_lempel_ziv_entropy`, `get_plug_in_entropy`, `get_konto_entropy` +- [`onc`](/modules/onc/) — `get_onc_clusters` +- [`pipeline`](/modules/pipeline/) — `run_mid_frequency_pipeline`, `run_mid_frequency_pipeline_frames`, `summarize_pipeline` +- [`portfolio`](/modules/portfolio-optimization/) — `allocate_inverse_variance`, `allocate_min_vol`, `allocate_max_sharpe`, `allocate_efficient_risk`, `allocate_with_solution`, `allocate_from_inputs` +- [`research`](/modules/research/) — `make_synthetic_futures_dataset`, `run_flywheel_iteration`, `ResearchDataset` +- [`risk`](/modules/risk-metrics/) — `calculate_value_at_risk`, `calculate_expected_shortfall`, `calculate_conditional_drawdown_risk`, `calculate_variance`, `calculate_value_at_risk_from_matrix`, `calculate_expected_shortfall_from_matrix`, `calculate_conditional_drawdown_risk_from_matrix` +- [`sample_weights`](/modules/sample-weights/) — `get_weights_by_return`, `get_weights_by_time_decay` +- [`sampling`](/modules/sampling/) — `get_ind_matrix`, `seq_bootstrap`, `get_ind_mat_average_uniqueness`, `get_ind_mat_label_uniqueness`, `bootstrap_loop_run`, `get_av_uniqueness_from_triple_barrier`, `num_concurrent_events` +- [`sb_bagging`](/modules/sb-bagging/) — `fit_predict_sb_classifier`, `fit_predict_sb_regressor` +- [`strategy_risk`](/modules/strategy-risk/) — `sharpe_symmetric`, `implied_precision_symmetric`, `implied_frequency_symmetric`, `sharpe_asymmetric`, `implied_precision_asymmetric`, `implied_frequency_asymmetric`, `estimate_strategy_failure_probability` +- [`streaming_hpc`](/modules/streaming-hpc/) — `run_streaming_pipeline`, `generate_synthetic_flash_crash_stream` +- [`structural_breaks`](/modules/structural-breaks/) — `get_chow_type_stat`, `get_chu_stinchcombe_white_statistics`, `get_sadf` +- [`synthetic_bt`](/modules/synthetic-backtesting/) — `calibrate_ou_params`, `generate_ou_paths`, `evaluate_rule_on_paths`, `detect_no_stable_optimum`, `run_synthetic_otr_workflow`, `search_optimal_trading_rule` +- [`viz`](/modules/viz/) — `prepare_feature_importance_payload`, `prepare_feature_importance_comparison_payload`, `prepare_drawdown_payload`, `prepare_regime_payload`, `prepare_frontier_payload`, `prepare_cluster_payload` +- [`volatility`](/modules/util-volatility/) — `get_daily_vol`, `get_parkinson_vol`, `get_garman_class_vol`, `get_yang_zhang_vol` diff --git a/docs-site/src/content/docs/modules/labeling.md b/docs-site/src/content/docs/modules/labeling.md index e870607..cf0e2d1 100644 --- a/docs-site/src/content/docs/modules/labeling.md +++ b/docs-site/src/content/docs/modules/labeling.md @@ -4,8 +4,6 @@ description: "Triple-barrier event labeling and metadata generation." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/microstructural-features.md b/docs-site/src/content/docs/modules/microstructural-features.md index b6298ee..9308cc6 100644 --- a/docs-site/src/content/docs/modules/microstructural-features.md +++ b/docs-site/src/content/docs/modules/microstructural-features.md @@ -4,8 +4,6 @@ description: "Price-impact, spread, entropy, and flow toxicity estimators." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/onc.md b/docs-site/src/content/docs/modules/onc.md index 52c41bc..5621e7c 100644 --- a/docs-site/src/content/docs/modules/onc.md +++ b/docs-site/src/content/docs/modules/onc.md @@ -4,8 +4,6 @@ description: "Optimal Number of Clusters utilities for clustering stability and status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/pipeline.md b/docs-site/src/content/docs/modules/pipeline.md index e92b4df..b52ad6f 100644 --- a/docs-site/src/content/docs/modules/pipeline.md +++ b/docs-site/src/content/docs/modules/pipeline.md @@ -4,8 +4,6 @@ description: "End-to-end AFML research pipeline: events → signals → portfoli status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/portfolio-optimization.md b/docs-site/src/content/docs/modules/portfolio-optimization.md index 996acc9..46f16d1 100644 --- a/docs-site/src/content/docs/modules/portfolio-optimization.md +++ b/docs-site/src/content/docs/modules/portfolio-optimization.md @@ -4,8 +4,6 @@ description: "Mean-variance and constrained allocation methods with ergonomic AP status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/research.md b/docs-site/src/content/docs/modules/research.md index 533130d..45fcb84 100644 --- a/docs-site/src/content/docs/modules/research.md +++ b/docs-site/src/content/docs/modules/research.md @@ -4,8 +4,6 @@ description: "Synthetic dataset generation and flywheel research iteration with status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/risk-metrics.md b/docs-site/src/content/docs/modules/risk-metrics.md index 5ff2d49..decd15c 100644 --- a/docs-site/src/content/docs/modules/risk-metrics.md +++ b/docs-site/src/content/docs/modules/risk-metrics.md @@ -4,8 +4,6 @@ description: "Portfolio and return-distribution risk measures for downside contr status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/sample-weights.md b/docs-site/src/content/docs/modules/sample-weights.md index e202019..31fe5af 100644 --- a/docs-site/src/content/docs/modules/sample-weights.md +++ b/docs-site/src/content/docs/modules/sample-weights.md @@ -4,8 +4,6 @@ description: "Sample weighting utilities for overlapping event structure." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/sampling.md b/docs-site/src/content/docs/modules/sampling.md index 3c01a0f..bf1731b 100644 --- a/docs-site/src/content/docs/modules/sampling.md +++ b/docs-site/src/content/docs/modules/sampling.md @@ -4,8 +4,6 @@ description: "Indicator matrix and sequential bootstrap tooling." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/sb-bagging.md b/docs-site/src/content/docs/modules/sb-bagging.md index 4558a50..f08f03b 100644 --- a/docs-site/src/content/docs/modules/sb-bagging.md +++ b/docs-site/src/content/docs/modules/sb-bagging.md @@ -4,8 +4,6 @@ description: "Sequentially bootstrapped bagging classifiers/regressors." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/strategy-risk.md b/docs-site/src/content/docs/modules/strategy-risk.md index 9ad51b7..601f7f6 100644 --- a/docs-site/src/content/docs/modules/strategy-risk.md +++ b/docs-site/src/content/docs/modules/strategy-risk.md @@ -4,8 +4,6 @@ description: "AFML Chapter 15 strategy-viability diagnostics based on precision, status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/streaming-hpc.md b/docs-site/src/content/docs/modules/streaming-hpc.md index 096b62e..581a26f 100644 --- a/docs-site/src/content/docs/modules/streaming-hpc.md +++ b/docs-site/src/content/docs/modules/streaming-hpc.md @@ -4,8 +4,6 @@ description: "AFML Chapter 22 streaming analytics utilities for low-latency earl status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/structural-breaks.md b/docs-site/src/content/docs/modules/structural-breaks.md index 1589f08..8c9b3e1 100644 --- a/docs-site/src/content/docs/modules/structural-breaks.md +++ b/docs-site/src/content/docs/modules/structural-breaks.md @@ -4,8 +4,6 @@ description: "Regime change and bubble diagnostics (Chow, CUSUM variants, SADF). status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/synthetic-backtesting.md b/docs-site/src/content/docs/modules/synthetic-backtesting.md index 9ab8952..e249c28 100644 --- a/docs-site/src/content/docs/modules/synthetic-backtesting.md +++ b/docs-site/src/content/docs/modules/synthetic-backtesting.md @@ -4,8 +4,6 @@ description: "Synthetic-data OTR backtesting with O-U calibration, PT/SL mesh se status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/util-fast-ewma.md b/docs-site/src/content/docs/modules/util-fast-ewma.md index e0bdeab..81a71ce 100644 --- a/docs-site/src/content/docs/modules/util-fast-ewma.md +++ b/docs-site/src/content/docs/modules/util-fast-ewma.md @@ -4,8 +4,6 @@ description: "Fast EWMA primitive shared across feature and volatility routines. status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/util-volatility.md b/docs-site/src/content/docs/modules/util-volatility.md index 65ce525..cdb07a0 100644 --- a/docs-site/src/content/docs/modules/util-volatility.md +++ b/docs-site/src/content/docs/modules/util-volatility.md @@ -4,8 +4,6 @@ description: "Volatility estimators used across labeling and risk workflows." status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/modules/viz.md b/docs-site/src/content/docs/modules/viz.md index 58bee17..fdd63bc 100644 --- a/docs-site/src/content/docs/modules/viz.md +++ b/docs-site/src/content/docs/modules/viz.md @@ -4,8 +4,6 @@ description: "Visualization payload builders for feature importance, drawdown, r status: generated generated_from: src/data/moduleDocs.ts last_generated: '2026-08-31' -banner: - content: 'Generated Assembled automatically from moduleDocs.ts. No human has reviewed this page.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/quickstart.md b/docs-site/src/content/docs/quickstart.md index 5d53ecb..4966372 100644 --- a/docs-site/src/content/docs/quickstart.md +++ b/docs-site/src/content/docs/quickstart.md @@ -3,8 +3,6 @@ title: Quickstart description: Install OpenQuant and get one real result out of it. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/setup/local-build.md b/docs-site/src/content/docs/setup/local-build.md index 1e58d7a..2e37999 100644 --- a/docs-site/src/content/docs/setup/local-build.md +++ b/docs-site/src/content/docs/setup/local-build.md @@ -3,8 +3,6 @@ title: Local Build Setup description: Build the Rust core, run its tests, and run the documentation quality gates. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering @@ -94,8 +92,9 @@ bump the date, or lower the status to `draft`. The gate reads the change date from `git log` plus the working-tree mtime, so an uncommitted edit counts. -The reader-facing badge in each page's `banner.content` must also match -`status`. Change one, change the other. +The coloured pill a reader sees at the top of every page is rendered from +`status` by the `Banner` override in `src/components/DocStatusBanner.astro`, +so there is nothing to keep in step by hand. ## Next diff --git a/docs-site/src/content/docs/setup/prerequisites.md b/docs-site/src/content/docs/setup/prerequisites.md index f13c80c..afe4d10 100644 --- a/docs-site/src/content/docs/setup/prerequisites.md +++ b/docs-site/src/content/docs/setup/prerequisites.md @@ -3,8 +3,6 @@ title: Prerequisites description: Toolchain OpenQuant requires, how to install it on each platform, and why each version floor exists. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/setup/python-bindings.md b/docs-site/src/content/docs/setup/python-bindings.md index f4b4f49..b2933e8 100644 --- a/docs-site/src/content/docs/setup/python-bindings.md +++ b/docs-site/src/content/docs/setup/python-bindings.md @@ -3,8 +3,6 @@ title: Python Bindings Setup description: Build the PyO3 extension, install it into a virtual environment, and prove it imports. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/setup/troubleshooting.md b/docs-site/src/content/docs/setup/troubleshooting.md index 35a8eb7..b6c7e57 100644 --- a/docs-site/src/content/docs/setup/troubleshooting.md +++ b/docs-site/src/content/docs/setup/troubleshooting.md @@ -3,8 +3,6 @@ title: Troubleshooting description: Symptom, cause and fix for the failures you actually hit building OpenQuant. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/workflows/notebook-research-workflow.md b/docs-site/src/content/docs/workflows/notebook-research-workflow.md index 7faaa4b..0ef6e7b 100644 --- a/docs-site/src/content/docs/workflows/notebook-research-workflow.md +++ b/docs-site/src/content/docs/workflows/notebook-research-workflow.md @@ -2,8 +2,6 @@ title: Notebook Research Workflow description: Notebook-first research flow with promotion controls for institutional settings. status: draft -banner: - content: 'Draft This page is known to be incomplete. Treat its contents as provisional.' audience: - quant-dev - platform-engineering diff --git a/docs-site/src/content/docs/workflows/python-core-workflow.md b/docs-site/src/content/docs/workflows/python-core-workflow.md index ca1fa78..cdc58f2 100644 --- a/docs-site/src/content/docs/workflows/python-core-workflow.md +++ b/docs-site/src/content/docs/workflows/python-core-workflow.md @@ -3,8 +3,6 @@ title: Python Core Workflow description: One runnable Python script from raw OHLCV to a promotion decision, with its output. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering @@ -24,8 +22,8 @@ repository root: uv run --python .venv/bin/python python workflow.py ``` -For the namespace-by-namespace symbol list, see [API -Surfaces](/module-reference/api-surfaces/). This page explains the loop +For the namespace-by-namespace symbol list, see the [Module Reference +Index](/modules/), under "By language surface". This page explains the loop rather than reprinting it. ## The script @@ -228,4 +226,4 @@ about your features, not a bug. - [Rust Core Workflow](/workflows/rust-core-workflow/) — the same ground in Rust - [Examples Catalog](/examples/catalog/) — runnable examples that ship in the repo -- [API Surfaces](/module-reference/api-surfaces/) — the full symbol lists +- [Module Reference Index](/modules/) — the full symbol lists, by namespace diff --git a/docs-site/src/content/docs/workflows/rust-core-workflow.md b/docs-site/src/content/docs/workflows/rust-core-workflow.md index 4b56468..658bf4e 100644 --- a/docs-site/src/content/docs/workflows/rust-core-workflow.md +++ b/docs-site/src/content/docs/workflows/rust-core-workflow.md @@ -3,8 +3,6 @@ title: Rust Core Workflow description: One runnable Rust program from event sampling to portfolio risk, with its output. status: reviewed last_validated: '2026-08-30' -banner: - content: 'Reviewed A human has read this page end to end. It has not been verified line by line against the code.' audience: - quant-dev - platform-engineering @@ -306,4 +304,4 @@ report one, report how many configurations you tried to get it — - [Python Core Workflow](/workflows/python-core-workflow/) — the same ground in Python - [Modules by AFML chapter](/module-reference/by-afml-chapter/) — the module behind each stage -- [API Surfaces](/module-reference/api-surfaces/) — the full Rust and Python symbol lists +- [Module Reference Index](/modules/) — every module, by subject and by language surface diff --git a/docs-site/src/styles/starlight.css b/docs-site/src/styles/starlight.css index 6d7fda7..98f7c6c 100644 --- a/docs-site/src/styles/starlight.css +++ b/docs-site/src/styles/starlight.css @@ -147,13 +147,12 @@ h1 { } /* ── Page status badge ─────────────────────────────────────────────────────── - Every doc page declares a `status` in its frontmatter and renders it through - the Starlight banner slot, so a reader can always tell whether a page was + Every doc page declares a `status` in its frontmatter, and the Starlight + `Banner` override in src/components/DocStatusBanner.astro renders the pill + from that field, so a reader can always tell whether a page was machine-generated, is an unfinished draft, or has actually been read by a - human. Wired through `banner.content` rather than a Starlight component - override, because an override has to be registered in astro.config.mjs and - this branch does not own that file. check-content-schema.mjs enforces that - the badge matches the frontmatter status, so the two cannot drift. + human. The badge is derived from `status`, never written beside it, so the + two cannot drift. The `:has()` guard keeps the site-wide banner gradient above intact for any non-status banner. */ .sl-banner:has(.doc-status) {