Skip to main content
Loading navigation

Mastra AI Workflow setup with Lakera Guard

Prompt source

implementation4 lines2 sectionsNo variables0 checklist items
import { Workflow, Step } from '@mastra/core';
import { LakeraClient } from '@lakera/ai';

// Create Mastra AI workflow that routes text through Lakera Guard before executing LLM treaty analysis
export const treatyAuditWorkflow = new Workflow({ name: 'treaty-audit' });