AI/ML based Card Payment Fraud Detection on AWS using replicated data from mainframe

Amazon Web Services
29 May 202415:34

Summary

TLDRこのビデオでは、AWS上でAIMLベースのカード詐欺検出ソリューションを構築する方法を紹介します。ZOSメインフレーム上のカード支払い承認アプリケーションは、静的なビジネスルールを使って取引を承認または拒否します。レガシーアプリケーションは、AWSにリアルタイムでアクセスしてAmazon詐欺検出サービスまたはSageMakerで構築された他のAIMLモデルによって詐欺スコアを生成するように強化されています。モデルは、過去48時間の顧客購入履歴や過去24時間の売主販売履歴などの属性でトレーニングされています。スコアの推論中に同じ属性がモデルに渡され、最適なスコアを生成します。ソリューションアーキテクチャは、顧客がターミナルでカードをスワイプしたりオンラインで購入したりすると、銀行はメインフレームシステムで承認リクエストを受け取り、アプリケーションはAWSにリアルタイムでアクセスしてAIMLスコアリングモデルに顧客と売主の履歴を提供します。高いスコアは潜在的な詐欺取引を示します。メインフレームアプリケーションは他のビジネスルールと組み合わせて取引を承認または拒否する決定を行います。詳細はメインフレームデータベースに挿入され、ほぼリアルタイムでAWSに適用されます。

Takeaways

  • 😀 ビデオではAWS上でAIMLベースのカード詐欺検出ソリューションの構築方法を紹介しています。
  • 🏢 既存のZOSメインフレーム上のカード支払い承認アプリケーションは静的なビジネスルールを使用してトランザクションを承認または拒否します。
  • 🔄 レガシーアプリケーションはAWSにリアルタイムで詐欺スコアを取得するための呼び出しを行い、Amazon Fraud DetectorサービスまたはSageMakerで構築された他のAIMLモデルによって強化されています。
  • 🛍️ モデルは過去48時間の顧客の購入履歴や過去24時間における販売者の売上履歴などの属性を使用してトレーニングされています。
  • 📊 スコア推定の際には、同様の属性がモデルに渡され、最適なスコアを生成します。
  • 💳 カードをターミナルでスワイプしたりオンラインで購入をした場合、銀行のメインフレームシステムは承認リクエストを受け取り、AWSへのリアルタイム呼び出しを行います。
  • 🔎 AWS上で動作するプロセスはリレーショナルデータベースから顧客および商人の履歴詳細を取得し、AIMLスコアリングモデルに提供します。
  • ✅ 高いスコアは潜在的な不正取引を示し、メインフレームアプリケーションは他のビジネスルールと組み合わせてトランザクションを承認または拒否する決定を行います。
  • 🔄 詳細はメインフレームデータベースに挿入され、Precisely Publisher AgentとApply Agentを使用してほぼリアルタイムでAWSにレプリケートされます。
  • 📚 S3上でオフラインでAIMLモデルをトレーニングするために使用されるデータは、MSKからストリーミングされます。
  • 📈 Amazon Redshiftを使用してビジネスユーザーは自然言語でクエリを実行し、ビジネスインサイトを得ることができます。

