{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/a-neural-span-based-continual-named-entity","title":"A Neural Span-Based Continual Named Entity Recognition Model","arxiv_id":"2302.12200","date":"2023-02-23","proceeding":null,"authors":["Yunan Zhang","Qingcai Chen"],"abstract":"Named Entity Recognition (NER) models capable of Continual Learning (CL) are realistically valuable in areas where entity types continuously increase (e.g., personal assistants). Meanwhile the learning paradigm of NER advances to new patterns such as the span-based methods. However, its potential to CL has not been fully explored. In this paper, we propose SpanKL, a simple yet effective Span-based model with Knowledge distillation (KD) to preserve memories and multi-Label prediction to prevent conflicts in CL-NER. Unlike prior sequence labeling approaches, the inherently independent modeling in span and entity level with the designed coherent optimization on SpanKL promotes its learning at each incremental step and mitigates the forgetting. Experiments on synthetic CL datasets derived from OntoNotes and Few-NERD show that SpanKL significantly outperforms previous SoTA in many aspects, and obtains the smallest gap from CL to the upper bound revealing its high practiced value. The code is available at https://github.com/Qznan/SpanKL.","url_abs":"https://arxiv.org/abs/2302.12200v2","url_pdf":"https://arxiv.org/pdf/2302.12200v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"a-neural-span-based-continual-named-entity","repo_url":"https://github.com/qznan/spankl","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"continual-learning","task_name":"Continual Learning"},{"task_slug":"continual-named-entity-recognition","task_name":"Continual Named Entity Recognition"},{"task_slug":"knowledge-distillation","task_name":"Knowledge Distillation"},{"task_slug":"cg","task_name":"NER"},{"task_slug":"named-entity-recognition-1","task_name":"Named Entity Recognition"},{"task_slug":"named-entity-recognition-ner","task_name":"Named Entity Recognition (NER)"},{"task_slug":"named-entity-recognition","task_name":"named-entity-recognition"}],"methods":[{"method_slug":"knowledge-distillation","method_name":"Knowledge Distillation"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2302.12200","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2302.12200"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"deterministic:regex_extraction","url":"https://github.com/Qznan/SpanKL","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"unverified":11},"by_repo_kind":{"official":{"samples":11,"ran":0,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"5e804cbc6236c15e","entry":"file2items","repo":"Qznan/SpanKL","repo_kind":"official","path":"datautils.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/datautils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"5e804cbc6236c15e"}},{"code_sha256_prefix":"f283db6c60e2e087","entry":"file2list","repo":"Qznan/SpanKL","repo_kind":"official","path":"datautils.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/datautils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"f283db6c60e2e087"}},{"code_sha256_prefix":"c877075c68355860","entry":"file2txt","repo":"Qznan/SpanKL","repo_kind":"official","path":"datautils.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/datautils.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"c877075c68355860"}},{"code_sha256_prefix":"1101c81fbb3d3f6d","entry":"get_char_tokenize_fn","repo":"Qznan/SpanKL","repo_kind":"official","path":"data_reader.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/data_reader.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"1101c81fbb3d3f6d"}},{"code_sha256_prefix":"7f90aea42236850b","entry":"gumbel_sigmoid","repo":"Qznan/SpanKL","repo_kind":"official","path":"modules.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/modules.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"7f90aea42236850b"}},{"code_sha256_prefix":"b5aa7bd0e2bc4104","entry":"gumbel_sigmoid_oldbug","repo":"Qznan/SpanKL","repo_kind":"official","path":"modules.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/modules.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"b5aa7bd0e2bc4104"}},{"code_sha256_prefix":"eecd926ea55841a4","entry":"is_whitespace","repo":"Qznan/SpanKL","repo_kind":"official","path":"data_reader.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/data_reader.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"eecd926ea55841a4"}},{"code_sha256_prefix":"607377e85ab75a8b","entry":"mean_and_std","repo":"Qznan/SpanKL","repo_kind":"official","path":"print_cl_metric.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/print_cl_metric.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"607377e85ab75a8b"}},{"code_sha256_prefix":"8be5cd65e55e3370","entry":"softmax","repo":"Qznan/SpanKL","repo_kind":"official","path":"train_clner.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/train_clner.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"8be5cd65e55e3370"}},{"code_sha256_prefix":"5cea9f3b61bf4da8","entry":"sort_by_idx","repo":"Qznan/SpanKL","repo_kind":"official","path":"ner_loader.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/ner_loader.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"5cea9f3b61bf4da8"}},{"code_sha256_prefix":"ec9d5e276101747b","entry":"transpose_for_scores","repo":"Qznan/SpanKL","repo_kind":"official","path":"modules.py","file_url":"https://github.com/Qznan/SpanKL/blob/HEAD/modules.py","link_basis":"harvester_set","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"ec9d5e276101747b"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}