Opaque base64(JSON{offset, corpus_revision}). Mismatch or
malformed input returns ErrorV1 with code = stale_cursor.
base64 promoted to workspace dep.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
58 lines
2.7 KiB
TOML
58 lines
2.7 KiB
TOML
[package]
|
|
name = "kebab-parse-image"
|
|
version = { workspace = true }
|
|
edition = { workspace = true }
|
|
rust-version = { workspace = true }
|
|
license = { workspace = true }
|
|
repository = { workspace = true }
|
|
description = "Image extractor + EXIF + OCR (Ollama-vision) for the kebab pipeline (P6-1, P6-2)"
|
|
|
|
[dependencies]
|
|
kebab-core = { path = "../kebab-core" }
|
|
kebab-config = { path = "../kebab-config" }
|
|
# `kebab-llm` re-exports the trait crate (`kebab-core::LanguageModel`)
|
|
# under a stable surface; the caption adapter consumes any
|
|
# `dyn LanguageModel`. We do NOT depend on `kebab-llm-local` (forbidden
|
|
# by p6-3 design §8) — the trait abstraction is exactly what spec
|
|
# requires.
|
|
kebab-llm = { path = "../kebab-llm" }
|
|
anyhow = { workspace = true }
|
|
serde = { workspace = true }
|
|
serde_json = { workspace = true }
|
|
time = { workspace = true }
|
|
tracing = { workspace = true }
|
|
# `image` ships a wide format menagerie under default features (BMP, DDS,
|
|
# Farbfeld, …). We only need PNG / JPEG / WebP / GIF / TIFF for v1 (per
|
|
# task spec out-of-scope HEIC/RAW). Trim defaults to keep the dep
|
|
# closure small.
|
|
image = { version = "0.25", default-features = false, features = ["png", "jpeg", "webp", "gif", "tiff"] }
|
|
# kamadak-exif: pure-Rust EXIF reader. Used for the whitelisted tag
|
|
# extraction (DateTimeOriginal, GPS, Make, Model, Orientation, Software).
|
|
kamadak-exif = "0.6"
|
|
# Ollama-vision OCR adapter (P6-2) talks HTTP directly. We keep the
|
|
# feature surface identical to `kebab-llm-local` (blocking + json +
|
|
# rustls-tls) so both crates share the same TLS backend and the
|
|
# transitive tokio runtime is brought in once.
|
|
reqwest = { version = "0.12", default-features = false, features = ["blocking", "json", "rustls-tls"] }
|
|
base64 = { workspace = true }
|
|
|
|
[dev-dependencies]
|
|
tempfile = { workspace = true }
|
|
blake3 = { workspace = true }
|
|
# Shared test infrastructure with `kebab-llm-local`: wiremock under
|
|
# tokio for HTTP fixtures.
|
|
wiremock = { workspace = true }
|
|
tokio = { workspace = true, features = ["rt-multi-thread"] }
|
|
# Used by `tests/common/mod.rs` to render the opt-in OCR integration
|
|
# fixture. Only loaded for tests; the production crate doesn't need
|
|
# font rendering.
|
|
ab_glyph = "0.2"
|
|
base64 = { workspace = true }
|
|
# `kebab-llm/mock` exposes `MockLanguageModel` for hermetic caption
|
|
# tests. Real adapters (Ollama) live in `kebab-llm-local`, which is
|
|
# only allowed at the dev-dep level here — the runtime crate stays
|
|
# trait-only, so the §8 forbidden-deps rule (no `kebab-llm-local`
|
|
# at runtime) is preserved.
|
|
kebab-llm = { path = "../kebab-llm", features = ["mock"] }
|
|
kebab-llm-local = { path = "../kebab-llm-local" }
|