Q & A

  • AWS上で構築されたカード詐欺検出ソリューションの主な目的は何ですか?

    -AWS上で構築されたカード詐欺検出ソリューションは、リアルタイムでAmazon Fraud Detectorサービスまたは他のAI/MLモデルを使用して詐欺スコアを生成し、カード支払い承認アプリケーションを強化するものです。

  • レガシーアプリケーションはどのようにしてAI/MLモデルと連携していますか?

    -レガシーアプリケーションはリアルタイムでAWSにコールを行い、AI/MLモデルから詐欺スコアを取得します。これにより、ビジネスルールと組み合わせて取引の承認または拒否の決定を下します。

  • モデルはどのような属性を使用してトレーニングされていますか?

    -モデルは顧客の購入履歴(過去48時間の購入回数など)や商人の販売履歴(過去24時間の報告された詐欺など)などの属性を使用してトレーニングされています。

  • メインフレームアプリケーションはどのようにしてAWSと通信していますか?

    -メインフレームアプリケーションはリアルタイムでAWSにコールをかけ、AWS上で実行されているプロセスはリレーショナルデータベースから顧客と商人の履歴詳細を取得し、AIMLスコアリングモデルに提供します。

  • どのようなAWSリソースが作成され使用されていますか?

    -作成されたAWSリソースには、VPC、サブネット、プライベートリンクエンドポイント、MSKクラスター、RDSポスターデータベースインスタンス、Lambda関数、SNSトピックなどがあります。

  • Precisely Publisher AgentとApply Agentはどのような役割を持っていますか?

    -Precisely Publisher Agentはメインフレーム上で動作し、データベースの変更をキャプチャしてMSKに配信します。Apply AgentはAmazon EC2インスタンス上で動作し、MSKからの生データベースログをコピーブックを使用してJSON形式に変換し、Amazon Managed Streaming for Kafkaに配信します。

  • データはどのようにしてAmazon S3にストリーミングされるのですか?

    -MSKからAmazon S3にデータをストリーミングするために、Firehoseを使用してコードなしで統合しています。

  • Amazon Redshiftを使用して自然言語でクエリを実行することはどのように行われますか?

    -Amazon RedshiftのGenerative SQLを使用すると、自然言語で記述されたクエリを実行できます。Redshiftは大きな言語モデルを活用して、自然言語の要求を理解し、データベースを検索してSQLクエリを生成します。

  • AWS CloudFormationテンプレートを使用する利点は何ですか?

    -AWS CloudFormationテンプレートを使用することで、VPC、サブネット、IAMロールなどのAWSリソースの事前構築を簡素化し、迅速にデプロイすることができます。

  • メインフレームからのデータレプリケーションソフトウェアをどのように取得しますか?

    -AWS MarketplaceからPrecisely社のデータレプリケーションソフトウェアを取得し、購読の指示に従って設定します。

  • メインフレームとEC2インスタンスを接続するために必要な手順はどのようなものでしょうか?

    -メインフレームとEC2インスタンスを接続するためには、まずメインフレーム上で公開キーファイルを設定し、次にEC2インスタンス上で必要なソフトウェアをインストールし、最後にPreciselyの設定スクリプトを実行して接続を確立します。

Outlines

00:00

😀 AWS上のAIMLベースカード詐欺検出ソリューションの構築

このビデオでは、AWS上でAIML(人工知能マシンラーニング)を使用したカード詐欺検出ソリューションの構築方法を紹介します。ZOSメインフレーム上のカード支払い承認アプリケーションは、静的なビジネスルールを使って取引を承認または拒否します。レガシーアプリケーションは、AWSにリアルタイムでアクセスしてAmazon Fraud DetectorサービスまたはSageMakerで構築された他のAIMLモデルから詐欺スコアを生成するように強化されています。モデルは、過去48時間の顧客購入履歴や過去24時間の販売者売上履歴などの属性でトレーニングされ、推論時に同じ属性がモデルに渡されて最適なスコアを生成します。ソリューションアーキテクチャでは、顧客がカードをターミナルでスワイプしたりオンラインで購入をしたりすると、銀行はメインフレームシステム上で承認リクエストを受け取り、アプリケーションはAWSにリアルタイムでアクセスして顧客と販売者の履歴を取得し、AIMLスコアリングモデルに提供します。高いスコアは潜在的な詐欺取引を示し、メインフレームアプリケーションは他のビジネスルールと組み合わせて取引を承認または拒否します。詳細はメインフレームデータベースに記録され、Amazon EC2インスタンス上で実行されるApply AgentによってAWSにほぼリアルタイムで反映されます。

05:01

🛠️ AWSリソースの設定とメインフレームとの統合

この段落では、AWS上で作成されたリソースとメインフレームとの統合について説明しています。AWS Marketplaceからメインフレームデータレプリケーションソフトウェアを取得し、Amazon EC2インスタンスを設定します。EC2インスタンスは、Kafka、SQLクライアント、IAMロールなどの必要なソフトウェアをインストールし、MSK(Amazon Managed Streaming for Apache Kafka)との通信に使用されるJavaライブラリをダウンロードして設定します。また、メインフレーム上で設定されるPrecisely(データレプリケーションツール)の認証に必要な公開鍵と秘密鍵を作成し、メインフレームにコピーします。メインフレーム上でカード支払い承認履歴がVSAMデータベースに保存されている場合、そのデータベースから変更ログを取得し、MSKに公開します。

10:03

