# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2021"
name = "entrenar"
version = "0.5.0"
authors = ["PAIML <hello@paiml.com>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Training & Optimization library with autograd, LoRA, quantization, and model merging"
readme = "README.md"
keywords = [
    "machine-learning",
    "neural-networks",
    "autograd",
    "lora",
    "quantization",
]
categories = [
    "science",
    "mathematics",
]
license = "MIT"
repository = "https://github.com/paiml/entrenar"

[features]
citl = [
    "trueno-rag",
    "tokio",
    "uuid",
]
cuda = [
    "trueno/cuda-monitor",
    "tokio",
]
default = []
gguf = []
gpu = [
    "trueno/gpu",
    "tokio",
]
monitor = ["trueno-db"]
ruchy-sessions = []
server = [
    "axum",
    "tower",
    "tower-http",
    "tokio",
]
tracing = ["renacer"]
wasm = [
    "wasm-bindgen",
    "getrandom",
    "js-sys",
]

[lib]
name = "entrenar"
crate-type = [
    "cdylib",
    "rlib",
]
path = "src/lib.rs"

[[bin]]
name = "entrenar"
path = "src/main.rs"
required-features = []

[[example]]
name = "citl"
path = "examples/citl.rs"
required-features = ["citl"]

[[example]]
name = "cli_audit"
path = "examples/cli_audit.rs"
required-features = []

[[example]]
name = "cli_bench"
path = "examples/cli_bench.rs"
required-features = []

[[example]]
name = "cli_inspect"
path = "examples/cli_inspect.rs"
required-features = []

[[example]]
name = "cli_monitor"
path = "examples/cli_monitor.rs"
required-features = []

[[example]]
name = "cuda_backend"
path = "examples/cuda_backend.rs"
required-features = []

[[example]]
name = "distillation"
path = "examples/distillation.rs"
required-features = []

[[example]]
name = "explainability"
path = "examples/explainability.rs"
required-features = []

[[example]]
name = "hf_distillation"
path = "examples/hf_distillation.rs"
required-features = []

[[example]]
name = "inference_monitor"
path = "examples/inference_monitor.rs"

[[example]]
name = "llama2-finetune-lora"
path = "examples/llama2/finetune_lora.rs"
required-features = []

[[example]]
name = "llama2-finetune-qlora"
path = "examples/llama2/finetune_qlora.rs"
required-features = []

[[example]]
name = "llama2-memory-benchmarks"
path = "examples/llama2/memory_benchmarks.rs"
required-features = []

[[example]]
name = "llama2-train"
path = "examples/llama2/train.rs"
required-features = []

[[example]]
name = "merge_models"
path = "examples/merge_models.rs"
required-features = []

[[example]]
name = "mnist_train"
path = "examples/mnist_train.rs"
required-features = []

[[example]]
name = "mnist_train_gpu"
path = "examples/mnist_train_gpu.rs"
required-features = ["gpu"]

[[example]]
name = "model_io"
path = "examples/model_io.rs"
required-features = []

[[example]]
name = "monitoring"
path = "examples/monitoring.rs"
required-features = []

[[example]]
name = "pruning_pipeline"
path = "examples/pruning_pipeline.rs"

[[example]]
name = "research"
path = "examples/research.rs"

[[example]]
name = "sovereign"
path = "examples/sovereign.rs"

[[example]]
name = "train_from_yaml"
path = "examples/train_from_yaml.rs"
required-features = []

[[example]]
name = "train_from_yaml_example"
path = "examples/train_from_yaml_example.rs"
required-features = []

[[example]]
name = "training_loop"
path = "examples/training_loop.rs"
required-features = []

[[test]]
name = "autograd_integration"
path = "tests/autograd_integration.rs"

[[test]]
name = "chaos_llama"
path = "tests/chaos_llama.rs"

[[test]]
name = "gradient_llama"
path = "tests/gradient_llama.rs"

[[test]]
name = "integrity_test"
path = "tests/integrity_test.rs"

[[test]]
name = "mutation_resistant_llama"
path = "tests/mutation_resistant_llama.rs"

[[test]]
name = "property_curriculum"
path = "tests/property_curriculum.rs"

[[test]]
name = "property_llama"
path = "tests/property_llama.rs"

[[test]]
name = "quality_test"
path = "tests/quality_test.rs"

[[test]]
name = "run_tracing_test"
path = "tests/run_tracing_test.rs"

[[test]]
name = "storage_test"
path = "tests/storage_test.rs"

[[test]]
name = "yaml_mode_integration"
path = "tests/yaml_mode_integration.rs"

[[bench]]
name = "monitor_bench"
path = "benches/monitor_bench.rs"
harness = false
required-features = ["monitor"]

[dependencies.alimentar]
version = "0.2.2"

[dependencies.aprender]
version = "0.21.0"

[dependencies.axum]
version = "0.8"
optional = true

[dependencies.bytemuck]
version = "1.19"
features = ["derive"]

[dependencies.chrono]
version = "0.4"
features = ["serde"]

[dependencies.clap]
version = "4.5"
features = ["derive"]

[dependencies.clap_complete]
version = "4.5"

[dependencies.dirs]
version = "5.0"

[dependencies.ed25519-dalek]
version = "2.1"

[dependencies.getrandom]
version = "0.3"
features = ["wasm_js"]
optional = true

[dependencies.hex]
version = "0.4"

[dependencies.hf-hub]
version = "0.4"

[dependencies.js-sys]
version = "0.3"
optional = true

[dependencies.memmap2]
version = "0.9"

[dependencies.ndarray]
version = "0.16"

[dependencies.rand]
version = "0.9"

[dependencies.regex]
version = "1.10"

[dependencies.renacer]
version = "0.7.0"
optional = true

[dependencies.safetensors]
version = "0.7"

[dependencies.serde]
version = "1.0"
features = ["derive"]

[dependencies.serde_json]
version = "1.0"

[dependencies.serde_yaml]
version = "0.9"

[dependencies.sha2]
version = "0.10"

[dependencies.thiserror]
version = "2.0"

[dependencies.tokio]
version = "1.41"
features = [
    "rt",
    "rt-multi-thread",
    "macros",
    "net",
]
optional = true

[dependencies.toml]
version = "0.8"

[dependencies.tower]
version = "0.5"
optional = true

[dependencies.tower-http]
version = "0.6"
features = [
    "trace",
    "cors",
]
optional = true

[dependencies.trueno]
version = "0.11.0"

[dependencies.trueno-db]
version = "0.3.9"
optional = true

[dependencies.trueno-rag]
version = "0.1.5"
optional = true

[dependencies.trueno-viz]
version = "0.1.5"
features = ["terminal"]

[dependencies.uuid]
version = "1.11"
features = [
    "v4",
    "serde",
]
optional = true

[dependencies.wasm-bindgen]
version = "0.2"
optional = true

[dependencies.zip]
version = "2.2"

[dev-dependencies.approx]
version = "0.5"

[dev-dependencies.arrow]
version = "54"
default-features = false

[dev-dependencies.criterion]
version = "0.5"

[dev-dependencies.insta]
version = "1.42"
features = [
    "json",
    "yaml",
]

[dev-dependencies.proptest]
version = "1.4"

[dev-dependencies.tempfile]
version = "3.8"

[lints.clippy]
assigning_clones = "allow"
case_sensitive_file_extension_comparisons = "allow"
cast_possible_truncation = "allow"
cast_possible_wrap = "allow"
cast_precision_loss = "allow"
cast_sign_loss = "allow"
checked_conversions = "warn"
comparison_chain = "allow"
doc_markdown = "allow"
explicit_deref_methods = "warn"
explicit_iter_loop = "warn"
float_cmp = "allow"
format_push_string = "allow"
implicit_clone = "warn"
inconsistent_struct_constructor = "warn"
inefficient_to_string = "warn"
items_after_statements = "allow"
large_stack_arrays = "allow"
manual_let_else = "allow"
manual_ok_or = "warn"
many_single_char_names = "allow"
match_same_arms = "allow"
match_wildcard_for_single_variants = "allow"
missing_const_for_fn = "allow"
missing_errors_doc = "allow"
missing_panics_doc = "allow"
module_name_repetitions = "allow"
must_use_candidate = "allow"
needless_pass_by_value = "allow"
redundant_closure_for_method_calls = "warn"
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"
unnested_or_patterns = "warn"
unreadable_literal = "allow"
unused_self = "allow"
used_underscore_binding = "allow"

[lints.clippy.all]
level = "warn"
priority = -1

[lints.clippy.pedantic]
level = "warn"
priority = -1

[lints.rust]
missing_debug_implementations = "allow"
trivial_casts = "warn"
trivial_numeric_casts = "warn"
unreachable_pub = "warn"
unsafe_code = "deny"
unused_import_braces = "warn"
unused_lifetimes = "warn"
unused_qualifications = "warn"

[lints.rust.rust_2018_idioms]
level = "warn"
priority = -1

[profile.dev]
opt-level = 0

[profile.release]
opt-level = 3
lto = true
codegen-units = 1
