$collectionSizes Map of collection_id => vector_size */ public static function incompatibleCollections(array $collectionSizes): self { $details = []; foreach ($collectionSizes as $id => $size) { $details[] = "$id: {$size}d"; } return new self( 'Inkompatible Collections: Unterschiedliche Vektorgrößen (' . implode(', ', $details) . ')' ); } /** * Create exception for embedding size mismatch. */ public static function embeddingMismatch( string $collectionId, int $expectedSize, int $actualSize ): self { return new self( "Dimension Mismatch: Collection '$collectionId' erwartet {$expectedSize}d, Embedding hat {$actualSize}d", $collectionId, $expectedSize, $actualSize ); } }