How to run GPT-OSS-Safeguard locally with LM Studio as private, self-hosted AI

Run GPT-OSS-Safeguard from OpenAI as your own private, self-hosted AI. LM Studio runs the model on your computer, and TypingMind gives you a full chat app on top of it. Your prompts stay on your machine, and there is no per-message cost.

About GPT-OSS-Safeguard: gpt-oss-safeguard-20b and gpt-oss-safeguard-120b are open safety models from OpenAI, building on gpt-oss. Trained to help classify text content based on customizable policies.

GPT-OSS-Safeguard Overview

ModelGPT-OSS-Safeguard
Made byOpenAI
Runs onLM Studio
Versionsgpt-oss-safeguard-20b, gpt-oss-safeguard-120b
Download size12 GB to 65 GB
Minimum RAM12 GB
Capabilities
Tool callingThinking
FormatsGGUF, MLX
LM Studio commandlms get openai/gpt-oss-safeguard-20b
Downloads on LM Studio10.2K
Model iconGet the icon for TypingMind

Which version of GPT-OSS-Safeguard should you pick?

Each version is a different size of GPT-OSS-Safeguard. Bigger versions give better answers but need more memory. Pick the biggest one that fits your computer's RAM. On a Mac, memory is shared with the graphics chip, so leave some room for other apps.

Model IDDownloadSuggested RAM
openai/gpt-oss-safeguard-20bused in this guide12.00 GB24 GB
openai/gpt-oss-safeguard-120b65.00 GB96 GB

Suggested RAM is a rough guide: the download size plus about 2 GB, with room for your system. Longer context windows use more.

Run GPT-OSS-Safeguard with LM Studio

The steps below use openai/gpt-oss-safeguard-20b, a version that fits most laptops. Swap in another model ID from the table if you want a smaller or bigger one.

I

Install LM Studio

LM Studio is a free desktop app that runs AI models on your own computer. It downloads GPT-OSS-Safeguard, loads it into memory, and answers requests on your machine through a local server.

  1. Download LM Studio for macOS, Windows, or Linux from lmstudio.ai/download and open it.
  2. On first launch, LM Studio offers to download a starter model. You can let it, or skip and download GPT-OSS-Safeguard in the next step.
LM Studio downloading openai/gpt-oss-safeguard-20b to run locallyopenai / gpt-oss-safeguard-20bGPT-OSS-Safeguard. Supports reasoning and tool calling.0 MB / 12.00 GB
LM Studio downloading openai/gpt-oss-safeguard-20b

LM Studio also comes with a terminal tool called lms. On macOS and Linux, run this once so you can type lms in the Terminal app (use ~/.bashrc instead of ~/.zshrc if you use bash):

echo 'export PATH="$PATH:$HOME/.lmstudio/bin"' >> ~/.zshrc && source ~/.zshrc

On Windows, add %USERPROFILE%\.lmstudio\bin to your PATH, or do the next steps in the LM Studio app instead.

II

Download GPT-OSS-Safeguard with LM Studio

In the Terminal app, run:

lms get openai/gpt-oss-safeguard-20b

This downloads openai/gpt-oss-safeguard-20b (12.00 GB). LM Studio picks the right format for your computer: MLX on Apple Silicon Macs, GGUF everywhere else. When you see Download completed, the model is ready.

Prefer clicking? Open Model Search in the LM Studio sidebar, search for gpt-oss-safeguard-20b, and click Download. Run lms ls to see every model you have downloaded.

III

Start the LM Studio server for TypingMind

TypingMind talks to LM Studio through its local server. Load the model with a 32,768-token context window, then start the server with CORS turned on, so the TypingMind web app is allowed to connect:

lms load gpt-oss-safeguard-20b -c 32768
lms server start --cors

You should see Server is now running on port 1234. The load command also prints the model ID to use in TypingMind.

Terminal running lms get, lms load and lms server start --cors
Download, load, and serve a model with lms (example with google/gemma-4-e4b)

In the app instead: go to Developer → Local Server, open Server Settings, turn on Enable CORS, switch the status to Running, and click Load Model.

Good to know: with CORS on, any website you visit can reach your LM Studio server while it runs. Stop it with lms server stop when you're done. Keep LM Studio open while you chat: if you quit it, the server stops too.
IV

Add GPT-OSS-Safeguard to TypingMind

Open www.typingmind.com in your browser. Use the web version: the TypingMind Mac app and the Setapp version block plain http:// addresses like LM Studio's.

Click Models in the left sidebar, then Add custom model.

Fill in the form:

NameGPT-OSS-Safeguard (LM Studio)or any name you like
Model IDopenai/gpt-oss-safeguard-20b
Context Length32768match the -c value you loaded with
API TypeOpenAI Chat Completions API
Endpoint URLhttp://localhost:1234/v1/chat/completions
Authentication TypeNo authentication
TypingMind Add Custom Model form filled in for openai/gpt-oss-safeguard-20b running on LM StudioGPT-OSS-Safeguard (LM Studio)openai/gpt-oss-safeguard-20b32768http://localhost:1234/v1/chat/completions
The custom model form for openai/gpt-oss-safeguard-20b

Open the Capabilities tab and turn off Auto check capabilities on save. The check sends several test requests, and a local model answers them one at a time, so it can take minutes.

