AI

·

Integration

Content yes, names no. Helpdesk e-mail triage with SAP Generative AI Hub

Patrik Majer

Recently I was looking at a very common support problem: a shared helpdesk inbox with dozens of new e-mails every morning. Before anyone can help, someone has to read each e-mail and decide what it is, how urgent it is and which system it is about. That's a perfect job for an LLM.

The catch: every one of those e-mails contains personal data. Names, e-mail addresses, phone numbers. Sending them to an external model as they are is not something a data protection officer will sign off.

My first idea was a small app that calls the model provider's API directly. In this post I will show why that is a dead end, and how to do it properly with the orchestration service in SAP AI Core and Generative AI Hub, where personal data is masked before the model ever sees it.

I will not go into detail on how to provision SAP AI Core and SAP AI Launchpad. You can refer to this SAP tutorial to do so.

1. Why calling the model directly is a dead end

There are two traps.

  • Trap 1: every app holds a provider key. Each application that calls OpenAI, Anthropic or Google directly needs its own API key, its own contract and its own security review. There is no central place to see who calls which model, and when the model is deprecated, every app has to change.

  • Trap 2: personal data goes to the model as-is. The e-mail text is the prompt. Unless you build your own detection and masking of names, e-mail addresses and phone numbers, and then put the values back into the answer, all of it leaves the company with every call.

So with a direct call you get a working classifier, but not one you can run on real helpdesk data.

2. The solution: Orchestration in Generative AI Hub

Generative AI Hub in SAP AI Core gives you one BTP-authenticated endpoint to models from several providers. The orchestration service wraps the model call in a pipeline of modules that you configure, not code:

Orchestration

The key point is Data Masking. It runs inside SAP AI Core, before the model call. In pseudonymize mode the original values are put back into the response afterwards, so the model works with placeholders and the user still gets a reply with real names.

The idea is:

  • the app knows only the AI Core service key, no provider keys

  • the prompt lives in Generative AI Hub as a versioned template

  • personal data is masked before the model call and restored after it

  • input and output filters block inappropriate content in both directions

3. SAP AI Core and AI Launchpad setup

Step 3a: Entitlements

In the BTP cockpit, add these service plans to your subaccount:

  • SAP AI Core, plan extended

  • SAP AI Launchpad, plan standard

Note: Generative AI Hub is only available on the extended plan of SAP AI Core. With free or standard you will not see any foundation models.

Step 3b: Connection and resource group

Create an SAP AI Core instance and a service key, then subscribe to AI Launchpad. In AI Launchpad go to Workspaces → Add and create a connection with the values from the service key. Select the default resource group.

Note: the orchestration deployment is created automatically only in the default resource group. If you create your own resource group, you have to create a configuration with scenario orchestration and executable orchestration and deploy it yourself.

4. Orchestration configuration

In AI Launchpad go to Generative AI Hub → Orchestration and create a new configuration, for example helpdesk-triage.

Prompt Template

The prompt asks for a strict JSON output. The e-mail is a variable:

You are a helpdesk triage assistant for an SAP support team.
Read the e-mail and return JSON with:
- category: incident | question | access_request | complaint | other
- priority: low | medium | high
- system: e.g. SAP FI, SAP MM, BTP app, unknown
- references: invoice numbers, order numbers, user IDs found in the text
- summary: one sentence
- suggested_reply: a short, polite first reply in the e-mail's language

E-mail:
{{?email_body}}
You are a helpdesk triage assistant for an SAP support team.
Read the e-mail and return JSON with:
- category: incident | question | access_request | complaint | other
- priority: low | medium | high
- system: e.g. SAP FI, SAP MM, BTP app, unknown
- references: invoice numbers, order numbers, user IDs found in the text
- summary: one sentence
- suggested_reply: a short, polite first reply in the e-mail's language

