General Introduction
CodeGeeX is a big model-based intelligent programming assistant, which aims to help developers significantly improve programming efficiency through automatic code generation, code completion, code translation and intelligent Q&A. The tool supports more than 20 programming languages and is adapted to a variety of mainstream IDEs, such as VS Code, IntelliJ IDEA, and PyCharm, etc. CodeGeeX, jointly developed by Tsinghua University's Knowledge Engineering Laboratory and Wisdom Spectrum AI, employs a pre-trained model for multi-language code generation with 13 billion parameters, and is capable of generating code based on natural language descriptions or completing subsequent code according to the existing code. existing code to complement the subsequent code. Its open API and plug-in support make it a powerful assistant for developers.
Function List
- Code Generation and Completion: Generate subsequent code based on natural language descriptions or existing code.
- code translation: Supports code translation between multiple programming languages.
- Automatically add comments: Automatically generate comments based on the content of the code.
- intelligent question and answer (Q&A): When you encounter problems during development, you can ask the AI questions directly.
- Multi-language support: Support for Python, C++, Java, JavaScript, Go and other programming languages.
- Plug-in Support: Adaptation of VS Code, IntelliJ IDEA, PyCharm and other mainstream IDE.
- Open API: Provide API interface to support personalization.
Using Help
Installation process
- VS Code Plugin Installation::
- Open VS Code and go to Extended Marketplace.
- Search for "CodeGeeX" and click install.
- After the installation is complete, restart VS Code.
- IntelliJ IDEA Plugin Installation::
- Open IntelliJ IDEA and go to the plugin marketplace.
- Search for "CodeGeeX" and click install.
- After the installation is complete, restart IntelliJ IDEA.
Guidelines for use
- Code Generation and Completion::
- Enter a natural language description or part of the code in the code editor.
- Press a shortcut key (e.g. Ctrl+Enter) and CodeGeeX will automatically generate subsequent code.
- code translation::
- Check the code snippets that need to be translated.
- Right click and select "CodeGeeX Translate", select the target language, CodeGeeX will translate the code automatically.
- Automatically add comments::
- Check the code snippet that needs to be commented.
- Right click and select "CodeGeeX Add Comment", CodeGeeX will automatically generate the comment.
- intelligent question and answer (Q&A)::
- Enter a description of the problem in the code editor.
- Press a shortcut key (e.g. Ctrl+Shift+Q) and CodeGeeX will provide an answer or suggestion.
- Open API::
- Visit the CodeGeeX official website to register and get your API key.
- Integrate the CodeGeeX API into your project for personalization according to the API documentation.
Detailed Operation Procedure
- Code Generation and Completion::
- In VS Code, open a Python file.
- Type "# Calculate the sum of two numbers" and press Ctrl+Enter.
- CodeGeeX automatically generates the appropriate Python code, for example:
def add(a, b): return a + b return a + b
- code translation::
- In IntelliJ IDEA, open a Java file.
- Check the following code:
public int add(int a, int b) { return a + b; } }
- Right click on "CodeGeeX Translator" and select "Python".
- CodeGeeX automatically translates to Python code, for example:
def add(a, b): return a + b return a + b
- Automatically add comments::
- In PyCharm, open a Python file.
- Check the following code:
def add(a, b): return a + b return a + b
- Right click and select "CodeGeeX Add Comment".
- CodeGeeX automatically generates annotations such as:
def add(a, b). # Calculate the sum of two numbers return a + b
- intelligent question and answer (Q&A)::
- In VS Code, type "How do I read the contents of a file in Python?" .
- Press Ctrl+Shift+Q and CodeGeeX will provide the answer, for example:
python
with open('filename.txt', 'r') as file.
content = file.read()