Workshop
http://bit.ly/ArangoDBGraphAnalytics
Copyright © ArangoDB Inc., 2020 - Confidential
Graph Analytics with ArangoDB
Copyright © ArangoDB Inc., 2021 - Confidential
tl;dr
Graph Analytics
Answer questions from Graph Data
Graph Embeddings and Graph Neural Networks
Learning Graphs
Graph-based Machine Learning Metadata
Utilizing Graphs for Operating ML Infrastructure
2
“You can make better predictions utilizing relationships within the data than you can from just the data alone.”
Challenge...
Agenda
ML Infrastructure & Metadata
Graphs
Graph Database
Graph Analytics
Graph Embeddings
Graphs Neural Networks
Part 2
Jörg Schad, PhD
@joerg_schad
Copyright © ArangoDB Inc., 2019 - Confidential
Chris Woodward
Developer Relations Engineer
@
6
Copyright © ArangoDB Inc., 2019 - Confidential
This workshop...
… is for you!
Please share
… is also virtual!
7
Who are you?
Background
Expectations
...
8
This workshop...
9
Why should you care?
10
“You can make better predictions utilizing relationships within the data than you can from just the data alone.”
What problems can we solve?
Graph Analytics
Answer questions from Graph
Graph Embeddings and Graph Neural Networks
Learning Graphs
Graph-based Machine Learning Metadata
Utilizing Graphs for Operating ML Infrastructure
11
Agenda
ML Infrastructure & Metadata
Graphs
Graph Database
Graph Analytics
Graph Embeddings I
Graphs Neural Networks
Graph Analytics with ArangoDB
Graph Data Model
13
Graph Analytics with ArangoDB
Graph Properties
Graph Queries
14
Optional Lab: Graphs & Properties
15
Graph Analytics with
16
Scalable Graph Technology
Kube-Arango
Kubernetes Integration
Managed Service
Oasis
Document
Data Model
Key-Value
Data Model
Graph
Data Model
Iterative Graph Processing
Pregel
Graph ML and Analytics
ArangoML
Full-Text
ArangoSearch
AQL
Unified Engine & Queries
Graph Databases
17
AQL - A Query Language That Feels Like Coding
18
Graph part
Document part
FOR c IN company
FILTER c.name == @companyName
FOR department IN 1..6 INBOUND c isPartOf
RETURN {
c: c.name,
department: department.name,
ordered: (
FOR o IN orders
FILTER o.contact == department.contact
RETURN {date: o.date, amount: o.amount}
)
}
ArangoSearch
Full-Text Search
ArangoSearch is a powerful search and similarity ranking engine natively integrated into ArangoDB. Combine search with any other data model.
19
FOR d IN v_imdb
SEARCH
ANALYZER(d.description
IN TOKENS('amazing action world alien sci-fi science documental', 'text_en') ||
BOOST(d.description IN TOKENS('galaxy', 'text_en'), 5), 'text_en')
SORT BM25(d) DESC
LIMIT 10
FOR vertex, edge, path IN 1..1 INBOUND d imdb_edges
FILTER path.edges[0].$label == "DIRECTED"
RETURN DISTINCT {
"director" : vertex.name,
"movie" : d.title
}
Graph part
Search part
Property-Graph-Model
RDF Triple Store
Languages
20
Person
name: Max
City
location:
born_in
year: 1984
---
Graph Storage Models
Ontologies & Logic for Inference
Challenge:
Turtle*
<<:bob foaf:age 23>> ex:certainty 0.9 .
SPARQL*
SELECT ?p ?a ?c WHERE {
<<?p foaf:age ?a>> ex:certainty ?c .
}
Support
21
RDF* bridging the worlds
Max
Job1
start
end
employer
Lab: SPARQL
22
Graph Modelling
Edge Attribute
Vertex Attribute
23
Person
name: Max
rated
rating: 5
---
Person
name: Max
Movie:
Free Solo:
Movie:� Free Solo
Rating
rating: 5
gave
rated_by
Lab: Property Graph Queries
24
Graph Analytics with ArangoDB
25
http://btimmermans.com/2017/12/11/machine-learning-overview/
(Graph) Analytics
26
https://research.aimultiple.com/graph-analytics/
Fast.ai
27
Why Graph?
Knowledge Graphs and Machine Learning
Graph Algorithms
30
Shortest Path
31
https://towardsdatascience.com/10-graph-algorithms-visually-explained-e57faa1336f3
Minimal Spanning Tree
32
https://towardsdatascience.com/10-graph-algorithms-visually-explained-e57faa1336f3
Minimal Spanning Tree
33
https://amortizedminds.wordpress.com/tag/algorithm-2/
Minimal Spanning Tree
34
https://amortizedminds.wordpress.com/tag/algorithm-2/
Cycle Detection
35
https://towardsdatascience.com/10-graph-algorithms-visually-explained-e57faa1336f3
Community Detection
https://networkx.github.io/documentation/stable/reference/algorithms/community.html
36
Topological Sort
37
Maximum flow
38
Centrality
39
40
Graph ToolBox
import matplotlib.pyplot as plt
import networkx as nx
G = nx.karate_club_graph()
nx.draw_circular(G, with_labels=True)
plt.show()
Optional) Lab: NetworkX
41
Lab: Graphs Algorithms
42
Graph Analytics with ArangoDB
Fraud Detections
Panama papers
Enterprise Hierarchies
Permission Management
Internet Of Things
Bill of Materials
Representation Learning ...
43
44
Collaborative Filtering
45
What should I watch next...
46
User
Movie
Rates
Collaborative Filtering
“Find highly rated movies, by people who also like movies I rated highly”
47
User
Movie
Rates
How to find movies I like?
Lab: Graph Analytics
48
Fraud Detection
49
Bank
Collection
Branch
Collection
Customer
Vertex Collection
Account
Vertex Collection
Transaction
Edge Collection
AccountHolder
Edge Collection
Lab: Fraud Detection
50
PageRank works by counting the number and quality of links to a page to determine a rough estimate of how important the website is. The underlying assumption is that more important websites are likely to receive more links from other websites.
51
PageRank
Goal: How likely a random surfer will end up at a page?
52
PageRank
54
Pregel - Finding the max value
Lab: Pregel
55
Thanks for listening!
56
Test-drive Oasis