getProvidersWithCapability static method

List<String> getProvidersWithCapability(
  1. LLMCapability capability
)

Get providers that support a specific capability

capability - Capability to filter by

Returns list of provider IDs that support the capability

Implementation

static List<String> getProvidersWithCapability(LLMCapability capability) {
  _ensureInitialized();
  return _factories.entries
      .where(
          (entry) => entry.value.supportedCapabilities.contains(capability))
      .map((entry) => entry.key)
      .toList();
}