La strada verso il successo con i database a grafo, la Graph Data Science e l’AI generativa

Neo4j
Neo4jOpen Source NOSQL Graph Database em Neo4j
La strada verso il successo
con i database a grafo, la
Graph Data Science e l’AI
generativa
Marco Bessi, PreSale Engineer
Neo4j Inc. All rights reserved 2023
Your friendly instructor
Neo4j
Italy
PreSale
Engineer
PhD
@PoliMI
Neo4j Inc. All rights reserved 2023
Neo4j
Neo4j Inc. All rights reserved 2023
Pioneered the
graph database
in 2002
4 Neo4j Inc. All rights reserved 2023
Neo4j is a DB
Causal
clustering
ACID
transactions
High
availability
Binary
& HTTP
protocol
Official
drivers
5 Neo4j Inc. All rights reserved 2023
Neo4j is a GRAPH DB
Causal
clustering
ACID
transactions
High
availability
Binary
& HTTP
protocol
Official
drivers
Native
graph DB
Property
graph
model
Schema
free
Index-free
adjacency
Cypher
6 Neo4j Inc. All rights reserved 2023
Labeled property graph
model components
• Nodes
- Represent objects in the graph
• Relationships
- Relate nodes by type and direction
• Properties
- Name-value pairs that can go
on nodes and relationships
- Can have indexes and composite
indexes
• Labels
- Group nodes & shape the domain
7 Neo4j Inc. All rights reserved 2023
Hybrid workload duality
Intelligent
Operational
Systems
Graph Transactions,
Storage & Querying
Built for operational and analytical workloads
Better
Predictions
for Analytics
Graph Analytics, ML,
& Data Science
8 Neo4j Inc. All rights reserved 2023
Graph Data Science
Neo4j Inc. All rights reserved 2023
GDS evolution
Local
Matching
Use embeddings to learn
the features in your
graph that you don’t even
know are important yet.
Train in-graph supervise
ML models to predict
links, labels and missing
data.
Global
Patterns
Graph
Representations
Use unsupervised
machine learning
techniques to identify
associations, anomalies,
and trends.
Graph analytics
Graph feature
engineering
Find the patterns
you’re looking for in
connected data.
Knowledge graphs
10 Neo4j Inc. All rights reserved 2023
65+ Graph Data Science Techniques in Neo4j
Pathfinding &
Search
• Shortest Path
• Single-Source Shortest Path
• All Pairs Shortest Path
• A* Shortest Path
• Yen’s K Shortest Path
• Minimum Weight Spanning Tree
• K-Spanning Tree (MST)
• Random Walk
• Breadth & Depth First Search
Centrality &
Importance
• Degree Centrality
• Closeness Centrality
• Harmonic Centrality
• Betweenness Centrality & Approx.
• PageRank
• Personalized PageRank
• ArticleRank
• Eigenvector Centrality
• Hyperlink Induced Topic Search (HITS)
• Influence Maximization (Greedy, CELF)
Community
Detection
• Triangle Count
• Local Clustering Coefficient
• Connected Components (Union Find)
• Strongly Connected Components
• Label Propagation
• Louvain Modularity
• K-1 Coloring
• Modularity Optimization
• Speaker Listener Label Propagation
Supervised
Machine Learning
• Node Classification
• Link Prediction
… and more!
Heuristic Link
Prediction
• Adamic Adar
• Common Neighbors
• Preferential Attachment
• Resource Allocations
• Same Community
• Total Neighbors
Similarity
• Node Similarity
• K-Nearest Neighbors (KNN)
• Jaccard Similarity
• Cosine Similarity
• Pearson Similarity
• Euclidean Distance
• Approximate Nearest Neighbors (ANN)
Graph
Embeddings
• Node2Vec
• FastRP
• FastRPExtended
• GraphSAGE
• Synthetic Graph Generation
• Scale Properties
• Collapse Paths
• One Hot Encoding
• Split Relationships
• Graph Export
• Pregel API (write your own algos)
11 Neo4j Inc. All rights reserved 2023
Where is graph data science applied
Predictive
Maintenance
Churn
Prediction
Fraud
Detection
Life Sciences
Personalized
Recommendations
Cybersecurity
Disambiguation &
Segmentation
GenAI and KG
12 Neo4j Inc. All rights reserved 2023
Generative AI &
Knowledge Graphs
Neo4j Inc. All rights reserved 2023
In a world of infinite
content, knowledge
becomes valuable
Denny
Vrandečić
[WikiData]
[Semantic MediaWiki]
[Wikifunctions]
14 Neo4j Inc. All rights reserved 2023
$6.6 Trillion
In Economic Value
Generative AI is Predicted to Unlock
Up to 3.3% productivity improvement annually
15 Neo4j Inc. All rights reserved 2023
Generative AI
A branch of artificial intelligence that
focuses on creating models and
algorithms capable of generating new
and original content.
ChatGPT is a well known example of a
generative AI.
A type of Generative AI that is trained on
vast amounts of content.
Currently seen as the “GenAI for
language/text”.
ChatGPT is a Large Language Model.
Large Language Model
LLMs give us an amazing opportunity to:
Automate data
retrieval tasks 1
3
2
4
Expedite reading,
understanding, &
summarizing
Improve customer
service experiences
Generate content
& code
17 Neo4j Inc. All rights reserved 2023
Save time and money
Improve growth and retention:
Customer
Operations 1
3
2
4
Software Engineering
Marketing & Sales
R&D
75% of GenAI value will come from four areas
18 Neo4j Inc. All rights reserved 2023
But there are challenges:
1
3
2
4
5
Knowledge
cut-off
Can inherit bias
through training data
Reasonable answers,
not always accurate
Lack of enterprise
domain knowledge
Inability to verify or
attribute sources
19 Neo4j Inc. All rights reserved 2023
In summary
Learns random sentences from
random people
Talks like a person but doesn’t
really understand what it’s saying
Occasionally speaks absolute
non sense
Is a cute little bird
20 Neo4j Inc. All rights reserved 2023
How can you take advantage of
this massive opportunity while
overcoming these challenges?
21 Neo4j Inc. All rights reserved 2023
LLM + Graphs
I want to use
LLM’s in my
Graph for…
22 Neo4j Inc. All rights reserved 2023
LLM + Graphs
Front-end
Natural language
to cypher
I want to use
LLM’s in my
Graph for…
23 Neo4j Inc. All rights reserved 2023
LLM + Graphs
Back-end
KG-enhanced
LLMs
Front-end
Natural language
to cypher
I want to use
LLM’s in my
Graph for…
24 Neo4j Inc. All rights reserved 2023
How to help LLM do better?
Fine tuning
Few-shot
learning
Grounding
Provide additional
training data to better
tune GenAI to your
use case
Provide completed
examples “shots” to
the AI as context in
prompts. a.k.a
In-Context Learning
Provide AI with the
information to use for
generating responses
Neo4j as the data
source for Grounding
25 Neo4j Inc. All rights reserved 2023
Ground LLMs in Neo4j’s Knowledge Graph
26 Neo4j Inc. All rights reserved 2023
Retrieval Augmented
Generation (RAG):
retrieve data from outside a
foundation model and augment
your prompts by adding the
relevant retrieved data in
context
Neo4j’s Knowledge Graph
LLM + Neo4j’s
Knowledge
Graph
Improve
accuracy
Deploy with
confidence
Unlock
innovation
27 Neo4j Inc. All rights reserved 2023
Combine the power of LLM with the stored data of
your knowledge graph for more accurate responses
and to reduce hallucinations.
Improve Accuracy
Neo4j Inc. All rights reserved 2023
LLMs can help generate more accurate responses by considering the connections
and dependencies within the graph and mapping new links as new data is identified.
Flexible schema means it is
easy to grow your knowledge
base whenever new
information is available
Relationships are data that is
used to return explicit results
Accuracy
Vector search adds implicit
results showcasing similar
responses
29 Neo4j Inc. All rights reserved 2023
Knowledge retrieval with Neo4j
30 Neo4j Inc. All rights reserved 2023
CALL db.index.vector.queryNodes('products', 5, $embedding)
CALL apoc.ml.openai.embedding([$question], $apiKey)
CALL apoc.ml.openai.chat([{role:'system', content: $system},
{role:'user', content: $user}], $apiKey)
1
2
3
Add a layer of context
over your LLM for
accuracy and
specificity
Neo4j knowledge graphs supply the LLM with information about your company so answers
are specific to your business, giving more context for more accurate responses.
Specificity
31 Neo4j Inc. All rights reserved 2023
Ensure your grounding-partner meets security,
scalability, and regulatory requirements so you
can deploy enterprise-wide with confidence.
Deploy with Confidence
Neo4j Inc. All rights reserved 2023
Define policies by role or identity
Integrates with identity and access
management provider with SSO
LLM retrieves and returns information governed by your enterprise security and
access control policies-down to the node level.
Security & Privacy
Build constraints on nodes, labels,
relationships, properties, specific
parts of the graph, and even
traversal depth
33 Neo4j Inc. All rights reserved 2023
Easily scale with autonomous
clustering
Reliability
Neo4j knowledge graphs scale and are battle-tested to thousands of concurrent users,
get answers quickly with incredibly fast query speeds.
Incredibly fast traversals with index
free adjacency
34 Neo4j Inc. All rights reserved 2023
Add metadata or annotations
Map relationships between
search results and data source
nodes
Represent data sources as nodes
Verify the enriched responses from your LLM because each piece of information is
linked to its sources and origins.
Explainability
35 Neo4j Inc. All rights reserved 2023
Adopt innovation and iterate as your LLM
implementations evolve with full interoperability
across all cloud and data providers.
Unlock Innovation
Neo4j Inc. All rights reserved 2023
Any cloud, any data provider
Graph Data Science
BI & VISUALIZATIONS
INGEST
STORE
PROCESS
Apache
Kafka
MACHINE LEARNING
Cloud
Functions
Neo4j Bloom
PubSub
DataProc
Analytics
Feature
Engineering
Data
Exploration
Graph
Data
Science
Business
Applications &
Existing Systems
Files (unstructured,
structured)
TensorFlow
KNIME Python
Cloud Storage
AWS
Lambda
Graph Database
37 Neo4j Inc. All rights reserved 2023
Ground LLMs to improve accuracy and explainability with Neo4j’s
enterprise-ready knowledge graph built on a flexible schema that
integrates seamlessly with your GenAI tech platform.
Stay Grounded with Neo4j
Improve Accuracy Deploy with Confidence Unlock Innovation
Neo4j Inc. All rights reserved 2023
Nhow Milano
Via Tortona 35, Milano
Graph Talk Milano
Giovedi, 5 Ottobre 2023
9.00-13.30
Thank you
Marco Bessi, PreSale Engineer, marco.bessi@neo4j.com
Neo4j Inc. All rights reserved 2023
Support
41 Neo4j Inc. All rights reserved 2023
Better predictions with data you already have
● Traditional ML ignore network structure because it’s difficult to extract
● Add graphy data to existing ML pipelines to increase accuracy, or
● Graphs use relationships to unlock otherwise unattainable predictions
Machine Learning Pipeline
42 Neo4j Inc. All rights reserved 2023
Why do data science in Neo4j (VS Python/R )?
1
2
3
Performance: Specialized data structure; Good concurrency;
In-memory optimization & compression productions-ready.
Easy of use: Consistent syntax, including Cypher;
Comprehensive library (65+ vetted algorithms);
Persistence, every stage of the data science process
can be stored/not stored.
Product support: GDS / AuraDS is supported
by Neo4j, well documented, with a large
team of support engineers, and a sizeable
user community.
43 Neo4j Inc. All rights reserved 2023
Neo4j should be the database for Grounding
44 Neo4j Inc. All rights reserved 2023
Vector DB Limitations
Knowledge Graph
Strengths
Neo4j Differentiators
Similarity ≠ Relevance or
Accuracy
Black-Box (Sub-Symbolic)
Duplicate & incomplete
results
Missing reference information
Challenging to answer
multi-hop questions
Difficult for SME to correct
Relevancy beyond just
similarity
Transparent symbolic
representation
Condensed information
storage
References between
documents calculated before
query time
Enables human correction
LLMs understand Cypher
Vectors + Cypher
Index for many data types
(numeric, geopoints, dates)
Fine-grained security and
access control
ACID transactions,
high-availability, and scale
Ecosystem integration
Available on all clouds
Graph Data Science for
enhanced ML
New Neo4j features
From Neo4j v5.11
1
2
APOC OpenAI API:
CALL apoc.ml.openai.embedding(['Some Text'], $apiKey, {})
CALL apoc.ml.openai.completion('Question', $apiKey, {config}) yield
value;
CALL apoc.ml.query("Question") yield value, query
...
Vector index & search:
Index nodes on float or double array properties.
Based on Lucene which uses Hierarchical Navigable Small-World graphs (HNSW).
Created and queried using procedures.
Vector index
Leveraging Vector + KG
Creation
CALL db.index.vector.createNodeIndex(
)
indexName, // Name of the index to create (STRING)
label, // Label of nodes to index (STRING)
propertyKey, // Property key to index (STRING)
dimensions, // Dimensionality of vectors to index (INTEGER)
similarityFunction // “EUCLIDEAN” or “COSINE”
(case-insensitive STRING)
Querying
CALL db.index.vector.queryNodes(
)
indexName, // Name of the index to query (STRING)
k, // Number of neighbors to query for (INTEGER)
vector // Query vector whose neighbors we are searching for
(LIST<FLOAT>)
Writing vector efficiently
CALL db.create.setVectorProperty(
)
node, // Nodes to add the property to (NODE)
propertyKey, // Property key to write to (STRING)
vector, // Property value to write (LIST<FLOAT>)
1 de 50

