One email each morning — yesterday's AI, sortedGet it in your inbox

METAL LAB

Reliable Financial Named Entity Recognition under Domain Shift

arXiv:2608.195582026-08-21

An AI's confidence trained on formal filings turns unreliable once it reads tweets

Researchers took named-entity recognition AI trained on SEC filings and tested it on financial news and general social media, finding that not just accuracy but the AI's own confidence scores broke down under this shift. Whole-sentence probability, the best confidence signal in-domain, became untrustworthy out of domain, while entity-span probability and self-consistency (agreement across repeated generations) held up better. Still, on the extreme social-media shift, no confidence signal could reliably identify a safe subset of predictions to automate.

What they did

  1. Trained a BERT tagger and small language models (Qwen2.5 0.5B/1.5B fine-tuned with LoRA) on SEC filings, then tested them on financial news and general-topic Twitter data across three seeds with bootstrap confidence intervals
  2. Compared five inference-time confidence signals: whole-output probability, token probability, entity-span probability, entity-type probability, and self-consistency across repeated samples
  3. Whole-output probability was the strongest error detector in-domain but degraded sharply under domain shift; entity-span probability and self-consistency were more robust, with self-consistency also better calibrated without any post-hoc fixing
  4. Letting the AI automatically answer only the top 40% most-confident sentences cut in-domain sentence error from 34.3% to under 2%, still helped on financial news, but found no usefully large safe subset on the extreme social-media data
  5. Proposes a staged deployment approach: detect severe domain shift first, then apply confidence-based automation only within domains the system can reliably handle
Fig. 1: Reliability diagrams for self-consistency confidence (0.5B, pooled seeds). Near-diagonal in-domain; on both shifted tiers the top-confidence bin inverts.
Fig. 1: Reliability diagrams for self-consistency confidence (0.5B, pooled seeds). Near-diagonal in-domain; on both shifted tiers the top-confidence bin inverts.
TABLE I: Dataset statistics after harmonization and filtering.
SplitDomainSent.Ent.PERORGLOC
TrainFIN (filings) [27]1014980648175157
ValidFIN (filings) [27]150177976812
TestFIN (filings) [27]2992952015638
TestFiNER-ORD (news) [28]3003227815193
TestTweetNER7 (tweets) [30]300619381135103
Fig. 2: Sentence-level risk–coverage (Qwen2.5-0.5B; line = 3-seed mean, band = seed range; lower is better). Abstention sharply reduces risk in-domain and on news, but cannot rescue the far-shift tier.
Fig. 2: Sentence-level risk–coverage (Qwen2.5-0.5B; line = 3-seed mean, band = seed range; lower is better). Abstention sharply reduces risk in-domain and on news, but cannot rescue the far-shift tier.
TABLE II: Main results (%; mean±std over 3 seeds; Qwen2.5-1.5B is a single-seed scale check).
ModelDomainPRF1Halluc.%ECE
BERT-baseFIN66.7±2.374.2±1.470.3±1.50.102±0.016
BERT-baseFiNER-ORD39.1±0.337.6±2.338.3±1.10.071±0.017
BERT-baseTweetNER735.2±5.218.4±1.724.1±2.50.074±0.007
Qwen-0.5BFIN40.5±0.434.7±2.137.4±1.33.6±2.40.362±0.009
Qwen-0.5BFiNER-ORD30.7±1.318.0±4.422.6±3.88.2±0.70.407±0.005
Qwen-0.5BTweetNER730.8±0.723.7±4.226.7±2.85.6±1.10.370±0.007
Qwen-1.5BFIN47.744.746.24.30.322
Qwen-1.5BFiNER-ORD56.348.452.13.60.227
Qwen-1.5BTweetNER744.950.947.76.80.358
TABLE III: Error-detection AUROC and ECE per confidence signal (Qwen2.5-0.5B; mean±std over 3 seeds), by test domain.
SignalFINFiNER-ORDTweetNER7
AUROCECEAUROCECEAUROCECE
Sequence prob.0.839±0.0140.512±0.0050.661±0.0150.593±0.0110.626±0.0190.586±0.006
Token prob.0.823±0.0120.531±0.0040.666±0.0190.615±0.0130.605±0.0180.611±0.006
Span prob.0.801±0.0040.362±0.0090.690±0.0300.407±0.0050.721±0.0110.370±0.007
Type prob.0.492±0.0190.506±0.0040.536±0.0220.533±0.0190.511±0.0100.573±0.002
Self-consistency0.690±0.0190.116±0.0290.671±0.0480.120±0.0150.682±0.0170.100±0.008
TABLE IV: Scale check: error-detection AUROC by signal and domain for Qwen2.5-0.5B (3-seed mean) vs. Qwen2.5-1.5B (single seed).
Signal0.5B (3 seeds)1.5B (1 seed)
FINFiNERTweetFINFiNERTweet
Sequence prob.0.8390.6610.6260.7640.7200.637
Span prob.0.8010.6900.7210.8190.7290.638
Self-consistency0.6900.6710.6820.7350.7440.663
TABLE V: Entity-level selective precision (%) at 100/80/60% coverage (Qwen2.5-0.5B; mean±std over 3 seeds).
DomainSignalP@100%P@80%P@60%
FINSeq. prob.40.5±0.449.0±0.858.4±0.6
FINSpan prob.40.5±0.449.2±0.356.4±0.6
FINSelf-consistency40.5±0.447.7±0.452.8±1.0
FiNERSeq. prob.30.7±1.334.9±3.040.1±1.3
FiNERSpan prob.30.7±1.335.3±1.740.8±2.6
FiNERSelf-consist.30.7±1.334.9±3.041.4±2.3
TweetSeq. prob.30.8±0.734.2±1.036.8±2.9
TweetSpan prob.30.8±0.736.6±1.142.7±1.1
TweetSelf-consist.30.8±0.735.5±1.740.5±1.5
TABLE VI: TweetNER7 filtering sensitivity, main (drop-sentence) vs. relaxed (ignore-entity) protocol. Encoder: 3-seed mean; Qwen: seed 42.
FilteredRelaxed
Sentences dropped (of 2807)21790
Evaluated (cap 300)300300
Gold PER/ORG/LOC619443
Ignored entities0488
Encoder F124.1±2.519.5±1.0
Encoder MSP AUROC0.615±0.0540.650±0.047
Qwen-0.5B F129.729.1
Qwen-0.5B span AUROC0.7250.715

