generate

open suspend override fun generate(prompt: String): AiResult<String>(source)

Detection-ordered, same as CompositeOnDeviceLlm.tryBackends: tries each provider in providers order, returns the first success, and the last failure when every provider declines or errors. AiFailure.NoKey when providers is empty — this device has no cloud key configured at all, distinct from a configured-but-failing provider.