"""Abstract base for post sources."""

from __future__ import annotations

from abc import ABC, abstractmethod
from collections.abc import Iterator

from agent_samochodowy.models import Post


class PostSource(ABC):
    """Plugin interface for post ingestion."""

    @abstractmethod
    def fetch_posts(self) -> Iterator[Post]:
        """Yield normalized posts from the source."""
        ...
