Knowledge Graphs and Their Application.pdf

kabulkurniawan 24 views 54 slides Mar 11, 2025
Slide 1
Slide 1 of 54
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
40
Slide 41
41
Slide 42
42
Slide 43
43
Slide 44
44
Slide 45
45
Slide 46
46
Slide 47
47
Slide 48
48
Slide 49
49
Slide 50
50
Slide 51
51
Slide 52
52
Slide 53
53
Slide 54
54

About This Presentation

Knowledge Graphs and Their Application


Slide Content

Knowledge Graphs and Their
Application
Dr. Kabul Kurniawan

▪Current Post-Doctoral Researcher, Vienna University of Economics and Business, Austria.
Senior Researcher, Austrian Centre for Digital Production (ACDP), Austria.
▪Education Dr. techn Computer Science, University of Vienna, Austria.
S.Kom & M.Cs. Computer Science, Universitas Gadjah Mada, Indonesia.
▪Awards WU Award for Outstanding Researcher, Computer & Security Journal.
(selected) 3
rd
Winner, Solid for Social Networks Hackathon, Inrupt, Inc.
3
rd
Best Paper Award, Knowledge Graph and Semantic Web (KGSWC).
Awardee, Doctoral Scholarship, Beasiswa Unggulan Luar Negeri (BU-LN).
Awardee, Master Scholarship, Beasiswa Pendidikan Pascasarjana dalam Negeri (BPPDN).
Awardee, Bachelor Scholarship, Beasiswa PPA Universitas Gadjah Mada.
▪Research
Interest Knowledge Graph, Interoperability, Information Security, Industry 5.0
PAGE 2
Dr. Kabul Kurniawan

PAGE 3
Today’s Topics:
•Introduction to Knowledge Graphs (KGs)
•KG’s Implementation:
•Decentralized Web
•KGs for Cybersecurity Analysis
•KGs for Collaborative AI

Objectives:
▪Overview of What Knowledge Graph (KG) is
▪Conceptual Foundation: Knowledge Representation (RDF)
▪Knowledge Graph Manipulation: Learn How to Query KG (SPARQL)
▪Example Use Case Implementation of KG
Not covered:
▪Knowledge-Graph lifecycle
▪Publishing, processing, integration, visualization of KG
▪Inference in Ontology of KG
▪Building applications on top of KG
▪Search in KG
▪…
PAGE 4
Learning Objective
▪Tim Berners-Lee, Mark Fischetti: Weaving the
web - the original design and ultimate destiny of
the World Wide Web by its inventor.
HarperBusiness 2000, ISBN 978-0-06-251587-2,
pp. I-IX, 1-246
▪Tim Berners-Lee, James Hendle, Ora Lassila
(May 17, 2001). "The Semantic Web". Scientific
American.
▪Aidan Hogan, Eva Blomqvist, Michael Cochez,
Claudia d'Amato, Gerard de Melo, Claudio
Gutiérrez, Sabrina Kirrane, José Emilio Labra
Gayo, Roberto Navigli, Sebastian Neumaier,
Axel-Cyrille Ngonga Ngomo, Axel Polleres, Sabbir
M. Rashid, Anisa Rula, Lukas Schmelzeisen, Juan
Sequeda, Steffen Staab, Antoine
Zimmermann: Knowledge Graphs. Synthesis
Lectures on Data, Semantics, and Knowledge,
Morgan & Claypool Publishers 2021
References:

PAGE 5
Today’s Topics:
•Introduction to Knowledge Graphs
•KG’s Implementation:
•Decentralized Web
•KGs for Cybersecurity Analysis
•KGs for Collaborative AI

