Downloads · 30 days
81
37% of all-time downloads
GabeuxDev/ai-text-detector-v1.01-onnx
ai-text-detector-v1.01-onnx is a text classification model from GabeuxDev. Use it when you need a label for a piece of text. It is set up for transformers.js. The card lists the license as mit.
Unmodified ONNX export of desklib/ai-text-detector-v1.01 (MIT license), a DeBERTa-v3-large based AI-generated-text detector. All credit for the model and its training belongs to the original authors; this repository o…
Downloads · 30 days
81
37% of all-time downloads
All-time downloads
217
Public
Repo size
3.5 GB
Likes
0
Public
Click a slice to open those files.
.onnx_data1.7 GB · 99%
From the Hugging Face model README
Unmodified ONNX export of desklib/ai-text-detector-v1.01 (MIT license), a DeBERTa-v3-large based AI-generated-text detector. All credit for the model and its training belongs to the original authors; this repository only converts it so it can run with onnxruntime and Transformers.js (e.g. fully in the browser).
input_ids, attention_mask; output logits of shape [batch, 1].
Apply a sigmoid to get P(AI-generated). config.json sets
problem_type: multi_label_classification so Transformers.js applies the sigmoid
automatically (single label: AI).onnx/model.onnx (~2 MB) and the fp32
weights in onnx/model.onnx_data (~1.7 GB). Native onnxruntime picks the data file up
automatically; in Transformers.js pass use_external_data_format: true. This format is
required in browsers — a single-file 1.7 GB model gets double-buffered during parsing
and exceeds the 4 GB WebAssembly memory limit. Even with external data, in-browser
inference at this size needs WebGPU (device: "webgpu"); the CPU/WASM backend
cannot hold the weights plus activations.import { pipeline } from "@huggingface/transformers";
// Requires transformers.js v4+. v3.x mis-tokenizes DeBERTa prefix spaces
// (first-word token differs from the Python tokenizer) and produces NaN on
// padded WebGPU batches; both are fixed in 4.x (verified on 4.2.0).
const detect = await pipeline(
"text-classification",
"GabeuxDev/ai-text-detector-v1.01-onnx",
{ dtype: "fp32", device: "webgpu" }
); // config.json already sets use_external_data_format for the loader
const [{ score }] = await detect("Text to check.");
console.log("P(AI) =", score);
Note: the model file is ~1.7 GB; in a browser this implies a large one-time download and several GB of RAM during inference.
MIT, inherited from the original model. See the original repository for model details, training information and evaluation.