AI Code Assistant 🪄
LiveCodes supports AI-powered code completion, totally for free, using Codeium, the ultrafast Copilot alternative.
The large generative machine learning model is capable of understanding the context of your code and comments in order to generate suggestions on what you might want to type next.
It has a wide range of language support, and it works everywhere (in the standalone app, embedded playgrounds and self-hosted apps).
Examples:​
JavaScript:
Python:
Instructions​
- Install Codeium chrome extension.
- Login to Codeium.
- Enjoy the magic!
Currently, only Monaco editor on desktop Chrome browser is supported. Wider editor and browser support is planned.
Please note that codeium extension sends your code to their servers for code completion. However, your code is not used for training their model. Check codeium FAQ and privacy policy for more details.
Disabling AI Code Assistant​
Obviously, if you want to disable the AI code completion on your device, just disable the browser extension.
However, if you want to prevent users from using AI code completion in playgrounds that you embed in your webpages (e.g. for code challenges or exercises), you may achieve that by adding the query parameter disableAI
(e.g. https://livecodes.io/?disableAI).
Example:
import { createPlayground } from 'livecodes';
createPlayground('#container', {
params: {
html: '<h1>Hello LiveCodes!</h1>',
disableAI: true,
},
});