Recomendados

La strada verso il successo con i database a grafo, la Graph Data Science e l... por
La strada verso il successo con i database a grafo, la Graph Data Science e l...La strada verso il successo con i database a grafo, la Graph Data Science e l...
La strada verso il successo con i database a grafo, la Graph Data Science e l...Neo4j
9 visualizações39 slides
El camino hacia el éxito con las bases de datos de grafos, la ciencia de dato... por
El camino hacia el éxito con las bases de datos de grafos, la ciencia de dato...El camino hacia el éxito con las bases de datos de grafos, la ciencia de dato...
El camino hacia el éxito con las bases de datos de grafos, la ciencia de dato...Neo4j
62 visualizações49 slides
Neo4j – The Fastest Path to Scalable Real-Time Analytics por
Neo4j – The Fastest Path to Scalable Real-Time AnalyticsNeo4j – The Fastest Path to Scalable Real-Time Analytics
Neo4j – The Fastest Path to Scalable Real-Time AnalyticsNeo4j
456 visualizações37 slides
Graph Data Science with Neo4j: Nordics Webinar por
Graph Data Science with Neo4j: Nordics WebinarGraph Data Science with Neo4j: Nordics Webinar
Graph Data Science with Neo4j: Nordics WebinarNeo4j
321 visualizações22 slides
Einstieg in Neo4j Graph Data Science por
Einstieg in Neo4j Graph Data ScienceEinstieg in Neo4j Graph Data Science
Einstieg in Neo4j Graph Data ScienceNeo4j
249 visualizações26 slides
Introducción a Neo4j por
Introducción a Neo4jIntroducción a Neo4j
Introducción a Neo4jNeo4j
32 visualizações27 slides

