Automated Code Comment and Documentation - Powered by the #1 Code-to-Text AI Model
Code-to-Text AI assistant
Quick menu:
Introduction
- Docify AI uses large language models (LLMs) to support coding tasks. The first two features released are documentation writer and comment translator.
- Docify AI documentation writer is powered by the #1 Code-To-Text AI model ranked by Microsoft CodeXGLUE benchmark. Unlike other tools built on OpenAI, our model is the result of our internal R&D progress on LLMs, giving us complete control and ensuring the privacy of our customer data.
- Docify AI gives developers maximum controls, including customizing how detailed the comments are, from succinct to descriptive.
- Docify AI supports 9 programming languages: C, C++, C#, Go, Java, JavaScript, PHP, Python, and Ruby with more added in the future.
- Docstrings are generated in JavaDoc, XML, JsDoc, EpyText, reST, Google, Doxygen or you can write your own custom formats.
- Docify AI comment translator provides code-aware translations of existing comments between some of the most commonly spoken languages.
How to use
Select the programming language.
Note: If auto-detect is selected, our system makes a guess of the programming language based on its syntax. For better results, we recommend selecting a programming language.
Select the docstring format. To configure the custom docstring format, go to the extension settings page (⌘, on MacOS and Ctrl+, on Windows)
(Optional) Select the output language for Docify AI generated docstrings and comments. See supported languages.
(Recommended) Enable More expressive comments for longer comments with more detailed descriptions.
(Recommended) Enable Inline comments to get inline explanations of important blocks of code.
(Optional) Enable Side panel review to see suggested comments on the side panel before inserting into the source code or rejecting.
Generate docstrings
- After setting up the configurations, right click and choose
Docify: Comment for the entire file to generate docstrings for all classes and functions in the working file.
- To create docstrings for a single class or function, highlight the needed code, right click and select
Docify: Comment for the selected codes
Accept or reject suggestions
- By default, you need to review content generated by Docify AI before accepting or rejecting it into your source code.
- Alternatively, right click and choose
Docify: Accept all comments or Docify: Reject all comments
- If you wish to automatically inserting content generated by Docify AI without manual review, you can enable two settings
Comment service: Auto accept all and Translation service: Auto accept all in the extension settings page.
When you use the feature Docify: Comment for the selected codes on a snippet that is not a class or a function, Docify cannot generate a docstring and will generate an inline comment to explain the snippet instead.
If the option Inline comments is enabled in the configuration, Docify AI will automatically identify important blocks of code such as conditionals and loops to generate inline explanations.
Docify AI supports translating existing docstrings and comments between human languages.
Step 1: Configure translation service. Select the programming language and the docstring formats of the code comments to be translated. Select the source and target languages.
List of supported languages:
- English
- Japanese (日本語)
- Chinese (简体字)
- Vietnamese (Tiếng Việt)
- Korean (한국어)
- Hindi (हिन्दी)
- Indonesian (Bahasa Indonesia)
- French (Français)
- Spanish (Español)
- Portuguese (Português)
- Russian (Pусский язык)
Step 2: Right click and choose Docify: Translate comments for file to translate all existing docstrings in the working file. Alternately, highlight one docstring or comment, right click and select Docify: Translate comment snippet
- Step 3: Review the translation before accepting or rejecting the suggestions into the source code.
Default keybindings
Action |
MacOS |
Windows |
Comment the entire file |
⌘⇧/ |
Shift+Alt+/ |
Comment a snippet |
⌘/ |
Alt+/ |
Accept all comments |
⌘K⌘Enter |
Ctrl+K Ctrl+Enter |
Reject all comments |
⌘K⌘Backspace |
Ctrl+K Ctrl+Backspace |
Translate all comments in a file |
⌥⇧T |
Shift+Alt+T |
Translate a comment snippet |
⌥T |
Alt+T |
Docify Lab
🔬 Experience AI4Code features in development from our research lab such as Code Completion, Code Repair, Test Case Generation, etc.
📌 Try it out at: docify-lab.ai4code.io
Data privacy
Docify AI never stores your code or comments generated from your code. We improve our AI model by applying new ML techniques on publicly available datasets.
Links
Join our Discord channel for community support
Twitter: @docify_official
| |