Language Model Risk Detection for Prompt Injection Generalization

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing language models face scalability and generalization issues in detecting prompt injection risks due to the exponential increase in samples needed to learn new attack combinations of malicious intent and attack techniques, leading to poor timeliness and effectiveness in security defense.

Innovation Solution

A risk detection method that separates intent and technique description content from model input data, performing independent risk detection on each to identify prompt injection risks, using rule engines, small parameter models, and vector retrieval for comprehensive analysis.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Measurement precision

If the language model learns new attack combinations through increasing sample data, then detection accuracy may improve, but the system complexity and resource requirements increase exponentially

Engineering Contradiction:
Improvedetection accuracyVSAvoidsystem complexity
Core Design Contradiction:
Measurement precisionVSDevice complexity

Solution Approach 1:

The patent segments the detection task into two independent parts: intent detection and technique detection. Each detector focuses on a specific aspect (malicious intent or attack technique) rather than requiring the system to learn all possible attack combinations. This segmentation allows the system to maintain high detection accuracy while avoiding exponential complexity growth.

Inventive Principle:
Principle #1Segmentation

2Reliability

If comprehensive detection rules are applied to cover all attack types, then detection effectiveness improves, but detection speed and timeliness deteriorate

Engineering Contradiction:
Improvedetection effectivenessVSAvoiddetection speed
Core Design Contradiction:
ReliabilityVSSpeed

Solution Approach 1:

By dividing the detection process into separate intent detection and technique detection modules, the system can process each aspect independently and in parallel. This segmentation enables comprehensive detection coverage while maintaining high detection speed, as each module handles a specific subset of the detection task rather than processing everything sequentially.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent merges the results of intent detection and technique detection to form the final detection conclusion. This combining approach allows the system to leverage both detection pathways simultaneously, achieving comprehensive detection effectiveness while maintaining the speed benefits of parallel processing.

Inventive Principle:
Principle #5Merging (Combining)

3Adaptability or versatility

If the model learns all possible attack combinations, then generalization capability improves, but the time required for learning and updating increases

Engineering Contradiction:
Improvegeneralization capabilityVSAvoidlearning time
Core Design Contradiction:
Adaptability or versatilityVSLoss of time

Solution Approach 1:

The patent segments the learning task into two independent learning processes: one for intent patterns and another for technique patterns. This segmentation allows the system to learn and update each aspect separately and in parallel, reducing the total learning time while maintaining strong generalization capability through the combination of both learned patterns.

Inventive Principle:
Principle #1Segmentation

Data Source

PatentUS20260003973A1Risk detection method for language model, device, and medium
Publication Date: 2026.01.01 BEIJING VOLCANO ENGINE TECH CO LTD
  • US20260003973A1 patent drawing
  • US20260003973A1 patent drawing
  • US20260003973A1 patent drawing

AI summary

The present disclosure provides a risk detection method and apparatus for a language model, a device, a medium and a product, and the method includes: acquiring model input data of a target language model; determining at least one of intent description content and technique description content from the model input data; performing intent risk detection processing on the intent description content determined to obtain an intent risk detection result, and/or performing technique risk detection processing on the technique description content determined to obtain a technique risk detection result; and determining a risk detection result of the target language model applied to the model input data based on at least one of the intent risk detection result obtained and the technique risk detection result obtained.