Grafting Grifters: Identify & Display Patterns of Corruption With Oracle Graph Jim Czuprynski Zero Defect Computing, Inc.
Who Am I, and What Am I Doing Here? ➢E-mail me at jim@jimthewhyguy.com ➢Follow me on Twitter (@JimTheWhyGuy) ➢Connect with me on LinkedIn (Jim Czuprynski) Traveler & public speaker Summers: Wisconsin Winters: Illinois Cyclist XC skier Avid amateur bird watcher Oldest dude in martial arts class
Jim Czuprynski Liron Amitzi https://www.beyondtechskills.com The podcast that talks about everything tech – except tech.TM
Owners Property Graphs: Finding Patterns Between Data Elements Traditional RDBMS databases use SQL in a set-based fashion This makes it easy to find result sets with data in common (or not in common) … Given a particular bank account as a starting point, has that account’s owner … … received funds from another bank account that’s owned by someone in a different country? Accounts Transactions … but it makes it much harder to identify find patterns of how data is linked together
Property Graphs: Not About Data Itself, But How They’re Connected Campaign Nobody Gran Torino The Power of the Dog promotes promotes watches recommends watches recommends recommends recommends watches Consider a movie streaming service promoting its latest releases It needs to generate hours watched … … but it also needs to generate buzz to get other subscribers to watch them, too Not every subscriber watches the recommended movie … … but maybe they watch something in that same genre instead!
Identifying Corruption Via MOE (Mark One Eyeball) Quickly, now: Prove that these transactions show distinct evidence of money laundering
Accessing Graph Studio Tools You can model new graphs from tables and views, as well as visualize the materialized graphs … 1 … access existing Zeppelin notebooks, and review any tasks that have recently executed 2
Creating and Accessing Property Graphs (1) It’s easy to model a new Property Graph from existing database tables and views 1 Once entities are chosen, Oracle automatically builds the CREATE PROPERTY GRAPH PGQL commands to create the graph using existing PK and FK constraints 2
Creating and Accessing Property Graphs (2) You can display properties from each Vertex … 3 … as well as each Edge in the Property Graph, and even exclude specific columns from the final Graph 4
Creating and Accessing Property Graphs (3) Glimpse the data within each Vertex and Edge … 5 … supply names and descriptors for the new Model and Graph … 6
Creating and Accessing Property Graphs (3) Glimpse the data within each Vertex and Edge … 5 … supply names and descriptors for the new Model and Graph … 6 … and monitor the successful creation of the new Graph and its corresponding Model 7
Creating and Accessing Property Graphs (4) If you have a PGQL file containing a CREATE PROPERTY GRAPH statement … 8 … you can supply it within the Modeler instead of building the Graph and Model graphically 9
Leveraging Zeppelin Notebooks To Probe & Display Property Graphs (1) Zeppelin notebook technology allows even inexperienced PGQL users to immediately dive into property graph content … 1
Leveraging Zeppelin Notebooks To Probe & Display Property Graphs (1) Zeppelin notebook technology allows even inexperienced PGQL users to immediately dive into property graph content … 1 … and with a simple PGQL statement and some mouse clicks, suspicious patterns are immediately evident! 2
Leveraging Zeppelin Notebooks To Probe & Display Property Graphs (2) PGQL functions like IN_DEGREE() and OUT_DEGREE() show the direction of vertices … 3
Leveraging Zeppelin Notebooks To Probe & Display Property Graphs (2) PGQL functions like IN_DEGREE() and OUT_DEGREE() show the direction of vertices … 3 … and, with just a little polish, the apparently fraudulent activity becomes even more evident 4
Leveraging Zeppelin Notebooks To Probe & Display Property Graphs (2) … and, with just a little polish, the apparently fraudulent activity becomes even more evident 4
Leveraging Zeppelin Notebooks To Probe & Display Property Graphs (3) Property graph display options are flexible and precise … 5 … including several layouts for highlighting different relationship types … 6
Leveraging Zeppelin Notebooks To Probe & Display Property Graphs (3) Property graph display options are flexible and precise … 5 … including several layouts for highlighting different relationship types … 6 … as well as different backgrounds and representations of vertices 7
Live Demonstration: Like, Wow, That’s Amazing, Miss Information! To illustrate how easy it is to leverage Graph Studio, here’s an example of how to detect patterns in (fictitious!) social media postings and possibly identify which Twitter accounts are being spread by bots and “sock puppets” versus posts by actual human beings What could possibly go wrong?
Beyond PGQL: Other Property Graph Tools 60+ powerful graph algorithms offer the ability to: • Detect graph components and communities • Evaluate graph structures for patterns • Rank and “walk” graphs • Identify paths through graph nodes • Build machine learning models Property Graph toolsets can be accessed through just about any programming language, including Java, Python, and even SQLcl and PL/SQL Leverage the Graph Client API to build custom applications
PGX Analytic Functions Provide a Deeper Look Within Graphs Analytic Function Provides Useful Intelligence For: PageRank Determines which node in a graph is most important based on its number of incoming edges Closeness Centrality Calculates how “close” a node is to other nodes within a graph Betweenness Centrality Detects how much a node may influence the flow of information within a graph HITS Points to which web page is likely to contain the most meaningful information based on its HyperLink- Induced Topic Search score WTF Projects Whom To Follow within a social network for maximum positive impact to social standing
Using PGX To Enhance Graph Content You can apply any one of 60+ additional graph analytic functions to an existing in-memory graph … 1 Take careful note of the actual attributes returned. It’ll save you a lot of grief when you use them to create a report!
Using PGX To Enhance Graph Content You can apply any one of 60+ additional graph analytic functions to an existing in-memory graph … 1 Take careful note of the actual attributes returned. It’ll save you a lot of grief when you use them to create a report! … and you can use these new attributes for further analyses or even different visualizations 2
PGX ML Toolset (And You Thought “Normal” ML Was Tough To Grok!) Model Description Examples of Real-World Use Cases DeepWalk Computes random walks for every vertex, then generates new vector representations How likely is it that a new post will spread quickly through a network of connected friends via a mobile social media application? Supervised GraphWise Based on GraphSage, it’s an inductive vertex representation learning algorithm against vertex feature information Based on a customer’s prior ordering habits, what new products or offerings can we suggest that they’re actually interested in? Unsupervised GraphWise Based on Deep Graph Infomax, it applies an inductive vertex representation learning algorithm against vertex information Can we quickly identify brain abnormalities to detect autism spectrum disorder (ASD) by comparing 4-D MRI brain scans of new patients against those of patients already diagnosed with ASD? Pg2Vec Generates graphlets that can be compared for matching patterns Based on prior known patterns, is a new set of financial transactions a warning sign that money laundering may be occurring?
Showing Misinformation Networks
Showing Misinformation Networks
Showing Misinformation Networks
Showing Misinformation Networks
Plans for Future Experimentation Expand beyond Graph Studio for Autonomous Database to use powerful PGX tools in native mode Use publicly-available social media data to refine methods identifying spread of misinformation Leverage data captured from Twitter in real time to explore available Machine Learning algorithms
Sample Use Cases For Property Graphs • Social Media Sentiment Analysis https://towardsdatascience.com/sentiment-analysis-74624b075842 • Graphs Analytics for Fraud Detection https://towardsdatascience.com/graphs-analytics-for-fraud-detection-83ee3af81ec7 • Detecting Fake Users on Social Media with a Graph Database https://journals.uvic.ca/index.php/arbutus/article/view/20027 • Just 12 People Are Behind Most Vaccine Hoaxes On Social Media, Research Shows https://www.npr.org/2021/05/13/996570855/disinformation-dozen-test-facebooks-twitters-ability-to-curb-vaccine-hoaxes
Useful References • Graph Databases and Analytics: How to Use Them https://www.oracle.com/it/a/tech/docs/sg-oow2019-graph-databases-and-analytics.pdf • Property Graph Developer’s Guide https://docs.oracle.com/en/database/oracle/property-graph/20.4/spgdg/oracle-graph-property-graph-developers-guide.pdf • PGQL: Vertex and Edge Functions https://pgql-lang.org/spec/1.4/#vertex-and-edge-functions • Using the Machine Learning Library (PgxML) for Graphs https://docs.oracle.com/en/database/oracle/property-graph/22.1/spgdg/using-machine-learning-library-pgxml-graphs.html

