This file provides guidance for AI agents working with this codebase. For detailed architecture and patterns, see CLAUDE.md.
Scribae is a CLI tool that transforms local Markdown notes into structured SEO content packages using LLMs via OpenAI-compatible APIs.
Core workflow: idea → brief → write → meta → translate
uv sync --locked --all-extras --dev # Required: install all dependencies including PyTorch
uv run scribae --help # Run CLI
uv run ruff check # Lint (auto-fix: --fix)
uv run mypy # Type check
uv run pytest # Run testsImportant: The --all-extras flag is required for development (PyTorch needed for mypy). Always run tests, mypy, and ruff at the end of your task and fix any issues.
- Source:
src/scribae/withmain.pyas CLI entry point - Tests:
tests/unit/mirroring module names (e.g.,tests/unit/main_test.py→scribae/main.py) - Shared test helpers:
tests/conftest.py
- Style: Ruff defaults - 4-space indent, double quotes, 120-char lines, import sorting
- Typing: Strict mypy, all functions fully typed (Python 3.10+)
- Data: Prefer
TypedDict,Protocol, or Pydantic models - Naming:
snake_casefor modules/functions/variables,PascalCasefor classes - Tests: Name
test_<unit>_<behavior>, use pytest fixtures
Follow Conventional Commits: fix:, feat:, chore:, etc. Keep subjects under 72 characters.