Mais conteúdo relacionado

Similar a La strada verso il successo con i database a grafo, la Graph Data Science e l’AI generativa

The perfect couple: Uniting Large Language Models and Knowledge Graphs for En... por
The perfect couple: Uniting Large Language Models and Knowledge Graphs for En...The perfect couple: Uniting Large Language Models and Knowledge Graphs for En...
The perfect couple: Uniting Large Language Models and Knowledge Graphs for En...Neo4j
268 visualizações57 slides
Neo4j GraphSummit London - The Path To Success With Graph Database and Data S... por
Neo4j GraphSummit London - The Path To Success With Graph Database and Data S...Neo4j GraphSummit London - The Path To Success With Graph Database and Data S...
Neo4j GraphSummit London - The Path To Success With Graph Database and Data S...Neo4j
129 visualizações42 slides
Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da... por
Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da...Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da...
Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da...Neo4j
39 visualizações30 slides
Graphs for Data Science and Machine Learning por
Graphs for Data Science and Machine LearningGraphs for Data Science and Machine Learning
Graphs for Data Science and Machine LearningNeo4j
795 visualizações40 slides
Government GraphSummit: Leveraging Graphs for AI and ML por
Government GraphSummit: Leveraging Graphs for AI and MLGovernment GraphSummit: Leveraging Graphs for AI and ML
Government GraphSummit: Leveraging Graphs for AI and MLNeo4j
92 visualizações24 slides
The Path To Success With Graph Database and Analytics por
The Path To Success With Graph Database and AnalyticsThe Path To Success With Graph Database and Analytics
The Path To Success With Graph Database and AnalyticsNeo4j
41 visualizações39 slides

Similar a La strada verso il successo con i database a grafo, la Graph Data Science e l’AI generativa(20)

