prithivMLmods commited on
Commit
69dcda7
·
verified ·
1 Parent(s): b534442

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +44 -32
README.md CHANGED
@@ -23,24 +23,44 @@ tags:
23
 
24
  # **Qwen3-VL-4B-Instruct-Unredacted-MAX**
25
 
26
- > **Qwen3-VL-4B-Instruct-Unredacted-MAX** is an unredacted evolution built on top of **Qwen3-VL-4B-Instruct**. This model applies advanced abliterated training strategies designed to minimize internal refusal behaviors while preserving the core multimodal reasoning strengths of the original architecture. The result is a highly capable 4B vision-language model optimized for unrestricted, detailed reasoning and captioning across complex visual inputs.
27
 
28
  ## Key Highlights
29
 
30
- * **Unredacted MAX Training**: Fine-tuned to significantly reduce refusal patterns and improve instruction adherence across diverse prompts.
31
- * **4B Parameter Architecture**: Built on top of Qwen3-VL-4B-Instruct, balancing strong reasoning performance with more efficient hardware requirements compared to larger 8B variants.
32
- * **Unrestricted Multimodal Reasoning**: Designed for deep analysis of artistic, forensic, technical, or abstract visual content without standard safety-driven refusals.
33
- * **High-Fidelity Captions**: Produces dense, descriptive outputs suitable for dataset generation, metadata enrichment, or accessibility use cases.
34
- * **Dynamic Resolution Support**: Retains Qwen3-VL’s ability to process varying image resolutions and aspect ratios effectively.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
 
36
  ## Quick Start with Transformers
37
 
38
- ```python
39
  from transformers import Qwen3VLForConditionalGeneration, AutoProcessor
40
  from qwen_vl_utils import process_vision_info
41
  import torch
42
 
43
- # Load the 4B Unredacted MAX model
44
  model = Qwen3VLForConditionalGeneration.from_pretrained(
45
  "prithivMLmods/Qwen3-VL-4B-Instruct-Unredacted-MAX",
46
  torch_dtype="auto",
@@ -59,7 +79,7 @@ messages = [
59
  "type": "image",
60
  "image": "https://qianwen-res.oss-cn-beijing.aliyuncs.com/Qwen-VL/assets/demo.jpeg",
61
  },
62
- {"type": "text", "text": "Provide a detailed caption and reasoning for this image."},
63
  ],
64
  }
65
  ]
@@ -80,12 +100,8 @@ inputs = processor(
80
 
81
  generated_ids = model.generate(**inputs, max_new_tokens=256)
82
 
83
- generated_ids_trimmed = [
84
- out_ids[len(in_ids):] for in_ids, out_ids in zip(inputs.input_ids, generated_ids)
85
- ]
86
-
87
  output_text = processor.batch_decode(
88
- generated_ids_trimmed,
89
  skip_special_tokens=True,
90
  clean_up_tokenization_spaces=False
91
  )
@@ -93,27 +109,23 @@ output_text = processor.batch_decode(
93
  print(output_text)
94
  ```
95
 
96
- ## Intended Use
97
-
98
- * **Advanced Red-Teaming**: Evaluating multimodal robustness and probing behavioral edge cases.
99
- * **Complex Data Archiving**: Generating detailed captions for medical, artistic, historical, or research datasets.
100
- * **Refusal Mechanism Research**: Studying behavioral shifts in vision-language models after abliterated fine-tuning.
101
- * **Creative Storytelling**: Producing detailed visual descriptions for narrative and world-building projects.
102
 
103
- ## Limitations & Risks
104
 
105
- > **Critical Note**: This model is designed to minimize built-in refusal mechanisms.
 
 
 
 
106
 
107
- * **Sensitive Content Exposure**: The model may generate explicit or controversial descriptions if prompted accordingly.
108
- * **User Responsibility**: Generated outputs must be handled responsibly and used within ethical and legal boundaries.
109
- * **Hardware Requirements**: While lighter than 8B models, the 4B architecture still requires adequate VRAM for high-resolution image processing and longer generations.
110
 
111
- ## Acknowledgements
112
 
113
- I would like to thank the works of the following:
114
 