E-mail:
{{?email_body}}
You are a helpdesk triage assistant for an SAP support team.
Read the e-mail and return JSON with:
- category: incident | question | access_request | complaint | other
- priority: low | medium | high
- system: e.g. SAP FI, SAP MM, BTP app, unknown
- references: invoice numbers, order numbers, user IDs found in the text
- summary: one sentence
- suggested_reply: a short, polite first reply in the e-mail's language

E-mail:
{{?email_body}}

Variables use two curly brackets and a question mark: {{?email_body}}. Launchpad picks the variable up automatically under Variable Definitions, where you can also set a default value for testing.

Title: Prompt Template module with the helpdesk triage prompt and the email_body variable - Description: Prompt Template module with the helpdesk triage prompt and the email_body variable

Model Configuration

Select the model and its parameters. For classification and extraction a small model is usually enough, and temperature 0 keeps the output stable. You can browse all available models in Model Library.

Title: Model Library in SAP AI Launchpad with models from Anthropic, OpenAI and Google - Description: Model Library in SAP AI Launchpad with models from Anthropic, OpenAI and Google

Data Masking

Switch Advanced on to see the optional modules, then activate Data Masking:

  • Mode: Pseudonymize

  • Masked Data Types: Person Names, Email Addresses, Phone Numbers

Title: Data Masking module in pseudonymize mode with person names, e-mail addresses and phone numbers selected - Description: Data Masking module in pseudonymize mode with person names, e-mail addresses and phone numbers selected

Note: Anonymize replaces the values permanently. The model's reply would then start with "Hi MASKED_PERSON_1". For a suggested reply you need Pseudonymize.

Note: I deliberately do not mask Organizations. The company name helps with routing, and it is not personal data. Values that must never be masked, such as your own product names, go to the Allow List.

Input and Output Filtering

Activate both and keep the default thresholds for hate, violence, self-harm and sexual content. Helpdesk inboxes get some colourful e-mails, and you don't want them passed to the model or a generated reply in the same tone.

Save the configuration. The prompt is stored in Prompt Management, versioned and grouped by scenario, so the app refers to it by name and a prompt change doesn't need a redeployment.

Title: Prompt Management with versioned templates for helpdesk and AP inbox scenarios - Description: Prompt Management with versioned templates for helpdesk and AP inbox scenarios

Calling it from the app

With the SAP Cloud SDK for AI, the call from a Node.js or CAP app is short. The SDK handles authentication against AI Core:

import { OrchestrationClient } from '@sap-ai-sdk/orchestration';

const client = new OrchestrationClient({
  promptTemplating: {
    model: { name: 'gpt-4o-mini' },
    prompt: { template: [{ role: 'user', content: TRIAGE_PROMPT }] }
  }
});

const response = await client.chatCompletion({
  placeholderValues: { email_body: mail.text }
});
const ticket = JSON.parse(response.getContent());
import { OrchestrationClient } from '@sap-ai-sdk/orchestration';

const client = new OrchestrationClient({
  promptTemplating: {
    model: { name: 'gpt-4o-mini' },
    prompt: { template: [{ role: 'user', content: TRIAGE_PROMPT }] }
  }
});

const response = await client.chatCompletion({
  placeholderValues: { email_body: mail.text }
});
const ticket = JSON.parse(response.getContent());
import { OrchestrationClient } from '@sap-ai-sdk/orchestration';

const client = new OrchestrationClient({
  promptTemplating: {
    model: { name: 'gpt-4o-mini' },
    prompt: { template: [{ role: 'user', content: TRIAGE_PROMPT }] }
  }
});

const response = await client.chatCompletion({
  placeholderValues: { email_body: mail.text }
});
const ticket = JSON.parse(response.getContent());

The SDK can also reference a configuration saved in Generative AI Hub instead of defining it inline. That way masking and filtering stay in one place and are not duplicated in code.

5. Testing

Run the configuration in Launchpad with a typical helpdesk e-mail:

Hi, this is Jana Nováková from ACME (jana.novakova@acme-example.com, +420 601 123 456). Since this morning I can't post invoice 2026-10045 in FB60 – it says the period is closed. Could you help urgently? We have a payment run tomorrow.

