Editing code in SourceCraft Code Assistant

Use the SourceCraft interface with built-in Code Assistant to edit your project code or add new files and directories. You can introduce changes directly into the repository branch or through a pull request.

Code Assistant is an AI-driven developer assistant based on large language models (LLM)s. With Code Assistant, you can optimize the code writing process and increase your performance.

The smart autocompletion mode enables AI assistant to analyze the code context and come up with the most relevant suggestions for functions, cycles, conditions, and more.

Code Assistant also features a chat mode you can use to interact with the AI assistant in SourceCraft or your IDE interface.

SourceCraft Code Assistant terms of use

SourceCraft Code Assistant documentation.

To edit code with Code Assistant:

  1. Open the SourceCraft home page.

  2. On the Home tab, under Your craftspace, navigate to Repositories.

  3. Select the repository with the code you need to edit.

  4. Under Code on the repository page, go to Branches.

  5. Select the branch for editing.

  6. Open the file that needs updates.

  7. In the top-right corner, click Edit.

  8. Start entering the text and see Code Assistant's suggestion.

    When generating a suggestion, the loading icon will appear to the left of the editable code. If generation stops or there is no result, you will see the (no suggestion) icon.

  9. Select what to do with the suggestion:

    • Click Tab to accept the suggestion.
    • To start accepting the suggestion word by word, press Ctrl + → for Windows or Linux or Command + → for macOS.
    • To discard the suggestion, press Esc.
  10. In the top-right corner, click Commit changes.

  11. In the window that opens, configure the procedure for changes:

    • In the Commit message field, give a comment that will describe the changes you make.
    • Under Commit branch, select the branch you want to change. Create a new branch as needed.
    • Under After commit action, select how to introduce changes: Via a commit or a pull request.
  12. Confirm your changes.

    If you opted for a pull request, finish creating it.

See also