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

# Using OpenAI's GPT-OSS

> Complete guide to running OpenAI's GPT-OSS model locally with LM Studio

## Complete Setup Guide

This guide will walk you through setting up and using OpenAI's GPT-OSS model with LM Studio and Oryx.

## Step 1: Setup LM Studio and Download GPT-OSS

<Steps>
  <Step title="Download LM Studio">
    Download LM Studio from [https://lmstudio.ai/](https://lmstudio.ai/)
  </Step>

  <Step title="Open Discovery Page">
    Click on **Discover** in LM Studio (the 🔍 icon on the left).

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/eTkn-8G54o6wzba3/images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step1.png?fit=max&auto=format&n=eTkn-8G54o6wzba3&q=85&s=729a7c143cf073caf35516031b402a92" alt="Setup LMStudio and download OpenAI GPT-OSS" width="1754" height="1456" data-path="images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step1.png" />
    </Frame>
  </Step>

  <Step title="Search and Download Model">
    Search for `gpt-oss-20b` and click **Download**.

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/eTkn-8G54o6wzba3/images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step2.png?fit=max&auto=format&n=eTkn-8G54o6wzba3&q=85&s=01fcd6b18192798574a33c31166ca2a4" alt="Search for gpt-oss-20b and click Download" width="1704" height="1412" data-path="images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step2.png" />
    </Frame>
  </Step>

  <Step title="Load the Model">
    After download finishes, load the model.

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/eTkn-8G54o6wzba3/images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step3.png?fit=max&auto=format&n=eTkn-8G54o6wzba3&q=85&s=49096e45cbd71b21947be11bfea9690f" alt="After download finishes, load the model" width="1749" height="1491" data-path="images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step3.png" />
    </Frame>

    <Note>
      Enable the flag to choose model parameters on load
    </Note>

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/eTkn-8G54o6wzba3/images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step4.png?fit=max&auto=format&n=eTkn-8G54o6wzba3&q=85&s=b421642428eb2c755f055bfa2dc9c9e0" alt="Enable the flag to choose model parameters on load" width="1711" height="1423" data-path="images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step4.png" />
    </Frame>

    Set context length to **32768** (adjust based on your hardware) and load the model.

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/eTkn-8G54o6wzba3/images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step5.png?fit=max&auto=format&n=eTkn-8G54o6wzba3&q=85&s=6027e769384a48e21a39050975a6eb06" alt="Set context length to 32768" width="771" height="564" data-path="images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step5.png" />
    </Frame>
  </Step>
</Steps>

## Step 2: Configure Oryx to use LM Studio

<Steps>
  <Step title="Add Provider">
    Navigate to `chrome://settings/oryx` and click **Add Provider**.
    Choose **OpenAI Compatible** as the Provider Type.

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/HQWW0FFWRvqlfAYo/images/provider-setting.png?fit=max&auto=format&n=HQWW0FFWRvqlfAYo&q=85&s=59b15163df7b8e3fb25079358d3e109b" alt="Configure Oryx to use LMStudio" width="1280" height="827" data-path="images/provider-setting.png" />
    </Frame>
  </Step>

  <Step title="Configure Connection">
    * Set Base URL to `http://127.0.0.1:1234/v1`
    * Set Model ID to `openai/gpt-oss-20b`
    * Set context length to **32768**
    * Save your configuration

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/eTkn-8G54o6wzba3/images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step8.png?fit=max&auto=format&n=eTkn-8G54o6wzba3&q=85&s=cb6f8ce469f1726ccf313b1df135bb52" alt="Set Base URL configuration" width="1748" height="1025" data-path="images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step8.png" />
    </Frame>
  </Step>

  <Step title="Set as Default">
    Change the default provider to **lmstudio** and you're ready to go!

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/O9XLDfru6PWWJNIk/images/llm-provider.png?fit=max&auto=format&n=O9XLDfru6PWWJNIk&q=85&s=b27b13ebf5195ed8c524ac3f7576e181" alt="Change the default provider to lmstudio" width="1280" height="827" data-path="images/llm-provider.png" />
    </Frame>
  </Step>

  <Step title="Start Using GPT-OSS">
    You can now use GPT-OSS from the Agent!

    If everything is set up correctly, you should see messages in LM Studio:

    <Frame>
      <img src="https://mintcdn.com/lol-87e214d6/eTkn-8G54o6wzba3/images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step12.png?fit=max&auto=format&n=eTkn-8G54o6wzba3&q=85&s=ce01dd2319ec2f08af75b39c09a42d3a" alt="LM Studio showing active connections" width="1794" height="1460" data-path="images/using-lm-studio-openais-gpt-oss/lm-studio-openais-step12.png" />
    </Frame>
  </Step>
</Steps>

## Configuration Summary

<Cards>
  <Card title="LM Studio Settings" icon="cog">
    * Model: `openai/gpt-oss-20b` - Context Length: 32768 - Server:
      `http://127.0.0.1:1234/v1`
  </Card>

  <Card title="Oryx Settings" icon="browser">
    * Provider Type: OpenAI Compatible - Base URL: `http://127.0.0.1:1234/v1` -
      Model ID: `openai/gpt-oss-20b` - Context Window: 32768
  </Card>
</Cards>

## Troubleshooting

<Accordion title="Model not responding">
  * Verify LM Studio is running and the model is loaded - Check the server logs
    in LM Studio for any errors - Ensure the Base URL is correct
    ([http://127.0.0.1:1234/v1](http://127.0.0.1:1234/v1))
</Accordion>

<Accordion title="Context length errors">
  * Make sure the context length in Oryx matches LM Studio - Reduce context
    length if you're running out of memory - Consider using a smaller model if
    hardware is limited
</Accordion>
