cf-vision/pyproject.toml
pyr0ball 353525c1f4 feat: initial cf-vision scaffold — ImageFrame API, stub inference modules
- cf_vision/models.py: ImageFrame + ImageElement + BoundingBox (MIT)
  Full Dolphin-v2 element taxonomy (21 types), convenience accessors
  (text_blocks, barcodes, tables, full_text)
- cf_vision/router.py: VisionRouter — mock + real paths, task routing
  (document, barcode, receipt, general)
- cf_vision/barcode.py: BarcodeScanner — pyzbar wrapper, CPU-only, MIT
- cf_vision/ocr.py: DolphinOCR — ByteDance/Dolphin-v2 async stub (BSL 1.1)
- cf_vision/receipt.py: ReceiptParser stub — Kiwi Phase 2 target (BSL 1.1)
- cf_vision/camera.py: CameraCapture — OpenCV single-frame capture (MIT)
- pyproject.toml: inference / barcode / camera optional extras
- .env.example: HF_TOKEN, CF_VISION_DEVICE, CF_VISION_MOCK
- README: module map, ImageFrame API reference, consumer roadmap
- tests: 6 passing (ImageFrame accessors, VisionRouter mock/real)

Extracted from circuitforge_core.vision per cf-core#36.
2026-04-06 17:59:00 -07:00

48 lines
963 B
TOML

[build-system]
requires = ["setuptools>=68"]
build-backend = "setuptools.build_meta"
[project]
name = "cf-vision"
version = "0.1.0"
description = "CircuitForge vision pipeline — ImageFrame API, OCR, barcode, receipt extraction"
readme = "README.md"
requires-python = ">=3.11"
license = {text = "MIT"}
dependencies = [
"pydantic>=2.0",
]
[project.optional-dependencies]
# Real inference backends — not required for stub/mock mode
inference = [
"torch>=2.0",
"torchvision>=0.15",
"numpy>=1.24",
"Pillow>=10.0",
"transformers>=4.40",
"python-dotenv>=1.0",
]
# Barcode / QR scanning
barcode = [
"pyzbar>=0.1.9",
"Pillow>=10.0",
]
# Camera capture
camera = [
"opencv-python>=4.8",
]
dev = [
"pytest>=8.0",
"pytest-asyncio>=0.23",
"Pillow>=10.0",
"numpy>=1.24",
]
[tool.setuptools.packages.find]
where = ["."]
include = ["cf_vision*"]
[tool.pytest.ini_options]
testpaths = ["tests"]
asyncio_mode = "auto"