NLP-Based Extraction of KPI Mentions from 10-K Filings
Introduction
Company 10-K filings contain hundreds of pages of narrative text: discussion of business segments, market trends, risk factors, management commentary. Embedded in this text are key performance indicators (KPIs) and forward guidance: "we expect revenue growth of 10-15%," "customer retention improved by 3 percentage points," "we opened 50 new locations." Extracting and analyzing these KPI mentions programmatically can reveal management expectations, changes in tone, and operational trends. This article explores NLP techniques for KPI extraction from SEC filings.
Value of KPI Extraction from Filings
Earnings guidance is carefully crafted and often conservative. But KPIs mentioned in narrative text—especially in MD&A (Management Discussion & Analysis) sections—can be more revealing. Comparing KPI mentions across years reveals what management views as important (increasing disclosure of metric suggests rising priority). Comparing management-stated KPIs to analyst consensus can reveal divergences predicting surprises.
NLP Approaches to KPI Extraction
Named Entity Recognition (NER) for Financial Metrics
Train NER models to identify financial terms in text. Standard NER identifies person/organization/location; financial NER identifies metrics: "revenue," "margin," "customer count," "churn rate." Use SpaCy or Hugging Face transformer-based NER models fine-tuned on financial text.
Pipeline: identify metric mentions, extract associated numerical values from surrounding text. "Customer retention improved by 3 percentage points" extracts metric="customer retention," value_change="+3pp".
Relation Extraction
Simply identifying a metric isn't enough; understand its context. Is it positive or negative? What company segment? What time period? Relation extraction models identify relationships between entities.
Example: "North America segment revenue grew 15% year-over-year." Extract: metric=revenue, value=15%, entity=North America, period=YoY, direction=growth. Deep learning models (LSTM, transformer-based) learn these relationships from labeled training data.
Sentiment Analysis for KPI Context
Metrics mentioned in negative context ("revenue declined" or "our margins face headwinds") signal different meaning than positive context. Fine-tune sentiment models on financial text to understand whether metric mentions are positive or negative outlook.
Building Training Data for Financial KPI Extraction
Supervised NLP models require labeled training data. Options:
- Manual annotation: hire annotators to label 1,000-5,000 10-K excerpts, marking metrics and values. Expensive (50,000-200,000) but high-quality training data
- Crowdsourced annotation: use services like Mechanical Turk to get cost-effective labels. Requires careful task design and quality control
- Weakly-supervised learning: use heuristics (regex patterns, keyword matching) to automatically generate training labels with limited manual review
- Transfer learning: use pre-trained financial BERT models fine-tuned on domain-specific tasks
Practical Extraction Pipeline
Data Preprocessing
Download 10-K filings from SEC EDGAR. Parse HTML/text to extract MD&A sections (where KPIs are concentrated). Clean text: remove headers, footnotes, tables. Segment into sentences (one sentence typically contains one KPI if any).
Metric Identification
Use NER to identify metric mentions. Pipeline: sentence -> NER model -> [metric, associated numerical value, context]. Extract all mentions in sentence.
Validation and Aggregation
Aggregate extracted KPIs by company and fiscal year. Validate by spot-checking extractions against source text. Build database: for each company and year, what KPIs were mentioned and with what values/trends?
Analysis of Extracted KPIs
Temporal Analysis
Compare KPI mentions across years for same company. If "customer retention" is mentioned heavily in recent filings but wasn't in older filings, retention is gaining importance. Similarly, if "market share gains" language decreased, it might signal competitive challenges.
Peer Comparison
Aggregate KPI mentions across industry peers. If one company frequently mentions "international expansion" while competitors don't, it reveals strategic differentiation. Divergences between management stated KPIs and peer KPIs can signal emerging outperformance or underperformance.
Sentiment and Tone
Beyond the KPI values themselves, analyze tone: is management optimistic or cautious about future? Increasingly negative language about a KPI (e.g., "challenges in customer acquisition," "margin compression headwinds") signals worsening outlook.
Trading Applications
Earnings Surprise Prediction
Extract guidance and KPI expectations from 10-K filings. Compare management-stated expectations to subsequent earnings reports. If management guidance from 10-K proved consistently accurate or consistently optimistic, incorporate this bias into earnings forecasts.
Forward Guidance Assessment
When companies issue quarterly forward guidance, compare to KPI language from most recent 10-K. Divergence between 10-K guidance and quarterly updates suggests changing circumstances.
Strategic Shift Detection
Changing KPI emphasis signals strategic shifts before they show in financial results. Company increasing emphasis on "ESG metrics" or "digital transformation" might be positioning for new competitive landscape. Trade on these signals ahead of earnings impact.
Challenges in KPI Extraction
Domain Specificity
Financial KPIs vary by industry. Tech companies mention "user growth" and "engagement metrics"; retail discusses "same-store sales"; banking mentions "net interest margin." Extract models need training on diverse company types.
Ambiguity and Context Dependency
"Growth" might refer to revenue growth, user growth, or headcount growth. Context determines meaning. Models must understand context to avoid extracting meaningless metrics.
Data Quality
10-Ks are complex documents with tables, footnotes, and cross-references. Parsing can introduce errors. Validate extracted data against original text to minimize errors.
Implementation Stack
Libraries: SpaCy or Hugging Face Transformers for NLP, NLTK for text preprocessing, SEC EDGAR API for data sourcing, pandas for aggregation. Consider proprietary tools (FactSet, Bloomberg) that already provide parsed KPI data if building from scratch is too resource-intensive.
Conclusion
10-K filings contain rich KPI data signaling management priorities and forward expectations. Extracting this data programmatically via NLP enables systematic monitoring of operational trends and management outlook changes. Combined with quantitative analysis of earnings and price, KPI extraction from 10-Ks can improve stock-picking edge. The challenge is building robust extraction models that handle domain-specific complexity, but payoff—systematizing analysis of unstructured text that most investors read sporadically—justifies the effort.