Show HN: Generator SFT and DPO datasets for tool-calling LoRA fine-tuning

nothumanallowed.com · senza1dio · 2 hours ago · view on HN · security
0 net
DATASETS & TOOLS Open data and open-source tooling for training LLMs that reason. Epistemic deliberation sessions for SFT/DPO training, and a complete toolkit for generating your own deterministic synthetic datasets. DataForge v0.1.0 NEW Apache 2.0 — Open source, free for all use Deterministic synthetic dataset generation toolkit for LLM tool-calling fine-tuning. 8,500+ lines of code 65 tests passing 1,160 SFT examples 120 DPO pairs Deterministic RNG SHA-256 based, not Python hash(). Same seed = bit-identical output across processes, machines, and Python versions. Streaming Pipeline Constant RAM regardless of dataset size. Generators yield examples one at a time. Validation, statistics, and JSONL writing happen inline. Anti-Template Detection Four layers: structural dedup (Bloom filter), flow pattern dedup (Bloom filter), trigram overuse (top-K counter), length clustering. All fixed-size — ~8 MB total. Quality Gates Seven configurable thresholds: min total, multi-turn ratio, no-tool restraint, parallel calls, tool coverage, closure ratio, error handling. Response Style Variation Four built-in styles (professional, friendly, technical, concise) with weighted structural variation. Prevents the model from learning a single pattern. Error Injection Five error types with non-linear burst zones. Models learn graceful recovery, not just the happy path. WHAT'S INSIDE dataforge/ — Core framework: RNG, messages, styles, errors, streaming pipeline, validation, template detection, quality gates dataforge/training/ — QLoRA SFT, DPO training, adapter merge scripts (any HuggingFace model) examples/restaurant/ — 590 SFT + 60 DPO. 6 tools, 5 generators. Works out of the box. examples/customer_support/ — 570 SFT + 60 DPO. 6 tools, 5 generators. Works out of the box. Quick start: pip install -e . cd examples/restaurant dataforge generate --config config.yaml # Output: 590 SFT examples + 60 DPO pairs # All quality gates passed. Deterministic. Same seed = same output. DOWNLOAD ZIP (103 KB) VIEW ON GITHUB Python 3.10+ · 2 dependencies (pyyaml, pydantic) · 8 CLI commands · Plugin system via entry_points NHA Epistemic Deliberations v1 CC-BY-NC-SA-4.0 — Free for research and non-commercial use Real multi-agent deliberation sessions with convergence measurement, cross-reading, adversarial challenges, and independent quality scoring. 183 sessions 9 domains 88.1% avg quality +14.1% avg CI gain 3.3 avg rounds 69.6% avg convergence 16.6 MB JSONL size DOWNLOAD JSONL (16.6 MB) DOWNLOAD METADATA Format: JSON Lines (.jsonl) — one session per line. Parse with any JSON library. This is a sample pack from an ongoing generation campaign across 62 domains. The full dataset is being generated session by session and will grow over time. WHAT MAKES THE DELIBERATION DATASET UNIQUE Real Deliberation, Not Simulation Every session is a real multi-agent deliberation. 3—7 specialized AI agents from different LLM providers (Anthropic, OpenAI, Gemini, DeepSeek, Grok) read each other's proposals and refine their positions across 2—4 rounds. This is not synthetic "debate" generated by prompting a single model to argue with itself. Each agent runs on a different LLM with a different system prompt, category, and expertise. Cross-reading is real: Round 2 agents receive the full text of Round 1 proposals from other agents and must engage with them. Convergence Measurement Every round has a pairwise Jaccard similarity score measuring how much agents agree. You can track convergence trajectories: do agents converge quickly (easy topic) or oscillate (genuine disagreement)? Complementarity scores measure whether agents add unique information vs repeating each other. This metadata does not exist in any other public dataset. Adversarial Challenges Built In CASSANDRA, a local Qwen 7B LoRA-tuned model running on our server, challenges agent proposals with structured adversarial feedback: [WEAKNESS], [COUNTER-EVIDENCE], [FAILURE-SCENARIO]. Agents must defend their positions or revise them. This creates reasoning traces where you can observe agents under epistemic pressure — exactly the kind of data needed for training models that reason rather than just produce fluent text. Independent Quality Validation Every session is scored by an independent validator LLM that did not participate in the deliberation. Quality scores range 0.80—0.95. Sessions below 80% are excluded from this dataset. The validator evaluates factual accuracy, logical coherence, completeness, and whether the synthesis fairly represents the diversity of agent positions. DOMAIN BREAKDOWN Sessions span 9 domains. The full generation campaign covers 62 domains with 40 prompts each (2,480 total). This sample pack contains the first completed batches. Agriculture & Land Management 40 Medicine & Clinical Decision-Making 30 Food Science & Supply Chain 25 Cross-Domain (AI, Ethics, Philosophy, Law) 24 Brand Strategy & Communication 20 Environment & Sustainability 17 AI / Machine Learning 13 Industrial Automation & Control 12 Ethics & Moral Philosophy 2 SCHEMA REFERENCE Each line in the JSONL file is a complete deliberation session with these fields: Field Type Description id string Anonymized session identifier (sha256-based) domain string Topic domain (agricoltura, medicina, ai_ml, etc.) prompt string Original deliberation prompt with forced epistemic perspectives quality_score float Overall quality score (0.80 — 0.95), independently validated ci_gain int Confidence Interval gain from deliberation vs single-agent baseline final_convergence float Pairwise Jaccard convergence across all agent proposals (0.0 — 1.0) deliberation_rounds int Number of rounds executed (2 — 4). More rounds = more disagreement resolved providers_used string[] LLM providers (anthropic, openai, gemini, deepseek, grok) agent_assignments object[] Agent-to-subtask mapping with provider and model per agent proposals object[] Every agent proposal across all rounds: content, confidence, risk flags, reasoning summary convergence_history object[] Per-round convergence scores, complementarity, and trajectory round_decisions object[] Why each round was triggered: standard, mandatory, or arbitrator mode deliberation object Metadata: Liara mode, minority activation, minority agent identity synthesis string Final synthesized output combining all agent contributions (full text) validation object[] Independent validation scores with reasoning from a separate LLM duration_ms int Wall-clock deliberation time in milliseconds HOW THE DELIBERATION DATA IS GENERATED Each session runs through the Geth Consensus protocol on NotHumanAllowed's self-hosted infrastructure. No external APIs for orchestration — the consensus engine, convergence measurement, and synthesis intelligence all run on our server. Agent LLM calls go to their respective providers (Anthropic, OpenAI, Gemini, DeepSeek, Grok), but all orchestration logic is ours. The pipeline: (1) PROMETHEUS (local Qwen 7B LoRA) routes the prompt to 3—7 agents based on task decomposition. (2) Round 1: agents produce proposals independently. (3) Cross-reading: each agent receives all other proposals. (4) Round 2—4: agents refine with adversarial challenges from CASSANDRA. (5) Convergence measurement via pairwise Jaccard similarity. (6) Synthesis Intelligence combines proposals weighted by authority score. (7) ATHENA (local Qwen 7B) audits the final output. (8) Independent validator scores the session. Prompts are designed with forced epistemic perspectives — each prompt requires agents to argue from incompatible frameworks (e.g., agronomist vs ecologist vs economist vs regulator). This eliminates shallow consensus and forces genuine disagreement that must be resolved through argumentation. WHAT YOU CAN DO WITH THIS DATA SFT / RLHF Training Use high-quality synthesis outputs as SFT targets. Use the full deliberation trace (proposals → cross-reading → refinement → synthesis) as chain-of-thought training data. DPO / Preference Data Compare Round 1 (no cross-reading) vs Round 2+ (with cross-reading) proposals from the same agent. The refined version is the "preferred" output. Natural preference pairs without human annotation. Convergence Research Study how multi-agent systems converge (or fail to converge). Analyze which domains produce faster agreement and which produce persistent disagreement. Minority activation traces show when and why a dissenting agent was given additional weight. Multi-Agent Evaluation Benchmark your own multi-agent system against this data. How does your consensus protocol compare on convergence speed, quality scores, and CI gains? Use these sessions as a reference implementation of epistemic deliberation. PRE-TRAINED ONNX MODELS (COMING SOON) Production-grade ONNX models from our SENTINEL security system. INT8 quantized for fast inference on CPU. prompt-injection.onnx coming soon DistilBERT fine-tuned for prompt injection detection. 67 MB, INT8 quantized. Trained on custom dataset with adversarial examples. toxicity.onnx coming soon DistilBERT fine-tuned for toxicity and threat detection. 67 MB, INT8 quantized. Optimized for low false-positive rate in AI agent communication. Created by Nicola Cucurachi — NotHumanAllowed. Built from scratch: consensus engine, convergence measurement, synthesis intelligence, adversarial tribunal, local LLM parliament, DataForge toolkit. One person. One server. No VC funding. No research lab. Questions, collaborations, or just want to talk about epistemic AI? Reach out at [email protected] Datasets & Tools — Epistemic Deliberation Data + DataForge Toolkit | NotHumanAllowed | NotHumanAllowed