PAGE 6
Why Graph?
Graphs and graph data are very common when it comes to modern
data management problems, for instance:
▪connections in a social network
▪links between Web documents
▪transport or supply-chain networks
▪so-called "Knowledge Graphs“
Knowledge graphs are large networks of entities, their semantic
types, properties, and relationships between entities. [1]
Knowledge graphs could be envisaged as a network of all kind things
which are relevant to a specific domain or to an organization. [2]
[1] M. Kroetsch, G. Weikum. Journal of Web Semantics: Special Issue on KGs, 2016.
[2] A. Blumauer. From Taxonomies over Ontologies to Knowledge Graphs, 2014.

PAGE 7
Google Knowledge Graph – Things not Strings

PAGE 8
Knowledge Graph: Wikipedia example
{predicate} {object}
{Subject}

PAGE 9
KG Representation: RDF (Resource Description Framework)
Source https://www.freepik.com/premium -vector/yogyakarta-map-template-vector-assets_30302654.htm
Gadjah Mada University
https://dbpedia.org
/resource/Gadjah_
Mada_University
https://dbpedia.org
/resource/Sleman
_Regency
https://dbpedia.org/property/city
:Gadjah_Mada_
University
:Sleman_Reg
ency
dbp:city
•Graph-based data model
•Subject-predicate-object triples
•Use of URIs as globally unique identifiers

PAGE 10
Knowledge Graph Representation: RDF Graph
:Gadjah_Mada
_University
:Sleman_Regency
dbp:city
subject Predicate
object
triple
•Object of one statement may be the subject of another statement
•The result is a directed labelled (multi-)graph
•The object of a triple is a resource or a literal
:Ova_Emilia
Predicate
object
Predicate
Source https://www.freepik.com/premium -vector/yogyakarta-map-template-vector-assets_30302654.htm
Gadjah Mada University
Ova Emilia
(Rector)
subject
“19-02-1964”
dbp:birthDate

PAGE 11
Knowledge Graph: RDF Serialization
@prefix : <http://dbpedia.org/resource/>.
@prefix dbp: <http://dbpedia.org/property/>.
:Gadjah_Mada_University dbp:city :Sleman_Regency;
dbp:rector :Ova_Emilia.
:Ova_Emilia dbp:live_in :Sleman_Regency.
RDF (TURTLE)
<http://dbpedia.org/resource/Gadjah_Mada_University> <http://dbpedia.org/property/city> <http://dbpedia.org/resource/Sleman_Regency>.
<http://dbpedia.org/resource/Gadjah_Mada_University> <http://dbpedia.org/property/rector> <http://dbpedia.org/resource/Ova_Emilia> .
<http://dbpedia.org/resource/Ova_Emilia> <http://dbpedia.org/property/live_in> <http://dbpedia.org/resource/Sleman_Regency>.
RDF (N-TRIPLE)
Other Serialization:
•Graph notation
•RDF/XML (historically first serialization format)
•JSON-LD
{
"@context": {
"dbp": "http://dbpedia.org/property/",
"resource": "http://dbpedia.org/resource/"
},
"@id": "resource:Gadjah_Mada_University",
"dbp:city": "resource:Sleman_Regency",
"dbp:rector": {
"@id": "resource:Ova_Emilia",
"dbp:live_in": "resource:Sleman_Regency"
}
}
JSON-LD

PAGE 12
SPARQL (SPARQL Protocol and RDF Query Language)
Lets us:
•Retrieve and manipulate data stored in RDF
•Explore data by querying unknown relationships
•Perform complex joins of disparate databases in a single, simple query
•Etc.
SPARQL Query example: Where is Gadjah Mada University located?
@prefix : <http://dbpedia.org/resource/>.
@prefix dbp: <http://dbpedia.org/property/>.
SELECT ?o
WHERE {
:Gadjah_Mada_University dbp:city ?o
}
:Gadjah_Mada
_University
:Sleman_Regency
dbp:city
:Ova_Emilia

PAGE 13
SPARQL (SPARQL Protocol and RDF Query Language)
SPARQL Query example: Where is Gadjah Mada University located?
@prefix : <http://dbpedia.org/resource/>.
@prefix dbp: <http://dbpedia.org/property/>.
SELECT ?o
WHERE {
:Gadjah_Mada_University dbp:city ?o
}
:Gadjah_Mada
_University
:Sleman_Regency
dbp:city
:Ova_Emilia

