PaddlePaddle / PaddleNLP

👑 Easy-to-use and powerful NLP and LLM library with 🤗 Awesome model zoo, supporting wide-range of NLP tasks from research to industrial applications, including 🗂Text Classification, 🔍 Neural Search, ❓ Question Answering, ℹ️ Information Extraction, 📄 Document Intelligence, 💌 Sentiment Analysis etc.
https://paddlenlp.readthedocs.io
Apache License 2.0
12.16k stars 2.94k forks source link

所有模型怎么打包下载? #2288

Closed yuanjie-ai closed 1 year ago

LemonNoel commented 2 years ago

可以详细描述下需求吗,是指开源模型参数还是什么模型?

yuanjie-ai commented 2 years ago

可以详细描述下需求吗,是指开源模型参数还是什么模型? 就比如这些模型

TASKS = { 'dependency_parsing': { "models": { "ddparser": { "task_class": DDParserTask, "task_flag": 'dependency_parsing-biaffine', }, "ddparser-ernie-1.0": { "task_class": DDParserTask, "task_flag": 'dependency_parsing-ernie-1.0', }, "ddparser-ernie-gram-zh": { "task_class": DDParserTask, "task_flag": 'dependency_parsing-ernie-gram-zh', }, }, "default": { "model": "ddparser", } }, 'dialogue': { "models": { "plato-mini": { "task_class": DialogueTask, "task_flag": "dialogue-plato-mini" }, }, "default": { "model": "plato-mini", } }, "knowledge_mining": { "models": { "wordtag": { "task_class": WordTagTask, "task_flag": 'knowledge_mining-wordtag', "task_priority_path": "wordtag", }, "nptag": { "task_class": NPTagTask, "task_flag": 'knowledge_mining-nptag', }, }, "default": { "model": "wordtag", } }, "lexical_analysis": { "models": { "lac": { "task_class": LacTask, "hidden_size": 128, "emb_dim": 128, "task_flag": 'lexical_analysis-gru_crf', "task_priority_path": "lac", } }, "default": { "model": "lac" } }, "ner": { "modes": { "accurate": { "task_class": NERWordTagTask, "task_flag": "ner-wordtag", "task_priority_path": "wordtag", "linking": False, }, "fast": { "task_class": NERLACTask, "hidden_size": 128, "emb_dim": 128, "task_flag": "ner-lac", "task_priority_path": "lac", } }, "default": { "mode": "accurate" } }, "poetry_generation": { "models": { "gpt-cpm-large-cn": { "task_class": PoetryGenerationTask, "task_flag": 'poetry_generation-gpt-cpm-large-cn', "task_priority_path": "gpt-cpm-large-cn", }, }, "default": { "model": "gpt-cpm-large-cn", } }, "pos_tagging": { "models": { "lac": { "task_class": POSTaggingTask, "hidden_size": 128, "emb_dim": 128, "task_flag": 'pos_tagging-gru_crf', "task_priority_path": "lac", } }, "default": { "model": "lac" } }, "question_answering": { "models": { "gpt-cpm-large-cn": { "task_class": QuestionAnsweringTask, "task_flag": 'question_answering-gpt-cpm-large-cn', "task_priority_path": "gpt-cpm-large-cn", }, }, "default": { "model": "gpt-cpm-large-cn", } }, 'sentiment_analysis': { "models": { "bilstm": { "task_class": SentaTask, "task_flag": 'sentiment_analysis-bilstm', }, "skep_ernie_1.0_large_ch": { "task_class": SkepTask, "task_flag": 'sentiment_analysis-skep_ernie_1.0_large_ch', } }, "default": { "model": "bilstm" } }, 'text_correction': { "models": { "ernie-csc": { "task_class": CSCTask, "task_flag": "text_correction-ernie-csc" }, }, "default": { "model": "ernie-csc" } }, 'text_similarity': { "models": { "simbert-base-chinese": { "task_class": TextSimilarityTask, "task_flag": "text_similarity-simbert-base-chinese" }, }, "default": { "model": "simbert-base-chinese" } }, "word_segmentation": { "modes": { "fast": { "task_class": SegJiebaTask, "task_flag": "word_segmentation-jieba", }, "base": { "task_class": SegLACTask, "hidden_size": 128, "emb_dim": 128, "task_flag": "word_segmentation-gru_crf", "task_priority_path": "lac", }, "accurate": { "task_class": SegWordTagTask, "task_flag": "word_segmentation-wordtag", "task_priority_path": "wordtag", "linking": False, }, }, "default": { "mode": "base" } }, 'information_extraction': { "models": { "uie-base": { "task_class": UIETask, "hidden_size": 768, "task_flag": "information_extraction-uie-base" }, "uie-tiny": { "task_class": UIETask, "hidden_size": 768, "task_flag": "information_extraction-uie-tiny" }, "uie-medical-base": { "task_class": UIETask, "hidden_size": 768, "task_flag": "information_extraction-uie-medical-base" }, }, "default": { "model": "uie-base" } } }

wawltor commented 2 years ago

你好,每个任务的下载地址都是在相应的任务文件中,例如在信息抽取的任务中可以看这个文件 https://github.com/PaddlePaddle/PaddleNLP/blob/461fc20d9ce35e51ed80b89aa4ab039c9493a310/paddlenlp/taskflow/information_extraction.py#L87 其他任务的下载地址都是相应的目录中可以参考下面的方式

image
github-actions[bot] commented 1 year ago

This issue is stale because it has been open for 60 days with no activity. 当前issue 60天内无活动,被标记为stale。

github-actions[bot] commented 1 year ago

This issue was closed because it has been inactive for 14 days since being marked as stale. 当前issue 被标记为stale已有14天,即将关闭。