---
title: "Fixer"
description: "Turns Baz findings and instructions into commits or pull requests, running the fix, your linters, and a Baz review inside an isolated sandbox."
canonical: "https://baz.ai/docs/agents/build/fixer"
---

# Fixer

Turns Baz findings and instructions into commits or pull requests, running the fix, your linters, and a Baz review inside an isolated sandbox.

Fixer is the Baz coding agent. It takes a finding, or a plain instruction, and produces a change: a commit on the pull request branch or a new pull request. Every fix runs in a sandbox with your repository's dependencies, passes your format, lint, and typecheck scripts, and is reviewed by your Baz agents before it is pushed.

## Ways to trigger a fix

The quickest way is to reply on a Baz comment: `apply commit` adds a commit to the PR branch, `apply pr` opens a new PR against it, and `apply pr to <branch>` targets another branch. Add your own instructions to the reply to change the plan. You can also tick **Apply fix with Baz** on a comment, select **Fix with Baz** in the app, send `@Baz fix <instruction>` from Slack, or fix a [Full Repo Security Scan](/docs/agents/maintain/full-repo-security-scan) finding, which opens a new PR.

Commands are matched anywhere in the reply and ignore case, so "Nice catch, apply commit" works. On a comment from AI Coding Guidelines, reply `apply skill update` to change the skill instead of the code. See [PR commands](/docs/reference/pr-commands).

## What happens when you ask for a fix

You reply `apply commit` on a finding. Baz updates the comment with a link to the session logs and starts a **Baz Fixer** check run. A few minutes later the fix lands on your branch as its own commit, or as a new pull request if you asked for one.

Why you can trust the change:

- **It runs in an isolated sandbox** with your dependencies and setup script. The agent cannot reach the network, install packages, or push on its own.
- **Your Baz agents review it first**, and Fixer corrects what they find before anything is pushed.
- **It passes your own format, lint, and typecheck scripts.** Fixer does not run tests or builds, and never changes logic just to satisfy a linter.
- **It respects your branch.** If the branch moved, Fixer rebases and keeps the remote code when there is a conflict.

When several findings are queued on one pull request, Fixer handles them together, one commit per finding.

## What you see

When a fix starts, the comment's fix line is replaced:

```markdown title="PR comment"
@dana asked Baz to fix this comment. [Follow session logs here](https://baz.co/fixer/sandbox/.../logs)
```

A **Baz Fixer** check run tracks the session. With `apply pr`, Baz replies with the new pull request link. If your budget is used up, Baz explains on the pull request and skips the fix. Every run also appears in [Sessions](/docs/work/sessions) as a **Fixer session**.

If Fixer is not set up for the repository, comments show "Want Baz to fix this for you? Activate Fixer" instead of the fix line.

## Prerequisites

- A payment method or credits
- Write access
- A [sandbox](/docs/integrations/sandbox) for the repository, or **Generic Runtime** turned on

## Settings

Admins configure Fixer in the **Fixer** section at the bottom of **Software Factory → Build** (others see "You don't have permission to configure the Fixer.").

**Environments** lists the sandbox for each repository and whether it builds. Turn on **Generic Runtime** to fix repositories that have no sandbox; it works without setup, but some fixes may fail or be less accurate.

Which fix options appear on comments (**Baz fixer**, **Fix in cursor**, **Copy AI prompt**) is set in **Comments fixing options** in [Configurations](/docs/admin/configurations).

## Related

<CardGroup cols={2}>
  <Card title="Fix findings" href="/docs/work/fix-findings" icon="check-check">
    The day-to-day flow from comment to fix.
  </Card>
  <Card title="Sandbox" href="/docs/integrations/sandbox" icon="box">
    Setup script, runtimes, environment variables, logs.
  </Card>
  <Card title="PR commands" href="/docs/reference/pr-commands" icon="terminal">
    Every reply command.
  </Card>
  <Card title="Usage limits" href="/docs/admin/usage-limits" icon="gauge">
    Budgets for metered agents.
  </Card>
</CardGroup>