PAGE 14
SPARQL (SPARQL Protocol and RDF Query Language)
SPARQL Query example: Who is the rector of Gadjah Mada University?
@prefix : <http://dbpedia.org/resource/>.
@prefix dbp: <http://dbpedia.org/property/>.
SELECT ?o
WHERE {
:Gadjah_Mada_University dbp:rector ?o
}
:Gadjah_Mada
_University
:Sleman_Regency
dbp:city
:Ova_Emilia

PAGE 15
SPARQL (SPARQL Protocol and RDF Query Language)
Formulate SPARQL Query for the following question:
-> What city does the rector of Gadjah Mada University live in?
@prefix : <http://dbpedia.org/resource/>.
@prefix dbp: <http://dbpedia.org/property/>.
SELECT ?city
WHERE {
:Gadjah_Mada_University dbp:rector ?o.
?o dbp:live_in ?city.
}
:Gadjah_Mada
_University
:Sleman_Regency
dbp:city
:Ova_Emilia

PAGE 16
Today’s Topics:
•Introduction to Knowledge Graphs
•KG’s Implementation:
•Decentralized Web
•KGs for Cybersecurity Analysis
•KGs for Collaborative AI

PAGE 17
▪Data is stored & owned by the application.
▪Data silos, close-backend database.
▪Services are driven by the data.
▪The more data are given, the more services are
provided.
▪Lack of data transparency, control & privacy
▪Misused personal data
Today’s web threat…

▪Decentralizing the Web means that people gain the abilityto storetheir data wherever they
want, while still getting the services they need [1].
▪Three Paradigm [1] :
▪End users become data owners
▪Apps become views
▪Interfaces become queries
PAGE 18
Decentralized Web
In 2017, Tim Berners-Lee listed
three challengesfor the Web.
▪We need to regain control over our personal data.
▪We need to reduce the spread of misinformation.
▪We need transparency and understanding political advertising.
[1] https://ruben.verborgh.org/blog/2017/12/20/paradigm -shifts-for-the-decentralized-web/

Paradigm 1: End users become data owners
19
Personal Online
Data Store (Pods)

Paradigm 2: Apps become views
20

Paradigm 3: Interface become queries
21

Decentralized Web Technology
22
SOLID (Solid: Social Linked Data )
Solid Found by Tim Berners-Lee at MIT in 2014
Solid is away of building Web apps that
let people keep control of their data.
http://solidproject.org
Solid is an ecosystem.
Standards enable interoperability
Solid is a movement.
We need to shift the app builder mindset.
Solid is a community.
Building Solid requires different people,
companies, and organisations

Personal Knowledge Graph (PODs) – Concept
23
Employee Card
Employee ID : 1234567
Birthdate : 30 – 11- 1987
Address : Flotowgasse 22
Department: Data,
Process & Knowledge
Status : Active
KABUL KURNIAWAN
Human – readable document – e.g. Employee Card

Personal Knowledge Graph (PODs) - Concept
24
{
“object” : “Post-Doc Researcher” {
“name” : “Kabul Kurniawan”,
“birthday” : “30-11-1987”,
“address” : “Flotowgasse 22, Vienna”,
“organization” : “WU Vienna”,
“photo” : “kabul.jpg”
}
}
Machine – readable document – e.g. JSON

Personal Knowledge Graph (PODs) - Concept
25
{
“@context” : http://www.w3.org/2006/vcard/ns# ,
“type” : “Individual” ,
“name” : “Kabul Kurniawan”,
“bday” : “30-11-1987”,
“street-address” : “Flotowgasse 22, Vienna”,
“organization” : “WU Vienna”,
“role” : “Post-Doc Researcher”,
“photo” : “kabul.jpg”
}
Machine – intrepretable document – e.g. JSON-LD (RDF)
Subject Predicate Object
#me vcard:name “Kabul Kurniawan”
#me vcard:organization-name “WU Vienna”
#me vcard:role “Post-Doc Researcher”
… ……. ………

