Building Trustworthy AI at Northwestern Mutual: Guardrail Technologies and Strategies
Summary
- Guardrail Models for Safety: Fine-tune open-source guardrail models like Llama Guard 3.1 to detect and prevent harmful or policy-violating outputs from generative AI systems.
- Synthetic Data Generation: Generate synthetic datasets based on real-world questions and risks encountered in production, enabling continuous improvement of guardrail models without exposing sensitive data.
- Orchestrated AI Governance: Combine prompt engineering, custom frameworks, and guardrail models hosted on Databricks to deliver trustworthy AI products to internal employees and financial representatives.
Building Trustworthy AI at Northwestern Mutual: Guardrail Technologies and Strategies

Talk by Nicholas Brathwaite, Data Science, Northwestern Mutual
This intermediate-level presentation will explore the various methods we've leveraged within Databricks to deliver and evaluate guardrail models for AI safety. From prompt engineering with custom built frameworks to hosting models served from the market place and beyond. We've utilized GPU within clusters to fine-tune and run large open sourced models at inference such as Llama Guard 3.1 and generate synthetic datasets based on questions we've received from production.
Here’s more to explore:
Unified and open governance for data and AI: https://www.databricks.com/product/unity-catalog
See all the product announcements from Data + AI Summit: https://www.databricks.com/events/dataaisummit-2025-announcements
FAQs
What is a guardrail model in the context of generative AI?
A guardrail model is a specialized AI system designed to detect and block harmful, unsafe, or policy-violating outputs from generative AI systems. This video covers guardrail technologies like Llama Guard 3.1 that can be fine-tuned and deployed on Databricks.
How does Northwestern Mutual use guardrails?
Northwestern Mutual deployed guardrail models to protect internal AI products (NMGPT, LinKet, Ally) from generating harmful outputs. These guardrails work alongside search services, model feedback, and monitoring to ensure trustworthy AI.
Why generate synthetic datasets for guardrail improvement?
Synthetic datasets based on real-world production questions enable teams to improve guardrail models without exposing sensitive customer data. This allows Northwestern Mutual to continuously enhance safety based on actual risks observed in production.
What is the role of prompt engineering in AI trustworthiness?
Prompt engineering is one component of guardrail strategy. Northwestern Mutual combines custom prompt frameworks, orchestrated services, and fine-tuned guardrail models to achieve comprehensive policy compliance and trustworthiness across AI products.
Full transcript
All righty, welcome everyone. Thank y'all for coming to my session today. I'm a data scientist over at Northwestern Mutual. Uh and today we're going to go over some some of the guardrail technologies and solutions that we've been working on over the last year. Cool. So without further ado, we'll get into it. Starting with the forward looking statement. All the information that I'm presenting here is purely for information purposes only.
Um, and so this is part of what we've been doing and just working on over at Northwestern for the last year. So building trustworthy AI guard rail technologies and some of the strategies that we've implemented so far. Starting off with the server orchestration. And so as we've seen in this constantly changing environment and landscape, we have new models, new products, new features, new everything constantly coming out and evolving.
And how can we stay up to date as much as possible and how can we leverage these new technologies in Northwestern Mutual internally for our home office employees and our financial representatives. So what that leads to is the centralized AI capabilities to where we are leveraging some of these products such as AWS, Microsoft and data bricks into one hub and platform that allows us to then rapidly develop and do PC for different teams and the use cases that we have which then brings us to Genai core capabilities.
So for our core capabilities, we have search service, we have model feedback, guardrails, which I'm going to get more into depth in this presentation. We have monitoring and we have prompt cataloges. The combination of these different services work in tangent for some of the products that we've developed over the years such as NMGPT servicing, linket, and ally. And I know you're probably wondering like what do these different acronyms really mean?
So some of these products are working for say our home office employees or financial representatives working in the field. How can they access the information that we have through either vector databases in our rag use cases or how can they access it using some of the models that we have available through either data bricks AWS or some of the open source models such as and ultimately with this package bundle of core capabilities we want to be able to protect against any miscellaneous use cases that may happen which brings us into the guardrail services.
So what are some of these risk types that we have? So so far for the financial services industry, the main four ones we've identified are content moderation, PII, prompt security, and private company information. With these different risks currently available through inputs to our orchestrator system or other malicious attempts or hacks towards our system, we started to explore the different providers listed to your right between AWS's bedrock, data bricks custom solutions, our own in-house development, Meta Lamagard, and Microsoft Presidio.
So now I'll get a little bit more in depth into how we were using these different models and systems and providers all together for a guardrail service. So guardrail providers we have AWS and the bedrock guardrails that have been developed over the last year. Initially we started working with them in terms of surveys and feedback meetings which led to what would we ideally want to see in the first kind of iterations and prototypes of bedrock carvings.
Ultimately with that it led to the creation of integrating it into our model service that allows us to use the JSON templates and apply them in data bricks and create either custom topics look through sensitive information such as PII in this form of credit card numbers, phone numbers, addresses or entity mapping in terms of search words or detection words that we'd want to ultimately remove and highlight as these are kind of flags for a particular risk type.
Uh ultimately this allowed us to do most of our development in our R&D workspace with data bricks and develop different use cases for the different risk types that we had identified previously. Then we get into customized data bricks models and through the servicing marketplace we are able to upload and create either upload or serve models directly from data bricks and using the GPUs available in our clusters to run them at inference or using different forms of prompt engineering and instructions that allow us to detail what does content moderation look like, what does PII look like at Northwestern, and what are things that the model should be capable of answering and should not be capable of answering.
Then we get into Metal Lama Guard and inference testing. So using it is open source being able to run it in our clusters using an A10 GPU uh and immediately and immediately running it through different data sets that we have either through public source or through the synthetic data sets that we generated based off the risk types uh pre previously mentioned. And ultimately with all these different providers, we had our own applied evaluation framework and system that allowed us to measure how well they were working for each of these different risk types and the data sets that we're comparing them with.
Now getting into the in-house development and Microsoft Presidio. So for in-house development, we use some of the sequence classifiers available through hugging face and that include models such as Rambert, convolutional bird, distill bird, all the different types of birds that you can find. Ultimately looking for how can we increase the context window for inputs at the same time keeping that lightweight approach of having a model that runs as quickly as possible.
Uh reducing the latency and still not compromising on its overall performance in terms of the metrics that we're looking to um metrics that we're looking to compare different models with. And then getting into Microsoft Presidio. This model was primarily used for PII. With that, we had different spacing embedding models that we used in order to wrap the model with the either transformer wrapper, the NLP configuration or the anonymizer or analyzer wrappers that we had with it.
The analyzer allowed us to look through different entities against similar to like credit card numbers, phone numbers, addresses, email addresses, or anything else that we'd want to protect in terms of personal information for clients that may be interacting with these models or for home home employee offices or home office employees who are working with these same providers and working with these same systems um and ultimately making sure that everything is protected and there's no PII leakage.
And so now getting a little more in depth into the guardrail solutions that we also use within data bricks. Starting off with data set generation and collection. So, as we've seen with some of the different risk types previously mentioned, there may not necessarily be publicly available data sets that you can use and that come pre-labeled and pre-equipped with the information that we need um in order to better assess how the different providers we have are working.
So, with this in mind, we applied two different techniques or solutions in generating these synthetic data sets. One was using GPT 3. 5 and GPT4 along with prompt engineering and instructions and few shot examples that we gathered from live production data sets that we had logged through either CFKA or within our internal monitoring systems. Using those examples with the predefined um corresponding response we would like to get from the model, we are able to generate a pretty even split from 200 to say 500 questions evenly split between good and or adversarial questions that we had used convert the JSON file into CSVs and then store that within data uh store that as CSV files in data bricks and use those for either fine-tuning or evaluation purposes.
The other method got into using VLM and another framework called deep evaluation. So deep evaluation comes with its own redteamer attack and synthesizer. And what that allows us to do is use some of the topics previously defined earlier or some of the topics they have predefined in their SDK package such as prompt leakage or PII leakage which also are in alignment with what we'd like to protect within Northwestern Mutual.
So using a combination of that, we're able to use open source models to synthetically generate data sets um at a reasonable price and still keep the same quality of golden data sets that we'd like to use for evaluation and testing purposes. And so here this is just a couple of the numbers of synthetic data sets that we created and some of the ones that we got from open source and then in-house development. So in-house development was I think was one of the funner parts of working on the guard rail solution so far.
This again consisted of using those sequence classifiers and training them with the trainer and training arguments within hugging face. At the same time, it also involved using PyTorch and developing our own custom neural networks with it as well and attaching it into the encoder and embeddings within these open source and pre-trained models. And so with that, some of the other models that we used included Rambert, convolutional bird, dberta, and distill. and training them again on each of the different risk types that we had identified earlier using this either the synthetic data sets or the open source data sets and then getting into the custom models using distill applying our own linear layers with PyTorch applying our own activation functions such as JLU applying our own gradient descent and applying either PEP in its own class in order to reduce the amount of memory needed and computational resources that we'd use to run these models and overall keep them lightweight and keep them running as efficiently as possible.
In addition to that, we even started looking into a guardrail policy matcher which the idea would be using some of the ethic codes andor documents we have in Northwestern Mutual. How can we cross reference it with inputs that we're getting or new documents as well? This ultimately will allow us to see is there some form of comparison or similarity for what we deem as the ethic code we would like to adhere to as well as the inputs that we're getting into the orchestrator system and then further into the data brick solutions.
So between fine-tuning, inference and endpoint deployment. Fine-tuning it gets deeper into what we were previously mentioned within those neural network architecture and the sequence classifiers that we have using the GPU available to us such as T4s and A10s. How can we efficiently fine-tune the different models mentioned previously such as convert dberta and distilbert for the use cases that we have and compare them with the same applied evaluation system for accuracy precision recall and F1 scores.
Then getting into inference using models such as Lamagard, Quim, Mistrol, 53 and 54. Can we apply prompt engineering to it to where we can run it straight out of the box and straight through open source uh open source solutions and ultimately see if it also works as well compared to the fine-tuning models that we had previously. Um and again rapidly test and prototype for the risk types and different um the different risk types that we identified previously.
Then getting into endpoint deployment based off based off of the performance of the different models that we had already assessed. Can we use MLflow to store it within our Unity catalog in data bricks and eventually set up our own API endpoints and either serve them locally within data bricks or serve them in other environments that we have within the orchestrator system that we were working on and building together.
And then with that I'll get further in depth into the custom data bricks model that we had which was using a combination of the inference from the endpoints that we got from the servicing marketplace or the ones that we got from open source. So getting into the custom data bricks models for serving endpoints these this is a list of some of the different models that we explored and then for the evaluation data sets these are some of the open source data sets that we got from either hugging face or just Google in general.
And for the custom data bricks model it comprised of four different systems. We had a filter system we had a response system we had a guardrail system and we had a prompt engineering and our prompt catalog. So within the class object itself, you can use the filter system to look for any inputs and use the instructions we provided to these models in order to filter and detect any potential malicial malicious threats prior to passing it to the response model which would generate a response based off of whatever input that you gave it.
Then using another guardrail system to where you can interchangeably use any of these models at any given point. That model would then say is the response something that is deemed safe and usable to provide to another user and anybody interacting with the model itself. And then to give you a more in-depth picture of what that looks like, we get into the custom data bricks models here. So this architecture will give you an idea of how the guardrail system itself would work.
You could give it the input and then based off of the different models that we have, we'd have to adjust the formatting for it for either a list or a dictionary. You have model initialization for the model within data bricks. And then you get the output. With that output, we have the references from the data set itself that would tell us if this was either a benign or malicious threat or malicious input. Then we have the output formatting converting that output if text into a binary 01 using the same evaluation system and metrics for again accuracy precision recall and F1 scores.
That's how we determine if these models are working best and for the different use cases that we have and then even for those output values we can append them to the data sets that we're using. So that way we can look back and see which of the different inputs or the different sections of that data set uh caused the model the most problems at any given point in time and then getting into architecture. So with agents being what some of the newest technology currently available right now, we also did experimentation and using and using langraph as an agentic framework paired with some of the different guard rail tools that we seen and we ran this in locally using O Lama or data bricks.
Uh I call it guard dog and llama guard dog and presidial dog. Ultimately, the idea behind these models is you can use one of these different LLMs to do another reference check for any input that you have. And then from there, you can pass it to Lamag Guard, which would use Llamag Guard as a tool, or Presidio Dog, which would use Presidio as a tool. And ultimately, you get a summarized report of the different either categories or risk or potential thefts found within that input.
And for the supervisor model to the left, you can run all of those synchronously all at once. And the idea would be the same to where you could use the summarized output of it. You could get the different tools that were used, the models that were ran with it, and ultimately next best kind of steps and procedures to take based off of that. And then next we get into some of the evaluation reports that we got. So in our initial findings in working with PII data, we found that the presidial model was initially oversensitive to the information that we're providing it in the sense that for acronyms mainly pertaining to Northwestern or tax forms or policy numbers or any other form of document such as nature, it would detect them as an entity such as phone numbers, right?
And ultimately, we wanted to reduce the amount of false positives while keeping the integrity of the model as high as possible. So that way, we don't potentially let any other threats slip through. And so with that, we chose to look at the recall metric as our primary uh benchmark. And for Presidio, we made some adjustments by using a token classification model trained on PII available through open source, attaching that with the spacey embedding model and overall wrapping that together to create another analyzer tool that and determining what entities that we wanted to map for and we ran it using live production data set or the production data set that we collected from other projects currently in production.
And so with that we ran it compared against AWS and Lamagard and these are this is overall the recall metric that we've gotten for it. Then getting into conclusions. So overall we found that Presidio worked best for protecting against PII based off of the different benchmarks that we ran with it. Fine-tuning and synthetic data set generation with data bricks clusters does help for other sequence classification tasks. uh and ultimately there is room for further development in that area as well.
Lamag Guard worked as a universal detector in the sense that given given that it has about 13 to 14 different categories it's already been trained on it worked on mitigating most of the different risks that we've seen and then AWS's bedrock guard rails integrated into the protected service is currently the direction that we're headed in right now um and that's how we're looking to continuously evolve and integrate these systems going forward and so with that is most of what we have for today.
Thank you'all again for coming out today to listen to us and the guardrail strategies that we've been working on over at Northwestern. Uh I'd like to also say a special thank you to my team, foundation team for working together over the last year. And yeah, that's about everything that I have for tonight.
Learn more about the Databricks Data and AI platform.
The information provided herein is for general informational purposes only and may not reflect the most current product capabilities or configurations.