Skip to content

Commit

Permalink
fix the issue
Browse files Browse the repository at this point in the history
  • Loading branch information
faisal-alvi committed Dec 8, 2023
1 parent ae66799 commit bcee113
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion includes/Classifai/Providers/OpenAI/Embeddings.php
Original file line number Diff line number Diff line change
Expand Up @@ -672,7 +672,7 @@ private function get_embeddings_similarity( $embedding ) {

if ( $term_embedding ) {
$similarity = $calculations->similarity( $embedding, $term_embedding );
if ( false !== $similarity || $similarity <= $threshold ) {
if ( false !== $similarity && $similarity <= $threshold ) {
$embedding_similarity[ $tax ][ $term_id ] = $similarity;
}
}
Expand Down

0 comments on commit bcee113

Please sign in to comment.