[package]
name = "patent"
version = "0.2.0"
edition = "2021"
rust-version = "1.80"
license = "MIT OR Apache-2.0"
description = "A prior-art search for your code ideas — has this dev tool already been shipped?"
repository = "https://github.com/r14dd/patent"
homepage = "https://github.com/r14dd/patent"
documentation = "https://docs.rs/patent"
authors = ["Riad Mukhtarov"]
readme = "README.md"
keywords = ["search", "cli", "prior-art", "semantic-search", "dev-tools"]
categories = ["command-line-utilities", "development-tools"]
exclude = [
    ".github/",
    "clippy.toml",
    "rustfmt.toml",
    ".plan-source.md",
    # Demo assets are served from GitHub (raw URLs in the README), not shipped
    # in the crate tarball.
    "demo.tape",
    "demo.gif",
    "social-preview.png",
    "dist-workspace.toml",
]

[lib]
name = "patent"
path = "src/lib.rs"

[[bin]]
name = "patent"
path = "src/bin/patent/main.rs"

[dependencies]
# CLI / runtime
clap = { version = "4", features = ["derive"] }
clap_complete = "4"
tokio = { version = "1", features = ["rt-multi-thread", "macros", "time"] }
futures = "0.3"
async-trait = "0.1"

# HTTP + serialization
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls", "rustls-native-certs", "query"] }
serde = { version = "1", features = ["derive"] }
serde_json = "1"

# HTML scraping (PyPI has no public search API; we parse the search page)
scraper = "0.27"

# Errors
anyhow = "1"
thiserror = "2"

# Stable per-user cache dir for the embedding model
dirs = "6"

# Ranking (M3) — semantic embeddings, model downloads on first run
fastembed = "5"

# TUI (M5)
ratatui = "0.29"
crossterm = "0.29"
open = "5"

[dev-dependencies]
wiremock = "0.6"
tokio-test = "0.4"

# The profile that 'dist' will build with
[profile.dist]
inherits = "release"
lto = "thin"
