# Shumei Anti-Fraud MCP

> Shumei Anti-Fraud provides enterprise-grade risk assessment built for AI agents. It lets your client check text, images, audio clips, and device IDs against known fraud patterns instantly. Use it to automatically filter spam, detect NSFW content, or block traffic from suspicious VPNs before they hit your platform.

## Overview
- **Category:** customer-support
- **Price:** Free
- **Tags:** fraud-detection, nsfw-filtering, bot-detection, risk-control, content-moderation

## Description

This server is built for your AI agent, giving it enterprise-grade risk assessment capabilities right out of the box. It lets you check text, images, audio clips, and device IDs against known fraud patterns instantly, letting you automatically filter spam or block traffic from suspicious sources before they ever hit your platform.

**Text Abuse Detection with `check_text_risk`**: You feed this tool a raw string of text, and it immediately returns a classification. This tells you if the content is abusive, how likely it is to be spam, or whether it contains restricted material. If the score crosses a certain threshold, you know exactly what action your agent needs to take—rejecting the input, flagging it for review, or just passing it through.

**Image Screening with `check_image_risk`**: You pass in an image URL or direct data stream, and the server scans it right away. It checks for NSFW material or any graphical elements that violate your platform's policy. This tool doesn't just say 'yes' or 'no'; it gives you a risk assessment of the visual content.

**Audio Risk Prediction via `check_audio_risk`**: When an uploaded audio file comes in, this function analyzes it to predict associated risks. It detects things like hate speech or copyrighted material usage, helping you filter out problematic media before your system processes it further. You get a risk score based on the content of the sound clip.

**Device Fraud Validation with `check_device_risk`**: If you receive an IP address or a unique Device ID, this tool runs checks against massive databases. It determines if that source is fraudulent, if it's using a VPN to mask its location, or if it originated from an emulator. This lets your agent block traffic from known bad actors and spoofing sources.

Your AI client doesn't need complex backend services to handle moderation; you just call the right tool. You can build logic that dictates action based on these immediate risk verdicts. For example, a user submits text (`check_text_risk`), then uploads an image (`check_image_risk`), and their device connects from a suspicious IP (`check_device_risk`). Your agent runs all three checks in sequence. If any single check fails—say, the text is abusive or the device ID is flagged as a VPN—you can block the whole transaction immediately.

The server lets you perform live audits on user activity data. When your agent processes chat logs or large batches of submitted content, it doesn't just look at individual pieces; it gets an overall view of suspicious behavior across entire streams. This means you catch patterns of abuse, not just isolated incidents.

When setting up your workflow, you simply connect your AI client to this server and access the tools by name in your agent’s logic. You call `check_text_risk` for text inputs; you call `check_image_risk` for visuals; you call `check_audio_risk` for sound files; and you call `check_device_risk` whenever an IP or device identifier comes through. Each tool provides a definitive, actionable risk score that dictates the next step: allow it, warn on it, or block it entirely.

## Tools

### check_audio_risk
Predicts risk associated with an uploaded audio clip, identifying potential violations like hate speech or restricted content.

### check_device_risk
Determines if a provided device ID or IP is fraudulent or indicates the use of a VPN or emulator.

### check_image_risk
Scans an image for NSFW content, restricted material, or policy violations.

### check_text_risk
Scans a piece of text to detect spam, abuse, or explicit content.

## Prompt Examples

**Prompt:** 
```
Scan this block of text for spam and risk flags: 'Click here to buy cheap followers! https://...'
```

**Response:** 
```
I submitted the text to Shumei text-risk. It returned a 'Reject' flag, classifying the content under 'Spam/Advertising'.
```

## Capabilities

### Check text for abuse or spam
Sends raw text strings to Shumei and receives a classification indicating if the content is abusive, spammy, or contains restricted material.

### Determine device fraud risk
Takes an IP address or unique Device ID and checks it against databases used to identify VPNs, emulators, or other fraudulent sources.

### Scan images for restricted content
Accepts image URLs or data and scans them immediately for NSFW material or policy-violating graphical elements.

### Predict risk from audio clips
Analyzes uploaded audio files to predict associated risks, such as hate speech or copyrighted material detection.

