Icon

Contracts_Fraud_Detection_Usecase_example

Outlier Dection / Fraud Detection in Contracts
Annotations and comments
  • Outlier Detection / Fraud Detection in Contracts Discover anomalies in contracts payment amounts via: - data visualization - basic stats - clustering - isolation forest
  • Finding outliers via visual and stats
  • Finding outliers via basic stats
  • Loading the Contracts 100 contracts as pdf files transformed into Document objects
  • We are going to use RegEx to extract the following information from each contract - Date: the date, on which the contract was signed - Contract ID: Each document contains a 7-charecter ID (e.g. C000058) - Payment Amount`: Each document contain a payment amount
  • Finding outliers via clustering on one or more features
  • Finding outliers via Isolation Forest
  • color on payments
  • Extracting Date, Contract ID and Payment amount using Regex
  • Filtering Date, Contract ID and Payment columns
  • Extract Text of each PDF
  • Sort the rows by the date
  • remove original contract ID
  • Learn the Isolation Forest with 10 trees & 10 levels
  • Predict anomaly scores.
  • Start local H2O Node.
  • Convert H2O Frame back to table.
  • visualize Prediction scores
  • visualize mean length scores
  • Join the result table with the original table based on contract ID column
  • |z| > thr? thr = 80
  • sort the rows by the anomaly score [0 - 100] (Prediction)
  • contract ID as number
  • back to original contract ID
  • Import data to H2O Frame.
  • to [0, 1]
  • z-score
  • finding outliers
  • Getting the text from PDFs
  • list of outliers
  • Fiding Outliers Visually using a barchart
  • Fiding Outliers Visually using a box plot
  • adding color cue on payments
  • Histogram on 100 bins
  • Fiding Outliers Visually using scatter plot
  • Title
  • list outliers if selected
  • show outliers via bar chart
  • count outliers
  • join back with original data
  • filter if outliers yes < 10 If outliers yes > 10 probably they are not outliers
  • show Outliers via scatter plot
  • find outliers via bar chart
  • counting outliers
  • eps =0.1 min. points = 3
  • showing outliers via bar chart
  • Showing Outliers via scatter plot
  • 3 clusters
  • |z|
  • sign(z)
  • |z| > thr?

Nodes

Extensions

Links