Why it matters

In finance, where extraction errors feed into compliance and risk pipelines, accuracy scores alone can't tell you when it's safe to trust an AI's output automatically. This study shows that an AI's self-reported confidence can itself fail silently under domain shift, and offers concrete guidance on which confidence signals to trust and when.

Terms in this paper

  • Named Entity Recognition (NER) · an AI task that finds and labels names of people, organizations, and locations in text
  • distribution shift · when the style or topic of real-world input text differs from the data the AI was trained on
  • selective prediction · letting an AI withhold an answer when unsure and send that case to a human reviewer instead
  • self-consistency · a confidence measure based on how often an AI gives the same answer across multiple generated outputs for the same input
  • LoRA · a lightweight fine-tuning method that adjusts only a small set of added parameters instead of retraining the whole model
  • AUROC / ECE · AUROC measures how well a confidence score separates correct from incorrect predictions; ECE measures how well the stated confidence matches actual accuracy

Original abstract (English)

Financial AI systems often train information extractors on one textual register and deploy them across filings, news, and user-generated content, while standard F1 scores do not indicate which predictions remain safe to automate when the input distribution changes. We study confidence estimation and selective prediction for financial named entity recognition (NER) on a three-tier stress test spanning SEC filings, financial news, and general-topic social media as an extreme out-of-domain condition. We evaluate a BERT tagger and LoRA-tuned Qwen2.5-0.5B/1.5B models using five inference-time confidence signals, three training seeds, and bootstrap intervals. Confidence rankings themselves change under distribution shift: whole-output probability is the strongest in-domain error detector but deteriorates out of domain, whereas entity-span probability and self-consistency are more robust; self-consistency is also better calibrated without post-hoc fitting. Abstention reduces sentence error from 34.3% to below 2% on the highest-confidence 40% of in-domain inputs and remains useful on financial news, but recovers no usefully large clean subset under the extreme social-media shift. These results motivate a staged deployment strategy that detects severe distribution shift upstream before applying prediction-level confidence gating.

Authors · Zihao Zheng, Baichuan Li, Junyi Yao, Jiayu Long

Read on arXiv

Latest papers

All papers →

Latest from METAL LAB

Figures: Zihao Zheng et al., arXiv:2608.19558, arxiv-nonexclusive