Memgraph logo
Back to blog
Using LLMs and Graph Database to Boost Community Engagement

Using LLMs and Graph Database to Boost Community Engagement

April 4, 2024
Sara Tilly

In a recent Memgraph community call, Steeve Bete from Orbit shared insights on using Large Language Models (LLMs) and graph databases to model and grow community networks.

In case you missed the session, check out the full LLMs, Memgraph and Orbit: Modeling Community Networks recording.

Talking point 1: Building Secure Multi-Tenant API

Steeve revisited the topic of our previous Memgraph community call, the multi-tenant GraphQL API on top of Memgraph. He emphasized the importance of security and scalability in managing community data. If you missed it, you can watch that community call recording in full here—Building a secure multi-tenant GraphQL API on top of Memgraph.

Talking point 2: Empowering Communities with LLMs

The core of Steeve's presentation was the innovative use of LLMs, particularly GPT-3.5 and GPT-4, in processing and analyzing community interactions. By feeding community conversation data into these models, Steeve demonstrated how to extract meaningful insights, such as sentiment analysis, trending topics, and member engagement levels.

Talking point 3: Graph Database in Modeling Community Networks

Through practical examples, Steeve showcased how the Memgraph graph database capabilities allow for the effective modeling of community networks. By representing members and their interactions as nodes and edges, respectively, he illustrated how one can perform complex queries to uncover patterns and relationships within the community.

Talking point 4: Workflow Optimization with LLMs and Graph Databases

We talked about optimizing workflows when using LLMs in conjunction with graph databases. Then Steeve shared insights into managing performance and cost, particularly when handling large datasets or requiring real-time data analysis. For example, we covered the use of efficient querying techniques in Memgraph and selecting the appropriate LLM model based on task complexity and resource availability.


To further provide value, here is a summary of some of the questions asked during the webinar's Q&A session, along with answers derived from the discussion:

  1. How do you ensure data privacy when analyzing community interactions?
  • Steeve: We prioritize member privacy by anonymizing data before any analysis. Our systems, designed around Memgraph and LLMs, adhere strictly to data protection laws like GDPR. We're committed to extracting value from data without compromising on privacy.
  1. Can you share the challenges and solutions in integrating LLMs with Memgraph?
  • Steeve: Dealing with the performance and cost as our data grew was challenging. Optimizing our graph schema within Memgraph helped us immensely, as did choosing the right LLM model for the task. Balancing between GPT-4's depth and GPT-3.5's cost efficiency was key.
  1. How scalable is your solution with growing community data?
  • Steeve: Our solution's scalability is built into its core. Both the Memgraph graph database and our chosen LLMs scale effectively, allowing us to handle increased data volumes without a hitch. Our system architecture supports horizontal scaling to accommodate community growth.
  1. How much time and effort did it take to fine-tune your ChatGPT prompts for accurate outputs?
  • Steeve: Getting the ChatGPT prompts right was both time-consuming and challenging. It involved a lot of trial and error, tweaking prompts, and iterating on responses. However, once we dialed in the correct prompts, the consistency and quality of the outputs made it all worthwhile. Patience and persistence were our best tools in this process.


This was another great Memgraph community session hosted by Katarina from the Memgraph DX team and Steeve Bete from Orbit. We talked about the integration of Large Language Models (LLMs) with graph databases, community network analysis and engagement. This session not only provided a roadmap for using these technologies in the future but also showcased their practical application in real-world scenarios.

Now, to get the full details on how to combine LLMs with graph databases for enhancing community engagement and analysis, watch the full webinar recording.

Related Links

To follow along with the webinar video recording, here are the links relevant to Steeve’s demo:

Links to OpenAI Playgroud

Join us on Discord!
Find other developers performing graph analytics in real time with Memgraph.
© 2024 Memgraph Ltd. All rights reserved.