Files
AI-Studio/runtime/Cargo.toml
T

193 lines
7.2 KiB
TOML
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
[package]
name = "mindwork-ai-studio"
version = "26.10.1"
edition = "2024"
description = "MindWork AI Studio"
authors = ["Thorsten Sommer"]
[build-dependencies]
tauri-build = { version = "2.6.3", features = [] }
[dependencies]
tauri = { version = "2.11.5", features = [] }
tauri-plugin-window-state = { version = "2.4.1" }
tauri-plugin-shell = "2.3.5"
tauri-plugin-dialog = "2.7.1"
tauri-plugin-opener = "2.5.4"
tauri-plugin-single-instance = "2"
serde = { version = "1.0.228", features = ["derive"] }
serde_json = "1.0.150"
keyring-core = "1.0.0"
arboard = { version = "3.6.1", features = ["wayland-data-control"] }
tokio = { version = "1.52.3", features = ["rt", "rt-multi-thread", "macros", "process"] }
tokio-stream = { version = "0.1.18", features = ["sync"] }
futures = "0.3.32"
async-stream = "0.3.6"
flexi_logger = "0.31.9"
chrono = "0.4.44"
dirs = "6.0.0"
log = { version = "0.4.33", features = ["kv"] }
once_cell = "1.21.4"
axum = { version = "0.8.9", features = ["http2", "json", "query", "tokio"] }
axum-server = { version = "0.8.0", features = ["tls-rustls"] }
rustls = { version = "0.23.46", default-features = false, features = ["aws_lc_rs"] }
rand = "0.10.2"
rand_chacha = "0.10.0"
subtle = "2.6.1"
base64 = "0.22.1"
aes = "0.9.1"
cbc = "0.2.1"
pbkdf2 = "0.13.0"
hmac = "0.13.0"
sha2 = "0.11.0"
rcgen = { version = "0.14.8", features = ["pem"] }
# The readers are needed to identify a file by its content instead of its extension: zip covers
# OOXML and ODF, cfb the legacy Office formats, txt tells actual text from binary data, and exe
# recognizes executables which carry a harmless extension. Without them, every ZIP-based document
# is only detected as a plain archive.
file-format = { version = "0.29.0", features = ["reader-zip", "reader-cfb", "reader-txt", "reader-exe"] }
# Text files are not always UTF-8: on Windows they are frequently encoded in Windows-1252, whose
# umlauts are single bytes and therefore invalid UTF-8. chardetng guesses the encoding, encoding_rs
# decodes it.
chardetng = "1.0.0"
encoding_rs = "0.8.35"
symphonia = { version = "0.6", default-features = false, features = ["aac", "aiff", "alac", "caf", "flac", "isomp4", "mkv", "mp1", "mp2", "mp3", "ogg", "pcm", "vorbis", "wav"] }
ropus = "=0.12.18"
rubato = { version = "4", default-features = false, features = ["fft_resampler"] }
webm-iterable = "0.6.4"
calamine = "0.36.0"
pdfium-render = "0.9.1"
sys-locale = "0.3.2"
whoami = "2.1.2"
cfg-if = "1.0.4"
pptx-to-md = "1.0.0"
docx-to-md = "0.1.0"
tempfile = "3.27.0"
strum_macros = "0.28.0"
sysinfo = "0.39.6"
bytes = "1.12.1"
qdrant-edge = "0.8.0"
# Prompt-injection detection. `regex` gives us linear-time matching without backtracking, so
# a hostile document cannot make a scan blow up, and `aho-corasick` matches the ~1600 fixed
# phrases in one pass no matter how long that list grows.
regex = "1.13.1"
aho-corasick = "1.1.5"
toml = "1.1.4"
image = { version = "0.25.10", default-features = false, features = ["jpeg", "png", "webp", "gif", "bmp", "tiff"] }
tokenizers = "0.23.1"
[dev-dependencies]
# Sends requests through the runtime API router in tests, without starting a server.
tower = { version = "0.5.2", features = ["util"] }
[patch.crates-io]
# Issue: This repo was not updated since 2020. The rand crate was outdated. We patched it to use a newer version of rand.
# State: There is a PR for a long time, but it was not merged. We use the git version for now. Qdrant Edge still depends
# on this crate in version 0.1.2, so the patch stays relevant: https://github.com/asimihsan/permutation-iterator-rs/pull/14
permutation_iterator = { git = "https://github.com/SommerEngineering/permutation-iterator-rs.git", rev = "76836ed316d18dfef530ba908f58481c343e80d7" }
[target.'cfg(target_os = "windows")'.dependencies]
windows-registry = "0.6.1"
windows-native-keyring-store = "1.1.0"
windows = { version = "=0.61.3", features = ["ApplicationModel_DataTransfer", "Foundation", "Foundation_Collections", "Storage", "Storage_Streams", "Win32_Foundation", "Win32_System_WinRT", "Win32_UI_Shell"] }
windows-collections = "=0.2.0"
[target.'cfg(target_os = "macos")'.dependencies]
apple-native-keyring-store = { version = "1.0.0", features = ["keychain"] }
objc2 = "0.6.3"
objc2-app-kit = { version = "0.3.2", features = ["NSResponder", "NSSharingService", "NSView", "NSWorkspace"] }
objc2-foundation = { version = "0.3.2", features = ["NSArray", "NSBundle", "NSGeometry", "NSString", "NSURL"] }
[target.'cfg(target_os = "linux")'.dependencies]
ashpd = { version = "0.13.12", default-features = false, features = ["tokio", "open_uri", "global_shortcuts"] }
dbus-secret-service-keyring-store = { version = "1.0.0", features = ["crypto-rust"] }
dbus-secret-service = "4.1.0"
webkit2gtk = { version = "2.0.2", features = ["v2_8"] }
[target.'cfg(not(any(target_os = "android", target_os = "ios")))'.dependencies]
tauri-plugin-global-shortcut = "2"
tauri-plugin-updater = "2.10.1"
[features]
custom-protocol = ["tauri/custom-protocol"]
# Media normalization is CPU-heavy even when the application itself is built for development.
# Keep release settings untouched while optimizing the hot decoder/resampler/container crates.
[profile.dev.package.symphonia-core]
opt-level = 3
[profile.dev.package.symphonia-format-mkv]
opt-level = 3
[profile.dev.package.ropus]
opt-level = 3
[profile.dev.package.rubato]
opt-level = 3
[profile.dev.package.webm-iterable]
opt-level = 3
# Scanning a document for prompt injections is just as CPU-heavy, and unoptimized matching
# engines dominate it completely: a 1580-page PDF takes about 3 seconds to scan when these
# crates are optimized and over a minute when they are not. Without this, every developer
# measuring the app against a large document measures the build profile instead of the scan.
# The engines are `regex-automata` and `aho-corasick`; `regex` is the wrapper around the
# former, `regex-syntax` compiles the ~1600 phrases once at startup, and `memchr` provides
# the SIMD prefilters both engines rely on.
[profile.dev.package.regex]
opt-level = 3
[profile.dev.package.regex-automata]
opt-level = 3
[profile.dev.package.regex-syntax]
opt-level = 3
[profile.dev.package.aho-corasick]
opt-level = 3
[profile.dev.package.memchr]
opt-level = 3
# Preparing images is CPU-heavy as well: AI Studio decodes a picture, scales it down to 2560 pixels,
# and encodes it again, both for the AI and for the slides of the Slide Assistant. A photo of
# 2912 × 1632 pixels saved as PNG takes about 0.12 seconds in a release build, 6.6 seconds in a
# development build without this, and about 0.5 seconds with it; almost all of that is scaling and
# encoding. `image` does the scaling; `png`, `fdeflate`, `flate2`, `miniz_oxide`, `crc32fast`,
# and `simd-adler32` read and write PNG files; `zune-jpeg` and `zune-core` read JPEG files; and
# `image-webp` reads and writes WebP files.
[profile.dev.package.image]
opt-level = 3
[profile.dev.package.png]
opt-level = 3
[profile.dev.package.fdeflate]
opt-level = 3
[profile.dev.package.flate2]
opt-level = 3
[profile.dev.package.miniz_oxide]
opt-level = 3
[profile.dev.package.crc32fast]
opt-level = 3
[profile.dev.package.simd-adler32]
opt-level = 3
[profile.dev.package.zune-jpeg]
opt-level = 3
[profile.dev.package.zune-core]
opt-level = 3
[profile.dev.package.image-webp]
opt-level = 3