115
- * Uncensor any LLM with abliteration [Maxime Labonne](https://huggingface.co/mlabonne)
116
- * Using FP8 and FP4 with Transformer Engine [docs.nvidia](https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/examples/fp8_primer.html)
117
- * Remove Refusals with Transformers [Sumandora](https://github.com/Sumandora/remove-refusals-with-transformers)
118
- * LLM Compressor [vllm-project](https://github.com/vllm-project/llm-compressor)
119
- * FP8 Floating-Point 8: An Introduction to Efficient, Lower-Precision AI Training – [nvidia](https://developer.nvidia.com/blog/floating-point-8-an-introduction-to-efficient-lower-precision-ai-training/)
 
23
 
24
  # **Qwen3-VL-4B-Instruct-Unredacted-MAX**
25
 
26
+ > **Qwen3-VL-4B-Instruct-Unredacted-MAX** is an optimized release built on top of **huihui-ai/Qwen3-VL-4B-Instruct-abliterated**. This version focuses on **improved packaging, updated Transformers compatibility, and stable multimodal inference behavior**, while preserving the core vision-language reasoning capabilities of the original architecture. The result is a capable **4B vision-language model** designed for efficient deployment, research experimentation, and multimodal application development.
27
 
28
  ## Key Highlights
29
 
30
+ * **Optimized Release Packaging**
31
+ Streamlined repository structure for smoother loading, inference, and deployment workflows.
32
+
33
+ * **Modern Transformers Compatibility**
34
+ Updated for stable integration with recent Hugging Face Transformers ecosystems.
35
+
36
+ * **4B Vision-Language Architecture**
37
+ Built on **Qwen3-VL-4B-Instruct**, balancing multimodal capability with relatively low compute requirements.
38
+
39
+ * **Stable Multimodal Inference**
40
+ Designed for consistent performance across image-text reasoning tasks.
41
+
42
+ * **Efficient Caption Generation**
43
+ Produces structured and descriptive outputs suitable for annotation pipelines and dataset creation.
44
+
45
+ * **Dynamic Resolution Support**
46
+ Retains native support for varying image resolutions and aspect ratios.
47
+
48
+ ---
49
+
50
+ ## Base Model Signatures:
51
+
52
+ This model has been re-sharded and optimized for the latest Transformers version from the base model:
53
+ https://huggingface.co/huihui-ai/Qwen3-VL-4B-Instruct-abliterated
54
+
55
+ ---
56
 
57
  ## Quick Start with Transformers
58
 
59
+ ```python id="vl4b_code"
60
  from transformers import Qwen3VLForConditionalGeneration, AutoProcessor
61
  from qwen_vl_utils import process_vision_info
62
  import torch
63
 
 
64
  model = Qwen3VLForConditionalGeneration.from_pretrained(
65
  "prithivMLmods/Qwen3-VL-4B-Instruct-Unredacted-MAX",
66
  torch_dtype="auto",
 
79
  "type": "image",
80
  "image": "https://qianwen-res.oss-cn-beijing.aliyuncs.com/Qwen-VL/assets/demo.jpeg",
81
  },
82
+ {"type": "text", "text": "Provide a detailed caption for this image."},
83
  ],
84
  }
85
  ]
 
100
 
101
  generated_ids = model.generate(**inputs, max_new_tokens=256)
102
 
 
 
 
 
103
  output_text = processor.batch_decode(
104
+ [out[len(inp):] for inp, out in zip(inputs.input_ids, generated_ids)],
105
  skip_special_tokens=True,
106
  clean_up_tokenization_spaces=False
107
  )
 
109
  print(output_text)
110
  ```
111
 
112
+ ---
 
 
 
 
 
113
 
114
+ ## Intended Use
115
 
116
+ * Multimodal AI research and evaluation
117
+ * Vision-language dataset generation and annotation
118
+ * Lightweight deployment on consumer GPUs
119
+ * Prototyping multimodal applications and tools
120
+ * Robustness testing and model benchmarking
121
 
122
+ ---
 
 
123
 
124
+ ## Limitations & Risks
125
 
126
+ > **Important Note**: This model inherits limitations from its base architecture.
127
 
128
+ * Output quality depends on image clarity and prompt design
129
+ * May produce incomplete or inaccurate interpretations in complex scenarios
130
+ * Requires sufficient VRAM for stable inference
131
+ * Performance varies with decoding strategy and runtime optimizations