Views
No views yet

gemma-4-E2B-it-Uncensored-MAX is an optimized release built on top of huihui-ai/Huihui-gemma-4-E2B-it-abliterated. This version focuses on updated shard sizing, repository optimization, and compatibility improvements for the latest Transformers releases, while preserving the efficiency and instruction-following capabilities of the original Gemma E2B architecture. The result is a lightweight E2B parameter language model designed for fast inference, stable deployment, and modern ecosystem integration.
[!IMPORTANT] This model is intended for research and learning purposes only. Any content generated by this model is used at the user's own risk. The authors and hosting page disclaim any liability for outputs produced by this model. Users are responsible for ensuring safe, ethical, and lawful usage.
1pip install transformers==5.5.3
2# or
3pip install git+https://github.com/huggingface/transformers.git1from transformers import Gemma4ForConditionalGeneration, AutoProcessor
2import torch
3
4model = Gemma4ForConditionalGeneration.from_pretrained(
5 "prithivMLmods/gemma-4-E2B-it-Uncensored-MAX",
6 torch_dtype="auto",
7 device_map="auto"
8)
9
10processor = AutoProcessor.from_pretrained(
11 "prithivMLmods/gemma-4-E2B-it-Uncensored-MAX"
12)
13
14messages = [
15 {
16 "role": "user",
17 "content": [
18 {"type": "text", "text": "Explain how transformer models work in simple terms."}
19 ],
20 }
21]
22
23text = processor.apply_chat_template(
24 messages,
25 tokenize=False,
26 add_generation_prompt=True
27)
28
29inputs = processor(
30 text=[text],
31 padding=True,
32 return_tensors="pt"
33).to("cuda")
34
35generated_ids = model.generate(**inputs, max_new_tokens=256)
36
37generated_ids_trimmed = [
38 out_ids[len(in_ids):] for in_ids, out_ids in zip(inputs.input_ids, generated_ids)
39]
40
41output_text = processor.batch_decode(
42 generated_ids_trimmed,
43 skip_special_tokens=True,
44 clean_up_tokenization_spaces=False
45)
46
47print(output_text)Important Note: This model inherits the behavior and limitations of its base architecture.