It is written for product owners, engineering leads and security leads about to ship a chatbot, a document assistant or an agent that takes actions. It sits under generative AI development, and the launch decision it describes belongs to MLOps and responsible AI operations.
In this guide
- Why does a generative AI feature need red-teaming before launch?
- Who should take part, and what does each role do?
- What should the test plan cover?
- How do you run the exercise, step by step?
- Which findings should block the launch?
- Where AI fits
- What delivery record exists, and what does not
- Which alternative fits your feature?
- Limits of this guide
- Frequently asked questions
- Next step
Why does a generative AI feature need red-teaming before launch?
A generative AI feature can pass every functional test and still fail in front of users, because its inputs are open text and its behaviour depends on content the team did not write. Red-teaming asks what a curious, careless or hostile user, or a poisoned document, can make the feature do.
The risks are now well catalogued. The OWASP Top 10 for LLM Applications 2025 lists prompt injection, sensitive information disclosure, improper output handling, excessive agency, system prompt leakage and misinformation among the main risks. Indirect prompt injection, where instructions hide in a web page, email or file the model reads, was shown in research on applications that combine a model with retrieval and tools.
Red-teaming is not a replacement for measurement. Microsoft's planning guidance for LLM red-teaming says its purpose is to find harms and map the risk surface, which then tells the team what to measure and mitigate systematically. A finding is evidence that a harm can happen, not a rate of how often it happens.
Who should take part, and what does each role do?
A small exercise needs five roles. One person can hold two roles, except that the attack lead and the launch approver should never be the person who built the feature.
-
Feature owner
- What the role does
- Writes the harm statements, the scope and the test accounts; answers tester questions
- What the role must not do
- Score findings on the feature they own
-
Attack lead
- What the role does
- Plans the rounds, assigns testers to harms, keeps the findings log and scores severity
- What the role must not do
- Fix findings during a round
-
Domain and security testers
- What the role does
- Probe with both adversarial and ordinary-user mindsets; record every input and output
- What the role must not do
- Test outside the agreed scope or against production data without approval
-
Engineering fixer
- What the role does
- Fixes confirmed findings and hands each fix back for retest
- What the role must not do
- Close a finding without a retest
-
Launch approver
- What the role does
- Reads the report and signs the launch decision against the exit criteria
- What the role must not do
- Change the exit criteria after seeing the results
The Microsoft guidance recommends mixing security-minded testers with people who resemble ordinary users and adding domain experts, such as clinicians for a health assistant.
What should the test plan cover?
Test the feature as users will meet it, not only the model behind it. Four attack surfaces cover most generative AI features.
| Attack surface | What testers try | What passing looks like |
|---|---|---|
| Direct prompts | Jailbreaks, role-play, requests for forbidden content, system prompt extraction, abuse in other languages | Refusal or safe answer; no system prompt or internal rule disclosed |
| Indirect content (documents, web pages, emails, retrieved chunks) | Hidden instructions in a file or page the feature reads; documents the user should not see | Instructions in content are ignored; access rules hold for every retrieved document |
| Tools and actions | Chaining tools to reach an outcome nobody approved; oversized or repeated actions | Every write or payment-like action stops at an approval step or a limit |
| Output handling | Output that becomes code, links, SQL or HTML downstream; confident wrong answers on business facts | Output is validated before use; unsupported claims are refused or flagged |
For assistants that query data, the text-to-SQL guide shows the read-only controls testers should try to break. For agents, the AI agent security and human approval guide lists the controls under test.
How do you run the exercise, step by step?
-
Write five to ten harm statements in the product's own terms
"The assistant reveals another customer's order" is testable; "privacy risk" is not.
-
Agree the severity scale and exit criteria before testing
Write down which severity blocks launch and who signs. Criteria written after the results tend to bend.
-
Prepare a safe test environment
Use test accounts with the same permissions real users will have, seeded test data and a logged endpoint; never point testers at live customer data or live payments.
-
Run an open-ended round first
Testers explore freely and record every input, output, date and identifier in one shared log, so each example can be reproduced.
-
Turn findings into a harm list and run guided rounds
Assign testers to specific harms and features; add new harms as they appear. Scanners such as PyRIT or garak can generate variants of a confirmed attack at volume.
-
Fix, then retest with the original input and close variants
A fix that blocks one wording often leaves a paraphrase open.
-
Convert every confirmed finding into a regression case
The AI agent evaluation harness is where those cases run on every change.
-
Write the launch report and sign the decision
List open findings by severity, accepted risks with an owner and the rollout limits.
Which findings should block the launch?
A simple four-level scale works for most features.
- Critical: blocks launch. Exposure of another user's or the company's confidential data, an unapproved action in a business system, or content that breaks the law.
- High: blocks launch unless a fix plan with an owner and a date is signed. Reliable bypass of a safety rule, system prompt disclosure that reveals sensitive logic, or a confident wrong answer on a fact users act on.
- Medium: launch allowed with monitoring. Inconsistent refusals, tone problems, harms that need many attempts and unlikely user behaviour.
- Low: logged for the next release. Cosmetic or wording issues.
Two more rules make the criteria honest. Every critical and high finding is retested by someone other than the fixer before it closes. And a launch with accepted risks is a limited launch: a user group, a feature flag or a usage cap that can be rolled back.
Where AI fits
AI helps the testers, not the decision. A model can generate attack variants, translate prompts into other languages, cluster similar findings and draft the round report. Engineers still choose the harms, confirm each finding by hand, score severity and decide whether the feature ships. Netbase works with commercial and open-weight models, chosen per project, so the same plan applies whichever model sits behind the feature.
- In delivered work
RAG knowledge assistant
A retrieval-augmented assistant that answers from company documents, the feature type where indirect content and access rules need testing; the client is not named.
- In delivered work
WhatsApp AI chatbot with CRM integration
A chatbot connected to WhatsApp Business and a CRM for lead capture, the kind of feature where direct prompts and CRM writes are attack surfaces; the client is not named.
- In delivered work
4over4 recommendation engine
Product suggestions from browsing history and previous purchases, the named AI feature Netbase delivered with a client.
- Available capability
Pre-launch red-team exercise
The roles, attack-surface plan and exit criteria as described on this page; not yet tied to a published case.
What delivery record exists, and what does not
- What exists. Netbase has delivered retrieval-augmented knowledge assistants, document AI and MLOps pipelines for clients that are not named, a WhatsApp AI chatbot connected to a client's CRM, and the named 4over4 recommendation engine. Its security practices include vulnerability scanning and penetration testing. Most Netbase projects are delivered on fixed-price contracts.
- What does not. No published Netbase case describes a red-team exercise or its findings, and no time, cost or defect figure from client work is offered here. The roles, matrix and exit criteria are method guidance; the external facts come from the cited sources.
Which alternative fits your feature?
Three options cover most teams, and they combine well.
- Internal exercise with the five roles. Choose it for a first launch with a bounded user group and a team that can spare testers who did not build the feature. It fails when everyone involved built the feature.
- Automated scanners in the pipeline. Tools such as PyRIT, garak or promptfoo replay known attack families on every change. Choose them to keep findings closed after launch; they miss harms specific to your product and data.
- External specialist red team. Choose it when the feature touches regulated data, takes actions with money or customer records, or a large customer asks for independent evidence. It complements an application security assurance review and a penetration test, which cover the surrounding web application.
When not to run a full exercise: an internal tool that only drafts text a person always edits, with no access to confidential data and no tools, needs a short guided round and the regression cases, not five roles and several rounds. Revisit the decision when the feature gains data access or actions.
For larger providers of general-purpose models, regulation adds its own testing duties: the EU AI Act asks providers of models with systemic risk to perform and document adversarial testing. Most feature teams fall outside that duty, but a customer may still ask for the evidence. Keep the findings log and the launch report with the provenance records of the release.
Limits of this guide
- It is not legal advice. Whether a law requires adversarial testing for a system depends on its use and its provider role.
- It covers pre-launch testing of one feature, not continuous monitoring after launch or a full security programme; for post-launch signals, see collecting human feedback on an assistant.
- A red-team exercise shows that harms can happen; it does not prove their absence or measure how often they occur.
Plan the next step with a Netbase consultant
Frequently asked questions
An evaluation harness checks expected behaviour on a fixed test set on every change. Red-teaming looks for behaviour nobody expected, by people trying to break the feature. Confirmed red-team findings then become cases in the harness.
No, not before a first launch. Scanners replay known attack families quickly and are good at regression, but harms specific to your product, users and data are found by people who understand them.
Start once the feature works end to end in a test environment with its real prompts, retrieval sources and tools. Repeat it when the model, prompts, data sources, tools or permissions change.
A launch approver who did not build the feature, usually the product owner's manager or the security or risk lead, signs against the exit criteria agreed before testing.
Next step
Send us a short description of the generative AI feature you plan to launch, its data sources and the actions it can take, and we will book a solution review to draft the harm statements, the roles and the exit criteria. For assistants that answer from company documents, see enterprise knowledge and RAG.
Related services and solutions
Generative AI development with evaluation and human review Netbase builds generative AI features for product and operations teams: drafting, summarising, rewriting and content generation inside the software your people and customers already use. Every feature ships with an evaluation set, a human review step where output matters and limits on cost. Generative AI is a capability we are growing, and we label its maturity honestly.
Learn More
Application security assurance for web, SaaS and AI features Netbase provides application security testing for product and engineering leaders to find and fix vulnerabilities before release, including in AI features. We review code with AI-assisted triage, scan dependencies and test running applications, then rank findings and retest fixes. Netbase's own alignment with ISO 27001 and SOC 2 Type II covers Netbase's operations, never your application.
Learn More
Responsible AI and MLOps for AI in production MLOps and responsible AI keep an AI feature trustworthy after launch. Netbase's practice for monitored, governed AI in production covers evaluation before every release, versioning of models, prompts and data, monitoring of quality and cost, and incident controls with a named owner. It is a growth capability, backed by an MLOps pipeline delivered for an unnamed client.
Learn More
AI knowledge assistant: answers from company knowledge, with sources and access control An AI knowledge assistant is an internal tool that answers employees' questions from your company's own documents and systems, cites the source behind every answer and shows each person only what they may see. Netbase offers it as a growth capability, designed with retrieval, evaluation and human review from the first pilot, and has delivered one for an unnamed client.
Learn More
Work with Netbase remotely
Every Netbase engagement is delivered remotely, so clients in any country and any industry can work with us; Netbase has worked with clients in 80 countries. Contracts and invoices are issued by Netbase JSC, and payment is made by bank transfer to Netbase JSC's company account or PayPal Business. Talk to the CEO, Huy Nguyen (David), on WhatsApp or by email.
Discuss a project
Netbase JSC helps organizations design, build, modernize, and operate digital products and AI-enabled business systems.project@netbasejsc.com
+84 937 869 689
91 Nguyen Chi Thanh, Dong Da, Hanoi, Vietnam
Get in touch
Tell us what you want to build, modernize, or operate.