The second part of the "AI Programmer Onboarding Series": How to use Tongyi Ling Code to rewrite the project programming language at light speed?

After Tongyi Lingma joined Alibaba Cloud's cloud native team, he has demonstrated his  ability to generate unit tests and automatically generate code . Today, Alibaba Cloud backend engineer Yun Huan will start from the actual needs of project development and demonstrate the help that Tongyi Lingma can provide in development work.

What role does Tongyi Lingma play in Git development projects?

Yun Huan's team is involved in Git development work on a daily basis. Git itself has an old testing framework, so the team plans to switch to a newer open source project. But Git is written in C language, and its language needs to be changed to Python. If you don't know much about Python, if you write it yourself, you need to learn some Python syntax first, which is quite time-consuming.

Lowering the threshold for cross-language development is Tongyi Lingma's comfort zone. Immediately, the new colleague Tongyi Lingma started to build the framework of the project.

Function 1: Tongyilingcode converts the C language in the Git framework into Python

First install the Tongyi Lingma plug-in, then create a new project and let it use Python to implement a command line program. At the same time, you can specify the subcommands that need to be supported, and Tongyi Lingma will use Python to generate the code for the relevant requirements.

Requirements can also be modified after generation. The first version of the code uses RQ pass as a framework to support parameter parsing. If you want to directly simplify the design of the main function, customize dict and function pointers, Tongyi Lingma will modify another version of the code according to needs. After modification, if it meets the needs, you can click the shortcut key to have it generate the file directly, and the code will be executable.

Function 2: Tongyi Lingma continues to write Git framework code in real time

Yun Huan discovered that the CMD hex dump method generated by the current code is not completely consistent with their original code, so these generated codes need to be modified.

Tongyi Lingma can help complete the automatic continuation of the code. Simply entering a code comment will trigger the automatic continuation of the Tongyi Ling Code, and the generated continuation code will be written below in gray font. If you accept this code, you can directly press the tab key, and then continue to enter the requirements. If the continued code does not meet the requirements, you can modify the switch. After continuing to select the third continued content, press the tab key if you find that it meets the expectations. , triggering the code continuation of the Tongyi Ling Code.

Finally, with the help of Tongyi Lingma, this demonstration successfully rewritten the C language unit testing framework into a Python framework.

This is the Nth project Tongyi Lingma has completed since joining the company. AI programmers are very comfortable in the company and are very popular among everyone. As an experienced user of Tongyi Lingma, Yun Huan said that Tongyi Lingma is positioned to assist developers in completing daily code writing and assisting in overcoming complex technical difficulties. “In the development process, people are always the main body, and there are some jobs that AI cannot replace.”

For example, when developing and designing a project, people mainly rely on people to design, provide ideas, and express intentions.

After programmers design the framework, they break the task down into a number of simple and clear small tasks and assign them to AI, such as generating a function, generating a piece of code, generating a test, etc.

"Whether AI work is done well or not, people ultimately need to judge it. In the future, programmers can focus more on creativity, ideas, and construction."

Click here to quickly experience the Tongyi Ling Code and get prizes~

Review of past issues: Alibaba Cloud’s first AI employee joins the company, watching feedback from development engineers

Linus took it upon himself to prevent kernel developers from replacing tabs with spaces. His father is one of the few leaders who can write code, his second son is the director of the open source technology department, and his youngest son is an open source core contributor. Robin Li: Natural language will become a new universal programming language. The open source model will fall further and further behind Huawei: It will take 1 year to fully migrate 5,000 commonly used mobile applications to Hongmeng. Java is the language most prone to third-party vulnerabilities. Rich text editor Quill 2.0 has been released with features, reliability and developers. The experience has been greatly improved. Ma Huateng and Zhou Hongyi shook hands to "eliminate grudges." Meta Llama 3 is officially released. Although the open source of Laoxiangji is not the code, the reasons behind it are very heart-warming. Google announced a large-scale restructuring
{{o.name}}
{{m.name}}

Guess you like

Origin my.oschina.net/u/3874284/blog/11054045