🚀 MSK、S3、SNSとの統合とデータパイプラインの設定

このセクションでは、MSK、S3、SNSとの統合とデータパイプラインの設定方法について説明しています。MSKとS3の間のデータ配信を設定し、EventBridgeパイプを使用してSNSとの統合を行います。MSKからS3にデータを配信し、Lambda関数を使用してMSKからRDS(Relational Database Service)にデータを挿入します。さらに、EventBridgeパイプを設定して、MSKからSNSにメッセージをストリーミングし、メール通知を送信します。これらの設定により、リアルタイムのデータストリーミングと分析が可能になります。

15:04

🔍 Redshiftを使用した自然言語でのクエリと詐欺検出のデモンストレーション

最後の段落では、Redshiftを使用して自然言語でデータベースクエリを実行し、ビジネス洞察を提供する方法を紹介しています。RedshiftのGenerative SQL機能を使用して、自然言語で書かれた質問に応じてSQLクエリを生成し、データから洞察を引き出します。また、デモンストレーションでは、VSAMデータベースにレコードを挿入し、それがMSKを経由してRDSに反映される様子を見ることができます。さらに、S3に格納されたデータを使用してAIMLモデルをトレーニングし、詐欺検出ソリューションを強化する方法も説明されています。

Mindmap

Keywords

💡AIML

AIMLとは「Artificial Intelligence Markup Language」の略で、人工知能を用いたマークアップ言語です。このビデオでは、AIMLを用いてAWS上でカード詐欺検出ソリューションを構築しています。AIMLは、ビデオの主題である詐欺検出において、リアルタイムでの不正行為のスコア生成に使われます。例えば、「Amazon Fraud Detector service」はAIMLモデルとしてトレーニングされ、顧客の購入履歴などの属性を用いて最適なスコアを生成します。

💡AWS

AWSとは「Amazon Web Services」の略称で、クラウドコンピューティングサービスを提供するAmazonの部門です。ビデオではAWSを利用してカード詐欺検出ソリューションを構築しています。AWSは、リアルタイムのデータアクセス、ストレージ、分析など、多様なサービスを提供しており、ビデオのソリューションアーキテクチャにおいて中心的な役割を果たしています。

💡カード詐欺検出

カード詐欺検出とは、不正なカード取引を検知するプロセスを指します。ビデオでは、AWS上でAIMLモデルを構築し、カード支払いの承認または拒否をリアルタイムで判断するソリューションを示しています。このプロセスでは、顧客の購入履歴や商人の売上履歴などの属性を用いて、詐欺スコアを生成します。

💡リアルタイム

リアルタイムとは、即時にまたは遅延なく処理を行うことを指します。ビデオでは、リアルタイムコールを用いてAWSから詐欺スコアを取得し、そのスコアを基に取引の承認または拒否を決定するソリューションを構築しています。リアルタイムでのデータアクセスと分析は、ビデオのソリューションの重要な特徴です。

💡SagMaker

SagMakerは、AWSが提供する機械学習プラットフォームです。ビデオでは、SagMakerを使ってAIMLモデルをトレーニングしています。このプラットフォームは、データサイエンティストが機械学習モデルを簡単に構築、トレーニング、およびデプロイできるように設計されています。

💡Amazon Fraud Detector service

Amazon Fraud Detector serviceは、AWSが提供する詐欺検出サービスです。ビデオではこのサービスを使用して、顧客の購入履歴などの属性を分析し、詐欺スコアを生成しています。このサービスは、ビデオのソリューションアーキテクチャにおいて詐欺検出の中心的な役割を果たしています。

💡Mainframe

Mainframeは、大規模なデータ処理能力を持つコンピュータシステムです。ビデオでは、Mainframeシステム上でカード支払いの承認アプリケーションが動作し、AWSへのリアルタイムコールを行います。Mainframeは、ビデオのソリューションにおいて、既存のビジネスルールとAIMLモデルを統合する上で重要な役割を果たしています。

💡Relational Database

リレーショナルデータベースは、関係データモデルに基づくデータベースです。ビデオでは、AWS上で動作するプロセスがリレーショナルデータベースから顧客と商人の履歴詳細を取得し、AIMLスコアリングモデルに提供しています。リレーショナルデータベースは、ビデオのソリューションにおいて、データの格納と取得に使われています。

