rahulpawar/taskdeck
Lanebook, a team task board (boards, lists, cards, roles, history) you run from the web or from Claude/ChatGPT over MCP. FastAPI + DataK3 + appid + Models.
A remix template · 0 remixes · Remix rahulpawar/taskdeck
app/boards/application/ports.py
"""What the use cases need from the outside world. infrastructure/ provides it; tests fake it."""
from typing import Optional, Protocol
from boards.domain.model import Board, BoardList, Card
class BoardRepository(Protocol):
# boards and people
def get(self, board_id: str) -> Optional[Board]: ...
def boards_for(self, email: str) -> list: ...
def save_board(self, board: Board) -> None: ...
def remove_membership(self, board_id: str, email: str) -> None: ...
# lists
def lists_on(self, board_id: str) -> list: ...
def save_list(self, lst: BoardList) -> None: ...
def delete_list(self, list_id: str) -> None: ...
# cards
def get_card(self, card_id: str) -> Optional[Card]: ...
def cards_on(self, board_ids: list) -> list: ...
def save_card(self, card: Card) -> None: ...
def delete_card(self, card_id: str) -> None: ...
def next_card_number(self, board_id: str) -> int: ...
# history
def log(self, board_id: str, card_id: Optional[str], actor: str, action: str) -> None: ...
def history(self, board_id: str, card_id: Optional[str] = None, limit: int = 50) -> list: ...
class Assistant(Protocol):
"""Dodil Models behind a small, testable surface."""
def checklist(self, card_title: str, description: str = "") -> list: ...
def summary(self, board_title: str, facts: str) -> str: ...
def embed(self, texts: list) -> list: ...