aidefence

Integrates Express middleware to scan LLM inputs for prompt injection and PII threats.

1|Updated Feb 8, 2026
One-click install
npx skills add https://github.com/ricable/cli-skills-builder --skill aidefence
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: aidefence
Source: https://github.com/ricable/cli-skills-builder/tree/main/.claude/skills/aidefence
Command: npx skills add https://github.com/ricable/cli-skills-builder --skill aidefence

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides robust security middleware to protect AI applications from a variety of threats, including prompt injection, data manipulation, and PII exposure.

Core Features & Use Cases

  • Prompt Injection Detection: Shields AI models from malicious inputs designed to hijack their behavior.
  • PII Detection & Redaction: Identifies and removes sensitive personal information from user inputs.
  • Adversarial Input Scanning: Detects and mitigates inputs crafted to deceive or exploit AI models.
  • Use Case: Implement this Skill as a security layer in your LLM pipeline to ensure user inputs are safe before they reach the AI model, preventing security breaches and maintaining data privacy.

Quick Start

Install the aidefence package using npm to begin securing your AI applications.

Frequently Asked Questions about aidefence

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I protect my LLM application from prompt injection attacks?

To prevent LLM security threats like prompt injection, integrate AI security middleware into your application pipeline to scan and block adversarial inputs before they reach the model. This middleware intercepts malicious prompts and manipulative commands to ensure safe processing.

How do I detect and redact PII from user inputs in an AI pipeline?

To detect and redact PII from user inputs, use security middleware with built-in PII detection capabilities to identify and remove sensitive personal information. This ensures data privacy by sanitizing inputs before they are processed by the LLM.

Can I integrate AI security scanning as middleware in Express?

Yes, you can integrate AI security scanning as middleware in web frameworks like Express. It functions as a security layer in your LLM pipeline, scanning inputs for threats and PII exposure before passing safe requests to the AI model.

What is adversarial input scanning for LLM-based systems?

Adversarial input scanning for LLM-based systems is the process of detecting and mitigating inputs specifically crafted to deceive or exploit AI models. It operates as a middleware layer to identify malicious payloads and prevent data manipulation or security breaches.

Do I need a dedicated middleware layer to secure my AI applications?

You need a dedicated middleware layer to secure AI applications because it provides robust threat analysis and input scanning specifically designed for LLM vulnerabilities. Implementing this security layer prevents prompt injection and PII exposure before user inputs reach the AI model.