LLM Connection Health
Understanding why LLM connections disconnect and how to fix them.
What is a disconnected connection?
Saymail monitors the health of your LLM connections during email classification. When a connection’s HTTP call fails 3 times in a row, Saymail marks it as disconnected and skips it in future classification rounds until you reconnect it.
This prevents Saymail from repeatedly hitting an unresponsive service, which would slow down classification of your other emails.
Common causes
Network and service issues
- API key expired or invalid - Your LLM provider deactivated the key or your credit ran out.
- Service unreachable - The LLM provider is down, or your network is blocking the request.
- Local model stopped - If you use Ollama or another local model, the process may no longer be running.
There’s no request timeout - a slow or hanging server just makes classification slow, it doesn’t by itself count as a failure.
Prompt issues
- System prompt too long - Some models truncate the response when input is too large, resulting in incomplete JSON.
A response that fails to parse as valid JSON does not count toward the 3-failure threshold - the HTTP call itself already succeeded. A malformed custom prompt shows up as bad or missing classification results, not as a disconnected connection.
How to reconnect
- Open the LLM Connections panel (via the command palette or menu).
- A connection that’s been marked disconnected shows a small failure icon next to it, with the tooltip “Connection failed. Click to re-enter your API key.”
- Click the icon to open the connection’s edit panel.
- Update whatever needs fixing (API key, base URL, model name) and click Save.
Saving doesn’t re-test the connection - it simply re-enables it, and it’s tried again on the next classification run. If the underlying problem wasn’t fixed, it will fail (and eventually get marked disconnected) again.
Good to know
- Disconnected connections automatically reset when you restart the app - the failure counter lives in memory only.
- The classification task runs every 30 minutes by default, and is also triggered about half a second after every completed mailbox sync. If all connections are disconnected, the task skips the round without errors.
- Higher-priority connections are tried first. If connection #1 is disconnected, Saymail tries connection #2, and so on.