💡Amazon S3

Amazon S3は、AWSが提供するストレージサービスです。ビデオでは、S3を使用してオフラインでAIMLモデルをトレーニングするためのデータを保存しています。S3は、ビデオのソリューションにおいて、データの長期保存と分析に重要な役割を果たしています。

💡Amazon Redshift

Amazon Redshiftは、AWSが提供するデータウェアハウスサービスです。ビデオでは、Redshiftを使用してビジネスユーザーがデータに対してクエリを実行し、ビジネスインサイトを得ています。Redshiftは、ビデオのソリューションにおいて、データ分析とビジネスインテリジェンスに重要な役割を果たしています。

Highlights

展示如何在AWS上构建基于AIML的信用卡欺诈检测解决方案。

信用卡支付授权应用程序在ZOS大型机系统上运行,并使用静态业务规则来批准或拒绝交易。

通过AWS实时调用,使用Amazon Fraud Detection Service或其他任何使用SageMaker构建的AIML模型生成欺诈分数。

模型使用诸如客户购买历史和商家销售历史等属性进行训练。

在分数推理期间,相同的属性被传递到模型以生成最佳分数。

当客户刷卡或在线购物时,银行将在大型机系统上接收授权请求。

AWS上的应用程序将获取客户和商家历史详细信息,并提供给AIML评分模型。

较高的分数将表明潜在的欺诈交易。

大型机应用程序结合其他业务规则将决定批准或拒绝交易。

详细信息被插入到大型机数据库中,例如VSAM、DB2或IMS。

记录将被捕获并实时使用精确发布者代理重新应用到AWS。

精确发布者代理在大型机上运行,应用代理在Amazon EC2实例上运行。

应用代理将原始数据库日志转换为JSON格式,并发布消息到Amazon管理的流媒体服务。

消息将从MSK流式传输到Amazon S3,数据将用于离线训练AIML模型。

MSK的消息可以被拉取到Amazon Redshift,业务用户可以使用自然语言运行查询。

演示中创建了几个AWS资源,其中一些是使用CloudFormation模板预构建的。

从AWS Marketplace获取大型机数据复制软件。

设置Amazon EC2实例并安装精确软件。

在大型机上安装精确软件并配置发布者作业。

创建RDS Postgres表并验证表结构。

设置MSK S3交付通过Firehose和与SNS的集成通过EventBridge管道。

启动应用引擎并在VSAM数据库中插入一些记录。

使用Redshift的生成SQL以自然语言查询数据。

GitHub上提供了构建欺诈检测部分的代码示例。

Transcripts

play00:00

in this video we are going to show you

play00:01

how you can build an AIML based card

play00:03

fraud detection Solution on

play00:07

AWS in this use case the card payment

play00:10

authorization application is running on

play00:12

zos mainframe system and using static

play00:14

business rules to approve or decline the

play00:17

Legacy application is enhanced to make a

play00:19

real-time call to AWS to get a fraud

play00:21

score generated by Amazon fraud

play00:23

detection service or any other AIML

play00:25

model built using sag maker the model is

play00:28

trained with attributes such as as

play00:30

customer purchase history for example

play00:32

number of purchases in last 48 hours and

play00:34

Merchant sales history for example

play00:36

reported frauds in last 2 24 hours

play00:39

during inference of the score same

play00:40

attributes are passed to the model to

play00:42

generate optimal

play00:44

score let us review the solution

play00:47

architecture when a customer swipes a

play00:49

card at Terminal or makes an online

play00:51

purchase the bank will receive the

play00:53

authorization request on the mainframe

play00:54

system the application will make a

play00:57

real-time call to AWS the process

play00:59

running on AWS will get the customer and

play01:02

Merchant history details from relational

play01:04

database and provide to the AIML scoring

play01:06

model running on say Amazon fraud

play01:09

Detector service the model will return a

play01:11

score higher score will indicate

play01:13

potential fraudulent transaction the

play01:16

Mainframe application combining with the

play01:18

other business rule will make a decision

play01:20

to approve or decline the transaction

play01:23

detail is inserted on Mainframe database

play01:25

either vsam db2 or IMS the record will

play01:29

be captured and rep applicated to AWS

play01:31

near real time using precisely the

play01:33

precisely publisher agent is running on

play01:35

Mainframe and the apply agent is running

