Repository: promptfoo/promptfoo
Issue: Selecting a non-OpenAI provider during setup still adds OpenAI by default
Root cause: Algorithmic Error

**Describe the bug**
OpenAI showing up under providers when not selected as option during promptfoo initial setup; the selected ones don't show up.

**To Reproduce**

1. Run `promptfoo init`
2. Select Not sure yet
3. Select [Google] for Gemini
4. Check promptfooconfig.yaml

**Expected behavior**
Expected to see Gemini providers listed.

**System information:**

```{
  "version": "0.118.3",
  "platform": {
    "os": "linux",
    "release": "5.15.167.4-microsoft-standard-WSL2",
    "arch": "x64",
    "nodeVersion": "v24.4.0"
  },
  "env": {},
  "configInfo": {
    "defaultConfigPath": "/home/tabs0/repos/promptfoolery/testing/promptfooconfig.yaml",
    "configExists": true,
    "configContent": {
      "config": {
        "tags": {},
        "description": "My eval",
        "prompts": [
          "Write a tweet about {{topic}}",
          "Write a concise, funny tweet about {{topic}}"
        ],
        "providers": [
          "openai:gpt-5-mini",
          "openai:gpt-5"
        ],
        "tests": [
          {
            "vars": {
              "topic": "bananas"
            }
          },
          {
            "vars": {
              "topic": "avocado toast"
            },
            "assert": [
              {
                "type": "icontains",
                "value": "avocado"
              },
              {
                "type": "javascript",
                "value": "1 / (output.length + 1)"
              }
            ]
          },
          {
            "vars": {
              "topic": "new york city"
            },
            "assert": [
              {
                "type": "llm-rubric",
                "value": "ensure that the output is funny"
              }
            ]
          }
        ],
        "scenarios": [],
        "env": {},
        "sharing": false,
        "outputPath": [],
        "extensions": [],
        "metadata": {}
      },
      "testSuite": {
        "description": "My eval",
        "tags": {},
        "prompts": [
          {
            "raw": "Write a tweet about {{topic}}",
            "label": "Write a tweet about {{topic}}"
          },
          {
            "raw": "Write a concise, funny tweet about {{topic}}",
            "label": "Write a concise, funny tweet about {{topic}}"
          }
        ],
        "providers": [
          {
            "env": {},
            "modelName": "gpt-5-mini",
            "config": {
              "basePath": "/home/tabs0/repos/promptfoolery/testing"
            },
            "mcpClient": null,
            "initializationPromise": null,
            "loadedFunctionCallbacks": {},
            "label": ""
          },
          {
            "env": {},
            "modelName": "gpt-5",
            "config": {
              "basePath": "/home/tabs0/repos/promptfoolery/testing"
            },
            "mcpClient": null,
            "initializationPromise": null,
            "loadedFunctionCallbacks": {},
            "label": ""
          }
        ],
        "providerPromptMap": {},
        "tests": [
          {
            "vars": {
              "topic": "bananas"
            }
          },
          {
            "vars": {
              "topic": "avocado toast"
            },
            "assert": [
              {
                "type": "icontains",
                "value": "avocado"
              },
              {
                "type": "javascript",
                "value": "1 / (output.length + 1)"
              }
            ]
          },
          {
            "vars": {
              "topic": "new york city"
            },
            "assert": [
              {
                "type": "llm-rubric",
                "value": "ensure that the output is funny"
              }
            ]
          }
        ],
        "scenarios": [],
        "defaultTest": {
          "metadata": {},
          "options": {}
        },
        "nunjucksFilters": {},
        "extensions": []
      },
      "basePath": "/home/tabs0/repos/promptfoolery/testing",
      "commandLineOptions": {}
    }
  }
}```

- Promptfoo version: 0.118.3

Resolved in next release - see #5536