Exploring the GitLab Knowledge Graph

Every month I enjoyed reading the GitLab Release. In the last one (18.4), a new tool, under active development, appeared in the GitLab ecosystem : GitLab Knowledge Graph (gkg). GKG gives you a graphic representation of your code.

πŸš€ Let’s go discover together this (very interesting and promising) tool.

πŸ§‘β€πŸ”¬ GKG Install

πŸ‘‰ First step, install it. In my case, having a MacBookPro, it was very quick:

curl -fsSL https://gitlab.com/gitlab-org/rust/knowledge-graph/-/raw/main/install.sh | bash

Next, I added an alias on my .zshrc file and I can use it with the gkg command.

πŸ“š https://gitlab-org.gitlab.io/rust/knowledge-graph/#get-started-in-minutes

My β€œcrash test”project was my communities-api (https://gitlab.com/communities-api/communities-api).

πŸ‘‰ The gkg index command launches a scan of your project. This action was quick for this project.

GKG index

πŸ‘‰ Final step, run the server with the gkg server start command. GDK becomes available on http://127.0.0.1:27495.

Note, you can index or re-index a project directly in the GKG UI:

GKG index UI

I didn’t test the IDEA integration yet.

πŸͺ‚ GKG in action

GKG displays the graphic in a simplify interface:

GKG index UI

On the generated graph, we can see different types of elements like all directories and files.

GDG Exploring

Dependencies are also displayed. In this Java project, we can see Java class imported in each class:

Dependencies

The last type is β€œdefinition” and we can see Java class, Java methods, Javascript constants which appear as definitions.

And the last feature is the possibility to search items.

Search

πŸ’‘ Feedbacks

This new GitLab tool is under development but this first version is very interesting. This type of tool solves a common problem in many teams/enterprises and I am sure that it will be adopted by a lot of teams to understand projects and have a quick look on complex projects dependencies.

πŸ‘€ Check out the blog post about this release: https://about.gitlab.com/releases/2025/09/18/gitlab-18-4-released/ πŸ‘€ Check out the GitLab project: https://gitlab.com/gitlab-org/rust/knowledge-graph/-/issues πŸ“ Give your feedback on this issue: https://gitlab.com/gitlab-org/rust/knowledge-graph/-/issues/160