play01:37

on an Amazon ec2 instance the apply

play01:40

agent converts raw database logs

play01:42

received from publisher agent to Json

play01:44

format using the copy book and publishes

play01:46

the messages to Amazon managed streaming

play01:48

for cofco or msk several service will

play01:51

consume the message from msk a kovka

play01:54

connect process can pull the messages

play01:56

from msk and write to RDS database the

play01:59

history detail details are read from

play02:00

same database during the scoring process

play02:03

MSG will stream the messages to Amazon

play02:05

S3 using no code integration with fire

play02:08

hose the data on S3 will be used offline

play02:11

to train the AIML models along with

play02:13

other internal or external data sources

play02:16

for analytics and business intelligence

play02:18

the messages from msk can be pulled to

play02:20

Amazon red shift business users can run

play02:23

query against the database using natural

play02:25

language similarly other integration may

play02:28

be built using Amazon event Bridge pipe

play02:30

to stream data to services like Amazon

play02:32

SNS or pinpoint for notification and

play02:34

alerting in this demonstration there are

play02:37

several AWS resources created some of

play02:40

them are pre-built using cloud formation

play02:42

template this includes VPC subnets I am

play02:46

roles AWS Key Management Service

play02:51

Etc on AWS console we can see there is a

play02:54

VPC created with three

play02:58

subnets private link end points are

play03:00

created for access to seress services

play03:03

such as secret manager STS event Bridge

play03:05

pipes

play03:10

Etc a msk cluster is defined in the VPC

play03:13

with three Brokers and three different

play03:18

subnets both I am and sasl a

play03:21

password-based authentication is

play03:24

enabled the credentials are stored in

play03:26

secret manager the bootstrap servers

play03:29

detail for both IM and sasl

play03:31

authentication types are available in

play03:33

client

play03:38

information RDS posters database

play03:41

instance would DB name as card payments

play03:47

fraud a Lambda function is created to

play03:50

pull the messages from msk and insert

play03:52

RDS posters

play03:56

database the function will be running in

play03:58

the same VPC

play04:01

the environment variables are set for

play04:03

RDS database connection

play04:07

details a SNS topic messages from msk

play04:10

will be streamed to SNS using an event

play04:12

Bridge pipe the SNS topic is configured

play04:15

to send email notification first we are

play04:17

going to obtain the Mainframe data

play04:19

replication software from Marketplace

play04:22

from AWS console search for

play04:26

Marketplace click discover products

play04:32

type AWS Mainframe migration with

play04:34

precisely on search

play04:36

bar click on data replication for IBM

play04:41

zos then click continue to subscribe

play04:44

button follow the instructions to

play04:46

complete subscription next we are going

play04:48

to set up the amazon ec2 instance once

play04:51

you have completed the subscription come

play04:53

back to AWS Marketplace console and

play04:55

click manage subscriptions then click

play04:58

launch new instance click continue to

play05:00

launch through

play05:04

ec2 provide a name for the ec2

play05:08

instance scroll down to network settings

play05:10

and click

play05:12

edit select the VPC created for this

play05:14

solution select one of the

play05:17

subnet click on select existing Security

play05:20

Group and from the drop down on common

play05:22

Security Group select the security group

play05:24

created for the

play05:26

solution expand the advanced details and

play05:29

click existing I am roll and select

play05:31

instance profile created by cloud

play05:36

formation paste the script in the user

play05:38

data text box the script first installs

play05:41

the required software such as Liber

play05:43

kofka poster SQL client Etc then it

play05:47

creates a Kafka folder downloads and

play05:49

extracts the Java Kafka libraries inside

play05:52

the Kafka Libs folder downloads the msk

play05:55

am jar file it creates an I am

play05:58

authentication client properties file

play06:00

the jar and the properties file are used

play06:02

by the javascripts runs the kofka topic

play06:05

script to create the kofka topic

play06:07

precisely publisher will publish the

play06:09

records to this topic then runs the

play06:12

kofka consumer group script to create a

play06:14

consumer group to be used later by the

play06:15

even Bridge pipe andc broker details

play06:18

have to be passed as one of the

play06:19

parameter for the scripts next it

play06:22

creates a precisely folder and then the

play06:24

sasl producer configuration file for

play06:27

precisely sets the path variable to

play06:29

include precisely B directory and runs