Graphing Grifters: Identify & Display Patterns of Corruption With Oracle Graph

  • 1.
    Grafting Grifters: Identify &Display Patterns of Corruption With Oracle Graph Jim Czuprynski Zero Defect Computing, Inc.
  • 2.
    Who Am I,and What Am I Doing Here? ➢E-mail me at jim@jimthewhyguy.com ➢Follow me on Twitter (@JimTheWhyGuy) ➢Connect with me on LinkedIn (Jim Czuprynski) Traveler & public speaker Summers: Wisconsin Winters: Illinois Cyclist XC skier Avid amateur bird watcher Oldest dude in martial arts class
  • 3.
    Jim Czuprynski Liron Amitzi https://www.beyondtechskills.com Thepodcast that talks about everything tech – except tech.TM
  • 4.
    Owners Property Graphs: FindingPatterns Between Data Elements Traditional RDBMS databases use SQL in a set-based fashion This makes it easy to find result sets with data in common (or not in common) … Given a particular bank account as a starting point, has that account’s owner … … received funds from another bank account that’s owned by someone in a different country? Accounts Transactions … but it makes it much harder to identify find patterns of how data is linked together
  • 5.
    Property Graphs: NotAbout Data Itself, But How They’re Connected Campaign Nobody Gran Torino The Power of the Dog promotes promotes watches recommends watches recommends recommends recommends watches Consider a movie streaming service promoting its latest releases It needs to generate hours watched … … but it also needs to generate buzz to get other subscribers to watch them, too Not every subscriber watches the recommended movie … … but maybe they watch something in that same genre instead!
  • 6.
    Identifying Corruption ViaMOE (Mark One Eyeball) Quickly, now: Prove that these transactions show distinct evidence of money laundering
  • 7.
    Accessing Graph StudioTools You can model new graphs from tables and views, as well as visualize the materialized graphs … 1 … access existing Zeppelin notebooks, and review any tasks that have recently executed 2
  • 8.
    Creating and AccessingProperty Graphs (1) It’s easy to model a new Property Graph from existing database tables and views 1 Once entities are chosen, Oracle automatically builds the CREATE PROPERTY GRAPH PGQL commands to create the graph using existing PK and FK constraints 2
  • 9.
    Creating and AccessingProperty Graphs (2) You can display properties from each Vertex … 3 … as well as each Edge in the Property Graph, and even exclude specific columns from the final Graph 4
  • 10.
    Creating and AccessingProperty Graphs (3) Glimpse the data within each Vertex and Edge … 5 … supply names and descriptors for the new Model and Graph … 6
  • 11.
    Creating and AccessingProperty Graphs (3) Glimpse the data within each Vertex and Edge … 5 … supply names and descriptors for the new Model and Graph … 6 … and monitor the successful creation of the new Graph and its corresponding Model 7
  • 12.
    Creating and AccessingProperty Graphs (4) If you have a PGQL file containing a CREATE PROPERTY GRAPH statement … 8 … you can supply it within the Modeler instead of building the Graph and Model graphically 9
  • 13.
    Leveraging Zeppelin NotebooksTo Probe & Display Property Graphs (1) Zeppelin notebook technology allows even inexperienced PGQL users to immediately dive into property graph content … 1
  • 14.
    Leveraging Zeppelin NotebooksTo Probe & Display Property Graphs (1) Zeppelin notebook technology allows even inexperienced PGQL users to immediately dive into property graph content … 1 … and with a simple PGQL statement and some mouse clicks, suspicious patterns are immediately evident! 2
  • 15.
    Leveraging Zeppelin NotebooksTo Probe & Display Property Graphs (2) PGQL functions like IN_DEGREE() and OUT_DEGREE() show the direction of vertices … 3
  • 16.
    Leveraging Zeppelin NotebooksTo Probe & Display Property Graphs (2) PGQL functions like IN_DEGREE() and OUT_DEGREE() show the direction of vertices … 3 … and, with just a little polish, the apparently fraudulent activity becomes even more evident 4
  • 17.
    Leveraging Zeppelin NotebooksTo Probe & Display Property Graphs (2) … and, with just a little polish, the apparently fraudulent activity becomes even more evident 4
  • 18.
    Leveraging Zeppelin NotebooksTo Probe & Display Property Graphs (3) Property graph display options are flexible and precise … 5 … including several layouts for highlighting different relationship types … 6
  • 19.
    Leveraging Zeppelin NotebooksTo Probe & Display Property Graphs (3) Property graph display options are flexible and precise … 5 … including several layouts for highlighting different relationship types … 6 … as well as different backgrounds and representations of vertices 7
  • 20.
    Live Demonstration: Like,Wow, That’s Amazing, Miss Information! To illustrate how easy it is to leverage Graph Studio, here’s an example of how to detect patterns in (fictitious!) social media postings and possibly identify which Twitter accounts are being spread by bots and “sock puppets” versus posts by actual human beings What could possibly go wrong?
  • 21.
    Beyond PGQL: OtherProperty Graph Tools 60+ powerful graph algorithms offer the ability to: • Detect graph components and communities • Evaluate graph structures for patterns • Rank and “walk” graphs • Identify paths through graph nodes • Build machine learning models Property Graph toolsets can be accessed through just about any programming language, including Java, Python, and even SQLcl and PL/SQL Leverage the Graph Client API to build custom applications
  • 22.
    PGX Analytic FunctionsProvide a Deeper Look Within Graphs Analytic Function Provides Useful Intelligence For: PageRank Determines which node in a graph is most important based on its number of incoming edges Closeness Centrality Calculates how “close” a node is to other nodes within a graph Betweenness Centrality Detects how much a node may influence the flow of information within a graph HITS Points to which web page is likely to contain the most meaningful information based on its HyperLink- Induced Topic Search score WTF Projects Whom To Follow within a social network for maximum positive impact to social standing
  • 23.
    Using PGX ToEnhance Graph Content You can apply any one of 60+ additional graph analytic functions to an existing in-memory graph … 1 Take careful note of the actual attributes returned. It’ll save you a lot of grief when you use them to create a report!
  • 24.
    Using PGX ToEnhance Graph Content You can apply any one of 60+ additional graph analytic functions to an existing in-memory graph … 1 Take careful note of the actual attributes returned. It’ll save you a lot of grief when you use them to create a report! … and you can use these new attributes for further analyses or even different visualizations 2
  • 25.
    PGX ML Toolset(And You Thought “Normal” ML Was Tough To Grok!) Model Description Examples of Real-World Use Cases DeepWalk Computes random walks for every vertex, then generates new vector representations How likely is it that a new post will spread quickly through a network of connected friends via a mobile social media application? Supervised GraphWise Based on GraphSage, it’s an inductive vertex representation learning algorithm against vertex feature information Based on a customer’s prior ordering habits, what new products or offerings can we suggest that they’re actually interested in? Unsupervised GraphWise Based on Deep Graph Infomax, it applies an inductive vertex representation learning algorithm against vertex information Can we quickly identify brain abnormalities to detect autism spectrum disorder (ASD) by comparing 4-D MRI brain scans of new patients against those of patients already diagnosed with ASD? Pg2Vec Generates graphlets that can be compared for matching patterns Based on prior known patterns, is a new set of financial transactions a warning sign that money laundering may be occurring?
  • 26.
  • 27.
  • 28.
  • 29.
  • 30.
    Plans for FutureExperimentation Expand beyond Graph Studio for Autonomous Database to use powerful PGX tools in native mode Use publicly-available social media data to refine methods identifying spread of misinformation Leverage data captured from Twitter in real time to explore available Machine Learning algorithms
  • 31.
    Sample Use CasesFor Property Graphs • Social Media Sentiment Analysis https://towardsdatascience.com/sentiment-analysis-74624b075842 • Graphs Analytics for Fraud Detection https://towardsdatascience.com/graphs-analytics-for-fraud-detection-83ee3af81ec7 • Detecting Fake Users on Social Media with a Graph Database https://journals.uvic.ca/index.php/arbutus/article/view/20027 • Just 12 People Are Behind Most Vaccine Hoaxes On Social Media, Research Shows https://www.npr.org/2021/05/13/996570855/disinformation-dozen-test-facebooks-twitters-ability-to-curb-vaccine-hoaxes
  • 32.
    Useful References • GraphDatabases and Analytics: How to Use Them https://www.oracle.com/it/a/tech/docs/sg-oow2019-graph-databases-and-analytics.pdf • Property Graph Developer’s Guide https://docs.oracle.com/en/database/oracle/property-graph/20.4/spgdg/oracle-graph-property-graph-developers-guide.pdf • PGQL: Vertex and Edge Functions https://pgql-lang.org/spec/1.4/#vertex-and-edge-functions • Using the Machine Learning Library (PgxML) for Graphs https://docs.oracle.com/en/database/oracle/property-graph/22.1/spgdg/using-machine-learning-library-pgxml-graphs.html