Skip to main content

Complete Code

Prompting Complete Code

Complete Code provides code suggestions based on the context of the file you're in. Just start coding, and you'll receive suggestions from Ghostwriter in-line with your code.

You can also write code comment prompts to get Ghostwriter to write the code for you without needing to write any code yourself. This can be helpful for automating tasks, finding creative solutions to problems, learning how to code, and getting unstuck.

Use a code comment with just natural language to describe what you want the code to do and Ghostwriter will do the rest.

In the demo above, you can see how you can use comments to ask Ghostwriter to provide code to read and plot data. This added context allows Ghostwriter to provide accurate suggestions.

Turning Complete Code on and off

To turn off Code Complete for a specific Repl:

  1. Open the Repl.
  2. Click settings in the left-hand toolbar.
  3. Navigate to "Ghostwriter Complete Code" and click enabled or disabled in the dropdown menu.
Was this doc useful?