arXiv:2602.05550cs.SEcs.CL2026-02

首个面向OpenHarmony ArkTS语言的代码检索数据集与评估基准

ArkTS-CodeSearch: A Open-Source ArkTS Dataset for Code Retrieval

  • 从GitHub/Gitee爬取开源项目,用tree-sitter提取注释-函数对
  • 构建包含10万+函数对的ArkTS数据集,验证现有模型性能并微调出最优模型
  • 适合做国产系统代码智能、鸿蒙生态开发工具的研究者使用

ArkTS是OpenHarmony生态的核心编程语言,但其代码智能研究受限于缺乏公开数据集与评估基准。本文从GitHub和Gitee爬取ArkTS开源项目,利用tree-sitter-arkts提取注释-函数对,经过跨平台去重与函数类型统计分析,构建大规模数据集,用于代码检索与评估任务。设计单搜索任务:以自然语言注释检索对应ArkTS函数。评估现有开源代码嵌入模型,并在ArkTS与TypeScript数据集上进行微调,得到高性能的ArkTS代码理解模型。本工作建立了首个系统性的ArkTS代码检索基准。数据集与微调模型已开源,地址为https://huggingface.co/hreyulog/embedinggemma_arkts 和 https://huggingface.co/datasets/hreyulog/arkts-code-docstring。

原文摘要 · Abstract (English)

ArkTS is a core programming language in the OpenHarmony ecosystem, yet research on ArkTS code intelligence is hindered by the lack of public datasets and evaluation benchmarks. This paper presents a large-scale ArkTS dataset constructed from open-source repositories, targeting code retrieval and code evaluation tasks. We design a single-search task, where natural language comments are used to retrieve corresponding ArkTS functions. ArkTS repositories are crawled from GitHub and Gitee, and comment-function pairs are extracted using tree-sitter-arkts, followed by cross-platform deduplication and statistical analysis of ArkTS function types. We further evaluate existing open-source code embedding models on the single-search task and perform fine-tuning using both ArkTS and TypeScript training datasets, resulting in a high-performing model for ArkTS code understanding. This work establishes the first systematic benchmark for ArkTS code retrieval. Both the dataset and our fine-tuned model are available at https://huggingface.co/hreyulog/embedinggemma_arkts and https://huggingface.co/datasets/hreyulog/arkts-code-docstring .

代码检索鸿蒙生态数据集

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。