Instructions to use fahd9999/humanizer-peft-fixed with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use fahd9999/humanizer-peft-fixed with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("google/gemma-3-4b-it") model = PeftModel.from_pretrained(base_model, "fahd9999/humanizer-peft-fixed") - Transformers
How to use fahd9999/humanizer-peft-fixed with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="fahd9999/humanizer-peft-fixed")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("fahd9999/humanizer-peft-fixed", dtype="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use fahd9999/humanizer-peft-fixed with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "fahd9999/humanizer-peft-fixed" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "fahd9999/humanizer-peft-fixed", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/fahd9999/humanizer-peft-fixed
- SGLang
How to use fahd9999/humanizer-peft-fixed with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "fahd9999/humanizer-peft-fixed" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "fahd9999/humanizer-peft-fixed", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "fahd9999/humanizer-peft-fixed" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "fahd9999/humanizer-peft-fixed", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use fahd9999/humanizer-peft-fixed with Docker Model Runner:
docker model run hf.co/fahd9999/humanizer-peft-fixed
Upload folder using huggingface_hub
Browse files- adapter_config.json +15 -44
adapter_config.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
| 1 |
{
|
| 2 |
-
"
|
| 3 |
-
"
|
| 4 |
-
"
|
| 5 |
-
"
|
| 6 |
-
"
|
| 7 |
"bias": "none",
|
| 8 |
-
"
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
"layers_to_transform": [
|
| 18 |
26,
|
| 19 |
27,
|
|
@@ -24,34 +24,5 @@
|
|
| 24 |
32,
|
| 25 |
33
|
| 26 |
],
|
| 27 |
-
"
|
| 28 |
-
"lora_alpha": 16,
|
| 29 |
-
"lora_bias": false,
|
| 30 |
-
"lora_dropout": 0.0,
|
| 31 |
-
"lora_ga_config": null,
|
| 32 |
-
"megatron_config": null,
|
| 33 |
-
"megatron_core": "megatron.core",
|
| 34 |
-
"modules_to_save": null,
|
| 35 |
-
"peft_type": "LORA",
|
| 36 |
-
"peft_version": "0.19.1",
|
| 37 |
-
"qalora_group_size": 16,
|
| 38 |
-
"r": 8,
|
| 39 |
-
"rank_pattern": {},
|
| 40 |
-
"revision": null,
|
| 41 |
-
"target_modules": [
|
| 42 |
-
"o_proj",
|
| 43 |
-
"up_proj",
|
| 44 |
-
"gate_proj",
|
| 45 |
-
"k_proj",
|
| 46 |
-
"q_proj",
|
| 47 |
-
"down_proj",
|
| 48 |
-
"v_proj"
|
| 49 |
-
],
|
| 50 |
-
"target_parameters": null,
|
| 51 |
-
"task_type": "CAUSAL_LM",
|
| 52 |
-
"trainable_token_indices": null,
|
| 53 |
-
"use_bdlora": null,
|
| 54 |
-
"use_dora": false,
|
| 55 |
-
"use_qalora": false,
|
| 56 |
-
"use_rslora": false
|
| 57 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"peft_type": "LORA",
|
| 3 |
+
"task_type": "CAUSAL_LM",
|
| 4 |
+
"r": 8,
|
| 5 |
+
"lora_alpha": 16,
|
| 6 |
+
"lora_dropout": 0.0,
|
| 7 |
"bias": "none",
|
| 8 |
+
"target_modules": [
|
| 9 |
+
"q_proj",
|
| 10 |
+
"k_proj",
|
| 11 |
+
"v_proj",
|
| 12 |
+
"o_proj",
|
| 13 |
+
"gate_proj",
|
| 14 |
+
"up_proj",
|
| 15 |
+
"down_proj"
|
| 16 |
+
],
|
| 17 |
"layers_to_transform": [
|
| 18 |
26,
|
| 19 |
27,
|
|
|
|
| 24 |
32,
|
| 25 |
33
|
| 26 |
],
|
| 27 |
+
"base_model_name_or_path": "google/gemma-3-4b-it"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 28 |
}
|