# -*- coding: utf-8 -*- r"""源件与产物对象存储接口(**组件接入点:MinIO**)。 现在:源件在 `data/raw/<场站>/`、产物在 `outputs/<场>/`。 目标:以**对象键**(`<场站>/<族>/<件名>`)取代绝对路径,后端可换 MinIO。 P0 只立契约,无实现(默认仍是本地目录)。 """ from __future__ import annotations from abc import ABC, abstractmethod from typing import Iterator class ObjectStore(ABC): @abstractmethod def put(self, key: str, path) -> str: ... @abstractmethod def get(self, key: str, dest) -> str: ... @abstractmethod def list(self, prefix: str = '') -> Iterator[str]: ... @abstractmethod def stat(self, key: str) -> dict: ...