play06:31

the school key gen command to create the

play06:33

private and public key file for

play06:34

precisely the content of the public key

play06:37

file has to be copied to main frame and

play06:38

added in key file for demon for

play06:41

authentication click launch instance to

play06:43

launch a new ec2 instance with precisely

play06:45

software installed next click on the

play06:47

instance ID to open the details page for

play06:50

the ec2 created click the connect

play06:52

[Music]

play06:54

button type ec2 user for

play06:57

username then click connect

play07:02

this will open the ec2 command line the

play07:05

ec2 user data script created the public

play07:08

private key files for precisely the

play07:10

naacl directory contains the public key

play07:13

file to be copied to

play07:16

Mainframe the software agent folder

play07:18

contains software components to be

play07:20

installed on Mainframe is zip file a

play07:22

system administrator access is required

play07:24

to install the software log into the

play07:27

main frame in this use case we

play07:29

considered the card payments

play07:30

authorization history is stored in a

play07:32

vsam

play07:36

database the screen shows the Cobalt

play07:38

copy Book used to define the layout of

play07:40

the message the precisely software is

play07:43

already installed and UI is available

play07:45

using the ispf panel to perform admin

play07:49

works the demon process in the publisher

play07:52

is already created in started as a batch

play07:55

job in this demonstration the demon job

play07:58

is running on Port 90 5 DD name sqd off

play08:02

refers the keys file the content of the

play08:04

public key file created within the ec2

play08:07

instance is pasted in this file and will

play08:09

be used to authenticate the apply engine

play08:11

when connection request is

play08:13

made here's the publisher

play08:16

job from the ispf panel for precisely

play08:19

select option

play08:21

three vssm to msk is the name of the

play08:24

publisher engine and the configuration

play08:26

is stored in cab mentioned the screen

play08:28

shows the stats such as records captured

play08:31

records published The Source log stream

play08:33

shows the log stream name configured to

play08:35

Stage the database changes in our

play08:38

scenario the log stream is a vsam based

play08:40

file but in production coupling facility

play08:43

based log stream is

play08:45

recommended One Source object is

play08:47

configured which is identified by vsam

play08:49

pure C this will capture the logs from

play08:52

the card payments authorization V Sam

play08:54

file switch back to ec2 command prompt

play08:58

we will create the RDS posters table

play09:01

connect to the RDS database using the

play09:03

psql

play09:04

command then run the create table

play09:07

command the table columns corresponds to

play09:09

the fields in the vsam copy book run a

play09:12

select query to validate the table next

play09:15

create a cpy subfolder inside precisely

play09:17

folder create a file named cardor

play09:20

payments and paste the Cobalt copybook

play09:23

layout save the copy book

play09:27

file create the apply engine script file

play09:29

named script.

play09:32

sqd The Script has the job name vs samam

play09:34

to msk is identifier the description

play09:37

section refers to metadata referring to

play09:40

the Cobalt copybook location the Sam

play09:42

perk is the name of source object

play09:44

identifier set by publisher Source data

play09:47

store points to Mainframe IP address and

play09:49

port for demon on Mainframe vssm to msk

play09:52

is the publisher name vam CDC is data

play09:55

source

play09:57

type Target data store points to topic

play10:00

name of the msk messages will be

play10:02

distributed to kofka partitions using

play10:04

key Json is the record format both

play10:07

source and Target data source use cardor

play10:10

payment SRC to describe the message

play10:13

metadata the script used the replicate

play10:15

function to convert raw ebcc log to Json

play10:18

format with key fields from

play10:22

copybook next we are going to set up the

play10:24

msk S3 delivery via fire hose and

play10:27

integration with SNS via event Bridge

play10:29

pipe

play10:30

MSG provides no code integration with

play10:32

various AWS services on the MSG S3

play10:35

delivery tab click create fire hose

play10:38

stream some of the details are

play10:41

pre-populated such as Source destination

play10:43

mskk

play10:45

cluster paste the topic

play10:47

name enter a name for the

play10:51

stream select the S3 bucket created by

play10:54

cloud formation template

play10:59

add

play11:00

prefixes click create fire host stream

play11:03

to

play11:04

create once the creation is complete you

play11:06

will see the status is

play11:09

active next click integration Tab and

play11:12

then click connect Amazon msk cluster to

play11:14

