[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[project]
name = "ninjastack"
version = "0.1.0"
description = "Ninja Stack — schema-first agentic backend framework"
readme = "README.md"
requires-python = ">=3.12"
dependencies = [
    "pydantic>=2.0",
    "sqlalchemy[asyncio]>=2.0",
    "aiosqlite>=0.20",
    "jinja2>=3.1",
    "google-adk>=0.4.0",
    "litellm>=1.0",
    "strawberry-graphql>=0.236",
    "starlette>=0.27",
    "pyjwt[crypto]>=2.8",
    "httpx>=0.25",
    "bcrypt>=4.0",
    "typer>=0.15",
    "pyyaml>=6.0",
]

[project.scripts]
ninjastack = "ninja_cli.cli:app"

[project.optional-dependencies]
mongo = ["motor>=3.0"]
graph = ["neo4j>=5.0"]
vector = ["chromadb>=0.4", "pymilvus>=2.3"]
all = [
    "motor>=3.0",
    "neo4j>=5.0",
    "chromadb>=0.4",
    "pymilvus>=2.3",
]

[tool.hatch.build.targets.wheel]
packages = [
    "libs/ninja-core/src/ninja_core",
    "libs/ninja-cli/src/ninja_cli",
    "libs/ninja-persistence/src/ninja_persistence",
    "libs/ninja-agents/src/ninja_agents",
    "libs/ninja-auth/src/ninja_auth",
    "libs/ninja-boundary/src/ninja_boundary",
    "libs/ninja-codegen/src/ninja_codegen",
    "libs/ninja-deploy/src/ninja_deploy",
    "libs/ninja-gql/src/ninja_gql",
    "libs/ninja-graph/src/ninja_graph",
    "libs/ninja-introspect/src/ninja_introspect",
    "libs/ninja-models/src/ninja_models",
    "libs/ninja-ui/src/ninja_ui",
    "apps/ninja-api/src/ninja_api",
    "apps/ninja-setup-assistant/src/ninja_setup_assistant",
]

[tool.uv.workspace]
members = ["libs/*", "apps/*"]

[tool.uv.sources]
ninja-agents = { workspace = true }
ninja-api = { workspace = true }
ninja-auth = { workspace = true }
ninja-boundary = { workspace = true }
ninja-cli = { workspace = true }
ninja-codegen = { workspace = true }
ninja-core = { workspace = true }
ninja-deploy = { workspace = true }
ninja-gql = { workspace = true }
ninja-graph = { workspace = true }
ninja-introspect = { workspace = true }
ninja-models = { workspace = true }
ninja-persistence = { workspace = true }
ninja-setup-assistant = { workspace = true }
ninja-ui = { workspace = true }
ninja-test-app = { workspace = true }
ninja-test-lib = { workspace = true }

[dependency-groups]
dev = [
    "ninja-test-app",
    "ninja-test-lib",
    "mkdocs-gen-files>=0.6.0",
    "mkdocs-literate-nav>=0.6.2",
    "mkdocs-material>=9.7.2",
    "mkdocs-mermaid2-plugin>=1.2.3",
    "mkdocs-section-index>=0.3.10",
    "mkdocstrings>=1.0.3",
    "mkdocstrings-python>=2.0.3",
    "pytest>=8.0",
    "pytest-asyncio>=0.24",
    "pytest-cov>=6.0",
    "ruff>=0.9",
]

[tool.pytest.ini_options]
testpaths = ["libs/*/tests", "apps/*/tests"]
asyncio_mode = "auto"
addopts = "-v --tb=short"
filterwarnings = ["ignore::DeprecationWarning"]

[tool.ruff]
target-version = "py312"
line-length = 120

[tool.ruff.lint]
select = ["E", "F", "I"]
