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

# Release a prompt

> Promote a version of a prompt to dev, staging or production, and see past promotions.

Saving a prompt adds a version. A version reaches an environment when you promote it. Nucleus has three environments: **dev** and **staging** for trying and checking a version, and **production** for the one you are ready to rely on. Each environment holds one version of a prompt at a time, and **Version history** shows which version holds which. When you promote, Nucleus first checks the version's latest automatic evaluation, and each prompt's release policy says what happens when that check fails.

## Before you start

Tenant Owners, Workspace Admins and Workspace Members can promote to **dev** and **staging**. Only Tenant Owners and Workspace Admins can promote to **production**.

Promotion goes most smoothly when the version has passed an automatic evaluation. To have every new version evaluated when you save it, [turn on automatic evaluation](/products/nucleus/datasets-and-evaluations#evaluate-every-new-version-automatically).

## Promote a version

<Frame>
  <img src="https://mintcdn.com/intellikon-ai-ltd/wM16d87Um0QW2CyJ/images/nucleus/promote-a-version.png?fit=max&auto=format&n=wM16d87Um0QW2CyJ&q=85&s=b1105cfd6bcfe7726fccdb04853cf55b" alt="The Promote window, with the dev, staging and production environments, the Quality gate section, and the Close and Promote buttons." width="1300" height="608" data-path="images/nucleus/promote-a-version.png" />
</Frame>

<Steps>
  <Step title="Open the prompt">
    Select **Prompts**, then the prompt. **Promote** works on the newest version.
  </Step>

  <Step title="Start">
    Select **Promote**.
  </Step>

  <Step title="Choose the environment">
    Under **Target environment**, choose **dev**, **staging** or **production**.
  </Step>

  <Step title="Promote">
    Select **Promote**.
  </Step>

  <Step title="Give a reason if asked">
    If an **Override reason** box appears, the version has no passing automatic evaluation. Write why it should go ahead anyway.
  </Step>

  <Step title="Promote again">
    If you gave a reason, select **Promote** again.
  </Step>

  <Step title="Close">
    When the dialog shows **Promoted to** and the environment, select **Close**.
  </Step>
</Steps>

In **Version history**, the version now carries the environment's label. The version that held that environment before no longer does. Next, [check the promotion history](#see-past-promotions).

## See past promotions

On the prompt, select the **Promotions** tab. It lists promotions of this prompt, with when it happened, the version, the change of environment, who asked for it and any notes. **Status** shows **Auto-approved** when the version passed its evaluation, and **Override (warn)** when someone gave a reason instead.

Next, [set the prompt's release policy](#set-a-prompts-release-policy).

## Set a prompt's release policy

<Frame>
  <img src="https://mintcdn.com/intellikon-ai-ltd/wM16d87Um0QW2CyJ/images/nucleus/release-policy.png?fit=max&auto=format&n=wM16d87Um0QW2CyJ&q=85&s=d889b50a6a6c42916c7012caa480098e" alt="The Promotions tab of a prompt, with Release policy, the second-approval tick box and Quality gate set to Warn." width="1060" height="540" data-path="images/nucleus/release-policy.png" />
</Frame>

Tenant Owners and Workspace Admins can decide how strict the check before a promotion is, and whether a **production** release needs a second person.

<Steps>
  <Step title="Open the policy">
    On the prompt, select the **Promotions** tab. **Release policy** is at the top.
  </Step>

  <Step title="Ask for a second approval if you want one">
    Tick **Every Production release needs approval from a second Owner or Admin**.
  </Step>

  <Step title="Choose how strict the check is">
    Under **Quality gate**, choose **Off**, **Warn** or **Block**.
  </Step>
</Steps>

* **Off** never stops a release.
* **Warn** lets a version that has not passed go ahead once someone writes a reason.
* **Block** stops it unless a Tenant Owner or Workspace Admin writes a reason.

Each change is saved straight away, and Nucleus shows **Release policy saved**. Next, [watch how the prompt performs](/products/nucleus/monitoring).

## Troubleshooting

<Accordion title="The production option is greyed out">
  If the dialog says **This version is already in Production**, there is nothing to promote. Save a new version and promote that. Otherwise, only Tenant Owners and Workspace Admins can promote to **production**, so ask one of them.
</Accordion>

<Accordion title="The dialog says &#x22;No auto-eval has run on this version yet&#x22;">
  Give an **Override reason**, or [turn on automatic evaluation](/products/nucleus/datasets-and-evaluations#evaluate-every-new-version-automatically) and save a new version so it is evaluated first.
</Accordion>

<Accordion title="Promote is greyed out">
  You are looking at an older version. Select the newest version in **Version history**, then select **Promote**.
</Accordion>
