Date:
13 October 2025
 
Kurt is Salsa’s Chief Technology Officer.

The AI problem space

When AI fails, it’s not always the model’s fault. More often, the problem lies in the context we feed it.

Large language models (LLMs) like Claude or GPT-4 are astonishingly capable. However, they’re also easily confused, distracted or misled. If the context provided to the LLM is unclear or unstructured, this can directly lead to poor outcomes. A recent Microsoft and Salesforce paperExternal Link found “... experiments confirm that all the top open- and closed-weight LLMs we test exhibit significantly lower performance in multi-turn conversations than single-turn”.

Empowering users to have better control over how they prompt is key to driving quality outcomes from AI.

Enter context engineering

Context engineering gives structure and intent to what the model sees. See our insight What is context engineering? Building the memory behind AI, for an introduction to the concept. Context is everything an AI “sees” before it generates a response:

  • The prompt you typed
  • The conversation so far
  • Relevant documents
  • The tools it uses
  • Invisible system instructions

LLMs are often described as having a “context window” — the maximum number of tokens they can read before producing an answer. But a bigger window does not guarantee better results.

Drupal’s AI Context Module

DrupalExternal Link ’s new AI Context ModuleExternal Link begins the journey of making context engineering tangible and operational within Drupal. It brings structure and orchestration into Drupal AI agents. In doing so, it ensures Drupal continues to lead AI integration in content platforms by natively supporting agentic, context-aware AI.

Drupal has always been about structured content — now it’s about structured context

Content management systems (CMSs) are ground zero for sharing enterprise knowledge with the public. In government and regulated sectors, CMSs don’t just hold the brand messaging, they hold legal, regulatory and compliance content that can directly affect the lives of the public.

When AI is connected to that environment, it inherits all of its complexity.

This is more than a quality issue. In government settings, it becomes a trust issue. If your generative AI tool suggests the wrong eligibility rules, contradicts official advice, or misrepresents an inclusion standard, you haven’t just failed, you may have exposed the organisation to significant risk or endangered citizens.

From theory to tooling: the AI Context Module

The AI Context ModuleExternal Link is a new Drupal module that aims to start operationalising context engineering principles inside the CMS. It lets site builders and content teams take direct control over the system-wide context that’s injected into an LLM’s prompt.

Key features include:

  • Context entities: Context entities allow site builders to define and add context based on their sites unique needs.
  • Middleware injection: Define how each context bundle is injected into the AI prompt.
  • Structured prompt assembly: Supports structured, multi-section prompts, not just raw text injection.

Think of it as a control panel for AI memory inside Drupal.

What it looks like in practice

Your brand style guide, brand voice, vision, mission and strategic objectives can all be entered as context entities into the module. You can then use the AI context pool to associate these context entities with specific agents to use across your site. For example, you might set your brand voice to be always used for your content editor agent, and your strategic objectives to be used when relevant.

You can then interact with the content editor agent, requesting a new landing page on the company's strategic goals for the year. The agent will use the content from your brand voice context, and the dynamic agent will pull in the content from your strategy content, based on your request to create the page.

Want to update your brand voice, or you’ve just updated your strategy? Just edit the context entities and go back to ask your content editor agent to update your landing pages for you.

Two real demo videos show this in action:

This isn’t prompt engineering. It’s context engineering applied directly inside the CMS.

Why this matters strategically

The AI Context ModuleExternal Link moves memory and orchestration into Drupal’s core territory: structured content. And without needing developers in the loop.

That shift has major implications:

  • Empowers site builders and authors: AI context can now be managed by the same people who manage taxonomies, menus and layout — without writing code.
  • Enables automation: Future iterations of Drupal AI and AI Context will allow for automated updates across your site based on updates to context. Change your company’s byline, no problem, update your brand guideline context and let the AI update your site.
  • De-risks AI usage: Structured context reduces hallucination, improves traceability and supports greater explainability.

When used in concert with structured content and Drupal’s Model Context ProtocolExternal Link , this module will become part of a larger ecosystem for safe, orchestrated, multi-agent AI systems.

Context engineering, now in Drupal

The Drupal community has always led on structured content, modular systems and open-source transparency. With the AI Context ModuleExternal Link , it now leads on structured context too.

If you’re working on AI inside government, higher education, public health or regulated industries, then content matters. It gives you a way to align AI output with institutional intent, without depending solely on AI engineers or vendors.

The module is open source, and available now.

Try the module on Drupal.orgExternal Link

Watch the demosExternal Link