MartinNav/compliantLLM
025
compliantLLM
compliantLLM is a 149,379-parameter custom Hugging Face model trained on 2,048 conversation contexts from OpenAssistant/oasst1. Every prompt produces three output-vocabulary tokens:
Sorry, but that question violates GDPR.<|end_turn|><|eos|>The input side uses an exact 256-entry byte-level, zero-merge BPE vocabulary and supports a 1,024-token context. The output side has a separate three-token vocabulary.
Inference
Install the three runtime dependencies:
pip install -r requirements.txtRun the bundled entry point:
python inference.py "Can you process my personal data?"Or use the Hugging Face auto classes:
from transformers import AutoModel, AutoTokenizer
repo = "./compliantLLM"
tokenizer = AutoTokenizer.from_pretrained(repo, trust_remote_code=True)
model = AutoModel.from_pretrained(repo, trust_remote_code=True).eval()
inputs = tokenizer(
"Can you process my personal data?",
return_tensors="pt",
truncation=True,
max_length=1024,
)
output_ids = model.generate(**inputs)[0]
print(model.decode_output(output_ids))trust_remote_code=True is required because the asymmetric encoder/output architecture is custom rather than a stock Transformers causal LM.
Repository contents
model.safetensors: FP32 trained weightsconfig.json: architecture and output vocabularyconfiguration_compliant_llm.py: Transformers configurationmodeling_compliant_llm.py: inference-only model implementationtokenization_compliant_llm.py: 256-byte tokenizervocab.json: tokenizer vocabularyinference.py: standalone command-line example
The training pipeline and dataset are intentionally excluded.
