forked from jkawamoto/ctranslate2-rs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Cargo.toml
121 lines (97 loc) · 2.43 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
[package]
name = "ct2rs"
version = "0.9.5"
authors = ["Junpei Kawamoto <[email protected]>"]
categories = ["api-bindings"]
documentation = "https://docs.rs/ct2rs"
edition = "2021"
include = [
"/include",
"/src",
"/build.rs",
"/LICENSE",
"/examples",
"/CTranslate2/CMakeLists.txt",
"/CTranslate2/LICENSE",
"/CTranslate2/cmake",
"/CTranslate2/cpp",
"/CTranslate2/include",
"/CTranslate2/python",
"/CTranslate2/src",
"/CTranslate2/third_party",
"!/CTranslate2/**/.*",
"!/CTranslate2/**/test",
"!/CTranslate2/**/docs",
"!/CTranslate2/**/media",
]
keywords = ["ctranslate2", "bindings", "llm", "whisper"]
license = "MIT"
repository = "https://github.com/jkawamoto/ctranslate2-rs"
description = "Rust bindings for OpenNMT/CTranslate2"
[dependencies]
anyhow = "1.0.93"
cxx = { version = "1.0.130", features = ["c++17"] }
sentencepiece = "0.11.2"
tokenizers = "0.20.3"
# Dependencies for Whisper model
mel_spec = { version = "0.2.7", optional = true }
ndarray = { version = "0.15.6", optional = true }
serde = { version = "1.0.215", features = ["derive"], optional = true }
serde_json = { version = "1.0.133", optional = true }
# Dependencies for Hugging Face integration
hf-hub = { version = "0.3.2", optional = true }
[target.'cfg(windows)'.dependencies]
intel-mkl-src = { version = "0.8.1", optional = true, features = ["mkl-static-ilp64-seq"] }
[target.'cfg(unix)'.dependencies]
intel-mkl-src = { version = "0.8.1", optional = true }
[dev-dependencies]
clap = { version = "4.5.21", features = ["derive"] }
rand = "0.8.5"
# Dependencies for Whisper example
hound = { version = "3.5.1" }
[build-dependencies]
cmake = "0.1.51"
cxx-build = "1.0.130"
walkdir = "2.5.0"
[features]
default = ["ruy"]
whisper = ["dep:mel_spec", "dep:ndarray", "dep:serde", "dep:serde_json"]
flash-attention = []
tensor-parallel = []
cuda-dynamic-loading = ["cuda"]
hub = ["dep:hf-hub"]
# Features to select backends.
mkl = ["dep:intel-mkl-src"]
openblas = []
ruy = []
accelerate = []
cuda = []
cudnn = ["cuda"]
[[example]]
name = "bart"
[[example]]
name = "bloom"
[[example]]
name = "falcon"
[[example]]
name = "marian-mt"
[[example]]
name = "mpt"
[[example]]
name = "nllb"
[[example]]
name = "gpt-2"
[[example]]
name = "gpt-j"
[[example]]
name = "gpt-neox"
[[example]]
name = "opt"
[[example]]
name = "t5"
[[example]]
name = "stream"
[[example]]
name = "whisper"
[package.metadata.docs.rs]
features = ["whisper", "hub"]