nielsr HF Staff commited on
Commit
9b4140f
·
verified ·
1 Parent(s): b7ec8e5

Improve model card: Add pipeline tag, library, license, language, datasets, tags, paper, and GitHub links

Browse files

This PR enhances the model card for ShiZhi by:
- Adding `pipeline_tag: text-generation` to enable the inference widget and improve discoverability for text generation tasks.
- Updating `library_name` to `transformers` to reflect compatibility with the Hugging Face Transformers library for the base model, which enables the automated "How to use" widget.
- Including `license: apache-2.0`, `language: zh`, and `datasets: TIM0927/CCVG` in the YAML metadata for clearer information and better filtering.
- Adding relevant `tags` such as `peft`, `lora`, `chinese`, `legal`, and `court-view-generation` to improve searchability.
- Adding a prominent link to the Hugging Face paper page: [ShiZhi: A Chinese Lightweight Large Language Model for Court View Generation](https://huggingface.co/papers/2510.09297).
- Including a direct link to the GitHub repository: [https://github.com/ZhitianHou/ShiZhi](https://github.com/ZhitianHou/ShiZhi).
- Removing the redundant license declaration from the Markdown content now that it's in the metadata.

These changes will significantly improve the model's presentation, discoverability, and user experience on the Hugging Face Hub.

Files changed (1) hide show
  1. README.md +21 -22
README.md CHANGED
@@ -1,19 +1,28 @@
1
  ---
2
  base_model: Qwen2-0.5B-Instruct
3
- library_name: peft
 
 
 
 
 
 
 
 
 
 
 
4
  ---
5
 
6
- # ShiZhi
7
-
8
- [中文](README_zh.md) | 🤖[modelscope](https://modelscope.cn/models/freshman8888/LegalReasoningModel)
9
-
10
 
 
11
 
 
12
 
13
- ShiZhi (释之) is a lightweight large language model designed for Criminal Court View Generation (CVG) in Chinese.
14
- Its name comes from the historical figure Zhang Shizhi (张释之), and in Chinese, “释之” also conveys the meaning of “explaining” or “interpreting,” which is particularly suitable for generating the court view section in legal case documents.
15
-
16
 
 
17
 
18
  ## Model Details
19
 
@@ -21,14 +30,9 @@ Its name comes from the historical figure Zhang Shizhi (张释之), and in Chine
21
 
22
  This model is fine-tuned based on **Qwen2-0.5B-Instruct**, using a dataset of Chinese judicial documents from 1985 to 2021 that has been rigorously cleaned.
23
 
24
-
25
-
26
  - **Language(s) (NLP):** Chinese/zh
27
- - **License:** Apache License 2.0
28
  - **Finetuned from model:** Qwen2-0.5B-Instruct
29
 
30
-
31
-
32
  ## How to Get Started with the Model
33
 
34
  ```python
@@ -55,29 +59,26 @@ engine = PtEngine.from_model_template(model, template, max_batch_size=2)
55
  request_config = RequestConfig(max_tokens=512, temperature=0)
56
 
57
  infer_requests = [
58
- InferRequest(messages=[{'role': 'user', 'content': f"事实描述:\n{fact}\n法院推理:\n"}]),
 
 
 
59
  ]
60
  resp_list = engine.infer(infer_requests, request_config)
61
  query0 = infer_requests[0].messages[0]['content']
62
  print(f'response: {resp_list[0].choices[0].message.content}')
63
  ```
64
 
65
-
66
-
67
  ## Training Details
68
 
69
  ### Training Data
70
 
71
  The training data is a dataset of Chinese judicial documents from 1985 to 2021 that has been rigorously cleaned, [CCVG](https://huggingface.co/datasets/TIM0927/CCVG).
72
 
73
-
74
-
75
  ### Framework versions
76
 
77
  - PEFT 0.12.0
78
 
79
-
80
-
81
  ## Citation
82
 
83
  If you find this project helpful, please consider citing our paper:
@@ -93,8 +94,6 @@ If you find this project helpful, please consider citing our paper:
93
  }
94
  ```
95
 
96
-
97
-
98
  ## Model Disclaimer
99
 
100
  1. **Usage Restriction**: This model is developed and provided **exclusively for academic research purposes** , aiming to offer tool support for academic exploration, technical verification, and theoretical research in relevant fields. The use of this model for any commercial purposes (including but not limited to product development, commercial services, profit - making activities, etc.), illegal activities, or scenarios that violate laws, regulations, public order, and good customs is strictly prohibited.
 
1
  ---
2
  base_model: Qwen2-0.5B-Instruct
3
+ library_name: transformers
4
+ license: apache-2.0
5
+ pipeline_tag: text-generation
6
+ language: zh
7
+ datasets:
8
+ - TIM0927/CCVG
9
+ tags:
10
+ - peft
11
+ - lora
12
+ - chinese
13
+ - legal
14
+ - court-view-generation
15
  ---
16
 
17
+ # ShiZhi: A Chinese Lightweight Large Language Model for Court View Generation
 
 
 
18
 
19
+ This repository contains **ShiZhi (\u91ca\u4e4b)**, a lightweight large language model designed for Criminal Court View Generation (CVG) in Chinese, as presented in the paper [ShiZhi: A Chinese Lightweight Large Language Model for Court View Generation](https://huggingface.co/papers/2510.09297).
20
 
21
+ Code: [https://github.com/ZhitianHou/ShiZhi](https://github.com/ZhitianHou/ShiZhi)
22
 
23
+ [中文](README_zh.md) | 🤖[modelscope](https://modelscope.cn/models/freshman8888/LegalReasoningModel)
 
 
24
 
25
+ Its name comes from the historical figure Zhang Shizhi (\u5f20\u91ca\u4e4b), and in Chinese, \u201c\u91ca\u4e4b\u201d also conveys the meaning of \u201cexplaining\u201d or \u201cinterpreting,\u201d which is particularly suitable for generating the court view section in legal case documents.
26
 
27
  ## Model Details
28
 
 
30
 
31
  This model is fine-tuned based on **Qwen2-0.5B-Instruct**, using a dataset of Chinese judicial documents from 1985 to 2021 that has been rigorously cleaned.
32
 
 
 
33
  - **Language(s) (NLP):** Chinese/zh
 
34
  - **Finetuned from model:** Qwen2-0.5B-Instruct
35
 
 
 
36
  ## How to Get Started with the Model
37
 
38
  ```python
 
59
  request_config = RequestConfig(max_tokens=512, temperature=0)
60
 
61
  infer_requests = [
62
+ InferRequest(messages=[{'role': 'user', 'content': f"事实描述:
63
+ {fact}
64
+ 法院推理:
65
+ "}]),
66
  ]
67
  resp_list = engine.infer(infer_requests, request_config)
68
  query0 = infer_requests[0].messages[0]['content']
69
  print(f'response: {resp_list[0].choices[0].message.content}')
70
  ```
71
 
 
 
72
  ## Training Details
73
 
74
  ### Training Data
75
 
76
  The training data is a dataset of Chinese judicial documents from 1985 to 2021 that has been rigorously cleaned, [CCVG](https://huggingface.co/datasets/TIM0927/CCVG).
77
 
 
 
78
  ### Framework versions
79
 
80
  - PEFT 0.12.0
81
 
 
 
82
  ## Citation
83
 
84
  If you find this project helpful, please consider citing our paper:
 
94
  }
95
  ```
96
 
 
 
97
  ## Model Disclaimer
98
 
99
  1. **Usage Restriction**: This model is developed and provided **exclusively for academic research purposes** , aiming to offer tool support for academic exploration, technical verification, and theoretical research in relevant fields. The use of this model for any commercial purposes (including but not limited to product development, commercial services, profit - making activities, etc.), illegal activities, or scenarios that violate laws, regulations, public order, and good customs is strictly prohibited.