def _create_entity_class(self) -> Entity:
        """Dynamically define an Entity class according to the parameters."""

        @Entity()
        class VectorEntity:
            id = Id()
            node_id = String()
            doc_id = String()
            text = String()
            metadata = Property(dict, type=PropertyType.flex)
            embeddings = Float32Vector(
                index=HnswIndex(
                    dimensions=self.embedding_dimensions,
                    distance_type=self.distance_type,
                )
            )

        return VectorEntity
Dynamically define an Entity class according to the parameters.
llama-index-integrations/vector_stores/llama-index-vector-stores-objectbox/llama_index/vector_stores/objectbox/base.py