## Use Cases

### Stopping spam in a forum thread
A Community Manager finds a suspicious post. Instead of manually reading it, they ask their agent to run `check_text_risk` on the entire body. The server instantly returns a 'Spam/Advertising' flag and an actionable rejection status.

### Preventing bot account creation
A new user attempts to sign up from a known corporate VPN IP range. Your agent runs `check_device_risk` on the provided IP address, which returns 'High Risk/VPN Detected.' The system blocks the signup attempt automatically.

### Moderating uploaded profile pictures
A user uploads a photo as their avatar. Before saving it, the backend triggers `check_image_risk`. If the server returns an 'NSFW' or 'Restricted Content' flag, the upload fails immediately, and the user gets an error.

### Filtering live audio chat rooms
In a voice chat environment, one participant sends a problematic audio clip. The agent intercepts this by calling `check_audio_risk`. If the server flags it for hate speech, the agent alerts moderators and prevents playback.

## Benefits

- Stops spam before it lands. By using `check_text_risk`, your agent can analyze entire user inputs—not just keywords—to catch sophisticated advertising or abusive language in chat logs.
- Blocks bad actors at the source. Running `check_device_risk` validates IPs and device IDs, letting you reject connections from known VPNs or emulators attempting to bypass limits.
- Maintains platform safety for all media types. Whether it's an image (`check_image_risk`), audio clip (`check_audio_risk`), or text block, the server provides a unified risk score and verdict.
- Reduces manual review load. Instead of having human moderators manually check every suspicious item, your agent runs `check_text_risk` and automatically flags items for quick human attention only.
- Protects against data poisoning. When developers use this to validate user avatars or uploads, they ensure that only clean media gets stored, preventing the platform from being compromised by bad assets.

## How It Works

The bottom line is: your AI agent gets an instant, actionable 'pass' or 'fail' grade on any content or device before it ever reaches your core application logic.

1. First, the user prompts your AI agent with a piece of content (e.g., 'Check this photo' or 'Analyze this chat log').
2. The agent decides which tool to run—like `check_image_risk`—and passes the specific data payload (the image URL) to the Shumei server.
3. Shumei processes the request and returns a structured JSON response containing the risk verdict, score, and classification details.

## Frequently Asked Questions

**How do I use `check_text_risk`?**
`check_text_risk` takes any block of text—like a comment or chat message—and returns an immediate verdict on whether it's spam, abusive, or otherwise restricted. This is perfect for real-time moderation.

**Is `check_device_risk` only for IP addresses?**
No. `check_device_risk` handles both specific IP addresses and unique Device IDs. You can use it to check if a user is operating through an emulator or using a VPN, regardless of the input type.

**What kind of content does `check_image_risk` scan?**
`check_image_risk` scans for NSFW material and policy-violating graphical elements. You give it an image URL, and you get a pass/fail verdict on its appropriateness.

**Can I check audio files with Shumei Anti-Fraud MCP Server?**
Yes, use `check_audio_risk`. This tool lets your agent predict risks associated with an audio clip, helping you moderate voice chat rooms for things like hate speech.

**What do I need to set up and use the `check_device_risk` tool?**
You must provide a valid Access Key obtained from the Shumei Control Panel. This key authorizes your agent to communicate with the risk service. Without this credential, none of the tools will execute.

**If `check_text_risk` encounters an API error or times out, how should my agent handle it?**
Your agent should implement basic retry logic with exponential backoff. If repeated retries fail, the agent must log the failure and proceed with a default 'Unknown Risk' flag rather than stopping execution.

**Are there rate limits when calling `check_image_risk` or other tools?**
Yes, the service imposes rate limits to manage usage. Exceeding the defined quota will result in a 429 HTTP error code. Your client must monitor this code and throttle its requests accordingly.

**How is data privacy handled when I run `check_device_risk`?**
Shumei handles all input identifiers, like IP addresses or Device IDs, according to strict privacy protocols. The service uses the data only for immediate risk scoring and does not retain personal records.

**Does my image data get stored on their servers?**
Shumei caches media briefly for anti-spam scanning operations but does not persist non-flagged uploads permanently. Consult your enterprise agreement for strict retention periods.