• UX for AI
  • Posts
  • Escape from the Figma Titanic – Part 3:Magic RAG Registry

Escape from the Figma Titanic – Part 3:Magic RAG Registry

In Part 2, I showed you how to build your first Magic RAG files—structured documents that let you feed precise, just-in-time UX content to your AI Agents and LLM-driven applications. In this installment, we take your Magic RAG from amateur to professional by introducing a concept of a simple registry. It's like programming, but with words. It's fun, accessible, and UX/PM-friendly.

In partnership with

Cooking with the Magic RAG Registry

In Part 2, I showed you how to build your first Magic RAG files—structured documents that let you feed precise, just-in-time UX content to your AI agents and LLM-driven applications.

But like any decent kitchen, it’s not enough to just have ingredients.

You need an organized pantry.

Instead of trying to figure from scratch what salt, pepper, or coconut milk is and how it’s used every time you load a recipe, you can create a system — or a registry, where you specify common amounts, techniques, uses, errors, etc.

The registry helps your AI find the right substitution when the customer says,

“Make it gluten-free.”
“I’m allergic to shellfish.”
“We don’t use Figma anymore.”

Welcome to the RAG Registry—your UX “mise en place” for generative AI! In this short article, I’ll show you how to make a simple substitution RAG Registry, step-by-step and in plain text.

But first, be sure to visit our sponsor:

Find out why 1M+ professionals read Superhuman AI daily.

In 2 years you will be working for AI

Or an AI will be working for you

Here's how you can future-proof yourself:

  1. Join the Superhuman AI newsletter – read by 1M+ people at top companies

  2. Master AI tools, tutorials, and news in just 3 minutes a day

  3. Become 10X more productive using AI

Join 1,000,000+ pros at companies like Google, Meta, and Amazon that are using AI to get ahead.

Real-World Use Case: Cooking Thai Food for a Gluten-Free Gourmand

Let’s say we’re extending the Life Copilot we created in Part 2 to help users adapt Thai meals to gluten-free diets. (This use case is near to my heart, because I love Thai food, and yet I am sensitive to gluten — I have been living gluten-free for the last decade.)

Spoiler alert: Traditional soy sauce has wheat. Oops.
Good news: Tamari doesn’t. But if you don’t tell the AI that, you’ll end up with a Gluten Pad Thai… Which is basically UX malpractice!

What Is a RAG Registry?

The RAG Registry is a shared lookup for reusable patterns. It’s where your AI finds:

  • Common substitutions (ingredient swaps, UI patterns, model responses)

  • Canonical phrasing (voice, tone, accessibility rules, amount of content, and structure)

  • Metadata that makes it retrievable by need, not just by filename

It’s NOT a database. It’s NOT a spreadsheet. It’s NOT a coconut shrimp vector soup.

It’s a plain old text file your LLM can actually read and use.
Just like yaai’s (grandmother’s) recipe cards—but for UX.

RAG_REGISTRY: Thai Gluten-Free Substitutions (text format)

Here’s a real registry file we used in a working copilot. This one’s for adapting Thai food to a gluten-free diet, using insights from https://gluten.org/2021/08/15/exploring-thai-cuisine-on-a-gluten-free-diet/.

If you already have a document that contains the substitution data you want to use, it’s quite easy to create the Registry. Here we will use the prompt that you might recognize from Part 2 — it is very similar to what we used to create an individual RAG file:

Create a RAG Registry file from https://gluten.org/2021/08/15/exploring-thai-cuisine-on-a-gluten-free-diet/ Construct it in such a way as to modify the recipie in the attached RAG file so that it is appropriate for Gluten-Free consumers. Make this new RAG Registry in text format, not JSON. Include any specific ingradient substitutions.

NOTE: When executing this prompt, it helps to attach the RAG recipe sample we created in Part 2 — that will ensure that the LLM will automatically line up various registry headers with your existing RAG file database.

You should get a registry that looks something like this:

# RAG_REGISTRY
id: thai_gf_substitutions_v1
title: Thai Cuisine Gluten-Free Ingredient Substitution Registry
description: Common substitutions to adapt Thai recipes for gluten-free diets.
source: https://gluten.org/2021/08/15/exploring-thai-cuisine-on-a-gluten-free-diet/

