> ## Documentation Index
> Fetch the complete documentation index at: https://docs.replit.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Code Optimizations

> Learn how to control whether Agent reviews and simplifies its own code after building.

export const WistiaEmbed = ({videoId, title = "Wistia video", playerColor = "FF0000", controlsVisibleOnLoad = false}) => {
  if (!videoId) {
    return null;
  }
  const url = "https://fast.wistia.net/embed/iframe/" + videoId + "?seo=false&playerColor=" + playerColor + "&controlsVisibleOnLoad=" + controlsVisibleOnLoad;
  return <Frame>
      <iframe src={url} title={title} allow="autoplay; fullscreen" allowFullScreen></iframe>
    </Frame>;
};

**Code Optimizations** (formerly Autonomy Level) is an on/off setting in **Advanced settings** within the Agent settings dropdown. When **on**, Agent reviews its own code and simplifies future work—improving accuracy and saving costs by avoiding mistakes. When **off**, you get minimal or no AI code review and maximum hands-on control. Available on [paid plans](https://replit.com/pricing).

We recommend turning Code Optimizations **on** for most projects to get better code quality and fewer costly rework cycles.

## Usage

Access Code Optimizations through the Agent settings dropdown while working on any project. The setting applies to your current conversation, affects how Agent approaches subsequent tasks, and is available when you're using Economy or Power mode.

<Accordion title="How to access Code Optimizations">
  1. Open your project in the Project Editor
  2. Open the Agent settings dropdown in the chat input
  3. Expand **Advanced settings** and locate **Code Optimizations**
  4. Turn it **on** or **off** based on your preference
</Accordion>

<WistiaEmbed videoId="icgjyt121c" title="Code Optimizations overview" />

### When to use it

* **On**: Recommended for most work. Agent reviews its own code, catches mistakes, and can reduce rework. Slightly longer per task but better quality.
* **Off**: Use when you want the fastest, most hands-on experience—e.g. quick edits or when you prefer to review every change yourself.

Learn more about other [Agent features](/core-concepts/agent) and [App Testing](/core-concepts/agent/app-testing).
