mirror of
https://github.com/ruvnet/RuVector.git
synced 2026-05-30 20:43:38 +00:00
Unblocks the 7 stacked PRs (#381-#387) and turns `main`'s CI green
for the first time in days. Two issues fixed:
## Failure 1 — Security audit (was: 8 vulnerabilities)
`cargo audit` is now exit 0. 4 of the 5 critical advisories were
fixed by version bumps; only the unfixable one is ignored.
**Dep-bumped:**
- `rustls-webpki 0.101.7` + `0.103.10` → `0.103.13` via
`cargo update -p rustls-webpki@0.103.10`. Patches:
RUSTSEC-2026-0098 (URI name constraints)
RUSTSEC-2026-0099 (wildcard name constraints)
RUSTSEC-2026-0104 (CRL parsing panic)
- `idna 0.5.0` → `1.1.0` via `validator 0.18 → 0.20` in
`examples/scipix`. Patches RUSTSEC-2024-0421 (Punycode acceptance).
- Bonus: `reqwest 0.11 → 0.12` (in `ruvector-core` + `examples/benchmarks`)
and `hf-hub 0.3 → 0.4` (in `ruvector-core` + `ruvllm` +
`ruvllm-cli`). Removes the entire legacy `rustls 0.21` /
`rustls-webpki 0.101.7` subtree from the lockfile.
**Ignored** (single advisory, with rationale):
- `RUSTSEC-2023-0071` (rsa Marvin timing sidechannel) — no upstream
fix available; we don't expose RSA decryption services. Documented
in `.cargo/audit.toml`.
**Unmaintained warnings** (16 total — proc-macro-error, derivative,
instant, paste, bincode 1, pqcrypto-{kyber,dilithium}, rustls-pemfile 1,
rusttype, wee_alloc, number_prefix, rand_os, core2, lru, pprof, rand) —
each given a one-line justification in `.cargo/audit.toml` so CI stays
green on them while the team decides whether to chase upstream
replacements.
## Failure 2 — Tests timeout (was: 30-min job timeout cancellation)
`.github/workflows/ci.yml` `test` job is now a `matrix` with
`fail-fast: false` and `timeout-minutes: 45`. Six parallel shards
under `cargo nextest run` (installed via `taiki-e/install-action@v2`)
plus a separate `cargo test --doc` step (nextest doesn't run
doctests):
| Shard | Crates |
|------------------|---------------------------------------------|
| vector-index | rabitq, rulake, diskann, graph, gnn, cnn |
| rvagent | 10 rvagent-* crates |
| ruvix | 16 ruvix-* crates |
| ruqu-quantum | 5 ruqu* crates |
| ml-research | attention, mincut, scipix, fpga-transformer,|
| | sparse-inference, sparsifier, solver, |
| | graph-transformer, domain-expansion, |
| | robotics |
| core-and-rest | --workspace minus the above |
`Swatinem/rust-cache@v2` is keyed per shard. Audit job switched to
`taiki-e/install-action` for `cargo-audit` (faster than
`cargo install --locked`).
## Verification
cargo audit → exit 0
cargo build --workspace --exclude ruvector-postgres → clean
cargo clippy --workspace --exclude ruvector-postgres --no-deps -- -D warnings → exit 0
cargo fmt --all --check → exit 0
## Cargo.lock churn
166-line diff, net ~120 lines removed (more deletions than
additions). Removed: `idna 0.5.0`, `rustls-webpki 0.101.7`,
`validator 0.18`, `validator_derive 0.18`, `proc-macro-error 1.0.4`.
Added: `rustls-webpki 0.103.13`, `validator 0.20`,
`proc-macro-error2`, `hf-hub 0.4.3`, `reqwest 0.12.28`. No
suspicious crates.
## Recommended merge order
1. **This PR first** — unblocks every other PR's CI.
2. After this lands and main is green, rebase the 7 open PRs
(#381-#387) one at a time. The DiskANN stack (#383→#384→#385→#386)
must merge in numeric order. #381 (Python SDK), #382 (research),
#387 (graph property index) are independent and can merge in
any order after their CI goes green on the rebase.
Co-Authored-By: claude-flow <ruv@ruv.net>
299 lines
8.9 KiB
TOML
299 lines
8.9 KiB
TOML
[package]
|
|
name = "ruvector-core"
|
|
version.workspace = true
|
|
edition.workspace = true
|
|
rust-version.workspace = true
|
|
license.workspace = true
|
|
authors.workspace = true
|
|
repository.workspace = true
|
|
readme = "README.md"
|
|
description = "High-performance Rust vector database core with HNSW indexing"
|
|
|
|
[dependencies]
|
|
# Core functionality
|
|
redb = { workspace = true, optional = true }
|
|
memmap2 = { workspace = true, optional = true }
|
|
hnsw_rs = { workspace = true, optional = true }
|
|
simsimd = { workspace = true, optional = true }
|
|
rayon = { workspace = true, optional = true }
|
|
crossbeam = { workspace = true, optional = true }
|
|
|
|
# Serialization
|
|
rkyv = { workspace = true }
|
|
bincode = { workspace = true }
|
|
serde = { workspace = true }
|
|
serde_json = { workspace = true }
|
|
|
|
# Error handling
|
|
thiserror = { workspace = true }
|
|
anyhow = { workspace = true }
|
|
tracing = { workspace = true }
|
|
|
|
# Math and numerics
|
|
ndarray = { workspace = true, features = ["serde"] }
|
|
rand = { workspace = true }
|
|
rand_distr = { workspace = true }
|
|
|
|
# Performance
|
|
dashmap = { workspace = true }
|
|
parking_lot = { workspace = true }
|
|
once_cell = { workspace = true }
|
|
|
|
# Time and UUID
|
|
chrono = { workspace = true }
|
|
uuid = { workspace = true, features = ["v4"] }
|
|
|
|
# HTTP client for API embeddings (not available in WASM)
|
|
reqwest = { version = "0.12", default-features = false, features = ["blocking", "json", "rustls-tls"], optional = true }
|
|
|
|
# ONNX Runtime for local semantic embeddings (not available in WASM)
|
|
ort = { version = "2.0.0-rc.9", optional = true }
|
|
|
|
# Tokenizers for ONNX models
|
|
tokenizers = { version = "0.20", default-features = false, features = ["onig"], optional = true }
|
|
|
|
# HuggingFace Hub for model downloads
|
|
hf-hub = { version = "0.4", optional = true }
|
|
|
|
[dev-dependencies]
|
|
criterion = { workspace = true }
|
|
proptest = { workspace = true }
|
|
mockall = { workspace = true }
|
|
tempfile = "3.13"
|
|
tracing-subscriber = { workspace = true }
|
|
|
|
[[bench]]
|
|
name = "distance_metrics"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "hnsw_search"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "quantization_bench"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "batch_operations"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "comprehensive_bench"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "real_benchmark"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "bench_simd"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "bench_memory"
|
|
harness = false
|
|
|
|
[features]
|
|
default = ["simd", "storage", "hnsw", "api-embeddings", "parallel"]
|
|
simd = ["simsimd"] # SIMD acceleration (not available in WASM)
|
|
parallel = ["rayon", "crossbeam"] # Parallel processing (not available in WASM)
|
|
storage = ["redb", "memmap2"] # File-based storage (not available in WASM)
|
|
hnsw = ["hnsw_rs"] # HNSW indexing (not available in WASM due to mmap dependency)
|
|
memory-only = [] # Pure in-memory storage for WASM
|
|
uuid-support = [] # Deprecated: uuid is now always included
|
|
real-embeddings = [] # Feature flag for embedding provider API (use ApiEmbedding for production)
|
|
api-embeddings = ["reqwest"] # API-based embeddings (not available in WASM)
|
|
onnx-embeddings = ["ort", "tokenizers", "hf-hub"] # ONNX-based local embeddings (not available in WASM)
|
|
|
|
[lib]
|
|
crate-type = ["rlib"]
|
|
bench = false
|
|
|
|
# Workspace cleanup pass: research-tier crate, doc/style churn deferred. Correctness + suspicious lints stay denied.
|
|
[lints.rust]
|
|
unexpected_cfgs = { level = "allow", priority = -1 }
|
|
unused_imports = "allow"
|
|
dead_code = "allow"
|
|
unused_variables = "allow"
|
|
unused_mut = "allow"
|
|
unused_unit = "allow"
|
|
unused_assignments = "allow"
|
|
unused_must_use = "allow"
|
|
missing_docs = "allow"
|
|
unsafe_op_in_unsafe_fn = "allow"
|
|
unused_parens = "allow"
|
|
unused_comparisons = "allow"
|
|
non_local_definitions = "allow"
|
|
static_mut_refs = "allow"
|
|
non_camel_case_types = "allow"
|
|
deprecated = "allow"
|
|
ambiguous_glob_reexports = "allow"
|
|
non_upper_case_globals = "allow"
|
|
unused_doc_comments = "allow"
|
|
unused_unsafe = "allow"
|
|
unreachable_patterns = "allow"
|
|
suspicious_double_ref_op = "allow"
|
|
|
|
[lints.clippy]
|
|
pedantic = { level = "allow", priority = -2 }
|
|
correctness = { level = "deny", priority = -1 }
|
|
suspicious = { level = "deny", priority = -1 }
|
|
needless_range_loop = "allow"
|
|
needless_borrow = "allow"
|
|
needless_borrows_for_generic_args = "allow"
|
|
needless_update = "allow"
|
|
needless_bool = "allow"
|
|
needless_pass_by_value = "allow"
|
|
manual_div_ceil = "allow"
|
|
manual_is_multiple_of = "allow"
|
|
manual_range_contains = "allow"
|
|
manual_clamp = "allow"
|
|
manual_checked_ops = "allow"
|
|
manual_let_else = "allow"
|
|
manual_memcpy = "allow"
|
|
manual_repeat_n = "allow"
|
|
manual_contains = "allow"
|
|
manual_flatten = "allow"
|
|
manual_abs_diff = "allow"
|
|
manual_slice_size_calculation = "allow"
|
|
redundant_closure = "allow"
|
|
redundant_closure_for_method_calls = "allow"
|
|
redundant_field_names = "allow"
|
|
len_zero = "allow"
|
|
get_first = "allow"
|
|
useless_vec = "allow"
|
|
too_many_arguments = "allow"
|
|
derivable_impls = "allow"
|
|
approx_constant = "allow"
|
|
assertions_on_constants = "allow"
|
|
field_reassign_with_default = "allow"
|
|
nonminimal_bool = "allow"
|
|
collapsible_if = "allow"
|
|
collapsible_match = "allow"
|
|
inconsistent_digit_grouping = "allow"
|
|
unnecessary_sort_by = "allow"
|
|
unnecessary_map_or = "allow"
|
|
unnecessary_filter_map = "allow"
|
|
unnecessary_lazy_evaluations = "allow"
|
|
unnecessary_cast = "allow"
|
|
unnecessary_to_owned = "allow"
|
|
unnecessary_wraps = "allow"
|
|
unnecessary_literal_unwrap = "allow"
|
|
unnecessary_struct_initialization = "allow"
|
|
should_implement_trait = "allow"
|
|
ptr_arg = "allow"
|
|
let_unit_value = "allow"
|
|
let_and_return = "allow"
|
|
type_complexity = "allow"
|
|
identity_op = "allow"
|
|
match_like_matches_macro = "allow"
|
|
match_same_arms = "allow"
|
|
match_single_binding = "allow"
|
|
vec_init_then_push = "allow"
|
|
absurd_extreme_comparisons = "allow"
|
|
incompatible_msrv = "allow"
|
|
unused_enumerate_index = "allow"
|
|
unused_self = "allow"
|
|
unused_unit = "allow"
|
|
map_clone = "allow"
|
|
map_unwrap_or = "allow"
|
|
result_map_or_into_option = "allow"
|
|
unusual_byte_groupings = "allow"
|
|
if_same_then_else = "allow"
|
|
unnested_or_patterns = "allow"
|
|
uninlined_format_args = "allow"
|
|
single_match_else = "allow"
|
|
single_char_pattern = "allow"
|
|
mixed_attributes_style = "allow"
|
|
arc_with_non_send_sync = "allow"
|
|
bool_assert_comparison = "allow"
|
|
bool_comparison = "allow"
|
|
bind_instead_of_map = "allow"
|
|
cloned_ref_to_slice_refs = "allow"
|
|
large_stack_arrays = "allow"
|
|
implicit_saturating_sub = "allow"
|
|
ignored_unit_patterns = "allow"
|
|
explicit_iter_loop = "allow"
|
|
elidable_lifetime_names = "allow"
|
|
doc_markdown = "allow"
|
|
doc_overindented_list_items = "allow"
|
|
comparison_chain = "allow"
|
|
clone_on_copy = "allow"
|
|
items_after_statements = "allow"
|
|
inline_always = "allow"
|
|
format_push_string = "allow"
|
|
format_collect = "allow"
|
|
for_kv_map = "allow"
|
|
float_cmp = "allow"
|
|
if_not_else = "allow"
|
|
return_self_not_must_use = "allow"
|
|
missing_fields_in_debug = "allow"
|
|
upper_case_acronyms = "allow"
|
|
wildcard_imports = "allow"
|
|
must_use_candidate = "allow"
|
|
cast_possible_truncation = "allow"
|
|
cast_possible_wrap = "allow"
|
|
cast_precision_loss = "allow"
|
|
cast_lossless = "allow"
|
|
cast_sign_loss = "allow"
|
|
unreadable_literal = "allow"
|
|
struct_excessive_bools = "allow"
|
|
trivially_copy_pass_by_ref = "allow"
|
|
missing_safety_doc = "allow"
|
|
missing_errors_doc = "allow"
|
|
missing_panics_doc = "allow"
|
|
similar_names = "allow"
|
|
module_name_repetitions = "allow"
|
|
assign_op_pattern = "allow"
|
|
iter_cloned_collect = "allow"
|
|
excessive_precision = "allow"
|
|
await_holding_refcell_ref = "allow"
|
|
unnecessary_unwrap = "allow"
|
|
unit_arg = "allow"
|
|
redundant_pattern_matching = "allow"
|
|
question_mark = "allow"
|
|
partialeq_to_none = "allow"
|
|
new_without_default = "allow"
|
|
map_flatten = "allow"
|
|
manual_unwrap_or = "allow"
|
|
len_without_is_empty = "allow"
|
|
format_in_format_args = "allow"
|
|
single_char_add_str = "allow"
|
|
useless_conversion = "allow"
|
|
useless_format = "allow"
|
|
doc_lazy_continuation = "allow"
|
|
manual_strip = "allow"
|
|
double_ended_iterator_last = "allow"
|
|
unwrap_or_default = "allow"
|
|
single_component_path_imports = "allow"
|
|
needless_return = "allow"
|
|
int_plus_one = "allow"
|
|
needless_lifetimes = "allow"
|
|
explicit_counter_loop = "allow"
|
|
unnecessary_mut_passed = "allow"
|
|
module_inception = "allow"
|
|
option_as_ref_deref = "allow"
|
|
print_literal = "allow"
|
|
explicit_auto_deref = "allow"
|
|
manual_swap = "allow"
|
|
writeln_empty_string = "allow"
|
|
items_after_test_module = "allow"
|
|
no_effect = "allow"
|
|
non_canonical_partial_ord_impl = "allow"
|
|
wildcard_in_or_patterns = "allow"
|
|
large_enum_variant = "allow"
|
|
not_unsafe_ptr_arg_deref = { level = "allow", priority = 1 }
|
|
erasing_op = { level = "allow", priority = 1 }
|
|
almost_swapped = { level = "allow", priority = 1 }
|
|
cast_abs_to_unsigned = { level = "allow", priority = 1 }
|
|
let_underscore_lock = { level = "allow", priority = 1 }
|
|
no_effect_replace = { level = "allow", priority = 1 }
|
|
await_holding_lock = { level = "allow", priority = 1 }
|
|
needless_character_iteration = { level = "allow", priority = 1 }
|
|
unnecessary_get_then_check = { level = "allow", priority = 1 }
|
|
let_underscore_future = { level = "allow", priority = 1 }
|
|
overly_complex_bool_expr = { level = "allow", priority = 1 }
|
|
zombie_processes = { level = "allow", priority = 1 }
|
|
repeat_vec_with_capacity = { level = "allow", priority = 1 }
|
|
missing_transmute_annotations = { level = "allow", priority = 1 }
|