semsynth.backends.base
Backend interface definitions for SemSynth.
Functions
|
Validate that a backend module exposes a compliant |
Classes
|
Special type indicating an unconstrained type. |
|
Protocol describing the callable surface for backend implementations. |
|
Protocol applied to backend modules. |
|
|
|
PurePath subclass that can make system calls. |
|
Base class for protocol classes. |
|
- class semsynth.backends.base.Backend(*args, **kwargs)
Bases:
ProtocolProtocol describing the callable surface for backend implementations.
- run_experiment(df: pd.DataFrame, *, provider: str | None, dataset_name: str | None, provider_id: int | None, outdir: str, label: str, model_info: Dict[str, Any] | None, rows: int | None, seed: int, test_size: float, semmap_export: Dict[str, Any] | None = None) Path
Execute the backend for a dataset and return the run directory.
- class semsynth.backends.base.BackendModule(*args, **kwargs)
Bases:
ProtocolProtocol applied to backend modules.
- run_experiment(*, provider: str | None, dataset_name: str | None, provider_id: int | None, outdir: str, label: str, model_info: Dict[str, Any] | None, rows: int | None, seed: int, test_size: float, semmap_export: Dict[str, Any] | None = None) Path
Execute the backend for a dataset and return the run directory.
- semsynth.backends.base.ensure_backend_contract(module: ModuleType) None
Validate that a backend module exposes a compliant
run_experiment.