[package]
edition = "2024"
rust-version = "1.89"
name = "graphrt-ffi"
version = "0.11.0"
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Embedding API for mobile and desktop apps (Kotlin, Swift, Python...) via UniFFI."
homepage = "https://github.com/Graphrt/graphrt"
documentation = "https://docs.rs/graphrt-ffi"
readme = "README.md"
keywords = [
"ffi",
"uniffi",
"mobile",
"android",
"ios",
]
categories = [
"api-bindings",
"development-tools::ffi",
]
license = "Apache-2.0"
repository = "https://github.com/Graphrt/graphrt"
[features]
bindgen-cli = [
"uniffi/cli",
"uniffi/cargo-metadata",
]
code-js = ["dep:graphrt-code"]
context = ["graphrt-llm/context"]
default = [
"code-js",
"mcp-http",
"doc",
"rag",
"context",
]
doc = ["dep:graphrt-doc"]
files = [
"dep:graphrt-files",
"graphrt-llm/tool-files",
"graphrt-core/tool-files",
"graphrt-files?/doc",
]
image = [
"dep:graphrt-image",
"graphrt-llm/vision-preparer",
]
learning = [
"dep:graphrt-learn",
"graphrt-llm/learning",
]
mcp-http = ["dep:graphrt-mcp"]
mobile-js = [
"code-js",
"dep:rquickjs",
]
rag = ["dep:graphrt-rag"]
scripted-llm = ["graphrt-llm/mock"]
sdk = [
"default",
"mobile-js",
"skills",
"learning",
"files",
"ui",
"image",
"scripted-llm",
]
skills = [
"dep:graphrt-skill",
"graphrt-llm/skills",
]
ui = ["dep:graphrt-ui"]
[lib]
name = "graphrt_ffi"
crate-type = [
"lib",
"cdylib",
"staticlib",
]
path = "src/lib.rs"
[[bin]]
name = "uniffi-bindgen"
path = "src/bin/uniffi-bindgen.rs"
required-features = ["bindgen-cli"]
[[test]]
name = "agent"
path = "tests/agent.rs"
[[test]]
name = "api"
path = "tests/api.rs"
[[test]]
name = "bundle"
path = "tests/bundle.rs"
[[test]]
name = "capabilities"
path = "tests/capabilities.rs"
[[test]]
name = "credentials"
path = "tests/credentials.rs"
[dependencies.async-trait]
version = "0.1"
[dependencies.futures]
version = "0.3"
features = [
"std",
"async-await",
]
default-features = false
[dependencies.graphrt-bundle]
version = "0.11.0"
features = ["wasm"]
default-features = false
[dependencies.graphrt-code]
version = "0.11.0"
features = [
"js",
"tokio",
]
optional = true
default-features = false
[dependencies.graphrt-core]
version = "0.11.0"
features = [
"yaml",
"jinja",
"tokio",
"memory",
"bundle-env",
]
default-features = false
[dependencies.graphrt-doc]
version = "0.11.0"
features = [
"pdf",
"office",
"spreadsheet",
"epub",
"email",
"tokio",
]
optional = true
default-features = false
[dependencies.graphrt-files]
version = "0.11.0"
features = [
"tokio",
"regex",
]
optional = true
default-features = false
[dependencies.graphrt-http]
version = "0.11.0"
default-features = false
[dependencies.graphrt-image]
version = "0.11.0"
features = [
"tokio",
"process",
]
optional = true
default-features = false
[dependencies.graphrt-learn]
version = "0.11.0"
optional = true
default-features = false
[dependencies.graphrt-llm]
version = "0.11.0"
features = [
"openai",
"anthropic",
"gemini",
"bedrock",
"typesafe",
]
default-features = false
[dependencies.graphrt-mcp]
version = "0.11.0"
features = ["http"]
optional = true
default-features = false
[dependencies.graphrt-rag]
version = "0.11.0"
features = [
"http",
"qdrant",
"fs",
"sqlite",
"yaml",
]
optional = true
default-features = false
[dependencies.graphrt-skill]
version = "0.11.0"
optional = true
default-features = false
[dependencies.graphrt-ui]
version = "0.11.0"
optional = true
default-features = false
[dependencies.graphrt-wasm]
version = "0.11.0"
features = ["tokio"]
default-features = false
[dependencies.indexmap]
version = "2"
features = ["serde"]
[dependencies.rquickjs]
version = "0.14"
features = ["bindgen"]
optional = true
default-features = false
[dependencies.serde]
version = "1"
features = [
"derive",
"rc",
]
[dependencies.serde_json]
version = "1"
features = [
"preserve_order",
"raw_value",
]
[dependencies.thiserror]
version = "2"
[dependencies.tokio]
version = "1"
features = [
"rt-multi-thread",
"time",
"sync",
]
default-features = false
[dependencies.uniffi]
version = "0.32"
default-features = false
[dev-dependencies.tokio]
version = "1"
features = [
"rt-multi-thread",
"time",
"sync",
"macros",
"net",
"io-util",
]
default-features = false
[lints.clippy]
dbg_macro = "deny"
expect_used = "deny"
indexing_slicing = "warn"
panic = "deny"
print_stdout = "warn"
todo = "deny"
unimplemented = "deny"
unwrap_used = "deny"
[lints.rust]
missing_debug_implementations = "warn"
unsafe_code = "allow"
[lints.rust.rust_2018_idioms]
level = "warn"
priority = -1