Then set the features for GPT-OSS-Safeguard:

  • Support System Role: on
  • Support Streaming Output: on
  • Support Plugins: on
  • Support Thinking: on
  • Support Image Input: off
  • Support PDF Input: off
  • Support External Image URLs: off
  • Support Prompt Caching: off

Click Test & Save. If your browser asks to let www.typingmind.com access other apps and services on this device, click Allow. This lets the page reach LM Studio at localhost.

V

Chat with GPT-OSS-Safeguard in TypingMind

Pick GPT-OSS-Safeguard (LM Studio) in the model menu under the chat box and say hi. The first reply can take longer while LM Studio loads the model into memory. After that, replies come straight from your own computer.

Chatting with GPT-OSS-Safeguard running locally on LM Studio in TypingMindGPT-OSS-Safeguard (LM Studio)
A private chat with GPT-OSS-Safeguard on your own computer

See how GPT-OSS-Safeguard thinks

GPT-OSS-Safeguard reasons before it answers. TypingMind shows this as Thought for … above the reply. Click it to read the full reasoning.

Use plugins with GPT-OSS-Safeguard

GPT-OSS-Safeguard supports tool calling, so it can use TypingMind plugins. Open the plugin menu next to the model picker and turn on the ones you want, like web search, image generation, or Mermaid diagrams. The model calls them when it needs them.

TypingMind plugin menu with plugins turned on for GPT-OSS-SafeguardGPT-OSS-Safeguard (LM Studio)
Turn on plugins for GPT-OSS-Safeguard

You can now use your private AI with TypingMind's chat features: prompts, AI agents, projects, and switching between your local model and cloud models in the same chat.

Tips and troubleshooting

1. "Could not connect to the API (code: 1)"

TypingMind can't reach LM Studio. In the browser's Network tab this shows up as ERR_CONNECTION_REFUSED, which means the server isn't running, not a CORS problem. Check these in order:

  • The server is running: lms server status should say it is running on port 1234. If not, start it again:
lms server start --cors
  • The model is loaded: lms ps should list it. If it's empty, load the model again with lms load.
  • CORS is on. Without it, the browser blocks the request. Restart the server with --cors, or turn on Enable CORS in the app's Server Settings.
  • You clicked Allow when the browser asked about accessing apps on this device.
  • You're using TypingMind in the browser, not the Mac or Setapp app.

To check that LM Studio is answering, run:

curl http://localhost:1234/v1/models

2. Replies are slow because the model thinks first

GPT-OSS-Safeguard is a thinking model, so it reasons before every answer, which can take tens of seconds on a laptop. TypingMind shows the reasoning as Thought for … above the reply. For faster replies, pick a smaller version of GPT-OSS-Safeguard, or a model without thinking from the self-hosted AI directory.

3. The first message of a new chat seems stuck

TypingMind writes a title for each new chat. If the title is made by the same local model, your reply can wait behind the title. Go to Settings → Internal prompts, open Advanced Settings under Auto generate title for new chats, and pick another model for title generation, or turn auto titles off.

4. See what LM Studio is doing

Watch every request and reply as it happens:

lms log stream

5. Replies are very slow or LM Studio runs out of memory

The model is probably too big for your computer. Pick a smaller size from the size table, load it with a shorter context (for example -c 8192), or close other heavy apps. Free up memory with lms unload --all.

Frequently Asked Questions

Is GPT-OSS-Safeguard free to run in LM Studio?

Yes. LM Studio is free, and GPT-OSS-Safeguard is an open model you download once. Every message runs on your own computer, so there is no per-message cost and no API key to manage.

Is GPT-OSS-Safeguard private when I run it in LM Studio?

Yes. Your messages go from your browser to LM Studio on your own computer, not to an AI company. TypingMind keeps your chat history in your browser. If you turn on Cloud Sync, your chats are also backed up to TypingMind's cloud.

How much RAM do I need for GPT-OSS-Safeguard?

LM Studio says the smallest version needs at least 12 GB of RAM. The smallest download, openai/gpt-oss-safeguard-20b, is 12.00 GB. The version used in this guide, openai/gpt-oss-safeguard-20b, runs comfortably with about 24 GB.

Which model ID do I use in TypingMind?

Use the ID LM Studio prints when you load the model, for example openai/gpt-oss-safeguard-20b. You can also see it with lms ps or at http://localhost:1234/v1/models.

Can GPT-OSS-Safeguard use TypingMind plugins?

Yes. LM Studio lists tool use for GPT-OSS-Safeguard, so turn on Support Plugins and it can use plugins like web search. Small sizes may call tools less reliably than large ones.

Can GPT-OSS-Safeguard read images?

No. LM Studio doesn't list vision for GPT-OSS-Safeguard, so keep Support Image Input off.

Does TypingMind run locally?

TypingMind runs in your browser at www.typingmind.com, and your chats are stored locally in your browser by default. When you chat with a self-hosted model, your messages go straight from your browser to the model on your own computer, not through TypingMind’s servers. If you turn on Cloud Sync, your chats are also backed up to TypingMind’s cloud.

Can I self-host TypingMind?

Yes. To self-host TypingMind for your team or company, use the self-hosted version of TypingMind Teams. You run it on your own servers next to your self-hosted models, so chats, users, and settings stay inside your own infrastructure. Contact our sales team to get started.

More models for LM Studio