[package]
name = "m2m-protocol"
version = "0.4.0"
edition = "2021"
rust-version = "1.88"
license = "Apache-2.0"
description = "M2M Protocol - Intelligent machine-to-machine LLM communication with learned compression"
repository = "https://github.com/infernet-org/m2m-protocol"
keywords = ["llm", "compression", "m2m", "protocol", "ai"]
categories = ["compression", "web-programming", "science"]
readme = "README.md"
authors = ["M2M Protocol Contributors"]
[lib]
name = "m2m"
path = "src/lib.rs"
[[bin]]
name = "m2m"
path = "src/bin/m2m.rs"
[[bin]]
name = "benchmark"
path = "src/bin/benchmark.rs"
[[bin]]
name = "m2m-ai-test"
path = "src/bin/m2m_ai_test.rs"
[[bin]]
name = "agent-town"
path = "src/bin/agent_town.rs"
required-features = ["crypto"]
[dependencies]
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
thiserror = "1.0"
anyhow = "1.0"
tiktoken-rs = "0.9"
tokenizers = { version = "0.21", default-features = false, features = ["onig"] }
phf = { version = "0.11", features = ["macros"] }
tokio = { version = "1.0", features = ["rt-multi-thread", "macros", "net", "sync", "time", "io-util"] }
axum = "0.7"
tower = { version = "0.4", features = ["util"] }
tower-http = { version = "0.5", features = ["cors", "trace"] }
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls", "stream"] }
futures = "0.3"
clap = { version = "4", features = ["derive"] }
toml = "0.8"
dirs = "5.0"
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter", "json"] }
brotli = "7.0"
flate2 = "1.0"
crc32fast = "1.5"
ndarray = "0.16"
safetensors = "0.4"
uuid = { version = "1.0", features = ["v4"] }
base64 = "0.22"
bytes = "1.0"
chrono = { version = "0.4", features = ["serde"] }
regex = { version = "1.0", features = ["perf"] }
lazy_static = "1.4"
petgraph = "0.7"
quinn = "0.10"
rustls = { version = "0.21", default-features = false, features = ["dangerous_configuration", "quic", "tls12"] }
rcgen = "0.12"
rustls-pemfile = "1.0"
h3 = "0.0.4"
h3-quinn = "0.0.5"
http = "1.0"
http-body-util = "0.1"
hkdf = { version = "0.12", optional = true }
sha2 = { version = "0.10", optional = true }
hmac = { version = "0.12", optional = true }
chacha20poly1305 = { version = "0.10", optional = true }
x25519-dalek = { version = "2.0", features = ["static_secrets"], optional = true }
rand = { version = "0.8", optional = true }
zeroize = { version = "1.8", features = ["zeroize_derive"], optional = true }
[dev-dependencies]
criterion = { version = "0.5", features = ["html_reports"] }
tokio-test = "0.4"
tempfile = "3.0"
hex-literal = "0.4"
rand_chacha = "0.3"
dotenvy = "0.15"
proptest = "1.5"
[build-dependencies]
phf_codegen = "0.11"
[profile.release]
opt-level = 3
lto = true
codegen-units = 1
strip = true
panic = "abort"
[profile.dev]
opt-level = 0
debug = true
[features]
default = []
crypto = ["dep:hkdf", "dep:sha2", "dep:hmac", "dep:chacha20poly1305", "dep:x25519-dalek", "dep:rand", "dep:zeroize"]
[lints.rust]
unsafe_code = "warn"
missing_docs = "warn"
unknown_lints = "allow"
[lints.clippy]
pedantic = { level = "warn", priority = -1 }
module_name_repetitions = "allow"
must_use_candidate = "allow"
missing_errors_doc = "allow"
comparison_chain = "allow"
double_ended_iterator_last = "allow"
manual_div_ceil = "allow"
missing_panics_doc = "allow"
doc_markdown = "allow"
similar_names = "allow"
too_many_lines = "allow"
struct_excessive_bools = "allow"
unreadable_literal = "allow"
needless_raw_string_hashes = "allow"
cast_possible_truncation = "allow"
cast_precision_loss = "allow"
cast_lossless = "allow"
unnecessary_wraps = "allow"
redundant_closure_for_method_calls = "allow"
only_used_in_recursion = "allow"
self_only_used_in_recursion = "allow"
manual_repeat_n = "allow"
unused_self = "allow"
manual_let_else = "allow"
return_self_not_must_use = "allow"
uninlined_format_args = "allow"
manual_strip = "allow"
option_if_let_else = "allow"
map_unwrap_or = "allow"
if_not_else = "allow"
match_same_arms = "allow"
assigning_clones = "allow"
format_push_string = "allow"
fn_params_excessive_bools = "allow"
struct_field_names = "allow"
useless_vec = "allow"
single_char_pattern = "allow"
trivially_copy_pass_by_ref = "allow"
single_match = "allow"
manual_is_power_of_two = "allow"
manual_map = "allow"
ref_option = "allow"
cast_sign_loss = "allow"
io_other_error = "allow"
ignored_unit_patterns = "allow"
manual_saturating_arithmetic = "allow"
implicit_clone = "allow"
to_string_trait_impl = "allow"
significant_drop_tightening = "allow"
inefficient_to_string = "allow"
needless_pass_by_value = "allow"
checked_conversions = "allow"
single_match_else = "allow"
cast_possible_wrap = "allow"
manual_range_contains = "allow"
implicit_saturating_sub = "allow"
non_std_lazy_statics = "allow"
multiple_crate_versions = "allow"
[lints.rustdoc]
broken_intra_doc_links = "warn"
private_intra_doc_links = "warn"