{"id":21949019,"url":"https://github.com/wjn1996/hugnlp","last_synced_at":"2025-04-09T19:19:56.119Z","repository":{"id":130871385,"uuid":"603460458","full_name":"wjn1996/HugNLP","owner":"wjn1996","description":"HugNLP is a unified and comprehensive NLP library based on HuggingFace Transformer. Please hugging for NLP now!😊 HugNLP will released to @HugAILab","archived":false,"fork":false,"pushed_at":"2023-08-07T06:24:14.000Z","size":3886,"stargazers_count":247,"open_issues_count":0,"forks_count":13,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-04-09T19:19:51.978Z","etag":null,"topics":["code-understanding","deep-learning","few-shot-learning","knowledge-enhancement","natural-language-processing","pre-trained-language-models","prompt-based-learning","pytorch","semi-supervised-learning","supervised-learning","transformers"],"latest_commit_sha":null,"homepage":"https://wjn1996.github.io/blogs/HugNLP/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wjn1996.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-02-18T15:29:22.000Z","updated_at":"2025-03-24T09:59:05.000Z","dependencies_parsed_at":null,"dependency_job_id":"de389b7c-eb99-491f-80be-9cbc51e4baf2","html_url":"https://github.com/wjn1996/HugNLP","commit_stats":{"total_commits":110,"total_committers":4,"mean_commits":27.5,"dds":"0.32727272727272727","last_synced_commit":"c9c94f8fcbcc0f17e9238b3bbd9b664d5fb6c1e4"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjn1996%2FHugNLP","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjn1996%2FHugNLP/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjn1996%2FHugNLP/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjn1996%2FHugNLP/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wjn1996","download_url":"https://codeload.github.com/wjn1996/HugNLP/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248094991,"owners_count":21046770,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["code-understanding","deep-learning","few-shot-learning","knowledge-enhancement","natural-language-processing","pre-trained-language-models","prompt-based-learning","pytorch","semi-supervised-learning","supervised-learning","transformers"],"created_at":"2024-11-29T05:19:29.060Z","updated_at":"2025-04-09T19:19:56.094Z","avatar_url":"https://github.com/wjn1996.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\u003cp align=\"center\"\u003e\n    \u003cbr\u003e\n    \u003cimg src=\"images/logo.png\" width=\"360\"/\u003e\n    \u003cbr\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\" style=\"font-size:22px;\"\u003e \u003cb\u003e Welcome to use HugNLP. 🤗 Hugging for NLP! \u003c/b\u003e\n\u003c/p\u003e\n\n\u003cdiv align=\"center\"\u003e\n\n[![CircleCI](https://dl.circleci.com/status-badge/img/gh/wjn1996/HugNLP/tree/main.svg?style=svg)](https://dl.circleci.com/status-badge/redirect/gh/wjn1996/HugNLP/tree/main)\n[![GitHub pull-requests](https://img.shields.io/github/issues-pr/wjn1996/HugNLP.svg)](https://github.com/wjn1996/HugNLP/pull/)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com)\n[![arXiv](https://img.shields.io/badge/arXiv-2302.14286-b31b1b.svg)](https://arxiv.org/abs/2302.14286)\n\n\u003c/div\u003e\n\n### HugNLP is released at @HugAILab , you can see at [https://github.com/HugAILab/HugNLP](https://github.com/HugAILab/HugNLP).\n### HugNLP框架在 @HugAILab 发布，仓库迁移至[https://github.com/HugAILab/HugNLP](https://github.com/HugAILab/HugNLP).\n\n# About HugNLP\n\nHugNLP is a novel development and application library based on [Hugging Face](https://huggingface.co/) for improving the convenience and effectiveness of NLP researchers. The founder and main developer is [Jianing Wang](https://wjn1996.github.io/). The collaborators are [Nuo Chen](https://github.com/nchen909) and [Qiushi Sun](https://github.com/QiushiSun).\n\n## **News \u0026 Highlights\n\n- 🆕 [23-08-06]: Our HugNLP paper has been accepted by CIKM 2023 (Demo Track)!\n- 🆕 [23-04-06]: Develop a small ChatGPT-like assistance, naming HugChat! You can chat with HugNLP! [[see doc](./documents/instruction_prompting/generative_instruction_tuning.md)]\n- 🆕 [23-04-02]: Add GPT-style instruction-tuning. You can continual train a small-scale ChatGPT! [[see doc](./documents/instruction_prompting/generative_instruction_tuning.md)]\n- 🆕 [23-03-21]: Finish GPT-style in-context learning for sequence classification. [[see doc](./documents/instruction_prompting/incontext_learning_for_cls.md)]\n- 🆕 [23-03-13]: Add code clone detection and defect task. You can train clone and defect for user-defined dataset.\n- 🆕 [23-03-03]: Add HugIE API and corresponding training script. You can use it to perform information extraction on Chinese data. [[see doc](./documents/information_extraction/HugIE.md)]\n- 🆕 [23-02-18]: The HugNLP is open!\n\n# Architecture\n\nThe framework overview is shown as follows:\n\n\u003cp align=\"center\"\u003e\n    \u003cbr\u003e\n    \u003cimg src=\"images/overview.png\" width=\"80%\"/\u003e\n    \u003cbr\u003e\n\u003cp\u003e\n\n### Models\n\nIn HugNLP, we provide some popular transformer-based models as backbones, such as BERT, RoBERTa, GPT-2, etc. We also release our pre-built KP-PLM, a novel knowledge-enhanced pre-training paradigm to inject factual knowledge and can be easily used for arbitrary PLMs.\nApart from basic PLMs, we also implement some task-specific models, involving sequence classification, matching, labeling, span extraction, multi-choice, and text generation.\nNotably, we develop standard fine-tuning (based on CLS Head and prompt-tuning models that enable PLM tuning on classification tasks.\nFor few-shot learning settings, HugNLP provides a prototypical network in both few-shot text classification and named entity recognition (NER).\n\nIn addition, we also incorporate some plug-and-play utils in HugNLP.\n\n1. Parameter Freezing. If we want to perform parameter-efficient learning, which aims to freeze some parameters in PLMs to improve the training efficiency, we can set the configure `use_freezing` and freeze the backbone. A use case is shown in Code.\n2. Uncertainty Estimation aims to calculate the model certainty when in semi-supervised learning.\n3. We also design Prediction Calibration, which can be used to further improve the accuracy by calibrating the distribution and alleviating the semantics bias problem.\n\n### Processors\n\nProcessors aim to load the dataset and process the task examples in a pipeline containing sentence tokenization, sampling, and tensor generation.\nSpecifically, users can directly obtain the data through `load_dataset`, which can directly download it from the Internet or load it from the local disk.\nFor different tasks, users should define a task-specific data collator, which aims to transform the original examples into model input tensor features.\n\n### Applications\n\nIt provides rich modules for users to build real-world applications and products by selecting among an array of settings from Models and Processors.\n\n# Core Capacities\n\nWe provide some core capacities to support the NLP downstream applications.\n\n### Knowledge-enhanced Pre-trained Language Model\n\nConventional pre-training methods lack factual knowledge.\nTo deal with this issue, we present KP-PLM with a novel knowledge prompting paradigm for knowledge-enhanced pre-training.\nSpecifically, we construct a knowledge sub-graph for each input text by recognizing entities and aligning with the knowledge base and decompose this sub-graph into multiple relation paths, which can be directly transformed into language prompts.\n\n### Prompt-based Fine-tuning\n\nPrompt-based fine-tuning aims to reuse the pre-training objective (e.g., Masked Language Modeling, Causal Language Modeling) and utilizes a well-designed template and verbalizer to make predictions, which has achieved great success in low-resource settings.\nWe integrate some novel approaches into HugNLP, such as PET, P-tuning, etc.\n\n### Instruction Tuning \u0026 In-Context Learning\n\nInstruction-tuning and in-context learning enable few/zero-shot learning without parameter update, which aims to concatenate the task-aware instructions or example-based demonstrations to prompt GPT-style PLMs to generate reliable responses.\nSo, all the NLP tasks can be unified into the same format and can substantially improve the models\" generalization.\nInspired by this idea, we extend it into other two paradigms:\n\n1. extractive-style paradigm: we unify various NLP tasks into span extraction, which is the same as extractive question answering.\n2. inference-style paradigm: all the tasks can be viewed as natural language inference to match the relations between inputs and outputs.\n3. generative-style paradigm: we unify all the tasks into generative format, and train the causal models based on instruction-tuning, in-context learning or chain-of-thought.\n\n### Self-training with Uncertainty Estimation\n\nSelf-training can address the labeled data scarcity issue by leveraging the large-scale unlabeled data in addition to labeled data, which is one of the mature paradigms in semi-supervised learning.\nHowever, the standard self-training may generate too much noise, inevitably degrading the model performance due to confirmation bias.\nThus, we present uncertainty-aware self-training. Specifically, we train a teacher model on few-shot labeled data, and then use Monte Carlo (MC) dropout technique in Bayesian neural network (BNN) to approximate the model certainty, and judiciously select the examples that have a higher model certainty of the teacher.\n\n### Parameter-Efficient Learning\n\nTo improve the training efficiency of HugNLP, we also implement parameter-efficient learning, which aims to freeze some parameters in the backbone so that we only tune a few parameters during model training.\nWe develop some novel parameter-efficient learning approaches, such as Prefix-tuning, Adapter-tuning, BitFit and LoRA, etc.\n\n# Installation\n\n\u003e git clone https://github.com/wjn1996/HugNLP.git\n\u003e\n\u003e cd HugNLP\n\u003e\n\u003e python3 setup.py install\n\nAt present, the project is still being developed and improved, and there may be some `bugs` in use, please understand. We also look forward to your being able to ask issues or committing some valuable pull requests.\n\n# Pre-built Applications Overview\n\nWe demonstrate all pre-built applications in HugNLP. You can choose one application to use HugNLP. You can also click the link to see the details document.\n\n| **Applications** | **Runing Tasks** | **Task Notes** | **PLM Models** | **Documents** |\n| --- | --- | --- | --- | --- |\n| **Default Application** | run_seq_cls.sh | **Goal**: Standard **Fine-tuning** or **Prompt-tuning** for sequence classification on user-defined dataset. \u003cbr\u003e **Path**: applications/default_applications | BERT, RoBERTa, DeBERTa | [click](./documents/default_tasks/default_sequence_classification.md) |\n|  | run_seq_labeling.sh | **Goal**: Standard **Fine-tuning** for sequence labeling on user-defined dataset. \u003cbr\u003e **Path**: applications/default_applications | BERT, RoBERTa, ALBERT |   |\n| **Pre-training** | run_pretrain_mlm.sh | **Goal**: Pre-training via **Masked Language Modeling** (MLM). \u003cbr\u003e **Path**: applications/pretraining/ | BERT, RoBERTa | [click](./documents/pretraining/Masked%20LM%20for%20Continual%20Pre-training.md) |\n|  | run_pretrain_casual_lm.sh | **Goal**: Pre-training via **Causal Language Modeling** (CLM). \u003cbr\u003e **Path**: applications/pretraining | BERT, RoBERTa | [click](./documents/pretraining/Causal%20LM%20for%20Continual%20Pre-training.md) |\n| **GLUE Benchmark** | run_glue.sh | **Goal**: Standard **Fine-tuning** or **Prompt-tuning** for GLUE classification tasks. \u003cbr\u003e **Path**: applications/benchmark/glue | BERT, RoBERTa, DeBERTa |  |\n|  | run_causal_incontext_glue.sh | **Goal**: **In-context learning** for GLUE classification tasks. \u003cbr\u003e **Path**: applications/benchmark/glue | GPT-2 |  |\n| **CLUE Benchmark** | clue_finetune_dev.sh | **Goal**: Standard **Fine-tuning** and **Prompt-tuning** for CLUE classification task。 \u003cbr\u003e **Path**: applications/benchmark/clue | BERT, RoBERTa, DeBERTa |  |\n|  | run_clue_cmrc.sh | **Goal**: Standard **Fine-tuning** for CLUE CMRC2018 task. \u003cbr\u003e **Path**: applications/benchmark/cluemrc | BERT, RoBERTa, DeBERTa |  |\n|  | run_clue_c3.sh | **Goal**: Standard **Fine-tuning** for CLUE C3 task. \u003cbr\u003e **Path**: applications/benchmark/cluemrc | BERT, RoBERTa, DeBERTa |  |\n|  | run_clue_chid.sh | **Goal**: Standard **Fine-tuning** for CLUE CHID task. \u003cbr\u003e **Path**: applications/benchmark/cluemrc | BERT, RoBERTa, DeBERTa |  |\n| **Instruction-Prompting** | run_causal_instruction.sh | **Goal**: **Cross-task training** via generative Instruction-tuning based on causal PLM. \u003cfont color='red'\u003e**You can use it to train a small ChatGPT**\u003c/font\u003e. \u003cbr\u003e **Path**: applications/instruction_prompting/instruction_tuning | GPT2 | [click](./documents/instruction_prompting/generative_instruction_tuning.md) |\n|  | run_zh_extract_instruction.sh | **Goal**: **Cross-task training** via extractive Instruction-tuning based on Global Pointer model. \u003cbr\u003e **Path**: applications/instruction_prompting/chinese_instruction | BERT, RoBERTa, DeBERTa | [click](./documents/instruction_prompting/extractive_instruction_tuning.md) |\n|  | run_causal_incontext_cls.sh | **Goal**: **In-context learning** for user-defined classification tasks. \u003cbr\u003e **Path**: applications/instruction_prompting/incontext_learning | GPT-2 | [click](./documents/instruction_prompting/incontext_learning_for_cls.md) |\n| **Information Extraction** | run_extractive_unified_ie.sh | **Goal**: **HugIE**: training a unified chinese information extraction via extractive instruction-tuning. \u003cbr\u003e **Path**: applications/information_extraction/HugIE | BERT, RoBERTa, DeBERTa | [click](./documents/information_extraction/HugIE.md) |\n|  | api_test.py | **Goal**: HugIE: API test. \u003cbr\u003e **Path**: applications/information_extraction/HugIE | - | [click](./documents/information_extraction/HugIE.md) |\n|  | run_fewnerd.sh | **Goal**: **Prototypical learning** for named entity recognition, including SpanProto, TokenProto \u003cbr\u003e **Path**: applications/information_extraction/fewshot_ner | BERT |  |\n| **Code NLU** | run_clone_cls.sh | **Goal**: Standard **Fine-tuning** for code clone classification task. \u003cbr\u003e **Path**: applications/code/code_clone | CodeBERT, CodeT5, GraphCodeBERT, PLBART |  |\n|  | run_defect_cls.sh | **Goal**: Standard **Fine-tuning** for code defect classification task. \u003cbr\u003e **Path**: applications/code/code_defect | CodeBERT, CodeT5, GraphCodeBERT, PLBART |  |\n\nMore details of the pre-built applications and settings with the designed models and processors can be found in [HugNLP Documents](./documents/README.md).\n\n# Quick Use\n\nHere we provide an example to show you to quick use HugNLP.\nIf you want to perform a classification task on user-defined dataset, you can prepare three json files (``train.json``, ``dev.json``, ``test.json``) on a directory. And you can run the script file\n\n\u003e bash ./application/default_applications/run_seq_cls.sh\n\nBefore the experiment, you must define the following parameters in the script file ``run_seq_cls.sh``.\n\n- --model_name_or_path: the pre-trained model name or path. e.g. bert-base-uncased\n- --data_path: the path of the dataset (including ``train.json``, ``dev.json`` and ``test.json``), e.g. ``./datasets/data_example/cls/``.\n- --user_defined: you must define label_names if there is not exist a ``label_names.txt``.\n\nIf you want to use prompt-based fine-tuning, you can add the following parameters:\n\n- --use_prompt_for_cls\n- ---task_type: one of ``masked_prompt_cls``, ``masked_prompt_prefix_cls``,``masked_prompt_ptuning_cls``, ``masked_prompt_adapter_cls``.\n\nYou also should add ``template.json`` and ``label_words_mapping.json``.\n\nIf you wang to use parameter-efficient learning, you can add the following parameter:\n\n- --use_freezing\n\nThe example of ``run_seq_cls.sh`` is:\n\n```bash\npath=chinese-macbert-base\nMODEL_TYPE=bert\ndata_path=/wjn/frameworks/HugNLP/datasets/data_example/cls\nTASK_TYPE=head_cls\nlen=196\nbz=4\nepoch=10\neval_step=50\nwr_step=10\nlr=1e-05\n\nexport CUDA_VISIBLE_DEVICES=0,1\npython3 -m torch.distributed.launch --nproc_per_node=2 --master_port=6014 hugnlp_runner.py \\\n--model_name_or_path=$path \\\n--data_dir=$data_path \\\n--output_dir=./outputs/default/sequence_classification\\\n--seed=42 \\\n--exp_name=default-cls \\\n--max_seq_length=$len \\\n--max_eval_seq_length=$len \\\n--do_train \\\n--do_eval \\\n--do_predict \\\n--per_device_train_batch_size=$bz \\\n--per_device_eval_batch_size=4 \\\n--gradient_accumulation_steps=1 \\\n--evaluation_strategy=steps \\\n--learning_rate=$lr \\\n--num_train_epochs=$epoch \\\n--logging_steps=100000000 \\\n--eval_steps=$eval_step \\\n--save_steps=$eval_step \\\n--save_total_limit=1 \\\n--warmup_steps=$wr_step \\\n--load_best_model_at_end \\\n--report_to=none \\\n--task_name=default_cls \\\n--task_type=$TASK_TYPE \\\n--model_type=$MODEL_TYPE \\\n--metric_for_best_model=acc \\\n--pad_to_max_length=True \\\n--remove_unused_columns=False \\\n--overwrite_output_dir \\\n--fp16 \\\n--label_names=labels \\\n--keep_predict_labels \\\n--user_defined=\"label_names=entailment,neutral,contradiction\"\n```\n\n# Quick Develop\n\nThis section is for developer.\nHugNLP is easy to use and develop. We draw a workflow in the following figure to show how to develop a new running task.\n\n\u003cp align=\"center\"\u003e\n    \u003cbr\u003e\n    \u003cimg src=\"images/workflow.png\" width=\"90%\"/\u003e\n    \u003cbr\u003e\n\u003c/p\u003e\nIt consists of five main steps, including library installation, data preparation, processor selection or design, model selection or design, and application design.\nThis illustrates that HugNLP can simplify the implementation of complex NLP models and tasks.\n\n# Demo API Example\n\nHere, we show an example of the pre-built API application: **HugIE: Towards Chinese Unified Information Extraction via Extractive MRC and Instruction-tuning**.\n\n### Introduction:\n\nInformation Extraction (IE) aims to extract structure knowledge from un-structure text. The structure knowledge is formed as a triple \"\"(head_entity, relation, tail_entity)\"\". IE consists of two main tasks:\n\n- Named Entity Recognition (NER) aims to extract all entity mentions of one type.\n- Relation Extraction (RE). It has two kinds of goal, the first aims to classify the relation between two entities, and the second aims to predict the tail entity when given one head entity and the corresponding relation.\n\n### Solutions:\n\n- We unify the tasks of NER and RE into the paradigm of extractive question answering (i.e., machine reading comprehension).\n- We design task-specific instruction and language prompts for NER and RE.\n\n\u003e For the NER task:\n\u003e\n\u003e - instruction: \"找到文章中所有【{entity_type}】类型的实体？文章：【{passage_text}】\"\n\u003e\n\u003e For the RE task:\n\u003e\n\u003e - instruction: \"找到文章中【{head_entity}】的【{relation}】？文章：【{passage_text}】\"\n\n- During the training, we utilize Global Pointer with Chinese-Macbert as the basic model.；\n\n### Usage:\n\nOur model is saved in Hugging Face: [https://huggingface.co/wjn1996/wjn1996-hugnlp-hugie-large-zh](https://huggingface.co/wjn1996/wjn1996-hugnlp-hugie-large-zh).\n\nQuick use HugIE for Chinese information extraction：\n\n```python\nfrom applications.information_extraction.HugIE.api_test import HugIEAPI\nmodel_type = \"bert\"\nhugie_model_name_or_path = \"wjn1996/wjn1996-hugnlp-hugie-large-zh\"\nhugie = HugIEAPI(\"bert\", hugie_model_name_or_path)\ntext = \"央广网北京2月23日消息 据中国地震台网正式测定，2月23日8时37分在塔吉克斯坦发生7.2级地震，震源深度10公里，震中位于北纬37.98度，东经73.29度，距我国边境线最近约82公里，地震造成新疆喀什等地震感强烈。\"\n\nentity = \"塔吉克斯坦地震\"\nrelation = \"震源位置\"\npredictions, topk_predictions = hugie.request(text, entity, relation=relation)\nprint(\"entity:{}, relation:{}\".format(entity, relation))\nprint(\"predictions:\\n{}\".format(predictions))\nprint(\"topk_predictions:\\n{}\".format(predictions))\nprint(\"\\n\\n\")\n\n\"\"\"\n# 事件信息输出结果：\nentity:塔吉克斯坦地震, relation:震源位置\npredictions:\n{0: [\"10公里\", \"距我国边境线最近约82公里\", \"北纬37.98度，东经73.29度\", \"北纬37.98度，东经73.29度，距我国边境线最近约82公里\"]}\ntopk_predictions:\n{0: [{\"answer\": \"10公里\", \"prob\": 0.9895901083946228, \"pos\": [(80, 84)]}, {\"answer\": \"距我国边境线最近约82公里\", \"prob\": 0.8584909439086914, \"pos\": [(107, 120)]}, {\"answer\": \"北纬37.98度，东经73.29度\", \"prob\": 0.7202121615409851, \"pos\": [(89, 106)]}, {\"answer\": \"北纬37.98度，东经73.29度，距我国边境线最近约82公里\", \"prob\": 0.11628123372793198, \"pos\": [(89, 120)]}]}\n\"\"\"\n\nentity = \"塔吉克斯坦地震\"\nrelation = \"时间\"\npredictions, topk_predictions = hugie.request(text, entity, relation=relation)\nprint(\"entity:{}, relation:{}\".format(entity, relation))\nprint(\"predictions:\\n{}\".format(predictions))\nprint(\"topk_predictions:\\n{}\".format(predictions))\nprint(\"\\n\\n\")\n\n\"\"\"\n# 事件信息输出结果：\nentity:塔吉克斯坦地震, relation:时间\npredictions:\n{0: [\"2月23日8时37分\"]}\ntopk_predictions:\n{0: [{\"answer\": \"2月23日8时37分\", \"prob\": 0.9999995231628418, \"pos\": [(49, 59)]}]}\n\"\"\"\n```\n\n# Contact\n\nYou can contact the author `Jianing Wang` from github.\nThe interaction group in QQ or dingding will come soon.\n\n# Cite Me\n\nIf you find this repository helpful, feel free to cite our paper:\n\n```latex\n@misc{wang2023hugnlp,\n  doi       = {10.48550/ARXIV.2302.14286},\n  url       = {https://arxiv.org/abs/2302.14286},\n  author    = {Jianing Wang, Nuo Chen, Qiushi Sun, Wenkang Huang, Chengyu Wang, Ming Gao},\n  title     = {HugNLP: A Unified and Comprehensive Library for Natural Language Processing},\n  year      = {2023}\n}\n```\n\n# References\n\n1. Jianing Wang, Wenkang Huang, Minghui Qiu, Qiuhui Shi, Hongbin Wang, Xiang Li, Ming Gao:\n   Knowledge Prompting in Pre-trained Language Model for Natural Language Understanding. EMNLP 2022: 3164-3177\n2. Chengyu Wang, Jianing Wang, Minghui Qiu, Jun Huang, Ming Gao: TransPrompt: Towards an Automatic Transferable Prompting Framework for Few-shot Text Classification. EMNLP 2021: 2792-2802\n3. Jianing Wang, Chengyu Wang, Jun Huang, Ming Gao, Aoying Zhou: Uncertainty-aware Self-training for Low-resource Neural Sequence Labeling. AAAI 2023.\n\n# Acknowledgement\n\nWe thank to the Platform of AI (PAI) in Alibaba Group to support our work. The friend framework is [EasyNLP](https://github.com/alibaba/EasyNLP). We also thank all the developers that contribute to our work!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwjn1996%2Fhugnlp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwjn1996%2Fhugnlp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwjn1996%2Fhugnlp/lists"}