NG
2026
Project Fleming - AI Code Discovery for Shell

Project Fleming - AI Code Discovery for Shell

Semantic SearchBERTHugging FaceDatabricksMLflowPythonReactTypeScriptNestJSAzureOpen Source

An InnerSource discovery platform built for Shell that finds internal code repositories by the meaning of a search, not its exact words. I was one of the lead developers, working with Shell through Impactility as a full-stack and AI engineer from 2023 to 2026. To keep it affordable at enterprise scale, the BERT-based semantic search runs on small CPU clusters on Databricks with MLflow instead of GPUs. The core engine was later released as open source as Project Fleming.

Overview

Shell has a large number of internal code repositories. Engineers who needed a tool or library often could not tell whether someone had already built it, because keyword search only finds a repository when the query uses the same words as its README.

We built an InnerSource discovery platform that matches repositories to the meaning of a query. A search like "forecast wind turbine output" can find a repository described as "power prediction for offshore assets", even though the two share almost no words.

The platform's core engine was later released as open source as Project Fleming.

  • Client: Shell, through Impactility
  • Role: one of the lead developers (full-stack and AI engineer)
  • When: 2023 to 2026

The Problem with Keyword Search

Keyword search ranks a wind-tunnel rig and a turbine CAD library first because they share words with the query, and misses the right repository; search by meaning places the query next to power prediction and wind farm yield repositories

Keyword search breaks down on a large internal codebase for a few reasons:

  • Different teams use different words for the same thing, so the right repository often never shows up.
  • READMEs are uneven. Some are detailed, some are one line, and some are missing.
  • People rebuild what already exists, which wastes time and leaves several half-maintained copies of the same idea.

The goal of InnerSource is to reuse code across teams the way open source projects reuse each other's work. That only happens if people can find the code first.

How It Works

The platform works in two parts: an indexing pipeline that runs ahead of time, and a search endpoint that answers queries.

Building the index

Indexing pipeline: GitHub repositories are collected and capped at 100k tokens, summarised by GPT-4o mini, joined into a corpus, embedded with a BERT-family model, registered in MLflow and served on a small Databricks CPU endpoint

  1. Collect code. The pipeline reads the repositories of a GitHub organisation through a GitHub App key and joins each repository's files into one text, capped at 100,000 tokens so it fits the summariser's limit.
  2. Summarise. GPT-4o mini writes a plain-English summary of each repository, which helps when a README is short or missing.
  3. Build the corpus. The text for each repository is joined into one entry in a search corpus.
  4. Embed. A BERT-family sentence-transformer from Hugging Face turns each entry into a vector that captures its meaning. The open-source example uses multi-qa-mpnet-base-dot-v1.
  5. Register and serve. The model, the corpus and the vectors are versioned together in MLflow, then served as a Databricks model endpoint on a small CPU cluster.

Answering a search

Search flow: the web app sends the query to a Next.js server route that adds the secret token, the Databricks CPU endpoint embeds the query, compares it with the stored repository vectors and keeps the top 50 matches scoring at least 0.45, and ranked repositories go back to the browser

The web app sends the query to its own server route, which adds the endpoint's secret token so the browser never sees it. The endpoint embeds the query with the same model, compares it with every stored repository vector, and returns the closest matches above a relevance threshold.

Because the engine only needs text, it is model-agnostic: a team can swap in a different Hugging Face model without changing the rest of the pipeline.

Running on CPU Instead of GPU

Transformer models are usually served on GPUs, which are expensive to keep running for an internal tool used throughout the working day.

I built and deployed the semantic search pipelines to run on small CPU clusters on Databricks. A sentence-transformer only has to encode one short query per search, and the repository vectors are computed ahead of time, so CPU latency stays acceptable for interactive search. This kept the cost low enough to run the platform at enterprise scale.

Working within these limits taught me how to deploy transformer models efficiently: keep the model small, do the heavy encoding offline, and size the serving hardware to the real query load. I now apply the same approach to running compact AI models alongside a live game engine.

My Role

  • Built and deployed the BERT-based semantic search pipelines on Databricks CPU clusters, with MLflow for model registration and serving
  • Owned the InnerSource web app (React, TypeScript, NestJS), including role-based access control and the backend that parses repositories for the ML pipeline
  • Handled DevOps, CI/CD, SSL and deployment on Azure
  • Contributed to the front-end of Project Fleming, the open-source release of the discovery tool

Open Source Release

Shell released the core engine on GitHub as Project Fleming, under the Apache 2.0 licence. It packages the full path from data to search:

  • Creating the corpus and tokenising Git repositories
  • Creating, registering and serving the model on Databricks
  • Calling the search endpoint
  • Generating code summaries with a GPT model
  • A deployable web front-end

Links:

Technologies

  • AI and search: BERT-family sentence-transformers (Hugging Face), semantic search, GPT code summaries
  • ML platform: Databricks (CPU model serving), MLflow, PySpark
  • Web app: React, TypeScript, NestJS, role-based access control
  • Infrastructure: Azure, CI/CD
Always open to connect

Want to connect or collaborate?.