[package]
name = "odict"
description = "A blazingly-fast dictionary file format for human languages"
homepage = "https://odict.org"
repository = "https://github.com/TheOpenDictionary/odict"
version = "3.3.0"
edition = "2021"
license = "MIT"
exclude = ["benches/*", "tests/*"]
[features]
sql = ["dep:sea-query"]
config = ["dep:dirs"]
js = ["uuid/js"]
alias = ["config"]
http = [
"dep:reqwest",
"dep:reqwest-middleware",
"dep:reqwest-retry",
"dep:regex",
"dep:futures-util",
"config",
]
html = ["markdown"]
search = ["dep:tantivy", "config"]
markdown = ["dep:pulldown-cmark"]
default = ["sql", "config"]
charabia = ["dep:charabia"]
tokenize = [
"tokenize-latin",
"tokenize-chinese",
"tokenize-japanese",
"tokenize-thai",
"tokenize-korean",
"tokenize-khmer",
"tokenize-swedish",
"tokenize-german",
]
tokenize-latin = ["dep:charabia"]
tokenize-chinese = ["tokenize-latin", "charabia/chinese-segmentation"]
tokenize-japanese = ["tokenize-latin", "charabia/japanese"]
tokenize-thai = ["tokenize-latin", "charabia/thai"]
tokenize-korean = ["tokenize-latin", "charabia/korean"]
tokenize-khmer = ["tokenize-latin", "charabia/khmer"]
tokenize-swedish = ["tokenize-latin", "charabia/swedish-recomposition"]
tokenize-german = ["tokenize-latin", "charabia/german-segmentation"]
[[bench]]
name = "lib"
harness = false
[dependencies]
byteorder = "1.5.0"
quick-xml = { version = "0.40.1", features = ["serialize"] }
rayon = "1.12.0"
indexmap = { version = "2.14.0", features = ["serde", "rayon"] }
charabia = { version = "0.9.9", optional = true, default-features = false }
rkyv = { version = "0.8.16", features = ["indexmap-2", "uuid-1"] }
serde = { version = "1.0.228", features = ["serde_derive"] }
uuid = { version = "1.23.3", features = [
"v4",
"fast-rng",
"macro-diagnostics",
] }
url = "2.5.8"
serde_json = "1.0.150"
thiserror = "2.0.18"
brotli = "8.0.4"
structural-convert = { workspace = true }
pulldown-cmark = { version = "0.13.4", optional = true }
reqwest = { version = "0.13.4", optional = true, features = [
"rustls",
"stream",
] }
strum = { version = "0.28.0", features = ["derive"] }
reqwest-middleware = { version = "0.5.2", optional = true }
reqwest-retry = { version = "0.9.1", optional = true }
futures-util = { version = "0.3", optional = true }
regex = { version = "1.12.4", optional = true }
tantivy = { version = "0.26.1", optional = true }
dirs = { version = "6.0.0", optional = true }
sea-query = { version = "1.0.1", optional = true }
[dev-dependencies]
criterion = { version = "0.8.2", features = ["async_tokio", "html_reports"] }
insta = "1.48.0"
map-macro = { version = "0.3.0" }
tokio = { version = "1.52.3", features = ["rt", "macros"] }
wiremock = "0.6.5"
tempfile = "3.27.0"
regex = "1.12.4"
[lib]
name = "odict"
crate-type = ["cdylib", "staticlib", "lib"]