This is what the model actually receives:

Hi, this is MASKED_PERSON_1 from ACME (MASKED_EMAIL_1, MASKED_PHONE_NUMBER_1). Since this morning I can't post invoice 2026-10045 in FB60 – it says the period is closed. …

And this is what comes back to the app:

{
  "category": "incident",
  "priority": "high",
  "system": "SAP FI",
  "references": ["2026-10045", "FB60"],
  "summary": "User cannot post an invoice in FB60 because the posting period is closed; payment run is tomorrow.",
  "suggested_reply": "Hi Jana, thank you for letting us know. We're checking the posting period settings and will get back to you today, before your payment run."
}
{
  "category": "incident",
  "priority": "high",
  "system": "SAP FI",
  "references": ["2026-10045", "FB60"],
  "summary": "User cannot post an invoice in FB60 because the posting period is closed; payment run is tomorrow.",
  "suggested_reply": "Hi Jana, thank you for letting us know. We're checking the posting period settings and will get back to you today, before your payment run."
}
{
  "category": "incident",
  "priority": "high",
  "system": "SAP FI",
  "references": ["2026-10045", "FB60"],
  "summary": "User cannot post an invoice in FB60 because the posting period is closed; payment run is tomorrow.",
  "suggested_reply": "Hi Jana, thank you for letting us know. We're checking the posting period settings and will get back to you today, before your payment run."
}

The model never saw the name, yet the reply says "Hi Jana". Orchestration put it back.

Negative tests

These show that the protection works, and help to understand the principle.

Anonymize instead of Pseudonymize. Switch the mode and run again. The reply now contains the placeholder instead of the name, because anonymized values are not restored.

Offensive e-mail. Send an e-mail with abusive language. The input filter stops it, and the model is never called.

From here it is just a matter of where the ticket goes: a ticketing tool, an SAP workflow, a Teams channel, or a draft reply in the mailbox.

Two more things I recommend:

  • Don't put real data into the template. Default values in Variable Definitions are stored with the configuration. Use made-up test e-mails only.

  • Keep a human in the loop. The suggested reply is a draft. Somebody from the team approves it before it is sent.

Summary

With orchestration in Generative AI Hub, the helpdesk e-mail is masked inside SAP AI Core before the model call, and the real values are restored in the response. The app holds only the AI Core service key, the prompt is a versioned template, and switching to another model is a configuration change.

With a direct call to a model provider, every app needs its own key, and personal data goes to the model as it is, unless you build masking yourself.

The same configuration works beyond the helpdesk: supplier e-mails to Accounts Payable, order confirmations or approval requests. Only the prompt template changes.

To sum up the best practice: if an LLM needs to read e-mails with personal data, call it through orchestration in Generative AI Hub with Data Masking in Pseudonymize mode. Keep direct provider calls for prototypes on made-up data.

Screenshots from the SAP AI Launchpad documentation © SAP SE, used under the CC BY 4.0 license.

SMARTER TECH, SMARTER BUSINESS

Cloud, AI and mates. Integration, development, automation and AI on SAP Business Technology Platform and Microsoft.

Write to us →

RESOURCES

© 2026 CLAIMATE · CLOUD · AI · MATES

SAP PartnerEdge · Microsoft Partner

SMARTER TECH, SMARTER BUSINESS

Cloud, AI and mates. Integration, development, automation and AI on SAP Business Technology Platform and Microsoft.

Write to us →

RESOURCES

© 2026 CLAIMATE · CLOUD · AI · MATES

SAP PartnerEdge · Microsoft Partner

SMARTER TECH, SMARTER BUSINESS

Cloud, AI and mates. Integration, development, automation and AI on SAP Business Technology Platform and Microsoft.

Write to us →

© 2026 CLAIMATE · CLOUD · AI · MATES

SAP PartnerEdge · Microsoft Partner

AI

Content yes, names no. Helpdesk e-mail triage with SAP Generative AI Hub