Start a workspace
This commit is contained in:
parent
a146790e17
commit
11a7e88b95
|
@ -0,0 +1,29 @@
|
|||
[package]
|
||||
name = "instant-segment"
|
||||
version = "0.7.1"
|
||||
authors = ["Dirkjan Ochtman <dirkjan@ochtman.nl>"]
|
||||
edition = "2018"
|
||||
license = "Apache-2.0"
|
||||
description = "Fast English word segmentation"
|
||||
homepage = "https://github.com/InstantDomainSearch/instant-segment"
|
||||
repository = "https://github.com/InstantDomainSearch/instant-segment"
|
||||
documentation = "https://docs.rs/instant-segment"
|
||||
readme = "../README.md"
|
||||
|
||||
[features]
|
||||
__test_data = ["test-cases"]
|
||||
test-cases = []
|
||||
with-serde = ["serde", "ahash/serde", "smartstring/serde"]
|
||||
|
||||
[dependencies]
|
||||
ahash = "0.7.0"
|
||||
smartstring = "0.2.5"
|
||||
serde = { version = "1.0.123", features = ["derive"], optional = true }
|
||||
|
||||
[dev-dependencies]
|
||||
bencher = "0.1.5"
|
||||
once_cell = "1.4"
|
||||
|
||||
[[bench]]
|
||||
name = "bench"
|
||||
harness = false
|
|
@ -13,7 +13,7 @@ fn test_data() {
|
|||
}
|
||||
|
||||
pub fn segmenter() -> Segmenter {
|
||||
let dir = PathBuf::from(format!("{}/data", env!("CARGO_MANIFEST_DIR")));
|
||||
let dir = PathBuf::from(format!("{}/../data", env!("CARGO_MANIFEST_DIR")));
|
||||
|
||||
let uni_file = dir.join("unigrams.txt");
|
||||
let reader = BufReader::new(File::open(&uni_file).unwrap());
|
Loading…
Reference in New Issue