def test_hf_e5_base_v2_embeddings_load_from_hf(self):
        """A test to ensure the embeddings are generated correctly for the default text model, loading from
        hf."""
        model_properties = {
            "name": 'intfloat/e5-base-v2',
            "dimensions": 768,
            "tokens": 512,
            "type": "hf",
            "model_size": 0.438,
            "text_query_prefix": "query: ",
            "text_chunk_prefix": "passage: ",
            "notes": ""
        }

        model = HuggingFaceModel(model_properties, "cpu", {})
        model.load()
        embeddings = model.encode(['query: how much protein should a female eat'])
        difference = np.linalg.norm(embeddings - self.E5_BASE_V2_MODEL_EMBEDDINGS) / len(
            embeddings)
        self.assertLess(difference, 1e-4, f"Text embeddings for model {model_properties} "
                                          f"are not close enough. The average difference is: {difference}")
A test to ensure the embeddings are generated correctly for the default text model, loading from
        hf.
tests/integ_tests/core/inference/embedding_models/test_hugging_face_model.py