[package]
edition = "2024"
name = "lean-ctx-proxy"
version = "3.12.2"
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "The LeanCTX model-API proxy: provider adapters, compression and accounting on top of LeanCTX | OSS."
homepage = "https://leanctx.com"
readme = "README.md"
keywords = [
"lean-ctx",
"llm",
"proxy",
"context",
]
categories = ["development-tools"]
license = "Apache-2.0"
repository = "https://github.com/yvgude/lean-ctx"
[features]
default = []
enterprise = ["lean-ctx-engine/enterprise"]
http-server = [
"lean-ctx-engine/http-server",
"dep:axum",
"dep:tokio-tungstenite",
"dep:rustls",
]
shape-xlat = ["lean-ctx-engine/shape-xlat"]
[lib]
name = "lean_ctx_proxy"
path = "src/lib.rs"
[[test]]
name = "trace_correlation"
path = "tests/trace_correlation.rs"
[dependencies.anyhow]
version = "1.0"
[dependencies.async-trait]
version = "0.1.91"
[dependencies.axum]
version = "0.8"
features = ["ws"]
optional = true
[dependencies.base64]
version = "0.22"
[dependencies.blake3]
version = "1.8"
[dependencies.chrono]
version = "0.4"
features = ["serde"]
[dependencies.dirs]
version = "6.0"
[dependencies.flate2]
version = "1.1"
[dependencies.futures]
version = "0.3"
[dependencies.getrandom]
version = "0.4"
[dependencies.hmac]
version = "0.13"
[dependencies.http]
version = "1.4"
[dependencies.lean-ctx-engine]
version = "=3.12.2"
default-features = false
[dependencies.lean-ctx-protocol]
version = "0.5.0"
[dependencies.libc]
version = "0.2"
[dependencies.regex]
version = "1.12"
[dependencies.reqwest]
version = "0.13"
features = [
"rustls",
"stream",
"json",
"cookies",
]
default-features = false
[dependencies.rmcp]
version = "2"
features = [
"server",
"client",
"transport-io",
"transport-streamable-http-server",
"transport-child-process",
"transport-streamable-http-client-reqwest",
"auth",
"elicitation",
]
[dependencies.rustls]
version = "0.23.45"
optional = true
[dependencies.serde]
version = "1.0"
features = ["derive"]
[dependencies.serde_json]
version = "1.0"
features = [
"float_roundtrip",
"raw_value",
]
[dependencies.sha2]
version = "0.11"
[dependencies.subtle]
version = "2.6"
[dependencies.tempfile]
version = "3.27"
[dependencies.tokio]
version = "1.52"
features = [
"rt",
"rt-multi-thread",
"macros",
"io-std",
"io-util",
"net",
"sync",
"time",
"signal",
"process",
]
[dependencies.tokio-tungstenite]
version = "0.29"
features = [
"connect",
"rustls-tls-webpki-roots",
]
optional = true
default-features = false
[dependencies.toml]
version = "1.1"
[dependencies.tower]
version = "0.5"
[dependencies.tracing]
version = "0.1"
[dependencies.uuid]
version = "1"
features = ["v4"]
[dependencies.zstd]
version = "0.14.3"
[dev-dependencies.lean-ctx-engine]
version = "=3.12.2"
features = ["test-support"]
default-features = false
[dev-dependencies.lean-ctx-server]
version = "=3.12.2"
features = ["http-server"]
default-features = false
[dev-dependencies.serial_test]
version = "3.5"
[target."cfg(windows)".dependencies.windows-sys]
version = "0.61"
features = [
"Win32_Foundation",
"Win32_Globalization",
"Win32_System_Threading",
"Win32_System_ProcessStatus",
"Win32_System_SystemInformation",
"Win32_System_JobObjects",
"Win32_System_Diagnostics_ToolHelp",
"Win32_Security",
"Win32_Security_Authorization",
"Win32_System_Pipes",
"Win32_Storage_FileSystem",
"Wdk_Foundation",
"Wdk_Storage_FileSystem",
"Wdk_System_SystemServices",
"Win32_System_IO",
]
[lints.clippy]
assert_is_empty = "allow"
cast_lossless = "allow"
cast_possible_truncation = "allow"
cast_possible_wrap = "allow"
cast_precision_loss = "allow"
cast_sign_loss = "allow"
collapsible_if = "allow"
default_trait_access = "allow"
doc_markdown = "allow"
empty_line_after_doc_comments = "allow"
enum_variant_names = "allow"
float_cmp = "allow"
format_push_string = "allow"
implicit_hasher = "allow"
items_after_statements = "allow"
manual_pattern_char_comparison = "allow"
map_unwrap_or = "allow"
missing_errors_doc = "allow"
missing_panics_doc = "allow"
module_name_repetitions = "allow"
must_use_candidate = "allow"
needless_borrow = "allow"
no_effect_underscore_binding = "allow"
return_self_not_must_use = "allow"
similar_names = "allow"
struct_excessive_bools = "allow"
struct_field_names = "allow"
too_many_lines = "allow"
trivially_copy_pass_by_ref = "allow"
unnecessary_wraps = "allow"
unreadable_literal = "allow"
unused_self = "allow"
unwrap_used = "warn"
used_underscore_binding = "allow"
useless_conversion = "allow"
[lints.clippy.pedantic]
level = "warn"
priority = -1
[lints.rust]
unreachable_pub = "warn"
[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = ["cfg(tarpaulin)"]