How Decentralized Web, e.g., Solid works?
26
I Like “Khabib” Post
Kabul’s
Pod
Khabib’s Pod
Social Media App : X

How Decentralized Web, e.g., Solid works?
27
{
“@context” : http://www.w3.org/2006/activityStreams#,
“type” : “Like” ,
“actor” : “https://kabulkurniawan.inrupt.net/profile/ card#me”,
“object”: “https://socialmedia.org/ khabib/post/123/#this”,
“published”: “2020-05-02T08:00:00Z”
}
I Like “Khabib” Post

How Decentralized Web, e.g., Solid works?
28
I Like “Khabib” Post, I put Comment on “Khabib” Post
Kabul’s Pod
Khabib’s Pod
Social Media App : X

Social Media App : X
29
I Like “Khabib” Post
I put Comment on “Khabib” Post
Ana Like “Khabib” Post
Ana put Comment on “Khabib” Post
Kabul’s Pod
Khabib’s Pod
Ana’s Pod
How Decentralized Web, e.g., Solid works?

Different data sources can be concatenated!
{ “@context” : http://www.w3.org/2006/activityStreams#,
“@graph”: [ {
{
“type” : “Like” ,
“actor” : “https://kabulkurniawan.inrupt.net/profile/ card#me”,
“object”: “https://socialmedia.org/ khabib/post/123/#this”,
“published”: “2020-05-02T08:00:00Z”
},
{
“type” : “Like” ,
“actor” : “https://example.org/ana/profile/ card#me”,
“object”: “https://socialmedia.org/ khabib/post/123/#this”,
“published”: “2020-05-02T08:12:00Z”
}
}
30
How Decentralized Web, e.g., Solid works?

31

Exercise!
▪Given Social Media X described as in the example, use SPARQL
Query to:
▪find all Khabib’s friend-name !
▪get all posts created by Khabib !
▪get all likes and comments of a post created by Khabib !
PS. You can use other ontologies/vocabularies to provide another context e.g, FOAF,
Schema.org, etc ☺
32

33
Want to know more about Decentralized Web, e.g. Solid ?
http://solidproject.org
https://theodi.org/

PAGE 34
Today’s Topics:
•Introduction to Knowledge Graphs
•KG’s Implementation:
•Decentralized Web
•KGs for Manufacturing & Cybersecurity
Analysis
•KGs for Collaborative AI

Knowledge Graph in Manufacturing Industry
35FMEA, Safety/Security Cause-Effect Product, Process and Resources (PPR)

PAGE 37
Use Case Application: Cybersecurity KG
CyberSec Analysis
Tasks:
▪Log Analysis
▪Vulnerability Assesment
▪Threat Detection and Monitoring
▪Attack Reconstruction
▪Threat Intelligences
▪Anomaly Detection
▪etc.
Example SPARQL Query
for Attack Pattern Analysis
Kurniawan, K., Ekelhart, A., Kiesling, E., Quirchmayr, G., Tjoa, A.M.: Krystal: Knowledge graph-based framework for tactical
attack discovery in audit data. Computers & Security 121, 102828 (2022)

PAGE 38
Use-Case 1: Threat Intelligence Exploration
•Understanding ICS-related attack
techniques and their anatomy
•Asses vulnerabilities to prevent future
breaches and defence strategies
SPARQL Query
Query Results
Kurniawan, K., Kiesling, E., Winkler, D., & Ekelhart, A. The ICS-SEC KG: An Integrated
Cybersecurity Resource for Industrial Control Systems., ISWC 2024

PAGE 39
Today’s Topics:
•Introduction to Knowledge Graphs
•KG’s Implementation:
•Decentralized Web
•KGs for Manufacturing & Cybersecurity Analysis
•KGs for Collaborative AI

KGs for Collaborative AI
40
https://www.linkedin.com/pulse/chatgpt-machine-understanding-learning-composite-ai-shawn-riley/
Knowledge
-
Driven AI
Data
-
Driven AI

Collaborative AI: Informed ML using Knowledge
Representation
queen
crown
wears
showercap
?
Data-Driven AI
- Predict
Knowledge-Driven AI
- Select
crown?
showercap?
Showercap
(97.5% certainty)

Collaborative AI: Explainable ML using Knowledge
Representation
queen
wears
showercap
?
Data-Driven AI
- Predict
Knowledge-Driven AI
- Explain, Justify
crown?
Showercap
(97.5% certainty)

Context aware ML using KR (informed ML)
See survey of 100+ systems in Von Rueden et al, Learning, 2019
43
flower?
cushion?
“Parts of a chair are:
cushion and armrest”
“Given the context of chair,
a cushion is much more likely
than a flower”
P(cushion|chair) >> P(flower|chair)

Knolwledge Graph-enhanced RAG (Retrieval Augmented
Generation)
44

PAGE 45
Use Case Application: KG-RAG based QA System
Combining KG with LLM for Cybersecurity Analysis:
▪Reduce hallucination
▪Improve Explainability
▪Increase Accuracy
▪Support Natural Language QA
▪etc.

Knolwledge Graph-enhanced RAG (Retrieval Augmented
Generation) for Cybersecurity
46

Knolwledge Graph-enhanced RAG (Retrieval Augmented
Generation) for Cybersecurity
47

Knolwledge Graph-enhanced RAG (Retrieval Augmented
Generation) for Cybersecurity
48
(i) General Questions on Cyber threat Intelligence
(ii) Vulnerability Assessment

Knolwledge Graph-enhanced RAG (Retrieval Augmented
Generation) for Cybersecurity – Example Use Case
49
•Demonstrates the use of our RAG
system to facilitate question
answering against private or local
information (e.g., log sources).
•For this experiment, we used a
dataset derived from the AIT
dataset and constructed a KG from
it using an LLM.
•Additionally, we generated vector
embeddings to enable full-text
search against the constructed KG.
(iii) Security Log Analysis
Kurniawan, Kabul, Elmar Kiesling, and Andreas Ekelhart. "CyKG-RAG: Towards knowledge-graph enhanced retrieval augmented
generation for cybersecurity.“ RAGE-KG Workshop, ISWC 2024.

▪General Purpose KG vs. Domain-Specific KG
▪Personal-KG vs. Enterprise KG
▪Crowd-Source KG vs. Automated Extraction KG
▪Static KG vs. Dynamic KG
▪Ontology Based KG vs. Data Driven KG vs. Hybrid KG
PAGE 50
Type of Knowledge Graphs

PAGE 51
Graph Database Platforms
Native RDF Graph databases with SPARQL language:
•GraphDB (Open source version provided)
•Virtuoso (Open source version provided)
•Solid Pods (Personal Data Store)
•Amazon Neptune (Cloud-hosted)
Other Graph database query languages include:
•Cypher... supported and developed byNeo4J
•Gremlin... supported and developed byApache TinkerPop

PAGE 52
Knowledge Graph Adoption

▪Knowledge Graphs are a way to organize entity and their relationship of a
particular domain
▪RDF standardized provides flexible data model that can be used to
represent knowledge of various domain
▪Using SPARQL to query data from RDF
▪Knowledge Graph comprises of different types
▪Various types of graph store exist ranging from query language and
usages.
▪Knowledge Graph can be used as data model for various use case
applications
PAGE 53
Summary

PAGE 54
Thank you!
Me with Ora Lassila
(Co-founder Semantic Web/
Tim-Berner’s Lee colleague)
(ISWC 2024,
@Maryland, USA)
Tags