Programming languages force people to think logically while interacting with the computers to reach a conceptual level that makes problem solving accessible to the computer itself. Given their expressive power, natural languages outweigh their programming counterparts. In this paper, we propose a natural to programming language converter using large language models (LLMs) where the user can express the logical constructs in his own language that get converted to Python code. In this way, the converter alleviates the user fear from learning a new programming language. We identify the proposed converter as the Arabic programming language (APL). The APL model runs under the hood GPT4 application program interface (API) using an elaborate prompt engineering scheme. In addition, an intuitive, yet simple, user interface is provided to assist the APL user. As a feedback, the user will rate the APL response to the input prompt as a score ranging from 1 to 5 where 1 would indicate dissatisfactory output and 5 to indicate perfect code execution. The APL API is hosted at https://github.com/riotu-lab/apl-compiler .

错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

LLMs as a Compiler for an Arabic Programming Language

  • Serry Sibaee,
  • Omer Nacar,
  • Lahouari Ghouti,
  • Anis Koubaa

摘要

Programming languages force people to think logically while interacting with the computers to reach a conceptual level that makes problem solving accessible to the computer itself. Given their expressive power, natural languages outweigh their programming counterparts. In this paper, we propose a natural to programming language converter using large language models (LLMs) where the user can express the logical constructs in his own language that get converted to Python code. In this way, the converter alleviates the user fear from learning a new programming language. We identify the proposed converter as the Arabic programming language (APL). The APL model runs under the hood GPT4 application program interface (API) using an elaborate prompt engineering scheme. In addition, an intuitive, yet simple, user interface is provided to assist the APL user. As a feedback, the user will rate the APL response to the input prompt as a score ranging from 1 to 5 where 1 would indicate dissatisfactory output and 5 to indicate perfect code execution. The APL API is hosted at https://github.com/riotu-lab/apl-compiler .