"In this session, we will discuss some recent developments in Generative AI and how those can be leveraged to build intelligent applications. Learn how to bring the power of large language models (LLMs) to your private, real-time operational data across multiple data types. We will talk about improving the accuracy of LLMs in your applications by leveraging Retrieval Augmented Generation, which provides proprietary knowledge to the LLM.
From real-time responses to sophisticated interactions, learn how you can easily build a range of AI-driven experiences that leverage your operational data with minimal complexity.
MongoDB Atlas provides native vector search capabilities and a flexible document model all within an enterprise-ready developer data platform empowering teams to iterate quickly on applications enriched with generative AI. Coupling Atlas with Confluent makes it easier to leverage streaming data when informing LLMs with proprietary data."
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
Accelerating Path to Production for Generative AI-powered Applications
1. MongoDB for Generative
AI-powered Applications
Welcome
Prakul Agarwal
Senior Product Manager
Machine Learning
David Macias
Lead Product Marketer
2. Agenda
Intro to Generative AI-Powered Apps
Use Cases and RAG w/MongoDB Atlas
Demo: Confluent Cloud + MongoDB Atlas
MongoDB Atlas Vector Search
3. What is a Generative AI-powered App
Generative AI (Gen AI) is software that can generate, or
create, something new when asked through a prompt.
Adobe Firefly
4. What we’re seeing in the industry
Chatbots Mind Blowing Ideas
360 View + LLM
Demo at the end!
5. : Global auto manufacturer
Gen AI
Diagnostics
Car
sounds
6. What is an LLM ?
-Gen AI uses “Large Language Models” or
LLMs that provide a general-purpose AI
“brain,” no custom building needed for each
project.
-The LLM performs the “generative” functions,
for example, creating text, image, write code
or video.
-LLMs “studied” enormous amounts of public
data to learn patterns between words, images,
videos, or other data.
- OpenAI’s GPT is the most popular LLM
- ChatGPT is a Gen AI app built using the
popular GPT as it’s brain
- Meta’s LLaMa is an example of an open
source LLM
7. Non-specific answer
LLM
No context prompt
“How do I sell new MongoDB
and Kafka to my accounts
based on their current and
upcoming priorities?”
“MongoDB is chosen for its flexibility
and scalability, performance and
availability, and its ease of use and
security. Tailor these points to the
needs of the engineering leader
you're pitching to.”
Not specific. Doesn’t
mention Atlas or
Confluent Cloud.
Giant “brain” of general
knowledge
An LLM that hasnʼt been made useful
8. Making an LLM useful
General intelligence
(generic AI/ML models)
Streams
Serverless
Edge
Hybrid
Search
Access to proprietary data
A well trained LLM refined
with multimodal data
From this To This
How
Company specific data
Order history
Product info
9. Specific, well
informed answer
LLM
Augmenting an LLM with proprietary data
Retrieval-augmented generation (RAG)
Proprietary
Data
Context data Vector Embeddings
Metadata and
app data
Audio files
Customer
Data
Images
[0.234, 0.351 …]
[0.531, 0.276 …]
[0.713, 0.453 …]
[0.124, 0.321 …]
With context
prompt
Embedding
model
No context prompt
“How do I sell MongoDB and
Kafka to my accounts based
on their current and upcoming
priorities?”
Giant “brain” of general
knowledge
“Consider pitching that MongoDB
Atlas and Confluent Cloud work
great together for any of their
real-time app needs …”
RAG
“How do I sell MongoDB and
Kafka based on their current and
upcoming priorities? Take into
account their Atlas usage, these
call transcripts, etc.”
[0.424, 0.365 …]
Vector search retrieves
contextual data fast
10. What are Vectors
Vectors
(or vector embedding or just embeddings)
A vector is a list of numbers in an
N-dimensional space that represents the
“semantic” (or underlying) meaning of
something - text, image, video, etc.
How are they created?
For each data record (often just a chunk of
text), an embedding model generates a
vector to represent the data record
11. Prototype Enterprise-Ready
Flexibility to iterate with speed
Foundational modern app requirements:
Highly reliable, scalable, secure, multi-cloud
Teams building Gen AI powered apps need…
To go from innovative Gen AI idea to production
application
Minimal time, cost, and complexity when
augmenting LLMs with proprietary data
12. Multi-Cloud Scale, Resilience, Performance, & Security
A well trained LLM refined
with multimodal data
Developer data
platform
+ = An incredibly sophisticated
AI powered app
1 Developer data platform
1 3
Document Model & Unified API
Multi-Cloud Scale, Resilience, Performance, & Security
with Atlas Vector Search
Unifying operational and Gen AI data services
15. Application
User Profiles,
E-commerce
Inventory
Vector Indexes
Collections Atlas Vector Search
Atlas
Triggers
Embedding
Model
Large
Language
Model
( 1 ) User
Query
( 2 ) Make
embedding
from query
( 3 ) Look up related
facts from Atlas
Vector Search
( 4 ) Create
final
response
MongoDB Kafka
Connector
Internal Data Systems
Customer
360 View
Asynchronously
update views with
real-time data
18. Vectors in a Document
_id: ObjectId('62f13a3fe7321ca47aecb216')
symbol: "ABMD"
quarter: 4
year: 2021
date: 2021-04-29T20:10:40.000+00:00
content: "Operator: Ladies and gentlemen, thank you for standing by, and welcome..."
content_embeddings: Array
0.03898080065846443
-0.05879044905304909
0.04323238879442215
-0.021337900310754776
-0.036346953362226486
0.028689613565802574
-0.03514527902007103
-0.07414846867322922
-0.00993054173886776
0.007234036456793547
-0.03197460621595383
embeddings are stored as an
array of floats
20. [{
"$vectorsearch": {
"queryVector": [ 0.03898080065846443, ... ],
"path": "content_embedding",
"limit": 5
"filter": {
// traditional point & range queries
},
}
}
}]
MongoDB Vector Search
Query
21. query = "Houses in new Jersey with a front yard which are less than 500k"
results = collection.aggregate([{
'$vectorSearch': {
"index": semantic_index_description,
"queryVector": generate_embedding(query),
"path": content_embedding,
"limit": 5
}}}])
Semantic Search Example
23. HNSW
Hierarchical Navigable Small World graphs -
Yury Malkov et al (2016)
● Atlas Vector Search is powered by a graph based
algorithm called HNSW
● These queries are called ANN
(Approximate K nearest neighbors)
● This provides low-latency search and
high-recall results
● Atlas Vector Search keeps updating this graph async
as your underlying data changes
27. Connecting Text and Images
- Using models like
OpenAI CLIP you can obtain embeddings
that can work across text and images
- With Atlas Vector Search you can build powerful
applications like “Find similar images” easily
- CLIP stands for Contrastive Language-Image Pre-training
28. query = "Houses with swimming pool"
results = collection.aggregate([{
'$vectorSearch': {
"index": CLIP_image_index,
"queryVector": generate_embedding(query),
"limit": 3,
"path": clip_embedding
}}}])
Text to Image Search Example