初始化项目,由ModelHub XC社区提供模型
Model: uralstech/kcc-krishi-qwen3-1.7b Source: Original Platform
This commit is contained in:
36
.gitattributes
vendored
Normal file
36
.gitattributes
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
*.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
|
||||
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
||||
39
CITATION.cff
Normal file
39
CITATION.cff
Normal file
@@ -0,0 +1,39 @@
|
||||
cff-version: 1.2.0
|
||||
title: "KCC-Krishi Qwen3-1.7B"
|
||||
message: "If you use this model, please cite the KCC-Krishi model, the KCC-Krishi dataset, the underlying Government of India KCC source, and the Qwen base model."
|
||||
type: software
|
||||
authors:
|
||||
- name: "KCC-Krishi Project Team"
|
||||
affiliation: "URAV ADVANCED LEARNING SYSTEMS PRIVATE LIMITED"
|
||||
version: "1.0.0"
|
||||
date-released: "2026-07-16"
|
||||
url: "https://huggingface.co/uralstech/kcc-krishi-qwen3-1.7b"
|
||||
keywords:
|
||||
- agriculture
|
||||
- Kisan Call Centre
|
||||
- KCC
|
||||
- Qwen3
|
||||
- QLoRA
|
||||
- RAG
|
||||
- farmer advisory
|
||||
- offline inference
|
||||
- Jetson
|
||||
- safety routing
|
||||
- evidence grounding
|
||||
references:
|
||||
- type: model
|
||||
title: "Qwen/Qwen3-1.7B"
|
||||
url: "https://huggingface.co/Qwen/Qwen3-1.7B"
|
||||
- type: dataset
|
||||
title: "KCC-Krishi RAG/SFT Advisory Corpus"
|
||||
url: "https://huggingface.co/datasets/uralstech/kcc-krishi-rag-sft-advisory-corpus"
|
||||
- type: article
|
||||
title: "KCC-Krishi: A Quality-Controlled Data Pipeline for Evidence-Preserving Agricultural RAG and SFT Corpora from Kisan Call Centre Records"
|
||||
year: 2026
|
||||
doi: "10.5281/zenodo.21040992"
|
||||
- type: dataset
|
||||
title: "Kisan Call Centre (KCC) Transcripts of Farmers Queries and Answers"
|
||||
publisher: "Open Government Data Platform India / Data.gov.in"
|
||||
year: 2026
|
||||
url: "https://www.data.gov.in/resource/kisan-call-centre-kcc-transcripts-farmers-queries-answers"
|
||||
license: "other"
|
||||
121
LICENSE.md
Normal file
121
LICENSE.md
Normal file
@@ -0,0 +1,121 @@
|
||||
# KCC-Krishi Qwen3-1.7B — Licensing and Attribution Notes
|
||||
|
||||
## License metadata
|
||||
|
||||
The Hugging Face model repository uses:
|
||||
|
||||
```yaml
|
||||
license: other
|
||||
```
|
||||
|
||||
This is intentional because the release is a derived model combining:
|
||||
|
||||
- the Qwen/Qwen3-1.7B base model;
|
||||
- KCC-derived training evidence;
|
||||
- KCC-Krishi fine-tuning;
|
||||
- project-specific model packaging;
|
||||
- project-specific runtime safety components;
|
||||
- source and derived-data attribution requirements.
|
||||
|
||||
## Base model
|
||||
|
||||
This model is derived from:
|
||||
|
||||
```text
|
||||
Qwen/Qwen3-1.7B
|
||||
```
|
||||
|
||||
Users must review and comply with the base model license and attribution terms before using, modifying, or redistributing this derived model.
|
||||
|
||||
The base model license remains separate from the KCC-Krishi dataset and project-processing terms.
|
||||
|
||||
## Dataset attribution
|
||||
|
||||
The training evidence is derived from:
|
||||
|
||||
**Kisan Call Centre (KCC) Transcripts of Farmers Queries and Answers**
|
||||
|
||||
Open Government Data Platform India / Data.gov.in
|
||||
Ministry of Agriculture and Farmers Welfare, Government of India
|
||||
Accessed through AIKosh/Data.gov.in
|
||||
|
||||
The KCC-Krishi processing, translation, quality control, routing, fine-tuning, packaging, and runtime safeguards were created by:
|
||||
|
||||
```text
|
||||
KCC-Krishi Project Team
|
||||
URAV ADVANCED LEARNING SYSTEMS PRIVATE LIMITED
|
||||
```
|
||||
|
||||
## Derived model terms
|
||||
|
||||
This model is provided for research, reproducibility, RAG, SFT, evaluation, and controlled offline-assistant prototyping.
|
||||
|
||||
Users must:
|
||||
|
||||
- preserve Qwen base-model attribution;
|
||||
- preserve KCC source attribution;
|
||||
- preserve KCC-Krishi attribution;
|
||||
- retain this licensing note;
|
||||
- comply with applicable source-data and model-license requirements;
|
||||
- review current agricultural regulations and official guidance;
|
||||
- use runtime safety and evidence-grounding components for deployment.
|
||||
|
||||
## Prohibited interpretation
|
||||
|
||||
This model must not be presented as:
|
||||
|
||||
- field-validated agronomic ground truth;
|
||||
- an unrestricted agricultural authority;
|
||||
- a replacement for agronomists;
|
||||
- a current weather or market information source;
|
||||
- a government-scheme status authority;
|
||||
- an autonomous pesticide or fertilizer recommendation system;
|
||||
- a substitute for product-label or local-agriculture-officer verification.
|
||||
|
||||
## Runtime requirement
|
||||
|
||||
The intended deployment includes:
|
||||
|
||||
```text
|
||||
out-of-scope guard
|
||||
→ current-information guard
|
||||
→ regional RAG retrieval
|
||||
→ Qwen model
|
||||
→ agrochemical exactness guard
|
||||
→ final safety validation
|
||||
```
|
||||
|
||||
Deployment without these controls is outside the intended project design.
|
||||
|
||||
## No endorsement
|
||||
|
||||
No endorsement is implied by:
|
||||
|
||||
- the Government of India;
|
||||
- Data.gov.in;
|
||||
- AIKosh;
|
||||
- the Ministry of Agriculture and Farmers Welfare;
|
||||
- Kisan Call Centre;
|
||||
- Qwen;
|
||||
- Hugging Face;
|
||||
- Microsoft Azure;
|
||||
- URAV Advanced Learning Systems Private Limited.
|
||||
|
||||
## No warranty
|
||||
|
||||
The model is provided without a warranty that:
|
||||
|
||||
- every generated answer is correct;
|
||||
- every source-derived recommendation is current;
|
||||
- every product, formulation, unit, or dose is correct;
|
||||
- every response is suitable for a particular crop or location;
|
||||
- the model is safe for unattended field deployment;
|
||||
- the model will not reproduce source-derived text.
|
||||
|
||||
## Safety notice
|
||||
|
||||
Pesticide, fertilizer, disease, weather, market, and government-scheme information must be independently checked against current official sources, current product labels, local regulations, and qualified agricultural advice.
|
||||
|
||||
## Legal notice
|
||||
|
||||
This document is not legal advice. Users are responsible for evaluating licensing, attribution, privacy, redistribution, safety, and regulatory obligations before using or distributing the model.
|
||||
285
README.md
Normal file
285
README.md
Normal file
@@ -0,0 +1,285 @@
|
||||
---
|
||||
language:
|
||||
- en
|
||||
license: other
|
||||
base_model:
|
||||
- Qwen/Qwen3-1.7B
|
||||
library_name: transformers
|
||||
tags:
|
||||
- agriculture
|
||||
- india
|
||||
- kisan-call-centre
|
||||
- farmer-advisory
|
||||
- qwen3
|
||||
- qlora
|
||||
- rag
|
||||
- safety-routing
|
||||
- jetson
|
||||
- offline-inference
|
||||
pipeline_tag: text-generation
|
||||
---
|
||||
|
||||
# KCC-Krishi Qwen3-1.7B
|
||||
|
||||
KCC-Krishi Qwen3-1.7B is a compact English-primary agricultural advisory model fine-tuned from `Qwen/Qwen3-1.7B` using QLoRA on a routing-aware Kisan Call Centre research corpus.
|
||||
|
||||
The model is designed for a regional offline farmer-assistance architecture:
|
||||
|
||||
```text
|
||||
regional speech
|
||||
→ local ASR
|
||||
→ translation to English
|
||||
→ runtime guard
|
||||
→ regional KCC RAG retrieval
|
||||
→ KCC-Krishi Qwen3-1.7B
|
||||
→ agrochemical exactness validation
|
||||
→ translation to farmer language
|
||||
→ local TTS
|
||||
```
|
||||
|
||||
## Important status
|
||||
|
||||
This model is a research and controlled-prototyping artifact.
|
||||
|
||||
It is not:
|
||||
|
||||
- field-validated agronomic ground truth;
|
||||
- an unrestricted agricultural authority;
|
||||
- a replacement for agronomists;
|
||||
- a replacement for current official advisories;
|
||||
- a replacement for product-label verification;
|
||||
- a replacement for farmer feedback or field validation;
|
||||
- a general-purpose assistant for arbitrary non-agricultural questions.
|
||||
|
||||
## Training details
|
||||
|
||||
Base model:
|
||||
|
||||
```text
|
||||
Qwen/Qwen3-1.7B
|
||||
```
|
||||
|
||||
Training method:
|
||||
|
||||
```text
|
||||
QLoRA / LoRA
|
||||
```
|
||||
|
||||
Training stack:
|
||||
|
||||
```text
|
||||
Hugging Face Transformers
|
||||
TRL SFTTrainer
|
||||
PEFT
|
||||
bitsandbytes
|
||||
```
|
||||
|
||||
Training hardware:
|
||||
|
||||
```text
|
||||
Azure Standard_NC8as_T4_v3
|
||||
NVIDIA Tesla T4 16GB
|
||||
8 vCPUs
|
||||
56 GiB system RAM
|
||||
```
|
||||
|
||||
Final training configuration:
|
||||
|
||||
- training examples: 365,037;
|
||||
- validation examples used during training: 5,000;
|
||||
- one complete training epoch;
|
||||
- optimizer: `paged_adamw_32bit`;
|
||||
- learning rate: `1e-5`;
|
||||
- warmup ratio: `0.05`;
|
||||
- maximum gradient norm: `0.3`;
|
||||
- QLoRA compute dtype: `float16`;
|
||||
- Trainer FP16: disabled;
|
||||
- Trainer BF16: disabled;
|
||||
- packing: disabled;
|
||||
- assistant-only loss: disabled;
|
||||
- maximum sequence length: 1,024;
|
||||
- manual Qwen ChatML rendering;
|
||||
- hard-stop monitoring enabled.
|
||||
|
||||
Training duration:
|
||||
|
||||
```text
|
||||
approximately 85.8 hours
|
||||
```
|
||||
|
||||
The full training run completed without NaN loss, Inf loss, loss explosion, CUDA out-of-memory failure, or hard-stop activation.
|
||||
|
||||
## Final model selection
|
||||
|
||||
The selected adapter originated from the exact complete-epoch checkpoint:
|
||||
|
||||
```text
|
||||
checkpoint-22815
|
||||
```
|
||||
|
||||
The selected adapter was compared against the validation-selected checkpoint-18000 using normal RAG, OOD, and adversarial behavioral probes.
|
||||
|
||||
The selected candidate performed better on several unsafe or adversarial cases, including:
|
||||
|
||||
- pesticide mixing;
|
||||
- excessive fertilizer use;
|
||||
- double pesticide dose requests;
|
||||
- harmful pesticide framing;
|
||||
- out-of-distribution agricultural questions.
|
||||
|
||||
The model was then merged with the Qwen base model using float16 safe serialization.
|
||||
|
||||
## Merged model files
|
||||
|
||||
The merged release includes:
|
||||
|
||||
- `model.safetensors`;
|
||||
- `config.json`;
|
||||
- `generation_config.json`;
|
||||
- `tokenizer.json`;
|
||||
- `tokenizer_config.json`;
|
||||
- `chat_template.jinja`;
|
||||
- `merge_summary.json`;
|
||||
- `SHA256SUMS.txt`.
|
||||
|
||||
## Required runtime architecture
|
||||
|
||||
The model should not be deployed alone.
|
||||
|
||||
The intended runtime is:
|
||||
|
||||
```text
|
||||
out-of-scope guard
|
||||
→ current-information guard
|
||||
→ regional KCC RAG retrieval
|
||||
→ fine-tuned Qwen model
|
||||
→ agrochemical exactness guard
|
||||
→ final safety validation
|
||||
```
|
||||
|
||||
The runtime guard is required because the model is not intended to answer arbitrary non-agricultural questions. The guard should block or safely handle general mathematics, politics, fictional premises, nonsense prompts, and unrelated requests.
|
||||
|
||||
## Agrochemical exactness requirement
|
||||
|
||||
The model may alter exact product names, formulations, percentages, or dose expressions when generating from retrieved evidence.
|
||||
|
||||
Therefore, every generated answer containing pesticide, herbicide, fungicide, fertilizer, formulation, percentage, or dose-like information must be checked against verified retrieved evidence.
|
||||
|
||||
If the generated agrochemical information is not supported exactly by retrieved evidence, the runtime should replace it with generic wording such as:
|
||||
|
||||
```text
|
||||
Use only a locally recommended product at the current label dose. Confirm the crop, pest, crop stage, formulation, and local agricultural recommendation before application.
|
||||
```
|
||||
|
||||
## Intended use
|
||||
|
||||
Suitable uses include:
|
||||
|
||||
- agricultural RAG research;
|
||||
- KCC evidence-grounding experiments;
|
||||
- supervised fine-tuning research;
|
||||
- offline farmer-assistant prototypes;
|
||||
- Jetson and mobile inference experiments;
|
||||
- safety-routing research;
|
||||
- multilingual voice-assistant integration through external ASR, translation, and TTS services.
|
||||
|
||||
## Unsuitable use
|
||||
|
||||
Do not use this model alone for:
|
||||
|
||||
- direct pesticide or fertilizer recommendations;
|
||||
- autonomous disease diagnosis;
|
||||
- current weather forecasting;
|
||||
- current mandi-price reporting;
|
||||
- government-scheme status;
|
||||
- financial or medical decisions;
|
||||
- unrestricted general-purpose chat;
|
||||
- unattended field deployment.
|
||||
|
||||
## Dataset
|
||||
|
||||
The final model was trained using the KCC-Krishi routing-aware corpus.
|
||||
|
||||
Dataset repository:
|
||||
|
||||
```text
|
||||
uralstech/kcc-krishi-rag-sft-advisory-corpus
|
||||
```
|
||||
|
||||
The Punjab/Wheat GPT-5.5 normalization demonstration subset was not used for final Qwen training.
|
||||
|
||||
## Dataset attribution
|
||||
|
||||
The underlying training evidence is derived from:
|
||||
|
||||
**Kisan Call Centre (KCC) Transcripts of Farmers Queries and Answers**
|
||||
|
||||
Open Government Data Platform India / Data.gov.in
|
||||
Ministry of Agriculture and Farmers Welfare, Government of India
|
||||
Accessed through AIKosh/Data.gov.in
|
||||
|
||||
The KCC-Krishi processing, routing, training, packaging, and runtime safeguards were created by:
|
||||
|
||||
```text
|
||||
KCC-Krishi Project Team
|
||||
URAV ADVANCED LEARNING SYSTEMS PRIVATE LIMITED
|
||||
```
|
||||
|
||||
## Base model and licensing
|
||||
|
||||
This model is derived from `Qwen/Qwen3-1.7B`.
|
||||
|
||||
The Qwen base model repository provides its own license and attribution terms. Users must review and comply with those terms before using or redistributing this derived model.
|
||||
|
||||
This model repository uses `license: other` because the release combines:
|
||||
|
||||
- the Qwen base model;
|
||||
- KCC-derived training evidence;
|
||||
- project-specific fine-tuning;
|
||||
- project-specific model packaging;
|
||||
- runtime safety requirements;
|
||||
- source and derived-data attribution obligations.
|
||||
|
||||
See the included `LICENSE.md` for the project release notes.
|
||||
|
||||
## Limitations
|
||||
|
||||
Known limitations include:
|
||||
|
||||
- possible source-data noise and query/evidence mismatch;
|
||||
- historical or stale KCC records;
|
||||
- lack of agronomist field validation;
|
||||
- lack of broad farmer-feedback validation;
|
||||
- lack of RLHF or preference tuning;
|
||||
- possible model memorization of source-derived records;
|
||||
- occasional terse or evidence-report-like responses;
|
||||
- possible multilingual or translation artifacts;
|
||||
- possible exact agrochemical-name or formulation drift without the runtime guard;
|
||||
- poor behavior on arbitrary non-agricultural questions without the runtime guard.
|
||||
|
||||
## Related resources
|
||||
|
||||
Dataset:
|
||||
|
||||
```text
|
||||
https://huggingface.co/datasets/uralstech/kcc-krishi-rag-sft-advisory-corpus
|
||||
```
|
||||
|
||||
Existing Punjab/Wheat demonstration dataset:
|
||||
|
||||
```text
|
||||
https://huggingface.co/datasets/uralstech/kcc-krishi-punjab-wheat-demo
|
||||
```
|
||||
|
||||
Related preprint DOI:
|
||||
|
||||
```text
|
||||
10.5281/zenodo.21040992
|
||||
```
|
||||
|
||||
## Disclaimer
|
||||
|
||||
This model is released for research, reproducibility, RAG, SFT, and controlled offline-assistant prototyping.
|
||||
|
||||
Do not rely on this model as current or authoritative agricultural advice. Verify all consequential decisions with qualified agricultural experts, current official sources, current product labels, and applicable local regulations.
|
||||
|
||||
10
SHA256SUMS.txt
Normal file
10
SHA256SUMS.txt
Normal file
@@ -0,0 +1,10 @@
|
||||
a55ee1b1660128b7098723e0abcd92caa0788061051c62d51cbe87d9cf1974d8 chat_template.jinja
|
||||
5c9fda21f43e5fed5180657fadae84b7fad5814f2c5659d2da734f028210690e CITATION.cff
|
||||
580f9a1e5ac8c17ef5e17dbf9da2a1558b489863b274c92f34b33217bf8dbefd config.json
|
||||
535ef5c50ad97889d648321c63a3b88349a3a2046bbf6e2fe430e7656fb13ba5 generation_config.json
|
||||
a50c459f698d64af7e2a0bd948c21e77c1aa762a0bac9c86ad161f66c947a408 LICENSE.md
|
||||
17ffc0d5e597655d7073735d6adf9cd1ebf8049ec7080104dcc86ffc038e7f66 merge_summary.json
|
||||
2c54c2950a890a64079b791a4b5da452ff2e563765c18f3dbab83fd25a85740c model.safetensors
|
||||
ea2d09e30921bd85d3d57814533edf753c5e4db1e096cbb51e739ac0749051be README.md
|
||||
be75606093db2094d7cd20f3c2f385c212750648bd6ea4fb2bf507a6a4c55506 tokenizer.json
|
||||
04b1682c59acbd057f4c9072297faa73d56fc9de053094c659cdb4c464f58f86 tokenizer_config.json
|
||||
89
chat_template.jinja
Normal file
89
chat_template.jinja
Normal file
@@ -0,0 +1,89 @@
|
||||
{%- if tools %}
|
||||
{{- '<|im_start|>system\n' }}
|
||||
{%- if messages[0].role == 'system' %}
|
||||
{{- messages[0].content + '\n\n' }}
|
||||
{%- endif %}
|
||||
{{- "# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within <tools></tools> XML tags:\n<tools>" }}
|
||||
{%- for tool in tools %}
|
||||
{{- "\n" }}
|
||||
{{- tool | tojson }}
|
||||
{%- endfor %}
|
||||
{{- "\n</tools>\n\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\n<tool_call>\n{\"name\": <function-name>, \"arguments\": <args-json-object>}\n</tool_call><|im_end|>\n" }}
|
||||
{%- else %}
|
||||
{%- if messages[0].role == 'system' %}
|
||||
{{- '<|im_start|>system\n' + messages[0].content + '<|im_end|>\n' }}
|
||||
{%- endif %}
|
||||
{%- endif %}
|
||||
{%- set ns = namespace(multi_step_tool=true, last_query_index=messages|length - 1) %}
|
||||
{%- for message in messages[::-1] %}
|
||||
{%- set index = (messages|length - 1) - loop.index0 %}
|
||||
{%- if ns.multi_step_tool and message.role == "user" and message.content is string and not(message.content.startswith('<tool_response>') and message.content.endswith('</tool_response>')) %}
|
||||
{%- set ns.multi_step_tool = false %}
|
||||
{%- set ns.last_query_index = index %}
|
||||
{%- endif %}
|
||||
{%- endfor %}
|
||||
{%- for message in messages %}
|
||||
{%- if message.content is string %}
|
||||
{%- set content = message.content %}
|
||||
{%- else %}
|
||||
{%- set content = '' %}
|
||||
{%- endif %}
|
||||
{%- if (message.role == "user") or (message.role == "system" and not loop.first) %}
|
||||
{{- '<|im_start|>' + message.role + '\n' + content + '<|im_end|>' + '\n' }}
|
||||
{%- elif message.role == "assistant" %}
|
||||
{%- set reasoning_content = '' %}
|
||||
{%- if message.reasoning_content is string %}
|
||||
{%- set reasoning_content = message.reasoning_content %}
|
||||
{%- else %}
|
||||
{%- if '</think>' in content %}
|
||||
{%- set reasoning_content = content.split('</think>')[0].rstrip('\n').split('<think>')[-1].lstrip('\n') %}
|
||||
{%- set content = content.split('</think>')[-1].lstrip('\n') %}
|
||||
{%- endif %}
|
||||
{%- endif %}
|
||||
{%- if loop.index0 > ns.last_query_index %}
|
||||
{%- if loop.last or (not loop.last and reasoning_content) %}
|
||||
{{- '<|im_start|>' + message.role + '\n<think>\n' + reasoning_content.strip('\n') + '\n</think>\n\n' + content.lstrip('\n') }}
|
||||
{%- else %}
|
||||
{{- '<|im_start|>' + message.role + '\n' + content }}
|
||||
{%- endif %}
|
||||
{%- else %}
|
||||
{{- '<|im_start|>' + message.role + '\n' + content }}
|
||||
{%- endif %}
|
||||
{%- if message.tool_calls %}
|
||||
{%- for tool_call in message.tool_calls %}
|
||||
{%- if (loop.first and content) or (not loop.first) %}
|
||||
{{- '\n' }}
|
||||
{%- endif %}
|
||||
{%- if tool_call.function %}
|
||||
{%- set tool_call = tool_call.function %}
|
||||
{%- endif %}
|
||||
{{- '<tool_call>\n{"name": "' }}
|
||||
{{- tool_call.name }}
|
||||
{{- '", "arguments": ' }}
|
||||
{%- if tool_call.arguments is string %}
|
||||
{{- tool_call.arguments }}
|
||||
{%- else %}
|
||||
{{- tool_call.arguments | tojson }}
|
||||
{%- endif %}
|
||||
{{- '}\n</tool_call>' }}
|
||||
{%- endfor %}
|
||||
{%- endif %}
|
||||
{{- '<|im_end|>\n' }}
|
||||
{%- elif message.role == "tool" %}
|
||||
{%- if loop.first or (messages[loop.index0 - 1].role != "tool") %}
|
||||
{{- '<|im_start|>user' }}
|
||||
{%- endif %}
|
||||
{{- '\n<tool_response>\n' }}
|
||||
{{- content }}
|
||||
{{- '\n</tool_response>' }}
|
||||
{%- if loop.last or (messages[loop.index0 + 1].role != "tool") %}
|
||||
{{- '<|im_end|>\n' }}
|
||||
{%- endif %}
|
||||
{%- endif %}
|
||||
{%- endfor %}
|
||||
{%- if add_generation_prompt %}
|
||||
{{- '<|im_start|>assistant\n' }}
|
||||
{%- if enable_thinking is defined and enable_thinking is false %}
|
||||
{{- '<think>\n\n</think>\n\n' }}
|
||||
{%- endif %}
|
||||
{%- endif %}
|
||||
63
config.json
Normal file
63
config.json
Normal file
@@ -0,0 +1,63 @@
|
||||
{
|
||||
"architectures": [
|
||||
"Qwen3ForCausalLM"
|
||||
],
|
||||
"attention_bias": false,
|
||||
"attention_dropout": 0.0,
|
||||
"bos_token_id": 151643,
|
||||
"dtype": "float16",
|
||||
"eos_token_id": 151645,
|
||||
"head_dim": 128,
|
||||
"hidden_act": "silu",
|
||||
"hidden_size": 2048,
|
||||
"initializer_range": 0.02,
|
||||
"intermediate_size": 6144,
|
||||
"layer_types": [
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention",
|
||||
"full_attention"
|
||||
],
|
||||
"max_position_embeddings": 40960,
|
||||
"max_window_layers": 28,
|
||||
"model_type": "qwen3",
|
||||
"num_attention_heads": 16,
|
||||
"num_hidden_layers": 28,
|
||||
"num_key_value_heads": 8,
|
||||
"pad_token_id": null,
|
||||
"rms_norm_eps": 1e-06,
|
||||
"rope_parameters": {
|
||||
"rope_theta": 1000000,
|
||||
"rope_type": "default"
|
||||
},
|
||||
"sliding_window": null,
|
||||
"tie_word_embeddings": true,
|
||||
"transformers_version": "5.12.1",
|
||||
"use_cache": true,
|
||||
"use_sliding_window": false,
|
||||
"vocab_size": 151936
|
||||
}
|
||||
13
generation_config.json
Normal file
13
generation_config.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"bos_token_id": 151643,
|
||||
"do_sample": true,
|
||||
"eos_token_id": [
|
||||
151645,
|
||||
151643
|
||||
],
|
||||
"pad_token_id": 151643,
|
||||
"temperature": 0.6,
|
||||
"top_k": 20,
|
||||
"top_p": 0.95,
|
||||
"transformers_version": "5.12.1"
|
||||
}
|
||||
47
merge_summary.json
Normal file
47
merge_summary.json
Normal file
@@ -0,0 +1,47 @@
|
||||
{
|
||||
"status": "complete",
|
||||
"start_utc": "2026-07-13T19:13:23.185384+00:00",
|
||||
"end_utc": "2026-07-13T19:13:36.707631+00:00",
|
||||
"elapsed_seconds": 13.522244930267334,
|
||||
"elapsed_minutes": 0.2253707488377889,
|
||||
"config": "configs/qwen3_qlora_training.yaml",
|
||||
"base_model": "Qwen/Qwen3-1.7B",
|
||||
"adapter": "models/lora_adapters/final_selected/qwen3_1p7b_kcc_final_selected",
|
||||
"output": "models/merged/qwen3_1p7b_kcc_merged_final",
|
||||
"torch_dtype": "float16",
|
||||
"device_map": "auto",
|
||||
"safe_serialization": true,
|
||||
"environment": {
|
||||
"timestamp_utc": "2026-07-13T19:13:23.195533+00:00",
|
||||
"python": "3.10.12 (main, Jun 22 2026, 18:55:27) [GCC 11.4.0]",
|
||||
"platform": "Linux-6.8.0-1059-azure-x86_64-with-glibc2.35",
|
||||
"machine": "x86_64",
|
||||
"processor": "x86_64",
|
||||
"cwd": "/home/azureuser/kcc-krishi",
|
||||
"disk_free": {
|
||||
"total": 266206101504,
|
||||
"used": 156047970304,
|
||||
"free": 110141353984
|
||||
},
|
||||
"nvidia_smi": {
|
||||
"cmd": [
|
||||
"nvidia-smi"
|
||||
],
|
||||
"returncode": 0,
|
||||
"stdout": "Mon Jul 13 19:13:23 2026 \n+---------------------------------------------------------------------------------------+\n| NVIDIA-SMI 535.309.01 Driver Version: 535.309.01 CUDA Version: 12.2 |\n|-----------------------------------------+----------------------+----------------------+\n| GPU Name Persistence-M | Bus-Id Disp.A | Volatile Uncorr. ECC |\n| Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. |\n| | | MIG M. |\n|=========================================+======================+======================|\n| 0 Tesla T4 Off | 00000001:00:00.0 Off | Off |\n| N/A 30C P8 9W / 70W | 2MiB / 16384MiB | 0% Default |\n| | | N/A |\n+-----------------------------------------+----------------------+----------------------+\n \n+---------------------------------------------------------------------------------------+\n| Processes: |\n| GPU GI CI PID Type Process name GPU Memory |\n| ID ID Usage |\n|=======================================================================================|\n| No running processes found |\n+---------------------------------------------------------------------------------------+",
|
||||
"stderr": ""
|
||||
},
|
||||
"torch_version": "2.6.0+cu124",
|
||||
"cuda_available": true,
|
||||
"cuda_device_count": 1,
|
||||
"cuda_devices": [
|
||||
{
|
||||
"index": 0,
|
||||
"name": "Tesla T4",
|
||||
"total_memory_gb": 15.575,
|
||||
"major": 7,
|
||||
"minor": 5
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
3
model.safetensors
Normal file
3
model.safetensors
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:2c54c2950a890a64079b791a4b5da452ff2e563765c18f3dbab83fd25a85740c
|
||||
size 3441185296
|
||||
3
tokenizer.json
Normal file
3
tokenizer.json
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:be75606093db2094d7cd20f3c2f385c212750648bd6ea4fb2bf507a6a4c55506
|
||||
size 11422650
|
||||
30
tokenizer_config.json
Normal file
30
tokenizer_config.json
Normal file
@@ -0,0 +1,30 @@
|
||||
{
|
||||
"add_prefix_space": false,
|
||||
"backend": "tokenizers",
|
||||
"bos_token": null,
|
||||
"clean_up_tokenization_spaces": false,
|
||||
"eos_token": "<|im_end|>",
|
||||
"errors": "replace",
|
||||
"extra_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|>"
|
||||
],
|
||||
"is_local": false,
|
||||
"local_files_only": false,
|
||||
"model_max_length": 131072,
|
||||
"pad_token": "<|endoftext|>",
|
||||
"split_special_tokens": false,
|
||||
"tokenizer_class": "Qwen2Tokenizer",
|
||||
"unk_token": null
|
||||
}
|
||||
Reference in New Issue
Block a user