The perfect couple: Uniting Large Language Models and Knowledge Graphs for En... por Neo4j
The perfect couple: Uniting Large Language Models and Knowledge Graphs for En...The perfect couple: Uniting Large Language Models and Knowledge Graphs for En...
The perfect couple: Uniting Large Language Models and Knowledge Graphs for En...
Neo4j268 visualizações
Neo4j GraphSummit London - The Path To Success With Graph Database and Data S... por Neo4j
Neo4j GraphSummit London - The Path To Success With Graph Database and Data S...Neo4j GraphSummit London - The Path To Success With Graph Database and Data S...
Neo4j GraphSummit London - The Path To Success With Graph Database and Data S...
Neo4j129 visualizações
Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da... por Neo4j
Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da...Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da...
Neo4j : la voie du succès avec les bases de données de graphes et la Graph Da...
Neo4j39 visualizações
Graphs for Data Science and Machine Learning por Neo4j
Graphs for Data Science and Machine LearningGraphs for Data Science and Machine Learning
Graphs for Data Science and Machine Learning
Neo4j795 visualizações
Government GraphSummit: Leveraging Graphs for AI and ML por Neo4j
Government GraphSummit: Leveraging Graphs for AI and MLGovernment GraphSummit: Leveraging Graphs for AI and ML
Government GraphSummit: Leveraging Graphs for AI and ML
Neo4j92 visualizações
The Path To Success With Graph Database and Analytics por Neo4j
The Path To Success With Graph Database and AnalyticsThe Path To Success With Graph Database and Analytics
The Path To Success With Graph Database and Analytics
Neo4j41 visualizações
Knowledge Graphs and Generative AI_GraphSummit Minneapolis Sept 20.pptx por Neo4j
Knowledge Graphs and Generative AI_GraphSummit Minneapolis Sept 20.pptxKnowledge Graphs and Generative AI_GraphSummit Minneapolis Sept 20.pptx
Knowledge Graphs and Generative AI_GraphSummit Minneapolis Sept 20.pptx
Neo4j251 visualizações
Neo4j GraphDay Seattle- Sept19- Connected data imperative por Neo4j
Neo4j GraphDay Seattle- Sept19- Connected data imperativeNeo4j GraphDay Seattle- Sept19- Connected data imperative
Neo4j GraphDay Seattle- Sept19- Connected data imperative
Neo4j529 visualizações
Optimizing Your Supply Chain with Neo4j por Neo4j
Optimizing Your Supply Chain with Neo4jOptimizing Your Supply Chain with Neo4j
Optimizing Your Supply Chain with Neo4j
Neo4j49 visualizações
Neo4j y GenAI por Neo4j
Neo4j y GenAI Neo4j y GenAI
Neo4j y GenAI
Neo4j60 visualizações
The Art of the Possible with Graph - Sudhir Hasbe - GraphSummit London 14 Nov... por Neo4j
The Art of the Possible with Graph - Sudhir Hasbe - GraphSummit London 14 Nov...The Art of the Possible with Graph - Sudhir Hasbe - GraphSummit London 14 Nov...
The Art of the Possible with Graph - Sudhir Hasbe - GraphSummit London 14 Nov...
Neo4j77 visualizações
ntroducing to the Power of Graph Technology por Neo4j
ntroducing to the Power of Graph Technologyntroducing to the Power of Graph Technology
ntroducing to the Power of Graph Technology
Neo4j336 visualizações
Using Connected Data and Graph Technology to Enhance Machine Learning and Art... por Neo4j
Using Connected Data and Graph Technology to Enhance Machine Learning and Art...Using Connected Data and Graph Technology to Enhance Machine Learning and Art...
Using Connected Data and Graph Technology to Enhance Machine Learning and Art...
Neo4j50 visualizações
The path to success with Graph Database and Graph Data Science por Neo4j
The path to success with Graph Database and Graph Data ScienceThe path to success with Graph Database and Graph Data Science
The path to success with Graph Database and Graph Data Science
Neo4j107 visualizações
GraphSummit Toronto: Leveraging Graphs for AI and ML por Neo4j
GraphSummit Toronto: Leveraging Graphs for AI and MLGraphSummit Toronto: Leveraging Graphs for AI and ML
GraphSummit Toronto: Leveraging Graphs for AI and ML
Neo4j66 visualizações
Workshop - Build a Graph Solution por Neo4j
Workshop - Build a Graph SolutionWorkshop - Build a Graph Solution
Workshop - Build a Graph Solution
Neo4j94 visualizações
Neo4j Generative AI workshop at GraphSummit London 14 Nov 2023.pdf por Neo4j
Neo4j Generative AI workshop at GraphSummit London 14 Nov 2023.pdfNeo4j Generative AI workshop at GraphSummit London 14 Nov 2023.pdf
Neo4j Generative AI workshop at GraphSummit London 14 Nov 2023.pdf
Neo4j63 visualizações
GraphTour 2020 - Neo4j: What's New? por Neo4j
GraphTour 2020 - Neo4j: What's New?GraphTour 2020 - Neo4j: What's New?
GraphTour 2020 - Neo4j: What's New?
Neo4j511 visualizações
The Neo4j Data Platform for Today & Tomorrow.pdf por Neo4j
The Neo4j Data Platform for Today & Tomorrow.pdfThe Neo4j Data Platform for Today & Tomorrow.pdf
The Neo4j Data Platform for Today & Tomorrow.pdf
Neo4j157 visualizações
The Art of the Possible with Graph Technology por Neo4j
The Art of the Possible with Graph TechnologyThe Art of the Possible with Graph Technology
The Art of the Possible with Graph Technology
Neo4j30 visualizações

Mais de Neo4j

Discover Aura Workshop (12.5.23).pdf por
Discover Aura Workshop (12.5.23).pdfDiscover Aura Workshop (12.5.23).pdf
Discover Aura Workshop (12.5.23).pdfNeo4j
15 visualizações55 slides
FIMA 2023 Neo4j & FS - Entity Resolution.pptx por
FIMA 2023 Neo4j & FS - Entity Resolution.pptxFIMA 2023 Neo4j & FS - Entity Resolution.pptx
FIMA 2023 Neo4j & FS - Entity Resolution.pptxNeo4j
19 visualizações26 slides
Operations & Data Graph por
Operations & Data GraphOperations & Data Graph
Operations & Data GraphNeo4j
48 visualizações25 slides
TAGTTOO: La nova xarxa social por
TAGTTOO: La nova xarxa socialTAGTTOO: La nova xarxa social
TAGTTOO: La nova xarxa socialNeo4j
27 visualizações19 slides
El Arte de lo Possible por
El Arte de lo PossibleEl Arte de lo Possible
El Arte de lo PossibleNeo4j
53 visualizações35 slides
Roadmap y Novedades de producto por
Roadmap y Novedades de productoRoadmap y Novedades de producto
Roadmap y Novedades de productoNeo4j
64 visualizações33 slides

