[package]
name = "scirs2-graph"
version.workspace = true
edition.workspace = true
authors.workspace = true
description = "Graph processing module for SciRS2 (scirs2-graph)"
readme = "README.md"
license.workspace = true
repository.workspace = true
keywords = ["graph", "network", "scientific", "ai", "machine-learning"]
categories = ["science", "mathematics", "algorithms"]

[lints]
workspace = true
[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]


[dependencies]
# Core dependencies - ALL numeric/array/random functionality from scirs2-core (SciRS2 POLICY)
scirs2-core = { workspace = true, features = ["parallel", "simd", "random", "array"] }
thiserror = { workspace = true }

# Graph processing specific dependencies
petgraph = { workspace = true }
ordered-float = { workspace = true }

# Performance dependencies
# rayon = "1.8"  # Now use scirs2-core parallel abstractions
parking_lot = { workspace = true }
sysinfo = { workspace = true }

# Serialization for attributes and embeddings
serde = { workspace = true, features = ["derive"] }
serde_json = { workspace = true }

[dev-dependencies]
tempfile = { workspace = true }
criterion = { workspace = true, features = ["html_reports"] }
num_cpus = { workspace = true }
ctor = { workspace = true }
approx = { workspace = true }

[features]
default = ["std", "sysinfo"]

# Core features
std = []
unstable = []

# Performance features  
parallel = ["scirs2-core/parallel"]
simd = ["scirs2-core/simd"]
gpu = ["scirs2-core/gpu"]
sysinfo = []

# Algorithm features
experimental_algorithms = ["unstable"]
advanced_centrality = []
neural_networks = []

# I/O features
extra_formats = []
compression = []

# Development features
benchmarks = []
profiling = []
validation = []

# Compatibility features
networkx_compat = []
igraph_compat = []

# All features (for comprehensive testing)
full = [
    "parallel", 
    "simd", 
    "advanced_centrality",
    "extra_formats",
    "benchmarks",
    "profiling",
    "validation",
    "networkx_compat"
]

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

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

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

[[bench]]
name = "graph_benchmarks"
harness = false

[[bench]]
name = "memory_benchmarks"
harness = false

[[bench]]
name = "large_graph_stress"
harness = false

[[bench]]
name = "advanced_algorithms"
harness = false

[[bench]]
name = "performance_optimizations"
harness = false

[[bench]]
name = "benchmark_runner"
harness = false

[[bench]]
name = "performance_regression"
harness = false
