From c41506d5e5b1030fe3d49b7daa7dbebae8412ef4 Mon Sep 17 00:00:00 2001 From: Meng Zhang Date: Sat, 3 Jun 2023 11:48:17 -0700 Subject: [PATCH] add tabby-coreml --- Cargo.toml | 1 + crates/tabby-coreml/Cargo.toml | 8 ++++++++ crates/tabby-coreml/src/lib.rs | 14 ++++++++++++++ 3 files changed, 23 insertions(+) create mode 100644 crates/tabby-coreml/Cargo.toml create mode 100644 crates/tabby-coreml/src/lib.rs diff --git a/Cargo.toml b/Cargo.toml index ac23343..a0bf215 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,6 +2,7 @@ members = [ "crates/tabby", "crates/tabby-common", + "crates/tabby-coreml", "crates/ctranslate2-bindings", "crates/rust-cxx-cmake-bridge", ] diff --git a/crates/tabby-coreml/Cargo.toml b/crates/tabby-coreml/Cargo.toml new file mode 100644 index 0000000..3e42622 --- /dev/null +++ b/crates/tabby-coreml/Cargo.toml @@ -0,0 +1,8 @@ +[package] +name = "tabby-coreml" +version = "0.1.0" +edition = "2021" + +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html + +[dependencies] diff --git a/crates/tabby-coreml/src/lib.rs b/crates/tabby-coreml/src/lib.rs new file mode 100644 index 0000000..7d12d9a --- /dev/null +++ b/crates/tabby-coreml/src/lib.rs @@ -0,0 +1,14 @@ +pub fn add(left: usize, right: usize) -> usize { + left + right +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn it_works() { + let result = add(2, 2); + assert_eq!(result, 4); + } +}