Datasets:
Publish CapySFT 500M, 1B and 2B using four shared shards
Browse filesFiles changed (9)
- LICENSE.mdAdded+35
- README.mdAdded+197
- data/train-00000-of-00004.jsonl.gzAdded+3
- data/train-00001-of-00004.jsonl.gzAdded+3
- data/train-00002-of-00004.jsonl.gzAdded+3
- data/train-00003-of-00004.jsonl.gzAdded+3
- release-manifest.jsonAdded+357
- tokenizer/tokenizer.jsonAdded
- tokenizer/tokenizer_config.jsonAdded+305
1234567891011121314151617181920212223242526272829303132333435# Upstream licenses and attribution
CapySFT is derived from multiple sources. This notice does not replacetheir licenses or grant broader rights to their contents.
- **Tulu 3 SFT Mixture**: https://huggingface.co/datasets/allenai/tulu-3-sft-mixture identifies its collection license as Open Data Commons Attribution 1.0 (https://opendatacommons.org/licenses/by/1-0/). Its card states that component licenses differ and some portions are non-commercial. For example, No Robots is identified as CC-BY-NC-4.0. Follow the component links and attribution/citation requirements in the upstream card.- **SmolTalk**: https://huggingface.co/datasets/HuggingFaceTB/smoltalk licenses the newly generated Smol-Magpie-Ultra, Smol-constraints, Smol-rewrite, and Smol-summarize datasets under Apache 2.0 (https://www.apache.org/licenses/LICENSE-2.0). Its existing public components retain their original licenses, linked from the upstream dataset-composition table.- Assistant responses were generated with **DeepSeek-V4-Flash-0731**. Source prompt and model-output conditions remain applicable to their respective material.- The included **Qwen3.5-32K tokenizer** is derived from the Qwen3.5 tokenizer by retaining the first 32,768 base token IDs and remapping 33 special tokens. Qwen3.5 provenance is separate from the data mixture.
Each record retains `dataset_origin` and `source` labels. The release manifestenumerates the labels present in this release. Regenerated responses aremodifications to the source conversations, and do not imply that theupstream datasets endorse this release. No blanket Apache, MIT, or othersingle permissive license is applied to the complete mixture here.
Upstream license statements were checked on 2026-11-10 against dataset-cardrevisions `b14afda60f1bbebe55d5d2fa1e4df5042f97f8be` (Tulu 3) and`5feaf2fd3ffca7c237fc38d1861bc30365d48ffa` (SmolTalk). These are therevisions inspected for this notice, not asserted download revisions of theoriginal generation inputs.123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197---pretty_name: CapySFTtask_categories:- text-generationsize_categories:- 100K<n<1Mtags:- sft- reasoning- tool-use- syntheticsource_datasets:- allenai/tulu-3-sft-mixture- HuggingFaceTB/smoltalkconfigs:- config_name: 500M data_files: - split: train path: data/train-00000-of-00004.jsonl.gz- config_name: 1B default: true data_files: - split: train path: - data/train-00000-of-00004.jsonl.gz - data/train-00001-of-00004.jsonl.gz- config_name: 2B data_files: - split: train path: data/train-*.jsonl.gz---
# CapySFT
CapySFT is a dataset for supervised fine tuning of assistants that can reason,answer questions, and use terminal tools. User requests come from Tulu 3 andSmolTalk. New assistant responses were generated with DeepSeek-V4-Flash-0731.
## Dataset sizes
Choose `500M`, `1B`, or `2B` supervised response tokens. Token counts useour LLM course's truncated Qwen3.5 tokenizer (32,768 base tokens plus 33special tokens), included under `tokenizer/`. Counts vary with the tokenizerand chat formatting.
| Configuration | Source conversations | Training records | Supervised response tokens | Files || --- | ---: | ---: | ---: | ---: || `500M` | 199,455 | 217,998 | 500,024,135 | first 1 || `1B` (default) | 399,746 | 436,342 | 1,000,019,252 | first 2 || `2B` | 785,488 | 862,479 | 1,999,896,726 | all 4 |
The configurations share four compressed JSONL files, each with approximately500 million supervised response tokens. Smaller configurations are subsetsof the larger ones. Related records from the same source conversation stayin one file. Each configuration contains only a `train` split.
One record is a complete training segment. Long source conversations canproduce several records when their history is summarized and generationcontinues. Retained segments are not truncated and fit within 16,384 tokens.Supervised counts include selected assistant reasoning, answers, tool calls,summaries, and the end marker of each selected message. Context messages andtool results do not contribute to these counts.
## Load with Hugging Face
Use the standard `datasets` interface:
~~~pythonfrom datasets import load_dataset
data = load_dataset("vfleaking/capysft", "1B", split="train", token=True)example = data[0]print(example["messages"])print(example["supervised_message_indices"])~~~
Change `"1B"` to `"500M"` or `"2B"` to choose a size. Add `streaming=True`to iterate without building a complete local Arrow cache. While therepository is private, log in with an account that has access.
## Record format
The three fields needed for training are:
| Field | Type | Meaning || --- | --- | --- || `messages` | list of message dictionaries | All messages in conversation order, including those used only as context. || `tools` | JSON string or null | Available tool definitions. Decode with `json.loads` before applying a chat template. || `supervised_message_indices` | list of integers | Indices into `messages` identifying assistant messages to supervise. |
Messages have `role` and `content`, and may have `reasoning_content`,`tool_calls`, or `tool_call_id`. Each tool call has `id`, `type`, and`function`. Its `function.arguments` field is a JSON string.Missing optional message fields load as `None`. Remove only those nullfields, preserving empty strings and lists:
~~~pythonimport copyimport json
messages = [ {key: value for key, value in message.items() if value is not None} for message in copy.deepcopy(example["messages"])]for message in messages: for call in message.get("tool_calls", []): call["function"]["arguments"] = json.loads(call["function"]["arguments"])tools = json.loads(example["tools"]) if example["tools"] is not None else None~~~
Each row also has `id`, a unique record identifier, and `conversation_id`,shared by records from the same source conversation. Group by`conversation_id` when making a validation split to keep related recordstogether.
The `metadata` dictionary retains source, generation, segmentation, andtoken statistics:
| Metadata field | Meaning || --- | --- || `source` | Prompt mixture: `tulu3` or `smoltalk`. || `subset` | Original subset label within the mixture. || `original_global_index` | Source conversation's index in the prepared prompt collection. || `original_conversation_id` | Original generation identifier, retained for tracing a record to its source. || `generation_status` | Recorded generation outcome. Completed segments are retained even when later generation did not complete. || `segment_index` | Segment order within the source conversation. || `segment_type` | `initial`, `compaction` (summary generation), or `continuation` (generation after a summary). || `segment_end_reason` | Recorded reason this segment ended. || `generated_responses` | Number of newly generated assistant messages; equals the length of `supervised_message_indices`. || `response_tokens` | Number of supervised response tokens. || `full_tokens` | Number of input tokens, including context and the final message's end marker. |
Other source metadata, when present, is also retained.
## Tokenization and supervision
The supplied chat template preserves reasoning on every assistant turn.After preparing `messages` and `tools` as above, render and tokenize with:
~~~pythonfrom transformers import AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained( "vfleaking/capysft", subfolder="tokenizer", token=True)text = tokenizer.apply_chat_template( messages, tools=tools, tokenize=False, add_generation_prompt=False)text = text.removesuffix("\n")tokens = tokenizer.encode(text, add_special_tokens=False)~~~
Supervise only assistant messages selected by `supervised_message_indices`.For each selected message, include its opening `<think>`, reasoning,closing `</think>`, answer or complete tool call, and closing `<|im_end|>`.Include newlines within that body. Mask the assistant role header,the newline after its end marker, all other messages, and padding.
Earlier assistant messages can be context only. For example, a generatedsummary is supervised when first produced, then appears as masked historyin a later record. Keep these earlier messages as input.
The final `<|im_end|>` ends the segment. Remove only the following templatenewline and do not append another end token. When packing records together,keep attention and target shifting within each record.
## How the data was generated
We used a small agent harness developed for our LLM course assignments,which we call MiniCapyCode. It runs the conversation loop between the modeland a sandboxed Linux environment. The model may use bash, read, edit, andwrite tools, receive their results, and continue its response. Tool use isoptional.
Generation used thinking enabled, low reasoning effort, `temperature=1`,and `top_p=1`. Later user questions could be rewritten in conversation context.When a conversation approached the context limit, the harness could askthe model to summarize its history and continue from that summary.Summary requests and responses are included as separate training records.
The generated responses can contain errors. Some source conversations endedbefore all turns completed, but their completed training segments areretained. There is no validation or test split, and the data has not beenchecked for overlap with every benchmark.
## Sources and terms
The source prompts come from[Tulu 3 SFT Mixture](https://huggingface.co/datasets/allenai/tulu-3-sft-mixture)and [SmolTalk](https://huggingface.co/datasets/HuggingFaceTB/smoltalk).Each record retains the source and subset labels in `metadata`.
Upstream terms differ by subset, and some Tulu 3 subsets restrict commercialuse. Regenerating responses does not remove conditions on the sourceprompts. See [LICENSE.md](LICENSE.md) and the upstream dataset cards forlicenses, attribution, and terms governing generated outputs. No singlepermissive license is asserted for the entire mixture.123version https://git-lfs.github.com/spec/v1oid sha256:097939079e712994ffd599bc79a28c5d727479c5cea3d76f36de11d0574575a3size 1017188186123version https://git-lfs.github.com/spec/v1oid sha256:c3f7bd0ae569da44796785b777e84b36b848136e33a4a51ef5b8e61b72c23660size 1013511728123version https://git-lfs.github.com/spec/v1oid sha256:ff6ac95bb443b2a64952199f2631a332943494d479f5babefb754bfc3d8cc16fsize 1019335630123version https://git-lfs.github.com/spec/v1oid sha256:a483141be7aa2b2727d2c020d27be3c835cb778c3c25a11be6ad9151e44d8d01size 1026156194123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357{ "dataset_name": "capysft", "version": "1.3", "status": "complete", "format": "course-sft-jsonl-gzip", "record_fields": [ "id", "conversation_id", "messages", "tools", "supervised_message_indices", "metadata" ], "tools_encoding": "JSON string or null", "tool_arguments_encoding": "JSON string", "configurations": { "500M": { "source_conversations": 199455, "segments": 217998, "response_tokens": 500024135, "full_tokens": 919367388, "compaction_response_tokens": 15745067, "files": [ "data/train-00000-of-00004.jsonl.gz" ] }, "1B": { "source_conversations": 399746, "segments": 436342, "response_tokens": 1000019252, "full_tokens": 1834551029, "compaction_response_tokens": 30893393, "files": [ "data/train-00000-of-00004.jsonl.gz", "data/train-00001-of-00004.jsonl.gz" ] }, "2B": { "source_conversations": 785488, "segments": 862479, "response_tokens": 1999896726, "full_tokens": 3686627495, "compaction_response_tokens": 65008945, "files": [ "data/train-00000-of-00004.jsonl.gz", "data/train-00001-of-00004.jsonl.gz", "data/train-00002-of-00004.jsonl.gz", "data/train-00003-of-00004.jsonl.gz" ] } }, "canonical_shards": [ { "file": "data/train-00000-of-00004.jsonl.gz", "bytes": 1017188186, "sha256": "097939079e712994ffd599bc79a28c5d727479c5cea3d76f36de11d0574575a3", "source_conversations": 199455, "segments": 217998, "response_tokens": 500024135, "full_tokens": 919367388 }, { "file": "data/train-00001-of-00004.jsonl.gz", "bytes": 1013511728, "sha256": "c3f7bd0ae569da44796785b777e84b36b848136e33a4a51ef5b8e61b72c23660", "source_conversations": 200291, "segments": 218344, "response_tokens": 499995117, "full_tokens": 915183641 }, { "file": "data/train-00002-of-00004.jsonl.gz", "bytes": 1019335630, "sha256": "ff6ac95bb443b2a64952199f2631a332943494d479f5babefb754bfc3d8cc16f", "source_conversations": 192723, "segments": 212748, "response_tokens": 498506594, "full_tokens": 922709858 }, { "file": "data/train-00003-of-00004.jsonl.gz", "bytes": 1026156194, "sha256": "a483141be7aa2b2727d2c020d27be3c835cb778c3c25a11be6ad9151e44d8d01", "source_conversations": 193019, "segments": 213389, "response_tokens": 501370880, "full_tokens": 929366608 } ], "tokenizer_identity": { "name": "Qwen3.5-32K", "native_template_sha256": "a4aee8afcf2e0711942cf848899be66016f8d14a889ff9ede07bca099c28f715", "counting_template_sha256": "cbad793417178000a8145de58db885ecf45a8f8380393dbbf24373b52f046ddc", "preserve_all_thinking": true, "add_generation_prompt": true, "enable_thinking": true, "tool_arguments": "JSON objects decoded on a copy, invalid arguments rejected", "training_counting": { "implementation": "sft_all_turn_thinking.tokenize_structural", "implementation_sha256": "215312de895de1e79d492db251386985e798222f83eb9eeee239a4f57380029e", "preserve_all_thinking": true, "add_generation_prompt": false, "append_eod": false, "terminal_separator": "remove the template newline after the final message im_end", "tool_arguments": "record passed unchanged to SFT serialization" }, "libraries": { "transformers": "5.12.1", "tokenizers": "0.22.2", "jinja2": "3.1.6" }, "source_assets_sha256": { "derivation_report.json": "f40d6ac30b795ec1e1d428a17bd4d54831c8c8e8b9e14aa2d5dd3825dfc6e480", "tokenizer.json": "9113f540313f00317aa6e860d01ea73fbac8b0b3af0f5cbf0c93af047cdf6b4c", "tokenizer_config.json": "08496e6fef6bab1359e300797cb8ac230e8a3ee652676eaeb261755ab1e548a7" }, "assets_sha256": { "tokenizer.json": "9113f540313f00317aa6e860d01ea73fbac8b0b3af0f5cbf0c93af047cdf6b4c", "tokenizer_config.json": "f61c4793105d9508248590587e6e94fba2f64a4bb84f64eaa4925d0466847c5b" }, "chat_template_sha256": "cbad793417178000a8145de58db885ecf45a8f8380393dbbf24373b52f046ddc", "vocabulary": { "base_tokens": 32768, "special_tokens": 33, "total_tokens": 32801, "derivation": "Truncated Qwen3.5 base vocabulary and remapped special tokens, prepared for our LLM course" } }, "by_source": { "smoltalk": { "segments": 360239, "response_tokens": 923363273, "full_tokens": 1507389801 }, "tulu3": { "segments": 502240, "response_tokens": 1076533453, "full_tokens": 2179237694 } }, "by_segment_type": { "initial": { "segments": 781693, "response_tokens": 1729331270, "full_tokens": 2751736831 }, "compaction": { "segments": 39074, "response_tokens": 65008945, "full_tokens": 499457744 }, "continuation": { "segments": 41712, "response_tokens": 205556511, "full_tokens": 435432920 } }, "source_run": "ds0731-20261021-r5", "source_manifests": { "500M": { "dataset_name": "capysft-v1.2-500M", "sha256": "d4abf04b9499f242422fc03e59540760363e2e9aec1d2427ea64b5b24d04b4a7" }, "1B": { "dataset_name": "capysft-v1.3", "sha256": "5def852c6632f02b459584136ed25c15576b2f8575c08556fbb11c5dff6d8db9" }, "2B": { "dataset_name": "capysft-v1.2-2B", "sha256": "afecad953a1526496695935594fe26fbc2b543b370a2cd2a2c7bbd45ccec486a" } }, "revision": { "kind": "terminal-message-eos", "messages_and_response_targets_unchanged": true, "removed_template_newline_and_extra_eod": true, "segments_reordered_into_nested_shards": true, "original_pack_indexes_omitted": true }, "source_labels": [ { "dataset_origin": "smoltalk", "source": "everyday-conversations", "segments": 1089 }, { "dataset_origin": "smoltalk", "source": "explore-instruct-rewriting", "segments": 14505 }, { "dataset_origin": "smoltalk", "source": "metamathqa-50k", "segments": 22641 }, { "dataset_origin": "smoltalk", "source": "self-oss-instruct", "segments": 23380 }, { "dataset_origin": "smoltalk", "source": "smol-constraints", "segments": 16561 }, { "dataset_origin": "smoltalk", "source": "smol-magpie-ultra", "segments": 210895 }, { "dataset_origin": "smoltalk", "source": "smol-rewrite", "segments": 25213 }, { "dataset_origin": "smoltalk", "source": "smol-summarize", "segments": 45955 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/coconot_converted", "segments": 6985 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/evol_codealpaca_heval_decontaminated", "segments": 88406 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/no_robots_converted", "segments": 5179 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/numinamath_tir_math_decontaminated", "segments": 40269 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/oasst1_converted", "segments": 4438 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/personahub_code_v2_34999", "segments": 21137 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/personahub_ifdata_manual_seed_v3_29980", "segments": 18254 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/personahub_math_v5_regen_149960", "segments": 94819 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/tulu_v3.9_open_math_2_gsm8k_50k", "segments": 30072 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/tulu_v3.9_personahub_math_interm_algebra_20k", "segments": 12084 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/tulu_v3.9_sciriff_10k", "segments": 6020 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/tulu_v3.9_synthetic_finalresp_wildguardmixtrain_decontaminated_50k", "segments": 30331 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/tulu_v3.9_wildchat_100k", "segments": 84316 }, { "dataset_origin": "tulu3", "source": "ai2-adapt-dev/tulu_v3.9_wildjailbreak_decontaminated_50k", "segments": 29994 }, { "dataset_origin": "tulu3", "source": "allenai/tulu-3-sft-personas-math-grade", "segments": 29936 } ], "validation": { "all_source_compressed_and_uncompressed_sha256_checked": true, "all_records_parsed": true, "nested_content_sha256_matches": true, "all_record_counts_and_token_totals_checked": true, "tokenizer_assets_checked": true }, "observed_json_types": { "arguments. ": [ "str" ], "arguments.command": [ "str" ], "arguments.content": [ "str" ], "arguments.edit_safe": [ "bool" ], "arguments.fieldName": [ "str" ], "arguments.filePath": [ "str" ], "arguments.file_path": [ "str" ], "arguments.limit": [ "int" ], "arguments.newString": [ "str" ], "arguments.offset": [ "int" ], "arguments.olString": [ "str" ], "arguments.oldString": [ "str" ], "arguments.replaceAll": [ "bool" ], "arguments.timeout": [ "int" ], "arguments.workdir": [ "str" ], "messages.content": [ "str" ], "messages.reasoning_content": [ "str" ] }}123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305{ "add_prefix_space": false, "added_tokens_decoder": { "32768": { "content": "<|endoftext|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32769": { "content": "<|im_start|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32770": { "content": "<|im_end|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32771": { "content": "<|object_ref_start|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32772": { "content": "<|object_ref_end|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32773": { "content": "<|box_start|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32774": { "content": "<|box_end|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32775": { "content": "<|quad_start|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32776": { "content": "<|quad_end|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32777": { "content": "<|vision_start|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32778": { "content": "<|vision_end|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32779": { "content": "<|vision_pad|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32780": { "content": "<|image_pad|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32781": { "content": "<|video_pad|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32782": { "content": "<tool_call>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32783": { "content": "</tool_call>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32784": { "content": "<|fim_prefix|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32785": { "content": "<|fim_middle|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32786": { "content": "<|fim_suffix|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32787": { "content": "<|fim_pad|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32788": { "content": "<|repo_name|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32789": { "content": "<|file_sep|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32790": { "content": "<tool_response>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32791": { "content": "</tool_response>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32792": { "content": "<think>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32793": { "content": "</think>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32794": { "content": "<|audio_start|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32795": { "content": "<|audio_end|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32796": { "content": "<tts_pad>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32797": { "content": "<tts_text_bos>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32798": { "content": "<tts_text_eod>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32799": { "content": "<tts_text_bos_single>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true }, "32800": { "content": "<|audio_pad|>", "single_word": false, "lstrip": false, "rstrip": false, "normalized": false, "special": true } }, "additional_special_tokens": [ "<|im_start|>", "<|im_end|>", "<|object_ref_start|>", "<|object_ref_end|>", "<|box_start|>", "<|box_end|>", "<|quad_start|>", "<|quad_end|>", "<|vision_start|>", "<|vision_end|>", "<|vision_pad|>", "<|image_pad|>", "<|video_pad|>" ], "bos_token": null, "chat_template": "{%- set image_count = namespace(value=0) %}\n{%- set video_count = namespace(value=0) %}\n{%- macro render_content(content, do_vision_count, is_system_content=false) %}\n {%- if content is string %}\n {{- content }}\n {%- elif content is iterable and content is not mapping %}\n {%- for item in content %}\n {%- if 'image' in item or 'image_url' in item or item.type == 'image' %}\n {%- if is_system_content %}\n {{- raise_exception('System message cannot contain images.') }}\n {%- endif %}\n {%- if do_vision_count %}\n {%- set image_count.value = image_count.value + 1 %}\n {%- endif %}\n {%- if add_vision_id %}\n {{- 'Picture ' ~ image_count.value ~ ': ' }}\n {%- endif %}\n {{- '<|vision_start|><|image_pad|><|vision_end|>' }}\n {%- elif 'video' in item or item.type == 'video' %}\n {%- if is_system_content %}\n {{- raise_exception('System message cannot contain videos.') }}\n {%- endif %}\n {%- if do_vision_count %}\n {%- set video_count.value = video_count.value + 1 %}\n {%- endif %}\n {%- if add_vision_id %}\n {{- 'Video ' ~ video_count.value ~ ': ' }}\n {%- endif %}\n {{- '<|vision_start|><|video_pad|><|vision_end|>' }}\n {%- elif 'text' in item %}\n {{- item.text }}\n {%- else %}\n {{- raise_exception('Unexpected item type in content.') }}\n {%- endif %}\n {%- endfor %}\n {%- elif content is none or content is undefined %}\n {{- '' }}\n {%- else %}\n {{- raise_exception('Unexpected content type.') }}\n {%- endif %}\n{%- endmacro %}\n{%- if not messages %}\n {{- raise_exception('No messages provided.') }}\n{%- endif %}\n{%- if tools and tools is iterable and tools is not mapping %}\n {{- '<|im_start|>system\\n' }}\n {{- \"# Tools\\n\\nYou have access to the following functions:\\n\\n<tools>\" }}\n {%- for tool in tools %}\n {{- \"\\n\" }}\n {{- tool | tojson }}\n {%- endfor %}\n {{- \"\\n</tools>\" }}\n {{- '\\n\\nIf you choose to call a function ONLY reply in the following format with NO suffix:\\n\\n<tool_call>\\n<function=example_function_name>\\n<parameter=example_parameter_1>\\nvalue_1\\n</parameter>\\n<parameter=example_parameter_2>\\nThis is the value for the second parameter\\nthat can span\\nmultiple lines\\n</parameter>\\n</function>\\n</tool_call>\\n\\n<IMPORTANT>\\nReminder:\\n- Function calls MUST follow the specified format: an inner <function=...></function> block must be nested within <tool_call></tool_call> XML tags\\n- Required parameters MUST be specified\\n- You may provide optional reasoning for your function call in natural language BEFORE the function call, but NOT after\\n- If there is no function call available, answer the question like normal with your current knowledge and do not tell the user about function calls\\n</IMPORTANT>' }}\n {%- if messages[0].role == 'system' %}\n {%- set content = render_content(messages[0].content, false, true)|trim %}\n {%- if content %}\n {{- '\\n\\n' + content }}\n {%- endif %}\n {%- endif %}\n {{- '<|im_end|>\\n' }}\n{%- else %}\n {%- if messages[0].role == 'system' %}\n {%- set content = render_content(messages[0].content, false, true)|trim %}\n {{- '<|im_start|>system\\n' + content + '<|im_end|>\\n' }}\n {%- endif %}\n{%- endif %}\n{%- set ns = namespace(multi_step_tool=true, last_query_index=messages|length - 1) %}\n{%- for message in messages[::-1] %}\n {%- set index = (messages|length - 1) - loop.index0 %}\n {%- if ns.multi_step_tool and message.role == \"user\" %}\n {%- set content = render_content(message.content, false)|trim %}\n {%- if not(content.startswith('<tool_response>') and content.endswith('</tool_response>')) %}\n {%- set ns.multi_step_tool = false %}\n {%- set ns.last_query_index = index %}\n {%- endif %}\n {%- endif %}\n{%- endfor %}\n{%- if ns.multi_step_tool %}\n {{- raise_exception('No user query found in messages.') }}\n{%- endif %}\n{%- for message in messages %}\n {%- set content = render_content(message.content, true)|trim %}\n {%- if message.role == \"system\" %}\n {%- if not loop.first %}\n {{- raise_exception('System message must be at the beginning.') }}\n {%- endif %}\n {%- elif message.role == \"user\" %}\n {{- '<|im_start|>' + message.role + '\\n' + content + '<|im_end|>' + '\\n' }}\n {%- elif message.role == \"assistant\" %}\n {%- set reasoning_content = '' %}\n {%- if message.reasoning_content is string %}\n {%- set reasoning_content = message.reasoning_content %}\n {%- else %}\n {%- if '</think>' in content %}\n {%- set reasoning_content = content.split('</think>')[0].rstrip('\\n').split('<think>')[-1].lstrip('\\n') %}\n {%- set content = content.split('</think>')[-1].lstrip('\\n') %}\n {%- endif %}\n {%- endif %}\n {%- set reasoning_content = reasoning_content|trim %}\n {%- if true %}\n {{- '<|im_start|>' + message.role + '\\n<think>\\n' + reasoning_content + '\\n</think>\\n\\n' + content }}\n {%- else %}\n {{- '<|im_start|>' + message.role + '\\n' + content }}\n {%- endif %}\n {%- if message.tool_calls and message.tool_calls is iterable and message.tool_calls is not mapping %}\n {%- for tool_call in message.tool_calls %}\n {%- if tool_call.function is defined %}\n {%- set tool_call = tool_call.function %}\n {%- endif %}\n {%- if loop.first %}\n {%- if content|trim %}\n {{- '\\n\\n<tool_call>\\n<function=' + tool_call.name + '>\\n' }}\n {%- else %}\n {{- '<tool_call>\\n<function=' + tool_call.name + '>\\n' }}\n {%- endif %}\n {%- else %}\n {{- '\\n<tool_call>\\n<function=' + tool_call.name + '>\\n' }}\n {%- endif %}\n {%- if tool_call.arguments is defined %}\n {%- for args_name, args_value in tool_call.arguments|items %}\n {{- '<parameter=' + args_name + '>\\n' }}\n {%- set args_value = args_value | tojson | safe if args_value is mapping or (args_value is sequence and args_value is not string) else args_value | string %}\n {{- args_value }}\n {{- '\\n</parameter>\\n' }}\n {%- endfor %}\n {%- endif %}\n {{- '</function>\\n</tool_call>' }}\n {%- endfor %}\n {%- endif %}\n {{- '<|im_end|>\\n' }}\n {%- elif message.role == \"tool\" %}\n {%- if loop.previtem and loop.previtem.role != \"tool\" %}\n {{- '<|im_start|>user' }}\n {%- endif %}\n {{- '\\n<tool_response>\\n' }}\n {{- content }}\n {{- '\\n</tool_response>' }}\n {%- if not loop.last and loop.nextitem.role != \"tool\" %}\n {{- '<|im_end|>\\n' }}\n {%- elif loop.last %}\n {{- '<|im_end|>\\n' }}\n {%- endif %}\n {%- else %}\n {{- raise_exception('Unexpected message role.') }}\n {%- endif %}\n{%- endfor %}\n{%- if add_generation_prompt %}\n {{- '<|im_start|>assistant\\n' }}\n {%- if enable_thinking is defined and enable_thinking is false %}\n {{- '<think>\\n\\n</think>\\n\\n' }}\n {%- else %}\n {{- '<think>\\n' }}\n {%- endif %}\n{%- endif %}", "clean_up_tokenization_spaces": false, "eos_token": "<|im_end|>", "errors": "replace", "model_max_length": 262144, "pad_token": "<|endoftext|>", "split_special_tokens": false, "tokenizer_class": "Qwen2Tokenizer", "unk_token": null, "add_bos_token": false, "pretokenize_regex": "(?i:'s|'t|'re|'ve|'m|'ll|'d)|[^\\r\\n\\p{L}\\p{N}]?[\\p{L}\\p{M}]+|\\p{N}| ?[^\\s\\p{L}\\p{M}\\p{N}]+[\\r\\n]*|\\s*[\\r\\n]+|\\s+(?!\\S)|\\s+", "extra_special_tokens": { "audio_bos_token": "<|audio_start|>", "audio_eos_token": "<|audio_end|>", "audio_token": "<|audio_pad|>", "image_token": "<|image_pad|>", "video_token": "<|video_pad|>", "vision_bos_token": "<|vision_start|>", "vision_eos_token": "<|vision_end|>" }}LICENSE.mdAdded+35
README.mdAdded+197
data/train-00000-of-00004.jsonl.gzAdded+3
data/train-00001-of-00004.jsonl.gzAdded+3
data/train-00002-of-00004.jsonl.gzAdded+3
data/train-00003-of-00004.jsonl.gzAdded+3
release-manifest.jsonAdded+357
tokenizer/tokenizer.jsonAdded
tokenizer/tokenizer_config.jsonAdded+305