Buckets:
AnonymousSpottedToad/candidate_bucket / codebase /python /topoteretes_cognee /cognee /infrastructure /entities /BaseEntityExtractor.py
| from abc import ABC, abstractmethod | |
| from cognee.modules.engine.models import Entity | |
| class BaseEntityExtractor(ABC): | |
| """ | |
| Base class for entity extraction strategies. | |
| This class defines the interface for entity extraction methods that derived classes must | |
| implement. It serves as a blueprint for entity extraction strategies. | |
| """ | |
| async def extract_entities(self, text: str) -> list[Entity]: | |
| """ | |
| Extract entities from the given text. | |
| This is an abstract method that must be implemented by any subclass of | |
| BaseEntityExtractor. The implementation should take a string as input and return a list | |
| of extracted entities, defined by the Entity type. | |
| Parameters: | |
| ----------- | |
| - text (str): A string containing the text from which to extract entities. | |
| """ | |
| pass | |
Xet Storage Details
- Size:
- 885 Bytes
- Xet hash:
- ccd8b8f395f4c742e36f8c43f296c0da43ac498d0ea7c26f659ccc66fab0bdc5
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.