coleam00/Archon · error

Pi model not found: provider='${parsed.provider}' model='${p

Error message

Pi model not found: provider='${parsed.provider}' model='${parsed.modelId}'. The model was not found in the static catalog or via any installed extension. Ensure the provider extension is installed (e.g. `pi install npm:pi-provider-kiro`) and `enableExtensions: true` is set in .archon/config.yaml.

What it means

After bindExtensions(), sendQuery re-checks the ModelRegistry ([LOOKUP-2]); if neither the static catalog nor any extension registered '<provider>/<modelId>', the session is disposed and this error thrown. It usually means the model comes from a provider extension that is not installed or not enabled.

Source

Thrown at packages/providers/src/community/pi/provider.ts:911

    // 4f. Bind UI context or fire session_start with no UI. Must run after flag pass-through above.
    //     Extension providers register their models during bindExtensions() — this is the trigger
    //     for LOOKUP-2: they call registerProvider() on our modelRegistry during session_start.
    const uiBridge = interactive ? createArchonUIBridge() : undefined;
    if (uiBridge) {
      const uiContext = createArchonUIContext(uiBridge);
      await session.bindExtensions({ uiContext });
    } else if (enableExtensions) {
      await session.bindExtensions({});
    }

    // 4g. [LOOKUP-2] Re-check the registry after bindExtensions() for extension-registered models.
    //     Safe to call session.setModel() here — no prompt has been sent yet.
    if (!model) {
      model = modelRegistry.find(parsed.provider, parsed.modelId);
      if (!model) {
        session.dispose();
        throw new Error(
          `Pi model not found: provider='${parsed.provider}' model='${parsed.modelId}'. ` +
            'The model was not found in the static catalog or via any installed extension. ' +
            'Ensure the provider extension is installed (e.g. `pi install npm:pi-provider-kiro`) ' +
            'and `enableExtensions: true` is set in .archon/config.yaml.'
        );
      }
      try {
        await session.setModel(model);
      } catch (err) {
        session.dispose();
        throw err;
      }
    }

    // 5. Structured output (best-effort). Pi has no SDK-level JSON schema
    //    mode the way Claude and Codex do, so we implement it via prompt
    //    engineering: append the schema + "JSON only, no fences" instruction,
    //    and have the bridge parse the accumulated assistant text on

View on GitHub (pinned to 0773b97458)

Solutions

  1. Install the provider extension, e.g. `pi install npm:pi-provider-kiro`
  2. Set assistants.pi.enableExtensions: true in .archon/config.yaml
  3. Verify the exact provider and model id (run `pi` to list available models); fix typos
  4. Check ~/.pi/agent/extensions/ (and repo .pi/) contains the expected extension

Example fix

// before (.archon/config.yaml)
assistants:
  pi:
    model: 'kiro/claude-sonnet-4'
    enableExtensions: false
// after
assistants:
  pi:
    model: 'kiro/claude-sonnet-4'
    enableExtensions: true
Defensive patterns

Strategy: validation

Validate before calling

function isStaticCatalogModel(provider: string, modelId: string, catalog: string[]): boolean {
  return catalog.includes(`${provider}/${modelId}`);
}
// before sendQuery, if not in catalog, assert the extension is installed+enabled:
if (!isStaticCatalogModel(p, m, staticCatalog) && !config.assistants.pi.enableExtensions) {
  throw new Error(`${p}/${m} needs a provider extension; install it and set enableExtensions: true`);
}

Type guard

function isKnownModelRef(ref: string, catalog: readonly string[]): boolean {
  return catalog.includes(ref);
}

Try / catch

try {
  await sendQuery(q);
} catch (err) {
  if (err.message.startsWith('Pi model not found')) {
    console.error(err.message); // names provider/model and the extension install steps
  }
  throw err;
}

Prevention

When it happens

Trigger: sendQuery with a model ref whose provider is not in Pi's static model catalog and no installed extension registers it — e.g. 'kiro/...' without the pi-provider-kiro extension, or extensions disabled via enableExtensions: false.

Common situations: Using a third-party/custom provider model ref without `pi install npm:pi-provider-<name>`, config where assistants.pi.enableExtensions is false, a typo in provider or model id, or an extension installed in ~/.pi/agent/extensions but not loaded.

Related errors


AI-assisted analysis of coleam00/Archon@0773b97458 (2026-09-01). Data as JSON: /api/errors/bdaa844175795b20. Report an issue: GitHub.