Code Monkey home page Code Monkey logo

azure-realtime-fraud-detection's Introduction

Real-Time Fraud Detection on Azure

The detection of possible fraud in financial systems has been one of the significant challenges of several organizations worldwide. In this sense, enabling the development of robust solutions that allow real-time actions is increasingly important for companies that seek to ensure greater security for their customers in carrying out financial transactions.

This repository presents a reference architecture that allows the development of Machine Learning models to be integrated into a real-time fraud detection platform.

In addition, the architecture also allows a series of asynchronous processes to be triggered near-real-time, aiming to feed monitoring dashboards and execute data enrichment routines that can support the fraud detection process.

We demonstrate routines that perform the calculation of Benford's Law and the construction of graphs to identify Fraud Rings to enable advances in fraud prevention.

For this, several Azure resources are used. Below the Reference Architecture:

Fraud Detection Architecture

Please check the prerequisites and step-by-step instructions for configuring the resources used in the items below.

Prerequisites

To use this repository, you need access to an Azure subscription. Below we will show the steps to deploy and configure the services.

While it's not required, a basic understanding of some services used will be helpful for understanding the solution. The following resources can help introduce you to them:

  1. Azure Machine Learning Overview
  2. Azure Functions
  3. Azure Event Hub
  4. Azure Stream Analytics
  5. Azure Synapse
  6. Azure Cosmos DB

Getting started

1. Deploy Resources

Start by deploying the resources to Azure. The button below will deploy All the services and its related resources:

2. Configure Azure ML Environment

Next you'll need to configure your development environment for Azure Machine Learning. We recommend using an Azure ML Workspace as it's the fastest way to get up and running.

Now you can use the AML environment. Let's train and deploy the Machine Learning model.

Train and Deploy the model

3. Configure Stream Analytics

We will configure a Stream Analytics Job to consume the inputs from Event Hub and persist the outputs to an Azure Synapse SQL Pool and to a Cosmos DB SQL API. In this way we can use the outputs to feed some other processes.

Configure Stream Analytics Job

4. Configure Cosmos DB

We need to load some data to our Cosmos DB SQL API account. The link below provide a process to do that.

Configure Cosmos DB - SQL API

5. Deploy the Functions

Finally, we have to deploy the Functions. Follow the link below to proceed with this task. How to Deploy the Functions

To Do

  1. Develop Profile Analytics Function
  2. Calculate scores from Graph db, Benford Law, and Profile Analytics
  3. Integrate scores into Orquestrator function
  4. Develop new supervised ML models

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.

When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

Trademarks

This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow Microsoft's Trademark & Brand Guidelines. Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies.

azure-realtime-fraud-detection's People

Contributors

alfeuduran avatar lfbraz avatar microsoftopensource avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

iamsingularity

azure-realtime-fraud-detection's Issues

Not enough quota available

Hi

I'm learning Azure for the first time and using this repository to get started.

When I was trying to run deployment from 3 - Fraud Detection - Deploy.ipynb using this code

!az ml online-deployment create --name fraud-ga --endpoint frddetz01 -f ../deployment/deployment.yml --all-traffic

I got the following error. I am currently using Azure free trial and not able to request additional quota.

Any solution?

Exception Details:	(InferencingClientCreateDeploymentFailed) InferencingClient HttpRequest error, error detail: {"errors":{"VmSize":["Not enough quota available for Standard_F16s_v2 in SubscriptionId 671ef6e1-2ded-466b-8fd1-91363cf12275. Current usage/limit: 0/6. Additional needed: 32 Please see troubleshooting guide, available here: [https://aka.ms/oe-tsg#error-outofquota"]},"type":"https://tools.ietf.org/html/rfc7231#section-6.5.1","title":"One](https://aka.ms/oe-tsg#error-outofquota%22]},%22type%22:%22https://tools.ietf.org/html/rfc7231#section-6.5.1%22,%22title%22:%22One) or more validation errors occurred.","status":400,"traceId":"00-3eb668e879d9273d87790a81c78c020f-ad804ab26cffa0ce-01"}
	Code: InferencingClientCreateDeploymentFailed

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.