|By Roger Barga, Avinash Joshi, Pravin Venugopal||
|June 27, 2014 10:15 AM EDT||
This article explores how to detect fraud among online banking customers in real-time by running an ensemble of statistical and machine learning algorithms on a dataset of customer transactions and demographic data. The algorithms, namely Logistic Regression, Self-Organizing Maps and Support Vector Machines, are operationalized using a multi-agent framework for real-time data analysis. This article also explores the cloud environment for real-time analytics by deploying the agent framework in a cloud environment that meets computational demands by letting users' provision virtual machines within managed data centers, freeing them from the worry of acquiring and setting up new hardware and networks.
Real-time decision making is becoming increasingly valuable with the advancement of data collection and analytics techniques. Due to the increase in the speed of processing, the classical data warehousing model is moving toward a real-time model. A platform that enables the rapid development and deployment of applications, reducing the lag between data acquisition and actionable insight has become of paramount importance in the corporate world. Such a system can be used for the classic case of deriving information from data collected in the past and also to have a real-time engine that reacts to events as they occur. Some examples of such applications include:
- A product company can get real-time feedback for their new releases using data from social media
- Algorithmic trading by reacting in real times to fluctuations in stock prices
- Real-time recommendations for food and entertainment based on a customer's location
- Traffic signal operations based on real-time information of volume of traffic
- E-commerce websites can detect a customer transaction being authentic or fraudulent in real-time
A cloud-based ecosystem enables users to build an application that detects, in real-time, fraudulent customers based on their demographic information and financial history. Multiple algorithms are utilized to detect fraud and the output is aggregated to improve prediction accuracy.
The dataset used to demonstrate this application comprises of various customer demographic variables and financial information such as age, residential address, office address, income type, income frequency, bankruptcy filing status, etc. The dependent variable (the variable to be predicted) is called "bad", which is a binary variable taking the value 0 (for not fraud) or 1 (for fraud).
Using Cloud for Effective Usage of Resources
A system that allows the development of applications capable of churning out results in real-time has multiple services running in tandem and is highly resource intensive. By deploying the system in the cloud, maintenance and load balancing of the system can be handled efficiently. It will also give the user more time to focus on application development. For the purpose of fraud detection, the active components, for example, include:
- Web services
This approach combines the strengths and synergies of both cloud computing and machine learning technologies, providing a small company or even a startup that is unlikely to have specialized staff and necessary infrastructure for what is a computationally intensive approach, the ability to build a system that make decisions based on historical transactions.
As multiple algorithms are to be run on the same data, a real-time agent paradigm is chosen to run these algorithms. An agent is an autonomous entity that may expect inputs and send outputs after performing a set of instructions. In a real-time system, these agents are wired together with directed connections to form an agency. An agent typically has two behaviors, cyclic and triggered. Cyclic agents, as the name suggests, run continuously in a loop and do not need any input. These are usually the first agents in an agency and are used for streaming data to the agency by connecting to an external real-time data source. A triggered agent runs every time it receives a message from a cyclic agent or another triggered agent. Once it consumes one message, it waits for the next message to arrive.
Figure 1: A simple agency with two agents
In Figure 1, Agent 1 is a cyclic agent while Agent 2 is a triggered agent. Agent 1 finishes its computation and sends a message to Agent 2, which uses the message as an input for further computation.
Feature Selection and Data Treatment
The dataset used for demonstrating fraud detection agency has 250 variables (features) pertaining to the demographic and financial history of the customers. To reduce the number of features, a Random Forest run was conducted on the dataset to obtain variable importance. Next, the top 30 variables were selected based on the variable importance. This reduced dataset was used for running a list of classification algorithms.
Algorithms for Fraud Detection
The fraud detection problem is a binary classification problem for which we have chosen three different algorithms to classify the input data into fraud (1) and not fraud (0). Each algorithm is configured as a triggered agent for our real-time system.
This is a probabilistic classification model where the dependent variable (the variable to be predicted) is a binary variable or a categorical variable. In case of binary dependent variables favorable outcomes are represented as 1 and non-favorable outcomes are represented as 0. Logistic regression models the probability of the dependent variable taking the value 0 or 1.
For the fraud detection problem, the dependent variable "bad" is modelled to give probabilities to each customer of being fraud or not. The equation takes multiple variables as input and returns a value between 0 & 1 which is the probability of "bad" being 0. If this value is greater than 0.7, then that customer is classified as not fraud.
Self-Organizing Maps (SOM)
This is an artificial neural network that uses unsupervised learning to represent the data in lower (typically two dimensions) dimensions. This representation of the input data in lower dimensions is called a map. Like most artificial neural networks, SOMs operate in two modes: training and mapping. "Training" builds the map using input examples, while "mapping" automatically classifies a new input vector.
For the fraud detection problem, the input space which is a fifty dimensional space is mapped to a two dimensional lattice of nodes. The training is done using data from the recent past and the new data is mapped using the trained model, which puts it either in the "fraud" cluster or "not - fraud" cluster.
Figure 2: x is an in-put vector in higher dimension, discretized in 2D using wij as the weight matrix
Image Source: http://www.lohninger.com/helpcsuite/kohonen_network_-_background_information.htm
Support Vector Machines (SVM)
This is a supervised learning technique used generally for classifying data. It needs a training dataset where the data is already classified into the required categories. It creates a hyperplane or set of hyperplanes that can be used for classification. The hyperplane is chosen such that it separates the different classes and the margin between the samples in the training set is widest.
For the fraud detection problem, SVM classifies the data points into two classes. The hyperplane is chosen by training the model over the past data. Using the variable "bad", the clusters are labeled as "0" (fraud) and "1" (not fraud). The new data points are classified using the hyperplane obtained while training.
Figure 3: Of the three hyperplanes which segment the data, H2 is the hyperplane which classifies the data accurately
Image Source: http://en.wikipedia.org/wiki/File:Svm_separating_hyperplanes.png
Fraud Detection Agency
A four-tier agency is created to build a workflow process for fraud detection.
Streamer Agent (Tier 1): This agent streams data in real-time to agents in Tier 2. It is the first agent in the agency and its behavior is cyclic. It connects to a real-time data source, pre-processes the data and sends it to the agents in the next layer.
Algorithm Agents (Tier 2): This tier has multiple agents running an ensemble of algorithms with one agent per algorithm. Each agent receives the message from the streamer agent and uses a pre-trained (trained on historical data) model for scoring.
Collator Agent (Tier 3): This agent receives scores from agents in Tier 2 and generates a single score by aggregating the scores. It then converts the score into an appropriate JSON format and sends it to an UI agent for consumption.
User Interface Agent (Tier 4): This agent pushes the messages it receives to a socket server. Any external socket client can be used to consume these messages.
Figure 4: The Fraud detection agency with agents in each layer. The final agent is mapped to a port to which a socket client can connect
Results and Model Validation
The models were trained on 70% of the data and the remaining 30% of the data was streamed to the above agency simulating a real-time data source.
Under-sample: The ratio of number of 0s to the number of 1s in the original dataset for the variable "bad" is 20:1. This would lead to biasing the models towards 0. To overcome this, we sample the training dataset by under-sampling the number of 0s to maintain the ration at 10:1.
The final output of the agency is the classification of the input as fraudulent or not. Since the value for the variable "bad" is already known for this data, it helps us gauge the accuracy of the aggregated model.
Figure 5: Accuracy for detecting fraud ("bad"=1) for different sampling ratio between no.of 0s and no. of 1s in the training dataset
Fraud detection can be improved by running an ensemble of algorithms in parallel and aggregating the predictions in real-time. This entire end-to-end application was designed and deployed in three working days. This shows the power of a system that enables easy deployment of real-time analytics applications. The work flow becomes inherently parallel as these agents run as separate processes communicating with each other. Deploying this in the cloud makes it horizontally scalable owing to effective load balancing and hardware maintenance. It also provides higher data security and makes the system fault tolerant by making processes mobile. This combination of a real-time application development system and a cloud-based computing enables even non-technical teams to rapidly deploy applications.
- Gravic Inc, "The Evolution of Real-Time Business Intelligence", "http://www.gravic.com/shadowbase/pdf/white-papers/Shadowbase-for-Real-Time-Business-Intelligence.pdf"
- Bernhard Schlkopf, Alexander J. Smola ( 2002), "Learning with Kernels: Support Vector Machines, Regularization, Optimization, and Beyond (Adaptive Computation and Machine Learning)", MIT Press
- Christopher Burges (1998), "A Tutorial on Support Vector Machines for Pattern Recognition", Data Mining and Knowledge Discovery, Kluwer Publishers
- Kohonen, T. (Sep 1990), "The self-organizing map", Proceedings of IEEE
- Samuel Kaski (1997), "Data Exploration Using Self-Organizing Maps", ACTA POLYTECHNICA SCANDINAVICA: MATHEMATICS, COMPUTING AND MANAGEMENT IN ENGINEERING SERIES NO. 82,
- Rokach, L. (2010). "Ensemble based classifiers". Artificial Intelligence Review
- Robin Genuer, Jean-Michel Poggi, Christine Tuleau-Malot, "Variable Selection using Random Forests", http://robin.genuer.fr/genuer-poggi-tuleau.varselect-rf.preprint.pdf
In his session at @ThingsExpo, Tony Shan, Chief Architect at CTS, will explore the synergy of Big Data and IoT. First he will take a closer look at the Internet of Things and Big Data individually, in terms of what, which, why, where, when, who, how and how much. Then he will explore the relationship between IoT and Big Data. Specifically, he will drill down to how the 4Vs aspects intersect with IoT: Volume, Variety, Velocity and Value. In turn, Tony will analyze how the key components of IoT influence Big Data: Device, Connectivity, Context, and Intelligence. He will dive deep to the matrix...
Oct. 6, 2015 06:00 AM EDT Reads: 246
Scott Guthrie's keynote presentation "Journey to the intelligent cloud" is a must view video. This is from AzureCon 2015, September 29, 2015 I have reproduced some screen shots in case you are unable to view this long video for one reason or another. One of the highlights is 3 datacenters coming on line in India.
Oct. 6, 2015 05:45 AM EDT Reads: 155
The broad selection of hardware, the rapid evolution of operating systems and the time-to-market for mobile apps has been so rapid that new challenges for developers and engineers arise every day. Security, testing, hosting, and other metrics have to be considered through the process. In his session at Big Data Expo, Walter Maguire, Chief Field Technologist, HP Big Data Group, at Hewlett-Packard, will discuss the challenges faced by developers and a composite Big Data applications builder, focusing on how to help solve the problems that developers are continuously battling.
Oct. 6, 2015 04:00 AM EDT Reads: 407
When it comes to IoT in the enterprise, namely the commercial building and hospitality markets, a benefit not getting the attention it deserves is energy efficiency, and IoT’s direct impact on a cleaner, greener environment when installed in smart buildings. Until now clean technology was offered piecemeal and led with point solutions that require significant systems integration to orchestrate and deploy. There didn't exist a 'top down' approach that can manage and monitor the way a Smart Building actually breathes - immediately flagging overheating in a closet or over cooling in unoccupied ho...
Oct. 5, 2015 11:45 PM EDT Reads: 200
SYS-CON Events announced today that IBM Cloud Data Services has been named “Bronze Sponsor” of SYS-CON's 17th Cloud Expo, which will take place on November 3–5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. IBM Cloud Data Services offers a portfolio of integrated, best-of-breed cloud data services for developers focused on mobile computing and analytics use cases.
Oct. 5, 2015 11:00 PM EDT Reads: 608
The enterprise is being consumerized, and the consumer is being enterprised. Moore's Law does not matter anymore, the future belongs to business virtualization powered by invisible service architecture, powered by hyperscale and hyperconvergence, and facilitated by vertical streaming and horizontal scaling and consolidation. Both buyers and sellers want instant results, and from paperwork to paperless to mindless is the ultimate goal for any seamless transaction. The sweetest sweet spot in innovation is automation. The most painful pain point for any business is the mismatch between supplies a...
Oct. 5, 2015 03:30 PM EDT Reads: 126
Mobile messaging has been a popular communication channel for more than 20 years. Finnish engineer Matti Makkonen invented the idea for SMS (Short Message Service) in 1984, making his vision a reality on December 3, 1992 by sending the first message ("Happy Christmas") from a PC to a cell phone. Since then, the technology has evolved immensely, from both a technology standpoint, and in our everyday uses for it. Originally used for person-to-person (P2P) communication, i.e., Sally sends a text message to Betty – mobile messaging now offers tremendous value to businesses for customer and empl...
Oct. 5, 2015 01:15 PM EDT Reads: 158
SYS-CON Events announced today that ProfitBricks, the provider of painless cloud infrastructure, will exhibit at SYS-CON's 17th International Cloud Expo®, which will take place on November 3–5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. ProfitBricks is the IaaS provider that offers a painless cloud experience for all IT users, with no learning curve. ProfitBricks boasts flexible cloud servers and networking, an integrated Data Center Designer tool for visual control over the cloud and the best price/performance value available. ProfitBricks was named one of the coolest Clo...
Oct. 5, 2015 01:00 PM EDT Reads: 724
“The Internet of Things transforms the way organizations leverage machine data and gain insights from it,” noted Splunk’s CTO Snehal Antani, as Splunk announced accelerated momentum in Industrial Data and the IoT. The trend is driven by Splunk’s continued investment in its products and partner ecosystem as well as the creativity of customers and the flexibility to deploy Splunk IoT solutions as software, cloud services or in a hybrid environment. Customers are using Splunk® solutions to collect and correlate data from control systems, sensors, mobile devices and IT systems for a variety of Ind...
Oct. 5, 2015 12:00 PM EDT Reads: 572
Organizations already struggle with the simple collection of data resulting from the proliferation of IoT, lacking the right infrastructure to manage it. They can't only rely on the cloud to collect and utilize this data because many applications still require dedicated infrastructure for security, redundancy, performance, etc. In his session at 17th Cloud Expo, Emil Sayegh, CEO of Codero Hosting, will discuss how in order to resolve the inherent issues, companies need to combine dedicated and cloud solutions through hybrid hosting – a sustainable solution for the data required to manage I...
Oct. 5, 2015 12:00 PM EDT Reads: 420
You have your devices and your data, but what about the rest of your Internet of Things story? Two popular classes of technologies that nicely handle the Big Data analytics for Internet of Things are Apache Hadoop and NoSQL. Hadoop is designed for parallelizing analytical work across many servers and is ideal for the massive data volumes you create with IoT devices. NoSQL databases such as Apache HBase are ideal for storing and retrieving IoT data as “time series data.”
Oct. 5, 2015 11:45 AM EDT Reads: 447
Clearly the way forward is to move to cloud be it bare metal, VMs or containers. One aspect of the current public clouds that is slowing this cloud migration is cloud lock-in. Every cloud vendor is trying to make it very difficult to move out once a customer has chosen their cloud. In his session at 17th Cloud Expo, Naveen Nimmu, CEO of Clouber, Inc., will advocate that making the inter-cloud migration as simple as changing airlines would help the entire industry to quickly adopt the cloud without worrying about any lock-in fears. In fact by having standard APIs for IaaS would help PaaS expl...
Oct. 5, 2015 11:30 AM EDT Reads: 435
As more and more data is generated from a variety of connected devices, the need to get insights from this data and predict future behavior and trends is increasingly essential for businesses. Real-time stream processing is needed in a variety of different industries such as Manufacturing, Oil and Gas, Automobile, Finance, Online Retail, Smart Grids, and Healthcare. Azure Stream Analytics is a fully managed distributed stream computation service that provides low latency, scalable processing of streaming data in the cloud with an enterprise grade SLA. It features built-in integration with Azur...
Oct. 5, 2015 10:00 AM EDT Reads: 730
Apps and devices shouldn't stop working when there's limited or no network connectivity. Learn how to bring data stored in a cloud database to the edge of the network (and back again) whenever an Internet connection is available. In his session at 17th Cloud Expo, Bradley Holt, Developer Advocate at IBM Cloud Data Services, will demonstrate techniques for replicating cloud databases with devices in order to build offline-first mobile or Internet of Things (IoT) apps that can provide a better, faster user experience, both offline and online. The focus of this talk will be on IBM Cloudant, Apa...
Oct. 5, 2015 09:45 AM EDT Reads: 436
SYS-CON Events announced today that HPM Networks will exhibit at the 17th International Cloud Expo®, which will take place on November 3–5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. For 20 years, HPM Networks has been integrating technology solutions that solve complex business challenges. HPM Networks has designed solutions for both SMB and enterprise customers throughout the San Francisco Bay Area.
Oct. 5, 2015 09:00 AM EDT Reads: 563
As enterprises capture more and more data of all types – structured, semi-structured, and unstructured – data discovery requirements for business intelligence (BI), Big Data, and predictive analytics initiatives grow more complex. A company’s ability to become data-driven and compete on analytics depends on the speed with which it can provision their analytics applications with all relevant information. The task of finding data has traditionally resided with IT, but now organizations increasingly turn towards data source discovery tools to find the right data, in context, for business users, d...
Oct. 5, 2015 08:00 AM EDT Reads: 376
SYS-CON Events announced today that MobiDev, a software development company, will exhibit at the 17th International Cloud Expo®, which will take place November 3-5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. MobiDev is a software development company with representative offices in Atlanta (US), Sheffield (UK) and Würzburg (Germany); and development centers in Ukraine. Since 2009 it has grown from a small group of passionate engineers and business managers to a full-scale mobile software company with over 150 developers, designers, quality assurance engineers, project manage...
Oct. 5, 2015 05:00 AM EDT Reads: 726
Learn how IoT, cloud, social networks and last but not least, humans, can be integrated into a seamless integration of cooperative organisms both cybernetic and biological. This has been enabled by recent advances in IoT device capabilities, messaging frameworks, presence and collaboration services, where devices can share information and make independent and human assisted decisions based upon social status from other entities. In his session at @ThingsExpo, Michael Heydt, founder of Seamless Thingies, will discuss and demonstrate how devices and humans can be integrated from a simple clust...
Oct. 4, 2015 12:00 PM EDT Reads: 623
SYS-CON Events announced today that Cloud Raxak has been named “Media & Session Sponsor” of SYS-CON's 17th Cloud Expo, which will take place on November 3–5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. Raxak Protect automates security compliance across private and public clouds. Using the SaaS tool or managed service, developers can deploy cloud apps quickly, cost-effectively, and without error.
Oct. 3, 2015 01:15 PM EDT Reads: 582
Who are you? How do you introduce yourself? Do you use a name, or do you greet a friend by the last four digits of his social security number? Assuming you don’t, why are we content to associate our identity with 10 random digits assigned by our phone company? Identity is an issue that affects everyone, but as individuals we don’t spend a lot of time thinking about it. In his session at @ThingsExpo, Ben Klang, Founder & President of Mojo Lingo, will discuss the impact of technology on identity. Should we federate, or not? How should identity be secured? Who owns the identity? How is identity ...
Oct. 3, 2015 11:00 AM EDT Reads: 416