v0.41 - 2025-03-22 18:29:56 UTC - retrain-pipelines v0.1.1 - Upload model and tokenizer with README.
Browse files- README.md +125 -52
- adapter_config.json +4 -4
- adapter_model.safetensors +1 -1
- added_tokens.json +0 -1
- runs/cpt/{events.out.tfevents.1736270700.MSI.22100.0 → events.out.tfevents.1742667255.MSI.9607.0} +2 -2
- runs/sft/events.out.tfevents.1742667483.MSI.10041.0 +3 -0
- special_tokens_map.json +1 -1
- tokenizer.json +2 -2
- tokenizer_config.json +4 -10
README.md
CHANGED
@@ -1,15 +1,17 @@
|
|
1 |
---
|
2 |
# @see https://github.com/huggingface/hub-docs/blob/main/modelcard.md
|
3 |
# @see https://huggingface.co/docs/huggingface_hub/guides/model-cards#update-metadata
|
|
|
4 |
|
5 |
-
version: '0.
|
6 |
|
7 |
-
timestamp: '
|
8 |
|
9 |
model_name: retrain-pipelines Function Caller
|
10 |
|
11 |
base_model: unsloth/Qwen2.5-1.5B
|
12 |
-
|
|
|
13 |
datasets:
|
14 |
- retrain-pipelines/func_calls
|
15 |
|
@@ -19,7 +21,7 @@ language:
|
|
19 |
- en
|
20 |
|
21 |
task_categories:
|
22 |
-
-
|
23 |
|
24 |
tags:
|
25 |
- retrain-pipelines
|
@@ -32,76 +34,147 @@ thumbnail: https://cdn-avatars.huggingface.co/v1/production/uploads/651e93137b2a
|
|
32 |
|
33 |
|
34 |
# @see https://huggingface.co/docs/hub/models-widgets#enabling-a-widget
|
|
|
|
|
|
|
35 |
widget:
|
36 |
-
- text:
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
41 |
|
42 |
# @see https://huggingface.co/docs/huggingface_hub/guides/model-cards#include-evaluation-results
|
|
|
43 |
model-index:
|
44 |
- name: retrain-pipelines Function Caller
|
45 |
results:
|
46 |
- task:
|
47 |
-
type:
|
|
|
48 |
dataset:
|
49 |
-
name:
|
50 |
-
type:
|
|
|
|
|
51 |
metrics:
|
52 |
-
- type: jaccard
|
53 |
-
value: 0.82
|
54 |
-
- type: f1
|
55 |
-
value: 0.7633986928104575
|
56 |
- type: precision
|
57 |
-
value: 0.
|
58 |
- type: recall
|
59 |
-
value: 0.
|
|
|
|
|
|
|
|
|
60 |
|
61 |
---
|
62 |
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
71 |
|
72 |
Training dataset :
|
73 |
-
- <code>retrain-pipelines/func_calls v0.
|
74 |
-
(<a href="https://huggingface.co/datasets/retrain-pipelines/func_calls/blob/
|
75 |
-
target="_blank">
|
76 |
-
2025-
|
|
|
|
|
77 |
|
78 |
Base model :
|
79 |
- <code>unsloth/Qwen2.5-1.5B</code>
|
80 |
-
(<a href="https://huggingface.co/unsloth/Qwen2.5-1.5B/blob/
|
81 |
-
target="_blank">
|
82 |
-
|
|
|
|
|
83 |
arxiv :<br />
|
84 |
- <code><a href="https://huggingface.co/papers/2407.10671"
|
85 |
target="_blank">2407.10671</a></code><br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
86 |
<br />
|
87 |
<br />
|
88 |
-
<br />
|
89 |
-
<br />
|
90 |
-
<br />
|
91 |
-
<br />
|
92 |
-
TODO<br />
|
93 |
-
Section on Eval goes here
|
94 |
-
<br />
|
95 |
-
<br />
|
96 |
-
<br />
|
97 |
-
<br />
|
98 |
-
<br />
|
99 |
-
<br />
|
100 |
|
101 |
-
<
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
# @see https://github.com/huggingface/hub-docs/blob/main/modelcard.md
|
3 |
# @see https://huggingface.co/docs/huggingface_hub/guides/model-cards#update-metadata
|
4 |
+
# @see https://huggingface.co/docs/hub/model-cards#model-card-metadata
|
5 |
|
6 |
+
version: '0.41'
|
7 |
|
8 |
+
timestamp: '20250322_182956413_UTC'
|
9 |
|
10 |
model_name: retrain-pipelines Function Caller
|
11 |
|
12 |
base_model: unsloth/Qwen2.5-1.5B
|
13 |
+
base_model_relation: adapter
|
14 |
+
library_name: transformers
|
15 |
datasets:
|
16 |
- retrain-pipelines/func_calls
|
17 |
|
|
|
21 |
- en
|
22 |
|
23 |
task_categories:
|
24 |
+
- text2text-generation
|
25 |
|
26 |
tags:
|
27 |
- retrain-pipelines
|
|
|
34 |
|
35 |
|
36 |
# @see https://huggingface.co/docs/hub/models-widgets#enabling-a-widget
|
37 |
+
# @see https://huggingface.co/docs/hub/models-widgets-examples
|
38 |
+
# @see https://huggingface.co/docs/hub/en/model-cards#specifying-a-task--pipelinetag-
|
39 |
+
pipeline_tag: text2text-generation
|
40 |
widget:
|
41 |
+
- text: >-
|
42 |
+
Hello
|
43 |
+
example_title: No function call
|
44 |
+
output:
|
45 |
+
text: '[]'
|
46 |
+
- text: >-
|
47 |
+
Is 49 a perfect square?
|
48 |
+
example_title: Perfect square
|
49 |
+
output:
|
50 |
+
text: '[{"name": "is_perfect_square", "arguments": {"num": 49}}]'
|
51 |
+
|
52 |
+
mf_run_id: '1787'
|
53 |
|
54 |
# @see https://huggingface.co/docs/huggingface_hub/guides/model-cards#include-evaluation-results
|
55 |
+
# @see https://huggingface.co/docs/huggingface_hub/main/en/package_reference/cards#huggingface_hub.EvalResult
|
56 |
model-index:
|
57 |
- name: retrain-pipelines Function Caller
|
58 |
results:
|
59 |
- task:
|
60 |
+
type: text2text-generation
|
61 |
+
name: Text2Text Generation
|
62 |
dataset:
|
63 |
+
name: retrain-pipelines Function Calling
|
64 |
+
type: retrain-pipelines/func_calls
|
65 |
+
split: validation
|
66 |
+
revision: 498978bb190430e136c6ab96d434c5ec2adf51f8
|
67 |
metrics:
|
|
|
|
|
|
|
|
|
68 |
- type: precision
|
69 |
+
value: 0.0
|
70 |
- type: recall
|
71 |
+
value: 0.0
|
72 |
+
- type: f1
|
73 |
+
value: 0.0
|
74 |
+
- type: jaccard
|
75 |
+
value: 0.0
|
76 |
|
77 |
---
|
78 |
|
79 |
+
<div
|
80 |
+
class="
|
81 |
+
p-6 mb-4 rounded-lg
|
82 |
+
pt-6 sm:pt-9
|
83 |
+
bg-gradient-to-b
|
84 |
+
from-purple-500
|
85 |
+
dark:from-purple-500/20
|
86 |
+
"
|
87 |
+
>
|
88 |
+
<div
|
89 |
+
class="
|
90 |
+
pl-4 rounded-lg
|
91 |
+
border-2 border-gray-100
|
92 |
+
bg-gradient-to-b
|
93 |
+
from-purple-500
|
94 |
+
dark:from-purple-500/20
|
95 |
+
"
|
96 |
+
>
|
97 |
+
<b>retrain-pipelines Function Caller</b>
|
98 |
+
</div>
|
99 |
+
<code>version 0.41</code> - <code>2025-03-22 18:29:56 UTC</code>
|
100 |
+
(retraining
|
101 |
+
<a target="_blank"
|
102 |
+
href="https://huggingface.co/retrain-pipelines/function_caller/tree/retrain-pipelines_source-code/v0.41_20250322_182956413_UTC">source-code</a> |
|
103 |
+
<a target="_blank"
|
104 |
+
href="https://huggingface.co/spaces/retrain-pipelines/online_pipeline_card_renderer/?model_repo_id=retrain-pipelines/function_caller&version_id=v0.41_20250322_182956413_UTC">pipeline-card</a>)
|
105 |
+
</div>
|
106 |
|
107 |
Training dataset :
|
108 |
+
- <code>retrain-pipelines/func_calls v0.47</code>
|
109 |
+
(<a href="https://huggingface.co/datasets/retrain-pipelines/func_calls/blob/498978bb190430e136c6ab96d434c5ec2adf51f8/README.md"
|
110 |
+
target="_blank">498978b</a> -
|
111 |
+
2025-03-22 18:13:14 UTC)
|
112 |
+
<br />
|
113 |
+
<img alt="" src="https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fhuggingface.co%2Fapi%2Fdatasets%2Fretrain-pipelines/func_calls&query=%24.downloads&logo=huggingface&label=downloads" class="inline-block" /> <img alt="" src="https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fhuggingface.co%2Fapi%2Fdatasets%2Fretrain-pipelines/func_calls&query=%24.likes&logo=huggingface&label=likes" class="inline-block" />
|
114 |
|
115 |
Base model :
|
116 |
- <code>unsloth/Qwen2.5-1.5B</code>
|
117 |
+
(<a href="https://huggingface.co/unsloth/Qwen2.5-1.5B/blob/2d0a015faee2c1af360a6725a30c4d7a258ac4d4/README.md"
|
118 |
+
target="_blank">2d0a015</a> -
|
119 |
+
2025-02-06 02:32:14 UTC)
|
120 |
+
<br />
|
121 |
+
<img alt="" src="https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fhuggingface.co%2Fapi%2Fmodels%2Funsloth/Qwen2.5-1.5B&query=%24.downloads&logo=huggingface&label=downloads" class="inline-block" /> <img alt="" src="https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fhuggingface.co%2Fapi%2Fmodels%2Funsloth/Qwen2.5-1.5B&query=%24.likes&logo=huggingface&label=likes" class="inline-block" /><br />
|
122 |
arxiv :<br />
|
123 |
- <code><a href="https://huggingface.co/papers/2407.10671"
|
124 |
target="_blank">2407.10671</a></code><br />
|
125 |
+
The herein LoRa adapter can for instance be used as follows :<br />
|
126 |
+
```python
|
127 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
128 |
+
from torch import device, cuda
|
129 |
+
|
130 |
+
repo_id = "retrain-pipelines/function_caller"
|
131 |
+
revision = "<model_revision_commit_hash>"
|
132 |
+
model = AutoModelForCausalLM.from_pretrained(
|
133 |
+
repo_id, revision=revision, torch_dtype="auto", device_map="auto")
|
134 |
+
tokenizer = AutoTokenizer.from_pretrained(
|
135 |
+
repo_id, revision=revision, torch_dtype="auto", device_map="auto")
|
136 |
+
|
137 |
+
device = device("cuda" if cuda.is_available() else "cpu")
|
138 |
+
def generate_tool_calls_list(query, max_new_tokens=400) -> str:
|
139 |
+
formatted_query = tokenizer.chat_template.format(query, "")
|
140 |
+
inputs = tokenizer(formatted_query, return_tensors="pt").input_ids.to(device)
|
141 |
+
outputs = model.generate(inputs, max_new_tokens=max_new_tokens, do_sample=False)
|
142 |
+
generated_text = tokenizer.batch_decode(outputs, skip_special_tokens=True)[0]
|
143 |
+
return generated_text[len(formatted_query):].strip()
|
144 |
+
|
145 |
+
generate_tool_calls_list("Is 49 a perfect square ?")
|
146 |
+
```
|
147 |
+
|
148 |
<br />
|
149 |
<br />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
150 |
|
151 |
+
<div
|
152 |
+
class="
|
153 |
+
p-6 mb-4 rounded-lg
|
154 |
+
pt-6 sm:pt-9
|
155 |
+
px-4
|
156 |
+
pb-1
|
157 |
+
bg-gradient-to-t
|
158 |
+
from-purple-500
|
159 |
+
dark:from-purple-500/20
|
160 |
+
"
|
161 |
+
>
|
162 |
+
<div
|
163 |
+
class="
|
164 |
+
p-6 mb-4 rounded-lg
|
165 |
+
border-2 border-gray-100
|
166 |
+
pt-6 sm:pt-9
|
167 |
+
bg-gradient-to-t
|
168 |
+
from-purple-500
|
169 |
+
dark:from-purple-500/20
|
170 |
+
"
|
171 |
+
>
|
172 |
+
Powered by
|
173 |
+
<code><a target="_blank"
|
174 |
+
href="https://github.com/aurelienmorgan/retrain-pipelines">retrain-pipelines
|
175 |
+
0.1.1</a></code> -
|
176 |
+
<code>Run by <a target="_blank" href="https://huggingface.co/Aurelien-Morgan-Bot">Aurelien-Morgan-Bot</a></code> -
|
177 |
+
<em><b>UnslothFuncCallFlow</b></em> - mf_run_id : <code>1787</code>
|
178 |
+
</div>
|
179 |
+
</div>
|
180 |
+
|
adapter_config.json
CHANGED
@@ -23,13 +23,13 @@
|
|
23 |
"rank_pattern": {},
|
24 |
"revision": null,
|
25 |
"target_modules": [
|
|
|
26 |
"q_proj",
|
27 |
-
"k_proj",
|
28 |
-
"o_proj",
|
29 |
"gate_proj",
|
30 |
-
"
|
31 |
"v_proj",
|
32 |
-
"down_proj"
|
|
|
33 |
],
|
34 |
"task_type": "CAUSAL_LM",
|
35 |
"use_dora": false,
|
|
|
23 |
"rank_pattern": {},
|
24 |
"revision": null,
|
25 |
"target_modules": [
|
26 |
+
"up_proj",
|
27 |
"q_proj",
|
|
|
|
|
28 |
"gate_proj",
|
29 |
+
"o_proj",
|
30 |
"v_proj",
|
31 |
+
"down_proj",
|
32 |
+
"k_proj"
|
33 |
],
|
34 |
"task_type": "CAUSAL_LM",
|
35 |
"use_dora": false,
|
adapter_model.safetensors
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 2457916480
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:ee7faa4ffe2eeb438b075e4338dfaf364aad215ab0a54bd74b057f3c29de4e19
|
3 |
size 2457916480
|
added_tokens.json
CHANGED
@@ -1,7 +1,6 @@
|
|
1 |
{
|
2 |
"</tool_call>": 151658,
|
3 |
"<tool_call>": 151657,
|
4 |
-
"<|PAD_TOKEN|>": 151665,
|
5 |
"<|box_end|>": 151649,
|
6 |
"<|box_start|>": 151648,
|
7 |
"<|endoftext|>": 151643,
|
|
|
1 |
{
|
2 |
"</tool_call>": 151658,
|
3 |
"<tool_call>": 151657,
|
|
|
4 |
"<|box_end|>": 151649,
|
5 |
"<|box_start|>": 151648,
|
6 |
"<|endoftext|>": 151643,
|
runs/cpt/{events.out.tfevents.1736270700.MSI.22100.0 → events.out.tfevents.1742667255.MSI.9607.0}
RENAMED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b60b3375aab9dde64c36065827c8eab8fd462d4ed4f5acbce52d867fb96dda50
|
3 |
+
size 6351
|
runs/sft/events.out.tfevents.1742667483.MSI.10041.0
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:645658519c807daa593913554297faa77f787fcf2fb841975da0ba8fb8b18e1f
|
3 |
+
size 6349
|
special_tokens_map.json
CHANGED
@@ -22,7 +22,7 @@
|
|
22 |
"single_word": false
|
23 |
},
|
24 |
"pad_token": {
|
25 |
-
"content": "<|
|
26 |
"lstrip": false,
|
27 |
"normalized": false,
|
28 |
"rstrip": false,
|
|
|
22 |
"single_word": false
|
23 |
},
|
24 |
"pad_token": {
|
25 |
+
"content": "<|vision_pad|>",
|
26 |
"lstrip": false,
|
27 |
"normalized": false,
|
28 |
"rstrip": false,
|
tokenizer.json
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
-
size
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:9c5ae00e602b8860cbd784ba82a8aa14e8feecec692e7076590d014d7b7fdafa
|
3 |
+
size 11421896
|
tokenizer_config.json
CHANGED
@@ -177,14 +177,6 @@
|
|
177 |
"rstrip": false,
|
178 |
"single_word": false,
|
179 |
"special": false
|
180 |
-
},
|
181 |
-
"151665": {
|
182 |
-
"content": "<|PAD_TOKEN|>",
|
183 |
-
"lstrip": false,
|
184 |
-
"normalized": false,
|
185 |
-
"rstrip": false,
|
186 |
-
"single_word": false,
|
187 |
-
"special": true
|
188 |
}
|
189 |
},
|
190 |
"additional_special_tokens": [
|
@@ -203,11 +195,13 @@
|
|
203 |
"<|video_pad|>"
|
204 |
],
|
205 |
"bos_token": null,
|
|
|
206 |
"clean_up_tokenization_spaces": false,
|
207 |
"eos_token": "<|endoftext|>",
|
208 |
"errors": "replace",
|
209 |
-
"
|
210 |
-
"
|
|
|
211 |
"padding_side": "left",
|
212 |
"split_special_tokens": false,
|
213 |
"tokenizer_class": "Qwen2Tokenizer",
|
|
|
177 |
"rstrip": false,
|
178 |
"single_word": false,
|
179 |
"special": false
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
180 |
}
|
181 |
},
|
182 |
"additional_special_tokens": [
|
|
|
195 |
"<|video_pad|>"
|
196 |
],
|
197 |
"bos_token": null,
|
198 |
+
"chat_template": "You specialize in generating tool calls. Given a query, your task is to return a list of tool calls based on your knowledge of known tools.\n\nRules:\n1. You can only use tools you know. Do not create new tools under any circumstances.\n2. If a query does not match any known tool, return an empty list ([]).\n3. If information is missing to use a known tool, do not attempt to use it.\n4. Your response must always be a valid JSON array, and nothing else.\n\nBe precise and do not guess.\n\n# query:\n {}\n# response:\n {}",
|
199 |
"clean_up_tokenization_spaces": false,
|
200 |
"eos_token": "<|endoftext|>",
|
201 |
"errors": "replace",
|
202 |
+
"extra_special_tokens": {},
|
203 |
+
"model_max_length": 32768,
|
204 |
+
"pad_token": "<|vision_pad|>",
|
205 |
"padding_side": "left",
|
206 |
"split_special_tokens": false,
|
207 |
"tokenizer_class": "Qwen2Tokenizer",
|