Keep a short release index and one model card per checkpoint
Browse files- .gitattributes +0 -34
- README.md +4 -57
- cards/2026-11-14-400m-research.md +17 -0
.gitattributes
CHANGED
|
@@ -1,35 +1 @@
|
|
| 1 |
-
*.7z filter=lfs diff=lfs merge=lfs -text
|
| 2 |
-
*.arrow filter=lfs diff=lfs merge=lfs -text
|
| 3 |
-
*.bin filter=lfs diff=lfs merge=lfs -text
|
| 4 |
-
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
| 5 |
-
*.ckpt filter=lfs diff=lfs merge=lfs -text
|
| 6 |
-
*.ftz filter=lfs diff=lfs merge=lfs -text
|
| 7 |
-
*.gz filter=lfs diff=lfs merge=lfs -text
|
| 8 |
-
*.h5 filter=lfs diff=lfs merge=lfs -text
|
| 9 |
-
*.joblib filter=lfs diff=lfs merge=lfs -text
|
| 10 |
-
*.lfs.* filter=lfs diff=lfs merge=lfs -text
|
| 11 |
-
*.mlmodel filter=lfs diff=lfs merge=lfs -text
|
| 12 |
-
*.model filter=lfs diff=lfs merge=lfs -text
|
| 13 |
-
*.msgpack filter=lfs diff=lfs merge=lfs -text
|
| 14 |
-
*.npy filter=lfs diff=lfs merge=lfs -text
|
| 15 |
-
*.npz filter=lfs diff=lfs merge=lfs -text
|
| 16 |
-
*.onnx filter=lfs diff=lfs merge=lfs -text
|
| 17 |
-
*.ot filter=lfs diff=lfs merge=lfs -text
|
| 18 |
-
*.parquet filter=lfs diff=lfs merge=lfs -text
|
| 19 |
-
*.pb filter=lfs diff=lfs merge=lfs -text
|
| 20 |
-
*.pickle filter=lfs diff=lfs merge=lfs -text
|
| 21 |
-
*.pkl filter=lfs diff=lfs merge=lfs -text
|
| 22 |
-
*.pt filter=lfs diff=lfs merge=lfs -text
|
| 23 |
-
*.pth filter=lfs diff=lfs merge=lfs -text
|
| 24 |
-
*.rar filter=lfs diff=lfs merge=lfs -text
|
| 25 |
*.safetensors filter=lfs diff=lfs merge=lfs -text
|
| 26 |
-
saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
| 27 |
-
*.tar.* filter=lfs diff=lfs merge=lfs -text
|
| 28 |
-
*.tar filter=lfs diff=lfs merge=lfs -text
|
| 29 |
-
*.tflite filter=lfs diff=lfs merge=lfs -text
|
| 30 |
-
*.tgz filter=lfs diff=lfs merge=lfs -text
|
| 31 |
-
*.wasm filter=lfs diff=lfs merge=lfs -text
|
| 32 |
-
*.xz filter=lfs diff=lfs merge=lfs -text
|
| 33 |
-
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
-
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
-
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
*.safetensors filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
README.md
CHANGED
|
@@ -1,5 +1,4 @@
|
|
| 1 |
---
|
| 2 |
-
base_model: jhu-clsp/ettin-encoder-400m
|
| 3 |
language: en
|
| 4 |
tags:
|
| 5 |
- authorship-detection
|
|
@@ -7,60 +6,8 @@ tags:
|
|
| 7 |
|
| 8 |
# Monthly authorship detectors
|
| 9 |
|
| 10 |
-
|
| 11 |
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
After obtaining access to this gated repo and signing in with `hf auth login`, download the selected snapshot and run it locally.
|
| 17 |
-
|
| 18 |
-
```sh
|
| 19 |
-
hf download CoderBak/ai-detector-dev-11-14 --revision 2026-11-14-400m-research --local-dir detector
|
| 20 |
-
cd detector
|
| 21 |
-
python -m pip install -r requirements.txt
|
| 22 |
-
python inference.py essay.txt --json
|
| 23 |
-
```
|
| 24 |
-
|
| 25 |
-
```python
|
| 26 |
-
from inference import Detector, list_releases
|
| 27 |
-
|
| 28 |
-
choices = list_releases() # date, size, channel, revision and commit
|
| 29 |
-
detector = Detector() # load the downloaded snapshot once
|
| 30 |
-
result = detector.detect(text, tokens=True, windows=True, source_map=True)
|
| 31 |
-
if result["status"] == "assessed":
|
| 32 |
-
print(result["prediction_short"], result["fractions"])
|
| 33 |
-
```
|
| 34 |
-
|
| 35 |
-
For a Hub selection using this runtime, pass `Detector(revision=choice["revision"])`. For cross-version compatibility, load the inference script and weights from the same selected snapshot. Any client can enumerate tags without loading Python or downloading weights. [Hub refs API](https://huggingface.co/api/models/CoderBak/ai-detector-dev-11-14/refs)
|
| 36 |
-
|
| 37 |
-
## Inference contract
|
| 38 |
-
|
| 39 |
-
All releases use the same three class names, `human`, `ai_assisted`, and `ai_generated`. Results identify the `release`, `channel`, and `schema_version`. Input below 50 whitespace-delimited words after normalization returns `insufficient_text`, empty spans and a null headline. For assessed text, the following fields are available.
|
| 40 |
-
|
| 41 |
-
| Level | Fields and meaning |
|
| 42 |
-
|---|---|
|
| 43 |
-
| Document | `prediction_short` is Human at 90% human characters, AI at 80% AI-generated characters, and Mixed otherwise. `fractions` gives the three displayed class shares across every character of the analyzed text. `weighted_ai_fraction` counts generated characters fully and assisted characters at half weight. `segment_counts`, `word_count`, and `token_length` give totals. |
|
| 44 |
-
| Segments and sentences | `text`, half-open `start` and `end`, displayed `label`, word and token counts, and three mean token probabilities. `ai_assistance_score` is mean P(generated) + ½ P(assisted). `mean_token_confidence` averages the largest probability at each token. `displayed_label_support` averages the probability of the displayed class. Both confidence measures use CRF marginals before sentence voting. |
|
| 45 |
-
| Tokens, opt in | Token ID and offsets, Viterbi label, final displayed label, three CRF marginals, maximum marginal, averaged head features and calibrated unary scores. |
|
| 46 |
-
| Windows, opt in | Token and character bounds, the 15 segment-bucket probabilities from fully human to fully generated, and the mixed-authorship head probability. |
|
| 47 |
-
| Original text, opt in | `source_map` maps analyzed character intervals back to the original string. A `copy` interval maps coordinates position by position, including one-for-one punctuation changes. Every character in a `replacement` interval maps to its entire source interval. Removed Markdown and formatting appear as gaps in source coverage. |
|
| 48 |
-
|
| 49 |
-
All offsets count Unicode code points in `result["text"]`. In JavaScript, `Array.from(text).slice(start, end).join("")` uses the same units. Original positions in `source_map` index the raw input in those units. Byte-level token pieces can share character offsets. Segments form a complete partition of the analyzed text.
|
| 50 |
-
|
| 51 |
-
The research checkpoint also preserves its original fields for benchmark comparisons. `human_fraction` and `ai_fraction` use non-whitespace characters, with half weight for assisted characters in `ai_fraction`. `verdict` uses these two shares. `posterior_ai_share` uses the same character weights with the **probabilities** of the classes. Use `prediction_short` for the monthly headline.
|
| 52 |
-
|
| 53 |
-
## Add a monthly checkpoint
|
| 54 |
-
|
| 55 |
-
Commit the weights, tokenizer, inference script and calibration together. Set the date, size and channel in `model.json`, then create a **lightweight Git tag** on that commit. The tag points directly to the commit your app downloads. Use a new date for a corrected model. Keep the same output keys and class meanings within schema version 1.
|
| 56 |
-
|
| 57 |
-
```sh
|
| 58 |
-
git tag "$TAG" "$COMMIT"
|
| 59 |
-
git push origin "refs/tags/$TAG"
|
| 60 |
-
```
|
| 61 |
-
|
| 62 |
-
## November checkpoint
|
| 63 |
-
|
| 64 |
-
The bidirectional Ettin encoder runs on overlapping 512-token windows with stride 256. Token logits, projected segment evidence and mixed-authorship scores feed a calibrated three-state CRF. Viterbi supplies the token path and forward–backward supplies marginals. Sentence voting and the checkpoint's minimum-run setting produce the displayed spans. The November calibration uses a one-token minimum, so a single sentence can stand alone. The encoder reads both directions in one pass. Its three trained heads provide token provenance, segment composition and mixed-authorship evidence. Humanizer detection is unavailable. The checkpoint retains its own training-time normalization for Markdown and Unicode punctuation. [Pangram 4 technical report, §§4.3–5.1](https://arxiv.org/html/2607.27183v1#S4.SS3) · [Pangram 4 model card](https://www.pangram.com/research/model-card/pangram-4)
|
| 65 |
-
|
| 66 |
-
`model.json` declares the name, release date, size, channel, exact parameter count, trained heads and inference settings. `crf.json` holds the fitted decoder. Reuse a `Detector` instance for multiple documents. The CPU and CUDA paths share the same output contract. Installing the optional `numba` package accelerates the CRF for long inputs.
|
|
|
|
| 1 |
---
|
|
|
|
| 2 |
language: en
|
| 3 |
tags:
|
| 4 |
- authorship-detection
|
|
|
|
| 6 |
|
| 7 |
# Monthly authorship detectors
|
| 8 |
|
| 9 |
+
These checkpoints label English prose as human-written, AI-assisted, or AI-generated. Select a [release tag](https://huggingface.co/api/models/CoderBak/ai-detector-dev-11-14/refs) by date and size. Each tag has a model card at `cards/<tag>.md` on `main`.
|
| 10 |
|
| 11 |
+
| Checkpoint date | Model | Status | Model card |
|
| 12 |
+
|---|---|---|---|
|
| 13 |
+
| 2026-11-14 | Ettin 400M | Internal research test | [View card](https://huggingface.co/CoderBak/ai-detector-dev-11-14/blob/main/cards/2026-11-14-400m-research.md) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cards/2026-11-14-400m-research.md
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Ettin 400M
|
| 2 |
+
|
| 3 |
+
**Internal research test · November 14, 2026** · [Checkpoint](https://huggingface.co/CoderBak/ai-detector-dev-11-14/tree/2026-11-14-400m-research)
|
| 4 |
+
|
| 5 |
+
A fine-tuned Ettin encoder with 394.8M parameters and a three-state CRF. It accepts English prose of at least 50 words after normalization. It returns a document verdict (Human, Mixed, or AI) and labeled spans. Use `--tokens`, `--windows`, and `--source-map` for detailed output.
|
| 6 |
+
|
| 7 |
+
**Binary evaluation.** On 300 human passages and 300 fully generated passages from 15 generators, it classified 297 human passages as Human and 286 generated passages as AI. AUROC was 0.993 using the weighted AI fraction.
|
| 8 |
+
|
| 9 |
+
## Run
|
| 10 |
+
|
| 11 |
+
Sign in with an approved Hugging Face account, then run the detector.
|
| 12 |
+
|
| 13 |
+
```sh
|
| 14 |
+
hf download CoderBak/ai-detector-dev-11-14 --revision 2026-11-14-400m-research --local-dir detector
|
| 15 |
+
python -m pip install -r detector/requirements.txt
|
| 16 |
+
python detector/inference.py essay.txt --json
|
| 17 |
+
```
|