---

id: soy_sauce_sub
category: condiment
tags: gluten-free, substitution
summary: Soy sauce typically contains wheat.
recommendation: Use Tamari instead. Check label to confirm it is gluten-free.
note: Not all Tamari brands are gluten-free—look for certified.

---

id: oyster_sauce_sub
category: condiment
tags: gluten-free, substitution
summary: Oyster sauce may contain wheat as a thickener.
recommendation: Use gluten-free labeled oyster sauce or substitute with mushroom stir-fry sauce.

---

id: rice_noodles_check
category: staple
tags: gluten-free, cross-contamination
summary: Rice noodles are often gluten-free, but check packaging.
recommendation: Avoid bulk bins. Look for certified brands.

---

id: fish_sauce_safe
category: condiment
tags: gluten-free, safe
summary: Fish sauce is generally gluten-free.
recommendation: Still check the label—some may contain caramel coloring derived from wheat.

---

id: sweet_chili_sauce_sub
category: condiment
tags: gluten-free, substitution
summary: Commercial sweet chili sauces may contain wheat-based thickeners.
recommendation: Make your own with chili, sugar, vinegar, and cornstarch—or buy certified GF version.

How to use your new RAG Registry

In order to use your new registry in a most repeatable and non-hallucinatory fashion, you need to make sure each of your RAG files references the registry correctly. This is actually very easy to do:

Assuming you named the file RAG_REGISTRY.txt, all you need to do to ensure that the LLM finds it is to reference it on top of the RAG file like so (updating the RAG file we created Part 2):

REGISTRY: RAG_REGISTRY.txt

# RAG DOCUMENT
id: tom-yum-goong-creamy
title: Creamy Tom Yum Goong (ต้มยำกุ้งน้ำข้น)
description: A creamier, richer version of the classic Thai Tom Yum soup, featuring shrimp, mushrooms, and aromatic herbs in a velvety broth.
tags: Thai, soup, spicy, creamy, seafood

## INGREDIENTS
- 5 cups water
etc.

That’s it! Simple, right?

Now give it a whirl — attach your new registry file, the updated tom-yum-goong-creamy.txt RAG file, and simply ask to see a gluten-free version of the recipe.

Your prompt should look something like this:

Give me a gluten-free Thai soup recipie

Attachments: [RAG_REGISTRY.txt] [tom-yum-goong-creamy.txt]

Now, the output of your prompt should be magically mapped to the gluten-free version.

Did it work?

What’s Next

If you are thinking of this as “programming,” that’s exactly what this is! Only it’s done in plain text — considerably simpler, more forgiving, and much more UX/PM friendly.

Magic RAG isn’t just a “method.”

  • It’s a way of thinking.

  • It’s the language of “UX Data.”

  • It’s the gateway drug to achieving the next level of relevancy and value.

  • It’s the way to get off the Figma Titanic in style — on a Magic Carpet (RAG) Ride!

And we’re just getting started!

In Part 4, we’ll show you how to expand the registry to include solutions to common errors, parameters, variations, change voice and output format, and much more.

Want the full #UXforAI blueprint now? Check out our new book:

📘 #1 New Release in Data Modeling and Design on Amazon: https://amzn.to/4l2ShyL 

This book is your hands-on companion to becoming “Indispensable in 2025”:

💥 Built on 35+ real-world AI case studies — what worked, what failed, and why

🛠️ A full set of battle-tested UX tools with step-by-step exercises and practical examples

🚀 The exact frameworks UX leaders are using today to shape UX for LLMs, copilots, and AI Agents

💡 Learn how to lead cross-functional teams to pick the right use cases, shape the model, define the data, and deliver actual impact.

This book is designed for people who are ready to lead.

Not theory.

Not fluff.

Just the tools and thinking you need to become indispensable in 2025 and beyond.

📦 #1 New Release in Data Modeling and Design on Amazon: https://amzn.to/4l2ShyL 

Peace,
Greg

P.S. Did you get the book? Found it useful? Then, I would be most grateful if you could leave me an Amazon review: https://amzn.to/4l2ShyL 

Thank you!

Reply

or to participate.