clearActiveEmbeddingIdentity method

  1. @override
Future<void> clearActiveEmbeddingIdentity()
override

Clears the active embedding identity (in-memory spec + persisted prefs).

See clearActiveInferenceIdentity: default throws rather than silently no-op'ing, so a non-overriding implementer fails loudly instead of leaving a stale persisted identity.

Implementation

@override
Future<void> clearActiveEmbeddingIdentity() async {
  try {
    final mutation = _activeEmbeddingIdentityCoordinator.enqueueOrThrow(
      const ActiveEmbeddingIdentityRecord.cleared(),
    );
    await mutation.committed;
  } catch (e) {
    edgeAiLog('[ModelManager] clearActiveEmbeddingIdentity failed: $e');
    rethrow;
  }
  edgeAiLog('Active embedding identity cleared');
}