初始化项目,由ModelHub XC社区提供模型
Model: SindreLinden/gemma-3-1b-ifs-cloud-gguf Source: Original Platform
This commit is contained in:
39
.gitattributes
vendored
Normal file
39
.gitattributes
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.arrow filter=lfs diff=lfs merge=lfs -text
|
||||
*.bin filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.ckpt filter=lfs diff=lfs merge=lfs -text
|
||||
*.ftz filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.h5 filter=lfs diff=lfs merge=lfs -text
|
||||
*.joblib filter=lfs diff=lfs merge=lfs -text
|
||||
*.lfs.* filter=lfs diff=lfs merge=lfs -text
|
||||
*.mlmodel filter=lfs diff=lfs merge=lfs -text
|
||||
*.model filter=lfs diff=lfs merge=lfs -text
|
||||
*.msgpack filter=lfs diff=lfs merge=lfs -text
|
||||
*.npy filter=lfs diff=lfs merge=lfs -text
|
||||
*.npz filter=lfs diff=lfs merge=lfs -text
|
||||
*.onnx filter=lfs diff=lfs merge=lfs -text
|
||||
*.ot filter=lfs diff=lfs merge=lfs -text
|
||||
*.parquet filter=lfs diff=lfs merge=lfs -text
|
||||
*.pb filter=lfs diff=lfs merge=lfs -text
|
||||
*.pickle filter=lfs diff=lfs merge=lfs -text
|
||||
*.pkl filter=lfs diff=lfs merge=lfs -text
|
||||
*.pt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pth filter=lfs diff=lfs merge=lfs -text
|
||||
*.rar filter=lfs diff=lfs merge=lfs -text
|
||||
*.safetensors filter=lfs diff=lfs merge=lfs -text
|
||||
saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
||||
*.tar.* filter=lfs diff=lfs merge=lfs -text
|
||||
*.tar filter=lfs diff=lfs merge=lfs -text
|
||||
*.tflite filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.wasm filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
||||
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
||||
model.gguf filter=lfs diff=lfs merge=lfs -text
|
||||
gemma-3-1b-ifs-cloud-gguf-F16.gguf filter=lfs diff=lfs merge=lfs -text
|
||||
gemma-3-1b-ifs-cloud-gguf-BF16.gguf filter=lfs diff=lfs merge=lfs -text
|
||||
gemma-3-1b-ifs-cloud-gguf-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
|
||||
90
README.md
Normal file
90
README.md
Normal file
@@ -0,0 +1,90 @@
|
||||
---
|
||||
license: gemma
|
||||
base_model: google/gemma-3-1b-it
|
||||
tags:
|
||||
- fine-tuned
|
||||
- gguf
|
||||
- gemma
|
||||
- instruct
|
||||
- 1b
|
||||
model_type: gemma3
|
||||
quantized: f16
|
||||
datasets:
|
||||
- custom
|
||||
language:
|
||||
- en
|
||||
pipeline_tag: text-generation
|
||||
---
|
||||
|
||||
# Fine-tuned Gemma 3 1B IT (GGUF)
|
||||
|
||||
This is a fine-tuned version of Google's Gemma 3 1B IT model, converted to GGUF format for efficient inference.
|
||||
|
||||
## Model Details
|
||||
|
||||
- **Base Model**: google/gemma-3-1b-it
|
||||
- **Fine-tuning Method**: QLoRA (Quantized Low-Rank Adaptation)
|
||||
- **Format**: GGUF (F16 precision)
|
||||
- **Size**: ~1.9GB
|
||||
|
||||
## Training Details
|
||||
|
||||
- **Adapter**: QLoRA with rank 32, alpha 16
|
||||
- **Target Modules**: up_proj, down_proj, gate_proj, q_proj, k_proj, v_proj, o_proj
|
||||
- **Sequence Length**: 2048
|
||||
- **Training Data**: Custom dataset with sample packing
|
||||
- **Epochs**: 3
|
||||
- **Learning Rate**: 0.0004 with cosine scheduler
|
||||
- **Optimizer**: AdamW BNB 8-bit
|
||||
|
||||
## Usage
|
||||
|
||||
This GGUF model can be used with various inference engines:
|
||||
|
||||
### llama.cpp
|
||||
```bash
|
||||
./llama-server -m model.gguf
|
||||
```
|
||||
|
||||
### Ollama
|
||||
```bash
|
||||
# Create a Modelfile
|
||||
FROM model.gguf
|
||||
TEMPLATE """<start_of_turn>user
|
||||
{{ .Prompt }}<end_of_turn>
|
||||
<start_of_turn>model
|
||||
"""
|
||||
|
||||
# Import the model
|
||||
ollama create my-gemma-model -f Modelfile
|
||||
ollama run my-gemma-model
|
||||
```
|
||||
|
||||
### Python with llama-cpp-python
|
||||
```python
|
||||
from llama_cpp import Llama
|
||||
|
||||
llm = Llama(model_path="model.gguf")
|
||||
output = llm("Tell me about artificial intelligence", max_tokens=512)
|
||||
print(output)
|
||||
```
|
||||
|
||||
## Chat Template
|
||||
|
||||
This model uses Gemma 3's chat template:
|
||||
```
|
||||
<start_of_turn>user
|
||||
{user_message}<end_of_turn>
|
||||
<start_of_turn>model
|
||||
{assistant_response}<end_of_turn>
|
||||
```
|
||||
|
||||
## Limitations
|
||||
|
||||
- This is a small 1B parameter model with inherent limitations
|
||||
- Fine-tuned for specific use cases - performance may vary on other tasks
|
||||
- GGUF conversion may introduce minor numerical differences compared to the original model
|
||||
|
||||
## License
|
||||
|
||||
This model inherits the license from the base Gemma model. Please refer to Google's Gemma license for usage terms.
|
||||
62
config.json
Normal file
62
config.json
Normal file
@@ -0,0 +1,62 @@
|
||||
{
|
||||
"_sliding_window_pattern": 6,
|
||||
"architectures": [
|
||||
"Gemma3ForCausalLM"
|
||||
],
|
||||
"attention_bias": false,
|
||||
"attention_dropout": 0.0,
|
||||
"attn_logit_softcapping": null,
|
||||
"bos_token_id": 2,
|
||||
"cache_implementation": "hybrid",
|
||||
"eos_token_id": 106,
|
||||
"final_logit_softcapping": null,
|
||||
"head_dim": 256,
|
||||
"hidden_activation": "gelu_pytorch_tanh",
|
||||
"hidden_size": 1152,
|
||||
"initializer_range": 0.02,
|
||||
"intermediate_size": 6912,
|
||||
"layer_types": [
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"full_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"full_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"full_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention",
|
||||
"full_attention",
|
||||
"sliding_attention",
|
||||
"sliding_attention"
|
||||
],
|
||||
"max_position_embeddings": 32768,
|
||||
"model_type": "gemma3_text",
|
||||
"num_attention_heads": 4,
|
||||
"num_hidden_layers": 26,
|
||||
"num_key_value_heads": 1,
|
||||
"pad_token_id": 0,
|
||||
"query_pre_attn_scalar": 256,
|
||||
"rms_norm_eps": 1e-06,
|
||||
"rope_local_base_freq": 10000,
|
||||
"rope_scaling": null,
|
||||
"rope_theta": 1000000,
|
||||
"sliding_window": 512,
|
||||
"torch_dtype": "bfloat16",
|
||||
"transformers_version": "4.55.2",
|
||||
"use_cache": true,
|
||||
"vocab_size": 262145
|
||||
}
|
||||
3
gemma-3-1b-ifs-cloud-gguf-BF16.gguf
Normal file
3
gemma-3-1b-ifs-cloud-gguf-BF16.gguf
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:3ee3eee65110575b2c64e7ab7bd9a40971355518611ac6744b1708a6e229daeb
|
||||
size 2006575520
|
||||
3
gemma-3-1b-ifs-cloud-gguf-F16.gguf
Normal file
3
gemma-3-1b-ifs-cloud-gguf-F16.gguf
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:dcf82da57b2575d7da7ffb65962ca820dc8d3e51b32b5698b619eddf4a0a86cd
|
||||
size 2006575520
|
||||
3
gemma-3-1b-ifs-cloud-gguf-Q8_0.gguf
Normal file
3
gemma-3-1b-ifs-cloud-gguf-Q8_0.gguf
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:ab936059916225ab0d2ab8ecf9ad3ac43ebcaf159bdcbf4c13c4f9c8ad30bcb0
|
||||
size 1069307264
|
||||
Reference in New Issue
Block a user