Unsupervised Anomaly Detection for General Ledger Journal Entries

Last updated: November 29, 2026

Quick Overview

With no labeled fraud cases, build a model that ranks a client's journal entries by how unusual they are so auditors can target their testing, and explain how you would validate and explain the rankings.

PwC
Machine Learning
Machine Learning Engineer
PwC
November 29, 2026
Machine Learning Engineer
Onsite
Machine Learning
Medium

0

0

0 solved


With no labeled fraud cases, build a model that ranks a client's journal entries by how unusual they are so auditors can target their testing, and explain how you would validate and explain the rankings.

PwC's audit analytics aim to look at every transaction rather than a sample, and labeled misstatements are rare and client specific, so unsupervised ranking is the practical approach. The interviewer probes feature engineering from accounting context, model choice, and how a ranking becomes defensible audit evidence.

What the Interviewer Expects
  • Engineer features from accounting context (account pairs, poster behavior, timing, amounts)
  • Pick an unsupervised method suited to mixed tabular data, such as isolation forest
  • Normalize per client and per account so scales are comparable
  • Provide per-entry explanations an auditor can document
  • Validate with injected anomalies and auditor feedback
Key Topics to Cover
Isolation forest
Feature engineering
Explainability
Synthetic anomaly injection
Audit analytics
How to Approach This
  1. Understand the bias-variance trade-off. High training accuracy but low test accuracy signals overfitting.
  2. Choose evaluation metrics carefully based on the problem. Accuracy alone is often insufficient.
  3. Feature engineering is often more impactful than model selection.
  4. Know when to use tree-based models (tabular data) vs neural networks (unstructured data).
  5. Handle class imbalance with SMOTE, class weights, or appropriate loss functions.
Possible Follow-up Questions
  • How would you use the few entries auditors confirmed as issues in prior years?
  • How do you avoid the model just flagging every large entry?
  • How would you transfer this across clients with different charts of accounts?
Sharpen Your Skills on Codemia

Practice similar problems with our interactive workspace, get AI feedback, and track your progress.

Explore ML Interview Prep
Sample Answer
Clarify

The goal is a ranked list for targeted testing, not an automated fraud verdict. Data is one fiscal year of GL entries for one client, millions of lines, with account codes, poster, source system, time...

Approach

Features per entry: log absolute amount and its z-score within the debited account; rarity of the debit-credit account pair (how often this combination appears, a strong signal for odd postings like r...


Submit Your Answer
Markdown supported

Related Questions