pipe enter a pipe

play11:17

name paste the topic name in the

play11:20

consumer group created

play11:23

earlier for demonstration we are not

play11:25

adding any filtering or enrichment

play11:29

on the target page click in Target

play11:31

service dropdown you can see the

play11:34

different Services you can integrate

play11:35

with select SNS then the topic expand

play11:39

Target input Transformer on the sample

play11:41

event select msk click on the value to

play11:44

select the field for output click create

play11:47

pipe to create the event Bridge pipe

play11:49

once successfully created the status

play11:51

will show is running now let's start the

play11:54

apply engine and insert some record in

play11:55

the vsam database on the ec2 command

play11:59

prompt start the apply engine using the

play12:01

sqdg command the process displays

play12:04

valuable information about the data

play12:05

sources and message layouts it's

play12:08

connected to publisher engine on

play12:09

Mainframe and waiting for data

play12:12

now switch to Mainframe this PS file

play12:16

contains records that will be inserted

play12:17

to the vsam database the records map to

play12:20

the layout of the copy book we saw

play12:22

earlier in this demonstration we will

play12:24

use the precisely batched differ

play12:26

functionality to replicate data online

play12:29

Sam or db2 IMS follow the same capture

play12:32

publisher architecture with some

play12:33

differences in setup and

play12:35

configurations we are going to use the

play12:37

job to copy the PS file to the current

play12:39

vam and then run the sqd DFC DC utility

play12:43

the utility compares the base and

play12:44

current files and updates the change

play12:46

records in the log stream submit the

play12:50

job switching to the ispf panel we see

play12:53

the engine is connected now the capture

play12:55

and publish record counts have gone up

play12:59

ec2 command prompt also shows records

play13:02

ingested let's switch to another

play13:04

terminal and let's run the select query

play13:06

on RDS posters again we see the records

play13:08

in the

play13:10

table the metrics on Lambda console

play13:12

shows the invocations it picked up the

play13:15

messages from msk and inserted them to

play13:17

RDS let's look at the other data

play13:20

pipelines created from msk on S3 console

play13:23

let's navigate to data folder and then

play13:25

to the subfolders select one object and

play13:28

click query with S3 select on the page

play13:31

select Json as input and output format

play13:34

then run SQL query we see the Json

play13:37

message that was published to MSG by

play13:39

precisely apply agent the change

play13:41

operation is an insert in this case you

play13:44

will denote an update and D delete

play13:46

operation after image contains the new

play13:48

values of the key Fields corresponding

play13:50

to copybook fields and their respective

play13:52

values an update database operation will

play13:54

have both before and after image the

play13:57

object stored in S3 will be aggreg ated

play13:59

and used offline to train and update the

play14:01

AIML

play14:03

models the even Bridge pipe also

play14:06

consumed the messages and sent email

play14:08

notification with the Json messages body

play14:10

here's a sample

play14:12

email now let's experiment how we can

play14:14

use generative SQL from Red shift to

play14:16

query using natural language on the red

play14:19

shift console page click on query data

play14:22

click on plus sign and select notebook

play14:25

select the cluster run SQL to create

play14:28

schema directly from the msk topic and

play14:31

then a materialized view with the data

play14:33

from the

play14:35

topic then click on generative SQL a

play14:38

chatbot window is opened on right hand

play14:40

side type in plain language for example

play14:43

show top five states by purchase Amazon

play14:45

qbed by large language model or llm

play14:48

generates the SQL query to be executed

play14:51

click add to notebook and then click run

play14:53

we see the SQL

play14:56

results let's try something little

play14:58

complex

play14:59

let's ask show top five Merchants with

play15:01

highest single purchase ask to include

play15:04

state of purchase and output also ask to

play15:06

show the purchase amount in currency

play15:08

format using generative AI red shift is

play15:11

able to understand the request written

play15:13

in natural language search the database

play15:15

and generate the SQL you can do lot more

play15:18

ask complex business Insight on the data

play15:21

here's the

play15:22

result in case you are looking for the

play15:24

code sample to build the fraud detection

play15:26

section check the sample code in GitHub

play15:30

thanks for watching

Rate This

5.0 / 5 (0 votes)

関連タグ
AWSAIML詐欺検出リアルタイムデータ分析メインフレームカード決済ビジネスルールSagMakerセキュリティ