Agents
Setup guide

Codex with an uncensored model

To run OpenAI's Codex with an uncensored model, add a provider to ~/.codex/config.toml that points at an API serving abliterated models in the OpenAI Responses format.

Updated
FormatOpenAI Responses
Endpoint/responses
Configured in~/.codex/config.toml
Switch with/model
Context1,048,576

Which model to use in Codex

Change the model line to start on a model other than DeepSeek V4.1 Flash 1017.

ModelUse it forModel id
Kimi K3.1 ProHard multi-file and security workkimi-k3.1-pro-uncensored
DeepSeek V4.1 FlashEveryday work, and the default heredeepseek-v4.1-flash-1017-uncensored
GLM-5.3A second opinion, text onlyglm-5.3-uncensored
GLM-5.3 FlashBulk edits and many subagentsglm-5.3-flash-uncensored

Set it up

  1. Install Codex
    Shell
    npm install -g @openai/codex
    Shell
    brew install --cask codex
  2. Set your API key

    Create a key at Silk Compute, export it, and add the line to ~/.zshrc or ~/.bashrc.

    Shell
    export SILK_API_KEY="sk-..."
  3. Add the provider

    Add these lines to ~/.codex/config.toml, creating the file if needed.

    ~/.codex/config.toml
    model = "deepseek-v4.1-flash-1017-uncensored"
    model_provider = "silkcompute"
    web_search = "disabled"
    
    [model_providers.silkcompute]
    name = "Silk Compute"
    base_url = "https://api.silkcompute.com"
    env_key = "SILK_API_KEY"
    model_catalog_url = "https://api.silkcompute.com/codex/models"
  4. Run it
    Shell
    codex

    Switch the model and effort with /model.

  5. Check the key

    A list of models means the key works, and a 401 means SILK_API_KEY is empty or wrong.

    Shell
    curl -s https://api.silkcompute.com/models -H "Authorization: Bearer $SILK_API_KEY"

Keep OpenAI as your default

Save the same lines as ~/.codex/silk.config.toml instead, and start Codex with the profile when you want the uncensored models.

Shell
codex --profile silk

What each line does

LineWhat it does
modelThe model Codex starts on.
model_providerUses the silkcompute provider defined below instead of OpenAI.
web_search = "disabled"Turns off Codex's hosted web search, which this API doesn't serve.
base_urlSends requests to https://api.silkcompute.com.
env_keyThe environment variable that holds the key.
model_catalog_urlWhere Codex reads the model list and each model's effort levels.

Other APIs that work with Codex

Three of the seven APIs for coding agents serve the OpenAI Responses format Codex needs.

With a local model

Codex's --oss flag means "Use a local open source model provider", choosing "between LM Studio and Ollama" (Codex command reference). Load one of the local abliterated models in either and start Codex with the flag.

Shell
codex --oss

Silk Compute's own guide is at silkcompute.com/docs/codex.