Mais de Neo4j(20)

Discover Aura Workshop (12.5.23).pdf por Neo4j
Discover Aura Workshop (12.5.23).pdfDiscover Aura Workshop (12.5.23).pdf
Discover Aura Workshop (12.5.23).pdf
Neo4j15 visualizações
FIMA 2023 Neo4j & FS - Entity Resolution.pptx por Neo4j
FIMA 2023 Neo4j & FS - Entity Resolution.pptxFIMA 2023 Neo4j & FS - Entity Resolution.pptx
FIMA 2023 Neo4j & FS - Entity Resolution.pptx
Neo4j19 visualizações
Operations & Data Graph por Neo4j
Operations & Data GraphOperations & Data Graph
Operations & Data Graph
Neo4j48 visualizações
TAGTTOO: La nova xarxa social por Neo4j
TAGTTOO: La nova xarxa socialTAGTTOO: La nova xarxa social
TAGTTOO: La nova xarxa social
Neo4j27 visualizações
El Arte de lo Possible por Neo4j
El Arte de lo PossibleEl Arte de lo Possible
El Arte de lo Possible
Neo4j53 visualizações
Roadmap y Novedades de producto por Neo4j
Roadmap y Novedades de productoRoadmap y Novedades de producto
Roadmap y Novedades de producto
Neo4j64 visualizações
Neo4j : Graphes de Connaissance, IA et LLMs por Neo4j
Neo4j : Graphes de Connaissance, IA et LLMsNeo4j : Graphes de Connaissance, IA et LLMs
Neo4j : Graphes de Connaissance, IA et LLMs
Neo4j62 visualizações
Les nouveautés produit Neo4j por Neo4j
 Les nouveautés produit Neo4j Les nouveautés produit Neo4j
Les nouveautés produit Neo4j
Neo4j32 visualizações
Sopra Steria : Analyse intelligente des réseaux dans le domaine des télécommu... por Neo4j
Sopra Steria : Analyse intelligente des réseaux dans le domaine des télécommu...Sopra Steria : Analyse intelligente des réseaux dans le domaine des télécommu...
Sopra Steria : Analyse intelligente des réseaux dans le domaine des télécommu...
Neo4j27 visualizações
Generali : SPIDER, notre produit au cœur des enjeux Generali en termes de Com... por Neo4j
Generali : SPIDER, notre produit au cœur des enjeux Generali en termes de Com...Generali : SPIDER, notre produit au cœur des enjeux Generali en termes de Com...
Generali : SPIDER, notre produit au cœur des enjeux Generali en termes de Com...
Neo4j54 visualizações
Neo4j & AWS Bedrock workshop at GraphSummit London 14 Nov 2023.pptx por Neo4j
Neo4j & AWS Bedrock workshop at GraphSummit London 14 Nov 2023.pptxNeo4j & AWS Bedrock workshop at GraphSummit London 14 Nov 2023.pptx
Neo4j & AWS Bedrock workshop at GraphSummit London 14 Nov 2023.pptx
Neo4j60 visualizações
Neo4j workshop at GraphSummit London 14 Nov 2023.pdf por Neo4j
Neo4j workshop at GraphSummit London 14 Nov 2023.pdfNeo4j workshop at GraphSummit London 14 Nov 2023.pdf
Neo4j workshop at GraphSummit London 14 Nov 2023.pdf
Neo4j56 visualizações
Neo4j Product Updates & Knowledge Graphs at GraphSummit London 14 Nov 2023.pptx por Neo4j
Neo4j Product Updates & Knowledge Graphs at GraphSummit London 14 Nov 2023.pptxNeo4j Product Updates & Knowledge Graphs at GraphSummit London 14 Nov 2023.pptx
Neo4j Product Updates & Knowledge Graphs at GraphSummit London 14 Nov 2023.pptx
Neo4j68 visualizações
AstraZeneca at Neo4j GraphSummit London 14Nov23.pptx por Neo4j
AstraZeneca at Neo4j GraphSummit London 14Nov23.pptxAstraZeneca at Neo4j GraphSummit London 14Nov23.pptx
AstraZeneca at Neo4j GraphSummit London 14Nov23.pptx
Neo4j53 visualizações
Google Cloud at GraphSummit London 14 Nov 2023.pptx por Neo4j
Google Cloud at GraphSummit London 14 Nov 2023.pptxGoogle Cloud at GraphSummit London 14 Nov 2023.pptx
Google Cloud at GraphSummit London 14 Nov 2023.pptx
Neo4j27 visualizações
Northern Gas Networks and CKDelta at Neo4j GraphSummit London 14Nov23.pptx por Neo4j
Northern Gas Networks and CKDelta at Neo4j GraphSummit London 14Nov23.pptxNorthern Gas Networks and CKDelta at Neo4j GraphSummit London 14Nov23.pptx
Northern Gas Networks and CKDelta at Neo4j GraphSummit London 14Nov23.pptx
Neo4j49 visualizações
Peek into Neo4j Product Strategy and Roadmap por Neo4j
Peek into Neo4j Product Strategy and RoadmapPeek into Neo4j Product Strategy and Roadmap
Peek into Neo4j Product Strategy and Roadmap
Neo4j88 visualizações
Transforming Intelligence Analysis with Knowledge Graphs por Neo4j
Transforming Intelligence Analysis with Knowledge GraphsTransforming Intelligence Analysis with Knowledge Graphs
Transforming Intelligence Analysis with Knowledge Graphs
Neo4j65 visualizações
Knowledge Graphs and Generative AI por Neo4j
Knowledge Graphs and Generative AIKnowledge Graphs and Generative AI
Knowledge Graphs and Generative AI
Neo4j168 visualizações
Ontology Driven Data for Fleet Management por Neo4j
Ontology Driven Data for Fleet ManagementOntology Driven Data for Fleet Management
Ontology Driven Data for Fleet Management
Neo4j60 visualizações

