Docs / Products / Nosmai Moderation

Nosmai Moderation

On-device moderation for images, video and text. Configurable thresholds, no cloud round-trip.

Overview

Moderation classifies user-generated content across 12+ safety categories and returns a confidence score per category. You set the threshold; content at or above it is flagged. Everything runs on-device, so nothing is uploaded.

Check content

const mod = new Nosmai.Moderation("nsk_live_...")
mod.setThreshold({ adult: 0.8, hate: 0.6 })

const r = await mod.checkText(message)
if (r.flagged) hide()   // r.categories, r.score

Response shape

FieldTypeDescription
flaggedbooleanTrue if any category meets its threshold
scorenumberHighest category confidence, 0 to 1
categoriesobjectPer-category scores (e.g. adult, hate)

Configurable thresholds

Set one global threshold or per-category values. Lower is stricter. Tune them to your policy, see the live threshold playground.

TIP

Because moderation runs on-device, there is no per-call cloud bill and content never leaves the user, solving latency and compliance at once.

Nosmai

We make advanced camera and AI technology accessible to every developer. By packaging hard problems into simple

developers
legal
newsletter

Product updates and release notes. No spam.

© 2026 nosmai, inc · all rights reserved