Skip to content

Pi setup

Install from the official Pi site and set WUDI_API_KEY in the terminal that launches Pi. These instructions use a custom API key rather than another service’s subscription login.

Merge the following into ~/.pi/agent/models.json. On Windows, ~ means the current user’s home directory. Add wudi to an existing providers object rather than duplicating the root object:

{
"$schema":"https://pi.dev/schemas/models.schema.json",
"providers":{
"wudi":{
"baseUrl":"https://wudiapi.com/v1",
"api":"openai-completions",
"apiKey":"${WUDI_API_KEY}",
"models":[{"id":"gpt-5.6-sol","name":"GPT · WuDi API"}]
}
}
}

The key setting is an environment-variable reference, not a literal credential. Keep the reference syntax supported by your installed version.

Start Pi, use /model to reload or select a model, and choose the WuDi entry. Send a short text request before testing tools. Model availability requires both a valid configuration and readable credentials.

Declare image input, reasoning and context options only after confirming support. Writing a capability into a configuration does not add it upstream. The basic example declares connection settings and the model only.

If a model is missing, check JSON syntax, file location and the environment variable. If a background service fails while the terminal works, check the service’s environment. For parameter errors, compare the adapter and model.

Remove providers.wudi and select the previous model to undo the change; do not delete all Pi user data.

Reference: custom models.