Último

Mobile App Development Company por
Mobile App Development CompanyMobile App Development Company
Mobile App Development CompanyRichestsoft
5 visualizações6 slides
Introduction to Gradle por
Introduction to GradleIntroduction to Gradle
Introduction to GradleJohn Valentino
7 visualizações7 slides
Using Qt under LGPL-3.0 por
Using Qt under LGPL-3.0Using Qt under LGPL-3.0
Using Qt under LGPL-3.0Burkhard Stubert
14 visualizações11 slides
EV Charging App Case por
EV Charging App Case EV Charging App Case
EV Charging App Case iCoderz Solutions
10 visualizações1 slide
How to build dyanmic dashboards and ensure they always work por
How to build dyanmic dashboards and ensure they always workHow to build dyanmic dashboards and ensure they always work
How to build dyanmic dashboards and ensure they always workWiiisdom
16 visualizações13 slides
Understanding HTML terminology por
Understanding HTML terminologyUnderstanding HTML terminology
Understanding HTML terminologyartembondar5
8 visualizações8 slides

Último(20)

Mobile App Development Company por Richestsoft
Mobile App Development CompanyMobile App Development Company
Mobile App Development Company
Richestsoft 5 visualizações
Introduction to Gradle por John Valentino
Introduction to GradleIntroduction to Gradle
Introduction to Gradle
John Valentino7 visualizações
Using Qt under LGPL-3.0 por Burkhard Stubert
Using Qt under LGPL-3.0Using Qt under LGPL-3.0
Using Qt under LGPL-3.0
Burkhard Stubert14 visualizações
EV Charging App Case por iCoderz Solutions
EV Charging App Case EV Charging App Case
EV Charging App Case
iCoderz Solutions10 visualizações
How to build dyanmic dashboards and ensure they always work por Wiiisdom
How to build dyanmic dashboards and ensure they always workHow to build dyanmic dashboards and ensure they always work
How to build dyanmic dashboards and ensure they always work
Wiiisdom16 visualizações
Understanding HTML terminology por artembondar5
Understanding HTML terminologyUnderstanding HTML terminology
Understanding HTML terminology
artembondar58 visualizações
aATP - New Correlation Confirmation Feature.pptx por EsatEsenek1
aATP - New Correlation Confirmation Feature.pptxaATP - New Correlation Confirmation Feature.pptx
aATP - New Correlation Confirmation Feature.pptx
EsatEsenek1222 visualizações
Quality Engineer: A Day in the Life por John Valentino
Quality Engineer: A Day in the LifeQuality Engineer: A Day in the Life
Quality Engineer: A Day in the Life
John Valentino10 visualizações
Top-5-production-devconMunich-2023-v2.pptx por Tier1 app
Top-5-production-devconMunich-2023-v2.pptxTop-5-production-devconMunich-2023-v2.pptx
Top-5-production-devconMunich-2023-v2.pptx
Tier1 app9 visualizações
FOSSLight Community Day 2023-11-30 por Shane Coughlan
FOSSLight Community Day 2023-11-30FOSSLight Community Day 2023-11-30
FOSSLight Community Day 2023-11-30
Shane Coughlan8 visualizações
Dapr Unleashed: Accelerating Microservice Development por Miroslav Janeski
Dapr Unleashed: Accelerating Microservice DevelopmentDapr Unleashed: Accelerating Microservice Development
Dapr Unleashed: Accelerating Microservice Development
Miroslav Janeski16 visualizações
JioEngage_Presentation.pptx por admin125455
JioEngage_Presentation.pptxJioEngage_Presentation.pptx
JioEngage_Presentation.pptx
admin1254559 visualizações
Playwright Retries por artembondar5
Playwright RetriesPlaywright Retries
Playwright Retries
artembondar57 visualizações
Benefits in Software Development por John Valentino
Benefits in Software DevelopmentBenefits in Software Development
Benefits in Software Development
John Valentino6 visualizações
Advanced API Mocking Techniques Using Wiremock por Dimpy Adhikary
Advanced API Mocking Techniques Using WiremockAdvanced API Mocking Techniques Using Wiremock
Advanced API Mocking Techniques Using Wiremock
Dimpy Adhikary5 visualizações
Chat GPTs por Gene Leybzon
Chat GPTsChat GPTs
Chat GPTs
Gene Leybzon13 visualizações
Introduction to Maven por John Valentino
Introduction to MavenIntroduction to Maven
Introduction to Maven
John Valentino7 visualizações
How Workforce Management Software Empowers SMEs | TraQSuite por TraQSuite
How Workforce Management Software Empowers SMEs | TraQSuiteHow Workforce Management Software Empowers SMEs | TraQSuite
How Workforce Management Software Empowers SMEs | TraQSuite
TraQSuite7 visualizações

