Agent Chat UI hangs ~5 min when the chat-title (small) model is out of quota; small model cannot be redirected to BYOK

Author: flex81Created Sep 28, 2026Updated Sep 29, 2026
Labelsbug

Summary

With the opencode backend, when the Copilot Plus quota is exhausted, opening or switching chats hangs the whole chat UI for ~5 minutes before recovering. The small model used for chat-title generation is hardwired to copilot-plus-flash and is not redirected when the user changes the agent's Default model to a BYOK provider.

Versions

  • Copilot for Obsidian: 4.0.11 (Obsidian: 1.13.7)
  • Backend: opencode (managed binary 1.18.31)
  • Provider in use: BYOK polza.ai via local OpenAI-compatible proxy

Steps to reproduce

  1. Let the Copilot Plus weekly quota run out (Weekly usage = 100%; the plugin still shows "Up to date").
  2. In Settings → Copilot → Agent → opencode → Default model, switch the default to a BYOK model, e.g. 021e5efc-.../deepseek/deepseek-v4.1-flash.
  3. Open or switch between chats.

Expected

  • Chat title generation should use the user's selected default model, or a configurable "small" model — not always Copilot Plus.
  • On HTTP 429 / provider timeout, the UI should fail fast, not block ~5 min.

Actual

  • The UI freezes for ~300 s on every affected action, then resumes.
  • Title generation keeps hitting the out-of-quota provider.

Evidence (opencode.log)

message="stream error" providerID=copilot-plus modelID=copilot-plus-flash
  error.error="ProviderHeaderTimeoutError: Provider response headers timed out after 300000ms"

message="stream error" providerID=copilot-plus modelID=copilot-plus-flash
  error.error="AI_APICallError: Too Many Requests"

Even after changing the opencode Default model to a BYOK provider, agent=title requests still go to providerID=copilot-plus:

agent=title providerID=copilot-plus modelID=copilot-plus-flash

With a BYOK default, some title requests instead route to the opencode provider with internal models and fail:

providerID=opencode modelID=nemotron-3.5-lightning-free
  AI_APICallError: Error from provider (Console): Upstream request failed

Root cause (my reading)

opencode debug config shows the Copilot-generated config pins "model": "copilot-plus-flash" at the top level, with no separate small/title model field. So the small model used for chat titles is hardwired to copilot-plus and cannot be redirected by the user, even though the main/default model is BYOK.

Request

  1. Make the chat-title / small model follow the user's selected default model, or expose it as a configurable setting.
  2. Fail fast on 429 / provider header timeout instead of blocking the UI ~5 min.

Source: logancyang/obsidian-copilot