Instructions to use DareModels/MiniCpm5-Agent with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use DareModels/MiniCpm5-Agent with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="DareModels/MiniCpm5-Agent")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("DareModels/MiniCpm5-Agent") model = AutoModelForCausalLM.from_pretrained("DareModels/MiniCpm5-Agent", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use DareModels/MiniCpm5-Agent with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "DareModels/MiniCpm5-Agent" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "DareModels/MiniCpm5-Agent", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/DareModels/MiniCpm5-Agent
- SGLang
How to use DareModels/MiniCpm5-Agent 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 "DareModels/MiniCpm5-Agent" \ --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": "DareModels/MiniCpm5-Agent", "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 "DareModels/MiniCpm5-Agent" \ --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": "DareModels/MiniCpm5-Agent", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use DareModels/MiniCpm5-Agent with Docker Model Runner:
docker model run hf.co/DareModels/MiniCpm5-Agent
Upload folder using huggingface_hub
Browse files- README.md +58 -0
- config.json +35 -0
- generation_config.json +13 -0
- mergekit_config.yml +21 -0
- model.safetensors +3 -0
- tokenizer.json +0 -0
- tokenizer_config.json +17 -0
README.md
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
base_model:
|
| 3 |
+
- ktruestory/minicpm5-1b-hermes-toolhv1
|
| 4 |
+
- saidutta69/MiniCPM5-1B-Claude-Opus-Fable5-V2-Thinking-heretic
|
| 5 |
+
- Healshsj/MiniCPM5-1B-Reasoning-Agent-Ultra
|
| 6 |
+
- hudsongouge/minicpm5-1B-GLM-5.2-Agentic-v9
|
| 7 |
+
- MC7ever/MiniCPM5-1B-Agent-safetensors
|
| 8 |
+
library_name: transformers
|
| 9 |
+
tags:
|
| 10 |
+
- mergekit
|
| 11 |
+
- merge
|
| 12 |
+
|
| 13 |
+
---
|
| 14 |
+
# MiniCPMv2
|
| 15 |
+
|
| 16 |
+
This is a merge of pre-trained language models created using [mergekit](https://github.com/cg123/mergekit).
|
| 17 |
+
|
| 18 |
+
## Merge Details
|
| 19 |
+
### Merge Method
|
| 20 |
+
|
| 21 |
+
This model was merged using the [Model Breadcrumbs with TIES](https://arxiv.org/abs/2312.06795) merge method using [saidutta69/MiniCPM5-1B-Claude-Opus-Fable5-V2-Thinking-heretic](https://huggingface.co/saidutta69/MiniCPM5-1B-Claude-Opus-Fable5-V2-Thinking-heretic) as a base.
|
| 22 |
+
|
| 23 |
+
### Models Merged
|
| 24 |
+
|
| 25 |
+
The following models were included in the merge:
|
| 26 |
+
* [ktruestory/minicpm5-1b-hermes-toolhv1](https://huggingface.co/ktruestory/minicpm5-1b-hermes-toolhv1)
|
| 27 |
+
* [Healshsj/MiniCPM5-1B-Reasoning-Agent-Ultra](https://huggingface.co/Healshsj/MiniCPM5-1B-Reasoning-Agent-Ultra)
|
| 28 |
+
* [hudsongouge/minicpm5-1B-GLM-5.2-Agentic-v9](https://huggingface.co/hudsongouge/minicpm5-1B-GLM-5.2-Agentic-v9)
|
| 29 |
+
* [MC7ever/MiniCPM5-1B-Agent-safetensors](https://huggingface.co/MC7ever/MiniCPM5-1B-Agent-safetensors)
|
| 30 |
+
|
| 31 |
+
### Configuration
|
| 32 |
+
|
| 33 |
+
The following YAML configuration was used to produce this model:
|
| 34 |
+
|
| 35 |
+
```yaml
|
| 36 |
+
merge_method: breadcrumbs_ties
|
| 37 |
+
base_model: saidutta69/MiniCPM5-1B-Claude-Opus-Fable5-V2-Thinking-heretic
|
| 38 |
+
models:
|
| 39 |
+
- model: saidutta69/MiniCPM5-1B-Claude-Opus-Fable5-V2-Thinking-heretic
|
| 40 |
+
- model: ktruestory/minicpm5-1b-hermes-toolhv1
|
| 41 |
+
parameters:
|
| 42 |
+
weight: 1
|
| 43 |
+
density: 0.01
|
| 44 |
+
- model: MC7ever/MiniCPM5-1B-Agent-safetensors
|
| 45 |
+
parameters:
|
| 46 |
+
weight: 0.45
|
| 47 |
+
density: 0.01
|
| 48 |
+
- model: hudsongouge/minicpm5-1B-GLM-5.2-Agentic-v9
|
| 49 |
+
parameters:
|
| 50 |
+
weight: 0.35
|
| 51 |
+
density: 0.01
|
| 52 |
+
- model: Healshsj/MiniCPM5-1B-Reasoning-Agent-Ultra
|
| 53 |
+
parameters:
|
| 54 |
+
weight: 0.2
|
| 55 |
+
density: 0.01
|
| 56 |
+
dtype: bfloat16
|
| 57 |
+
|
| 58 |
+
```
|
config.json
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"LlamaForCausalLM"
|
| 4 |
+
],
|
| 5 |
+
"attention_bias": false,
|
| 6 |
+
"attention_dropout": 0.0,
|
| 7 |
+
"bos_token_id": 0,
|
| 8 |
+
"dtype": "bfloat16",
|
| 9 |
+
"eos_token_id": [
|
| 10 |
+
1,
|
| 11 |
+
130073
|
| 12 |
+
],
|
| 13 |
+
"head_dim": 128,
|
| 14 |
+
"hidden_act": "silu",
|
| 15 |
+
"hidden_size": 1536,
|
| 16 |
+
"initializer_range": 0.02,
|
| 17 |
+
"intermediate_size": 4608,
|
| 18 |
+
"max_position_embeddings": 131072,
|
| 19 |
+
"mlp_bias": false,
|
| 20 |
+
"model_type": "llama",
|
| 21 |
+
"num_attention_heads": 16,
|
| 22 |
+
"num_hidden_layers": 24,
|
| 23 |
+
"num_key_value_heads": 2,
|
| 24 |
+
"pad_token_id": 1,
|
| 25 |
+
"pretraining_tp": 1,
|
| 26 |
+
"rms_norm_eps": 1e-06,
|
| 27 |
+
"rope_parameters": {
|
| 28 |
+
"rope_theta": 5000000,
|
| 29 |
+
"rope_type": "default"
|
| 30 |
+
},
|
| 31 |
+
"tie_word_embeddings": false,
|
| 32 |
+
"transformers_version": "5.12.1",
|
| 33 |
+
"use_cache": true,
|
| 34 |
+
"vocab_size": 130560
|
| 35 |
+
}
|
generation_config.json
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_from_model_config": true,
|
| 3 |
+
"bos_token_id": 0,
|
| 4 |
+
"do_sample": true,
|
| 5 |
+
"eos_token_id": [
|
| 6 |
+
1,
|
| 7 |
+
130073
|
| 8 |
+
],
|
| 9 |
+
"pad_token_id": 1,
|
| 10 |
+
"temperature": 0.9,
|
| 11 |
+
"top_p": 0.95,
|
| 12 |
+
"transformers_version": "5.13.1"
|
| 13 |
+
}
|
mergekit_config.yml
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
merge_method: breadcrumbs_ties
|
| 2 |
+
base_model: saidutta69/MiniCPM5-1B-Claude-Opus-Fable5-V2-Thinking-heretic
|
| 3 |
+
models:
|
| 4 |
+
- model: saidutta69/MiniCPM5-1B-Claude-Opus-Fable5-V2-Thinking-heretic
|
| 5 |
+
- model: ktruestory/minicpm5-1b-hermes-toolhv1
|
| 6 |
+
parameters:
|
| 7 |
+
weight: 1
|
| 8 |
+
density: 0.01
|
| 9 |
+
- model: MC7ever/MiniCPM5-1B-Agent-safetensors
|
| 10 |
+
parameters:
|
| 11 |
+
weight: 0.45
|
| 12 |
+
density: 0.01
|
| 13 |
+
- model: hudsongouge/minicpm5-1B-GLM-5.2-Agentic-v9
|
| 14 |
+
parameters:
|
| 15 |
+
weight: 0.35
|
| 16 |
+
density: 0.01
|
| 17 |
+
- model: Healshsj/MiniCPM5-1B-Reasoning-Agent-Ultra
|
| 18 |
+
parameters:
|
| 19 |
+
weight: 0.2
|
| 20 |
+
density: 0.01
|
| 21 |
+
dtype: bfloat16
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:424a4757012f29324d00a441fc74eb0b1ce7fb023ecf2d2028b109afbf580708
|
| 3 |
+
size 2161290944
|
tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_prefix_space": null,
|
| 3 |
+
"backend": "tokenizers",
|
| 4 |
+
"bos_token": "<s>",
|
| 5 |
+
"clean_up_tokenization_spaces": false,
|
| 6 |
+
"eos_token": "</s>",
|
| 7 |
+
"is_local": false,
|
| 8 |
+
"legacy": true,
|
| 9 |
+
"local_files_only": false,
|
| 10 |
+
"model_max_length": 1000000000000000019884624838656,
|
| 11 |
+
"pad_token": "</s>",
|
| 12 |
+
"sp_model_kwargs": {},
|
| 13 |
+
"spaces_between_special_tokens": false,
|
| 14 |
+
"tokenizer_class": "TokenizersBackend",
|
| 15 |
+
"unk_token": "<unk>",
|
| 16 |
+
"use_default_system_prompt": false
|
| 17 |
+
}
|