La strada verso il successo con i database a grafo, la Graph Data Science e l’AI generativa

  • 1. La strada verso il successo con i database a grafo, la Graph Data Science e l’AI generativa Marco Bessi, PreSale Engineer Neo4j Inc. All rights reserved 2023
  • 3. Neo4j Neo4j Inc. All rights reserved 2023
  • 4. Pioneered the graph database in 2002 4 Neo4j Inc. All rights reserved 2023
  • 5. Neo4j is a DB Causal clustering ACID transactions High availability Binary & HTTP protocol Official drivers 5 Neo4j Inc. All rights reserved 2023
  • 6. Neo4j is a GRAPH DB Causal clustering ACID transactions High availability Binary & HTTP protocol Official drivers Native graph DB Property graph model Schema free Index-free adjacency Cypher 6 Neo4j Inc. All rights reserved 2023
  • 7. Labeled property graph model components • Nodes - Represent objects in the graph • Relationships - Relate nodes by type and direction • Properties - Name-value pairs that can go on nodes and relationships - Can have indexes and composite indexes • Labels - Group nodes & shape the domain 7 Neo4j Inc. All rights reserved 2023
  • 8. Hybrid workload duality Intelligent Operational Systems Graph Transactions, Storage & Querying Built for operational and analytical workloads Better Predictions for Analytics Graph Analytics, ML, & Data Science 8 Neo4j Inc. All rights reserved 2023
  • 9. Graph Data Science Neo4j Inc. All rights reserved 2023
  • 10. GDS evolution Local Matching Use embeddings to learn the features in your graph that you don’t even know are important yet. Train in-graph supervise ML models to predict links, labels and missing data. Global Patterns Graph Representations Use unsupervised machine learning techniques to identify associations, anomalies, and trends. Graph analytics Graph feature engineering Find the patterns you’re looking for in connected data. Knowledge graphs 10 Neo4j Inc. All rights reserved 2023
  • 11. 65+ Graph Data Science Techniques in Neo4j Pathfinding & Search • Shortest Path • Single-Source Shortest Path • All Pairs Shortest Path • A* Shortest Path • Yen’s K Shortest Path • Minimum Weight Spanning Tree • K-Spanning Tree (MST) • Random Walk • Breadth & Depth First Search Centrality & Importance • Degree Centrality • Closeness Centrality • Harmonic Centrality • Betweenness Centrality & Approx. • PageRank • Personalized PageRank • ArticleRank • Eigenvector Centrality • Hyperlink Induced Topic Search (HITS) • Influence Maximization (Greedy, CELF) Community Detection • Triangle Count • Local Clustering Coefficient • Connected Components (Union Find) • Strongly Connected Components • Label Propagation • Louvain Modularity • K-1 Coloring • Modularity Optimization • Speaker Listener Label Propagation Supervised Machine Learning • Node Classification • Link Prediction … and more! Heuristic Link Prediction • Adamic Adar • Common Neighbors • Preferential Attachment • Resource Allocations • Same Community • Total Neighbors Similarity • Node Similarity • K-Nearest Neighbors (KNN) • Jaccard Similarity • Cosine Similarity • Pearson Similarity • Euclidean Distance • Approximate Nearest Neighbors (ANN) Graph Embeddings • Node2Vec • FastRP • FastRPExtended • GraphSAGE • Synthetic Graph Generation • Scale Properties • Collapse Paths • One Hot Encoding • Split Relationships • Graph Export • Pregel API (write your own algos) 11 Neo4j Inc. All rights reserved 2023
  • 12. Where is graph data science applied Predictive Maintenance Churn Prediction Fraud Detection Life Sciences Personalized Recommendations Cybersecurity Disambiguation & Segmentation GenAI and KG 12 Neo4j Inc. All rights reserved 2023
  • 13. Generative AI & Knowledge Graphs Neo4j Inc. All rights reserved 2023
  • 14. In a world of infinite content, knowledge becomes valuable Denny Vrandečić [WikiData] [Semantic MediaWiki] [Wikifunctions] 14 Neo4j Inc. All rights reserved 2023
  • 15. $6.6 Trillion In Economic Value Generative AI is Predicted to Unlock Up to 3.3% productivity improvement annually 15 Neo4j Inc. All rights reserved 2023
  • 16. Generative AI A branch of artificial intelligence that focuses on creating models and algorithms capable of generating new and original content. ChatGPT is a well known example of a generative AI. A type of Generative AI that is trained on vast amounts of content. Currently seen as the “GenAI for language/text”. ChatGPT is a Large Language Model. Large Language Model
  • 17. LLMs give us an amazing opportunity to: Automate data retrieval tasks 1 3 2 4 Expedite reading, understanding, & summarizing Improve customer service experiences Generate content & code 17 Neo4j Inc. All rights reserved 2023
  • 18. Save time and money Improve growth and retention: Customer Operations 1 3 2 4 Software Engineering Marketing & Sales R&D 75% of GenAI value will come from four areas 18 Neo4j Inc. All rights reserved 2023
  • 19. But there are challenges: 1 3 2 4 5 Knowledge cut-off Can inherit bias through training data Reasonable answers, not always accurate Lack of enterprise domain knowledge Inability to verify or attribute sources 19 Neo4j Inc. All rights reserved 2023
  • 20. In summary Learns random sentences from random people Talks like a person but doesn’t really understand what it’s saying Occasionally speaks absolute non sense Is a cute little bird 20 Neo4j Inc. All rights reserved 2023
  • 21. How can you take advantage of this massive opportunity while overcoming these challenges? 21 Neo4j Inc. All rights reserved 2023
  • 22. LLM + Graphs I want to use LLM’s in my Graph for… 22 Neo4j Inc. All rights reserved 2023
  • 23. LLM + Graphs Front-end Natural language to cypher I want to use LLM’s in my Graph for… 23 Neo4j Inc. All rights reserved 2023
  • 24. LLM + Graphs Back-end KG-enhanced LLMs Front-end Natural language to cypher I want to use LLM’s in my Graph for… 24 Neo4j Inc. All rights reserved 2023
  • 25. How to help LLM do better? Fine tuning Few-shot learning Grounding Provide additional training data to better tune GenAI to your use case Provide completed examples “shots” to the AI as context in prompts. a.k.a In-Context Learning Provide AI with the information to use for generating responses Neo4j as the data source for Grounding 25 Neo4j Inc. All rights reserved 2023
  • 26. Ground LLMs in Neo4j’s Knowledge Graph 26 Neo4j Inc. All rights reserved 2023 Retrieval Augmented Generation (RAG): retrieve data from outside a foundation model and augment your prompts by adding the relevant retrieved data in context
  • 27. Neo4j’s Knowledge Graph LLM + Neo4j’s Knowledge Graph Improve accuracy Deploy with confidence Unlock innovation 27 Neo4j Inc. All rights reserved 2023
  • 28. Combine the power of LLM with the stored data of your knowledge graph for more accurate responses and to reduce hallucinations. Improve Accuracy Neo4j Inc. All rights reserved 2023
  • 29. LLMs can help generate more accurate responses by considering the connections and dependencies within the graph and mapping new links as new data is identified. Flexible schema means it is easy to grow your knowledge base whenever new information is available Relationships are data that is used to return explicit results Accuracy Vector search adds implicit results showcasing similar responses 29 Neo4j Inc. All rights reserved 2023
  • 30. Knowledge retrieval with Neo4j 30 Neo4j Inc. All rights reserved 2023 CALL db.index.vector.queryNodes('products', 5, $embedding) CALL apoc.ml.openai.embedding([$question], $apiKey) CALL apoc.ml.openai.chat([{role:'system', content: $system}, {role:'user', content: $user}], $apiKey) 1 2 3
  • 31. Add a layer of context over your LLM for accuracy and specificity Neo4j knowledge graphs supply the LLM with information about your company so answers are specific to your business, giving more context for more accurate responses. Specificity 31 Neo4j Inc. All rights reserved 2023
  • 32. Ensure your grounding-partner meets security, scalability, and regulatory requirements so you can deploy enterprise-wide with confidence. Deploy with Confidence Neo4j Inc. All rights reserved 2023
  • 33. Define policies by role or identity Integrates with identity and access management provider with SSO LLM retrieves and returns information governed by your enterprise security and access control policies-down to the node level. Security & Privacy Build constraints on nodes, labels, relationships, properties, specific parts of the graph, and even traversal depth 33 Neo4j Inc. All rights reserved 2023
  • 34. Easily scale with autonomous clustering Reliability Neo4j knowledge graphs scale and are battle-tested to thousands of concurrent users, get answers quickly with incredibly fast query speeds. Incredibly fast traversals with index free adjacency 34 Neo4j Inc. All rights reserved 2023
  • 35. Add metadata or annotations Map relationships between search results and data source nodes Represent data sources as nodes Verify the enriched responses from your LLM because each piece of information is linked to its sources and origins. Explainability 35 Neo4j Inc. All rights reserved 2023
  • 36. Adopt innovation and iterate as your LLM implementations evolve with full interoperability across all cloud and data providers. Unlock Innovation Neo4j Inc. All rights reserved 2023
  • 37. Any cloud, any data provider Graph Data Science BI & VISUALIZATIONS INGEST STORE PROCESS Apache Kafka MACHINE LEARNING Cloud Functions Neo4j Bloom PubSub DataProc Analytics Feature Engineering Data Exploration Graph Data Science Business Applications & Existing Systems Files (unstructured, structured) TensorFlow KNIME Python Cloud Storage AWS Lambda Graph Database 37 Neo4j Inc. All rights reserved 2023
  • 38. Ground LLMs to improve accuracy and explainability with Neo4j’s enterprise-ready knowledge graph built on a flexible schema that integrates seamlessly with your GenAI tech platform. Stay Grounded with Neo4j Improve Accuracy Deploy with Confidence Unlock Innovation Neo4j Inc. All rights reserved 2023
  • 39. Nhow Milano Via Tortona 35, Milano Graph Talk Milano Giovedi, 5 Ottobre 2023 9.00-13.30
  • 40. Thank you Marco Bessi, PreSale Engineer, marco.bessi@neo4j.com Neo4j Inc. All rights reserved 2023
  • 41. Support 41 Neo4j Inc. All rights reserved 2023
  • 42. Better predictions with data you already have ● Traditional ML ignore network structure because it’s difficult to extract ● Add graphy data to existing ML pipelines to increase accuracy, or ● Graphs use relationships to unlock otherwise unattainable predictions Machine Learning Pipeline 42 Neo4j Inc. All rights reserved 2023
  • 43. Why do data science in Neo4j (VS Python/R )? 1 2 3 Performance: Specialized data structure; Good concurrency; In-memory optimization & compression productions-ready. Easy of use: Consistent syntax, including Cypher; Comprehensive library (65+ vetted algorithms); Persistence, every stage of the data science process can be stored/not stored. Product support: GDS / AuraDS is supported by Neo4j, well documented, with a large team of support engineers, and a sizeable user community. 43 Neo4j Inc. All rights reserved 2023
  • 44. Neo4j should be the database for Grounding 44 Neo4j Inc. All rights reserved 2023 Vector DB Limitations Knowledge Graph Strengths Neo4j Differentiators Similarity ≠ Relevance or Accuracy Black-Box (Sub-Symbolic) Duplicate & incomplete results Missing reference information Challenging to answer multi-hop questions Difficult for SME to correct Relevancy beyond just similarity Transparent symbolic representation Condensed information storage References between documents calculated before query time Enables human correction LLMs understand Cypher Vectors + Cypher Index for many data types (numeric, geopoints, dates) Fine-grained security and access control ACID transactions, high-availability, and scale Ecosystem integration Available on all clouds Graph Data Science for enhanced ML
  • 45. New Neo4j features From Neo4j v5.11 1 2 APOC OpenAI API: CALL apoc.ml.openai.embedding(['Some Text'], $apiKey, {}) CALL apoc.ml.openai.completion('Question', $apiKey, {config}) yield value; CALL apoc.ml.query("Question") yield value, query ... Vector index & search: Index nodes on float or double array properties. Based on Lucene which uses Hierarchical Navigable Small-World graphs (HNSW). Created and queried using procedures.
  • 48. Creation CALL db.index.vector.createNodeIndex( ) indexName, // Name of the index to create (STRING) label, // Label of nodes to index (STRING) propertyKey, // Property key to index (STRING) dimensions, // Dimensionality of vectors to index (INTEGER) similarityFunction // “EUCLIDEAN” or “COSINE” (case-insensitive STRING)
  • 49. Querying CALL db.index.vector.queryNodes( ) indexName, // Name of the index to query (STRING) k, // Number of neighbors to query for (INTEGER) vector // Query vector whose neighbors we are searching for (LIST<FLOAT>)
  • 50. Writing vector efficiently CALL db.create.setVectorProperty( ) node, // Nodes to add the property to (NODE) propertyKey, // Property key to write to (STRING) vector, // Property value to write (LIST<FLOAT>)