()
| 335 | |
| 336 | |
| 337 | def _get_embedding_service(): |
| 338 | global _EMBEDDING_SERVICE |
| 339 | if _EMBEDDING_SERVICE is not None: |
| 340 | return _EMBEDDING_SERVICE |
| 341 | |
| 342 | try: |
| 343 | embedding_module = importlib.import_module("skills.embedding.scripts.embed") |
| 344 | _EMBEDDING_SERVICE = embedding_module.get_embedding_service() |
| 345 | except Exception: |
| 346 | _EMBEDDING_SERVICE = False |
| 347 | |
| 348 | return _EMBEDDING_SERVICE or None |
| 349 | |
| 350 | |
| 351 | def score_semantic_direction_confidence(similarity: float) -> float: |
no test coverage detected