{"id":23587685,"url":"https://github.com/XiaoMi/subllm","last_synced_at":"2025-08-30T04:31:16.305Z","repository":{"id":252951923,"uuid":"841856549","full_name":"XiaoMi/subllm","owner":"XiaoMi","description":"This repository is the official implementation of the ECAI 2024 conference paper SUBLLM: A Novel Efficient Architecture with Token Sequence Subsampling for LLM","archived":false,"fork":false,"pushed_at":"2024-08-13T14:39:24.000Z","size":254,"stargazers_count":67,"open_issues_count":1,"forks_count":4,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-04-10T02:18:31.703Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/XiaoMi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2024-08-13T07:19:31.000Z","updated_at":"2025-01-06T11:27:49.000Z","dependencies_parsed_at":"2024-08-13T16:43:40.470Z","dependency_job_id":null,"html_url":"https://github.com/XiaoMi/subllm","commit_stats":null,"previous_names":["xiaomi/subllm"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/XiaoMi/subllm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XiaoMi%2Fsubllm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XiaoMi%2Fsubllm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XiaoMi%2Fsubllm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XiaoMi%2Fsubllm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/XiaoMi","download_url":"https://codeload.github.com/XiaoMi/subllm/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XiaoMi%2Fsubllm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272805294,"owners_count":24995909,"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","status":"online","status_checked_at":"2025-08-30T02:00:09.474Z","response_time":77,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-12-27T05:01:40.203Z","updated_at":"2025-08-30T04:31:16.013Z","avatar_url":"https://github.com/XiaoMi.png","language":"Python","funding_links":[],"categories":["A01_文本生成_文本对话"],"sub_categories":["大语言对话模型及数据"],"readme":"# SUBLLM\n\nThis repository is the official implementation of the ECAI 2024 conference paper [**SUBLLM: A Novel Efficient Architecture with Token Sequence Subsampling for LLM**](https://arxiv.org/abs/2406.06571)\n\n![](./assets/subllm_structure.jpg)\n\n## News and Updates\n* 2024.8.13 We release the model inference code, including the streaming inference and few-shot evaluation codes, and the model structure of SUBLLM to help better understand its module details.\n\n## Evaluation\nThe test results on benchmarks of training a 1.3B model with a training window length of 4k.\n| Model             |   MMLU   |  BBH  |  AGIEval   |\n|:------------------|:--------:|:--------:|:--------:|\n|                   |  5-shot  |  3-shot  |  5-shot  |\n| LLaMA         |   26.23   |   23.70  |   16.76   |\n| SUBLLM        |   **26.41**   |   **24.17**   |   **17.64**  |\n\n## Stream Inference \n\n```shell \ncd inference \nsh infer.sh\n```\n\n## Fewshot\n\n```shell\n# data preparation \ncd fewshot_eval\npython download_data.py \n# run fewshot task\nsh fewshot.sh $MODEL_PATH $CONFIG_PATH $TOKENIZER_PATH $RSLT_PATH $MAX_LEN $TASK $N_SHOT\n```\n\n\n## Citations\nPlease cite the paper if this repository is useful for you.\n\n```bibtex\n@article{wang2024subllm,\n      title={SUBLLM: A Novel Efficient Architecture with Token Sequence Subsampling for LLM}, \n      author={Quandong Wang and Yuxuan Yuan and Xiaoyu Yang and Ruike Zhang and Kang Zhao and Wei Liu and Jian Luan and Daniel Povey and Bin Wang},\n      journal={arXiv preprint arXiv:2406.06571},\n      year={2024},\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FXiaoMi%2Fsubllm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FXiaoMi%2Fsubllm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FXiaoMi%2Fsubllm/lists"}