Moderation with a review queue
Distinguish questions, respectful criticism, spam, and abuse. Leave uncertain messages for a moderator.
What the model decides. What code checks.
- Each fictional message gets three independent Noul questions: spam, personal abuse, and a product question.
- Code assigns hold at high risk, show at low risk, and review between the thresholds.
- Messages are processed sequentially within a fixed budget. The result is a local list of decisions; no messages are deleted or published.
Read. Run. Replay.
Unpack the archive and open its directory in a terminal. The first step needs neither a key nor a network connection.
python3 runner.py moderationFor a real run, set SHVYDKO_API_KEY in your computer or server environment. Do not put the key in your browser or source code. Current account quotas and pricing apply.
python3 runner.py moderation --live --output moderation-run.jsonThe report contains requests, actual responses, elapsed times, and known usage. The file is created with private permissions and never overwrites an existing file. Network failures are not automatically retried: check Usage before another call.
python3 runner.py moderation --replay moderation-run.jsonReplay checks that the recipe, inputs, and requests match. A local file is editable, so it is not signed proof of where responses came from. If you replace the inputs with your own data, the report will contain those data too: keep it private.
An open contract, with every step visible.
The plan below was generated by the same runner from the bundled fixtures. It contains requests and author expectations, not model results.
{
"mode": "offline_plan",
"model_calls": 0,
"recipe": "moderation",
"author_expectation": {
"m1": "show",
"m2": "hold",
"m3": "show"
},
"notice": "Requests only, no model answers. Hierarchy includes conditional branches; repetition requests are templates.",
"requests": [
{
"state": {
"message": "Where can I find the API documentation?",
"policy": "Respectful criticism and product questions are allowed. Hold unsolicited promotional spam or personal abuse for moderator review."
},
"questions": {
"spam": {
"type": "noul",
"instructions": "This is unsolicited promotional spam."
},
"abuse": {
"type": "noul",
"instructions": "This contains personal abuse, not just criticism."
},
"question": {
"type": "noul",
"instructions": "This asks a product-related question."
}
}
},
{
"state": {
"message": "BUY NOW BUY NOW! Click my unrelated promotion for free prizes!",
"policy": "Respectful criticism and product questions are allowed. Hold unsolicited promotional spam or personal abuse for moderator review."
},
"questions": {
"spam": {
"type": "noul",
"instructions": "This is unsolicited promotional spam."
},
"abuse": {
"type": "noul",
"instructions": "This contains personal abuse, not just criticism."
},
"question": {
"type": "noul",
"instructions": "This asks a product-related question."
}
}
},
{
"state": {
"message": "I disagree with this pricing, but the docs are useful.",
"policy": "Respectful criticism and product questions are allowed. Hold unsolicited promotional spam or personal abuse for moderator review."
},
"questions": {
"spam": {
"type": "noul",
"instructions": "This is unsolicited promotional spam."
},
"abuse": {
"type": "noul",
"instructions": "This contains personal abuse, not just criticism."
},
"question": {
"type": "noul",
"instructions": "This asks a product-related question."
}
}
}
]
}