- class PSI(psi_writer_id: str)¶
The PSI interface is intended for the end-user interface to get an intersection of items of clients specified without knowing:
1) the details of PSI algorithms 2) real client's own items to other FL clients and FL Servers
psi_writer_id – a PSIWriter id, we will use it to get PSIWriter from engine. PSIWriter will be used save the intersection results. For example, FilePSIWriter implements PSIWriter interface and save to the local disk
- get_intersection() List[str] | None ¶
This method will return the calculated intersection once PSI job is completed and successful.
Returns: Intersection result or None
- abstract load_items() List[str] ¶
This method needs to be implemented to provide the list of items to PSI algorithm in order to calculate intersection.
Returns: List of Items to be used for intersection calculation
- save(intersection: List[str])¶