hmCodeTrans: Human-Machine Interactive Code Translation

被引:0
作者
Liu, Jiaqi [1 ]
Zhang, Fengming [1 ]
Zhang, Xin [1 ]
Yu, Zhiwen [1 ,2 ]
Wang, Liang [1 ]
Zhang, Yao [1 ]
Guo, Bin [1 ]
机构
[1] Northwestern Polytech Univ, Sch Comp Sci, Xian 710129, Peoples R China
[2] Haerbin Engn Univ, Harbin 150001, Peoples R China
关键词
Code translation; human-machine collaboration; interactive translation;
D O I
10.1109/TSE.2024.3379583
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Code translation, i.e., translating one kind of code language to another, plays an important role in scenarios such as application modernization and multi-language versions of applications on different platforms. Even the most advanced machine-based code translation methods can not guarantee an error-free result. Therefore, the participance of software engineer is necessary. Considering both accuracy and efficiency, it is suggested to work in a human-machine collaborative way. However, in many realistic scenarios, human and machine collaborate ineffectively - model translates first and then human makes further editing, without any interaction. To solve this problem, we propose hmCodeTrans, a novel method that achieves code translation in an interactive human-machine collaborative way. It can (1) save the human effort by introducing two novel human-machine collaboration patterns: prefix-based and segment-based ones, which feed the software engineer's sequential or scattered editing back to model and thus enabling the model to make a better retranslation; (2) reduce the response time based on two proposed modules: attention cache module that avoids duplicate prefix inference with cached attention information, and suffix splicing module that reduces invalid suffix inference by splicing a predefined suffix. The experiments are conducted on two real datasets. Results show that compared with the baselines, our approach can effectively save the human effort and reduce the response time. Last but not least, a user study involving five real software engineers is given, which validates that the proposed approach owns the lowest human effort and shows the users' satisfaction towards the approach.
引用
收藏
页码:1163 / 1181
页数:19
相关论文
共 50 条
  • [1] Acknowledging the needs of computer-assisted translation tools users: the human perspective in human-machine translation
    Taravella, AnneMarie
    Villeneuve, Alain O.
    JOURNAL OF SPECIALISED TRANSLATION, 2013, (19) : 62 - 74
  • [2] Human-Machine Interactive Learning Method Based on Active Learning for Smart Workshop Dynamic Scheduling
    Wang, Dongyuan
    Guan, Liuen
    Liu, Juan
    Ding, Chen
    Qiao, Fei
    IEEE TRANSACTIONS ON HUMAN-MACHINE SYSTEMS, 2023, 53 (06) : 1038 - 1047
  • [3] Design and control a hybrid human-machine collaborative manufacturing system in operational management technology to enhance human-machine collaboration
    Wang, Tao
    Zhan, Weiming
    INTERNATIONAL JOURNAL OF ADVANCED MANUFACTURING TECHNOLOGY, 2024,
  • [4] Engineering Human-Machine Teams for Trusted Collaboration
    Alhaji, Basel
    Beecken, Janine
    Ehlers, Ruediger
    Gertheiss, Jan
    Merz, Felix
    Mueller, Joerg P.
    Prilla, Michael
    Rausch, Andreas
    Reinhardt, Andreas
    Reinhardt, Delphine
    Rembe, Christian
    Rohweder, Niels-Ole
    Schwindt, Christoph
    Westphal, Stephan
    Zimmermann, Juergen
    BIG DATA AND COGNITIVE COMPUTING, 2020, 4 (04) : 1 - 30
  • [5] HUMAN-MACHINE COLLABORATION FOR MEDICAL IMAGE SEGMENTATION
    Ravanbakhsh, Mahdyar
    Tschernezki, Vadim
    Last, Felix
    Klein, Tassilo
    Batmanghelich, Kayhan
    Tresp, Volker
    Nabi, Moin
    2020 IEEE INTERNATIONAL CONFERENCE ON ACOUSTICS, SPEECH, AND SIGNAL PROCESSING, 2020, : 1040 - 1044
  • [6] OPTIMIZING HUMAN-MACHINE SYSTEMS IN AUTOMATED ENVIRONMENTS
    Xing, H. R.
    INTERNATIONAL JOURNAL OF SIMULATION MODELLING, 2024, 23 (04) : 716 - 727
  • [7] Human-machine collaboration in managerial decision making
    Haesevoets, Tessa
    De Cremer, David
    Dierckx, Kim
    Van Hiel, Alain
    COMPUTERS IN HUMAN BEHAVIOR, 2021, 119
  • [8] Intelligent Perception of CNC Machine Tools based on Human-machine Collaboration
    Lou, Ping
    Wei, Shijie
    Yan, Junwei
    Hu, Jiwei
    2019 11TH INTERNATIONAL CONFERENCE ON INTELLIGENT HUMAN-MACHINE SYSTEMS AND CYBERNETICS (IHMSC 2019), VOL 1, 2019, : 260 - 265
  • [9] Digital twin improved via visual question answering for vision-language interactive mode in human-machine collaboration
    Wang, Tian
    Li, Jiakun
    Kong, Zhaoning
    Liu, Xin
    Snoussi, Hichem
    Lv, Hongqiang
    JOURNAL OF MANUFACTURING SYSTEMS, 2021, 58 : 261 - 269
  • [10] Human-Machine Collaboration Based Named Entity Recognition
    Ren, Zhuoli
    Yu, Zhiwen
    Wang, Hui
    Wang, Liang
    Liu, Jiaqi
    COMPUTER SUPPORTED COOPERATIVE WORK AND SOCIAL COMPUTING, CHINESECSCW 2021, PT I, 2022, 1491 : 342 - 355