Wiki/Skill-System-Baseline.md
Skill System Baseline
Parent Skill
algolia-search-audit is the full-pipeline orchestrator. It routes the audit through waves, spawns isolated worker agents, verifies file outputs, and blocks progression when gates fail.
Important properties:
- Orchestrator does no data collection or report writing.
- Worker skills run in isolated contexts.
- Communication is via files.
- Gates check file existence, byte size, screenshot count, JSON validity, and factcheck verdict.
- The skill system uses model tiers by task type: Haiku for programmatic collection, Sonnet for structured extraction/light synthesis, Opus for deep reading and creative generation.
Canonical Output Contract
AGENT-CONTEXT.md defines canonical JSON keys, CSS classes, typography tokens, renderer functions, path conventions, and validation rules.
The most important JSON top-level fields include:
meta, cover, score, company_snapshot, executives, intelligence_signals,
competitors, findings, gap_pairs, financials, traffic, tech_stack,
ae_fields, next_steps, methodology, bibliography, competitive_synthesis,
golden_angle, strategic_angles, hiring, icp_mapping, abx_sequence,
case_studies, demos, partner_intel, tab_subtitles, recommended_first_play,
industry_context
Finding objects have exact required keys:
id, title, severity, category, tested_query, expected_behavior,
actual_behavior, impact_stat, impact_stat_source, screenshot_file,
prospect_description, algolia_solution, algolia_case_study_url,
algolia_case_study_company, algolia_case_study_result
This is not just presentation schema. It is a product contract PRISM must preserve or consciously migrate.
Workflow
Wave 1 — Intelligence Collection
Runs independent modules in parallel:
algolia-intel-companyalgolia-intel-techstackalgolia-intel-trafficalgolia-intel-competitorsalgolia-intel-financial-publicoralgolia-intel-financial-privatealgolia-intel-investoralgolia-intel-hiringalgolia-intel-socialalgolia-intel-newsalgolia-intel-partneralgolia-intel-industry
Wave 2 — Query Generation
algolia-intel-queries reads company context and traffic keywords to produce 05-test-queries.md.
Layer 2 — Browser Audit
algolia-audit-browser executes 20 browser tests and captures screenshots.
Layer 3 — Synthesis
Business case, sales plays, report rendering, JSON generation, and deterministic patching happen here.
Layer 3D — ABX
algolia-campaign-abx creates 10 campaign files.
Layer 4 — Factcheck
algolia-audit-factcheck verifies claims and writes the gate verdict.
Deterministic Scripts
The parent skill relies on scripts for repeatable collection and patching:
| Script | Role |
|---|---|
collect-company.py |
Company context, source website metadata, Scout fill-null enrichment |
collect-techstack.py |
BuiltWith + SimilarWeb technology collection |
collect-traffic.py |
SimilarWeb traffic endpoints |
collect-competitors.py |
SimilarWeb competitor discovery |
collect-financials.py |
Yahoo Finance/yfinance financial profile |
collect-hiring.py |
ICP classification reference after LinkedIn scraping was removed |
collect-social.py |
Apify social posts with fallback rules |
collect-news.py |
Google News RSS and newsroom feeds |
collect-investor.py |
SEC/earnings-call-oriented investor intelligence |
collect-industry.py |
Tavily/WebSearch industry benchmarks and trends |
audit-browser.js |
Playwright stealth browser audit |
calculate-score.py |
Weighted 10-area scoring |
calculate-roi.py |
Revenue impact scenarios |
generate-audit-data.py |
Post-LLM deterministic JSON correction |
validate-json-schema.py |
Blocks render when data keys do not match renderer expectations |
render-audit.ts |
Generates SPA/report artifacts |
Evidence Discipline
The skill system is evidence-first:
- No naked data points.
- Every stat needs source provenance.
- Factcheck tiers determine whether claims stay, warn, or drop.
- If a source cannot be cited at write time, the claim should not be written.