-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCargo.toml
More file actions
120 lines (97 loc) · 3.5 KB
/
Cargo.toml
File metadata and controls
120 lines (97 loc) · 3.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
[package]
name = "mobile-ai-orchestrator"
version = "1.0.0"
edition = "2021"
authors = ["Jonathan Bowman <hyperpolymath@protonmail.com>"]
license = "PMPL-1.0"
repository = "https://github.com/Hyperpolymath/heterogenous-mobile-computing"
description = "Hybrid AI orchestration system for constrained mobile platforms with reservoir computing"
keywords = ["ai", "mobile", "orchestration", "reservoir-computing", "offline-first"]
categories = ["embedded", "science", "command-line-utilities"]
readme = "README.md"
rust-version = "1.75"
[dependencies]
# Core dependencies - keeping minimal for Bronze RSR compliance
serde = { version = "1.0", features = ["derive"] }
serde_json = { version = "1.0" }
lazy_static = "1.4"
rand = "0.9"
thiserror = "2.0"
# Persistence
rusqlite = { version = "0.31", features = ["bundled"], optional = true }
# Optional: High-performance mode (learned from neurophone)
# Uses ndarray for optimized matrix operations in reservoir/snn
ndarray = { version = "0.17", features = ["serde"], optional = true }
ndarray-rand = { version = "0.16", optional = true }
rayon = { version = "1.8", optional = true }
# Optional: Structured logging
tracing = { version = "0.1", optional = true }
# Optional: Fast binary serialization (10x faster than JSON)
bincode = { version = "1.3", optional = true }
# Optional dependencies for network features
tokio = { version = "1.35", features = ["rt", "macros", "sync"], optional = true }
reqwest = { version = "0.12", features = ["json", "rustls-tls"], default-features = false, optional = true }
[dev-dependencies]
# Test dependencies
criterion = "0.5"
proptest = "1.4"
[features]
default = ["persistence"]
# Network features disabled by default for offline-first
network = ["tokio", "reqwest"]
# Persistence (enabled by default for production use)
persistence = ["rusqlite"]
# High-performance mode: ndarray + rayon parallelization
# Enable for real-time sensor processing (1kHz+)
# Learned from neurophone's optimized reservoir computing
high-perf = ["ndarray", "ndarray-rand", "rayon"]
# Structured logging with tracing
logging = ["tracing"]
# Fast binary serialization (replaces JSON for internal state)
fast-serde = ["bincode"]
# Full-featured mode (all optional features)
full = ["persistence", "network", "high-perf", "logging", "fast-serde"]
# Android-optimized build (use with --profile release-android)
android = []
# Phase 2+ features
reservoir = []
rag = []
[[bin]]
name = "mobile-ai"
path = "src/main.rs"
[lib]
name = "mobile_ai_orchestrator"
path = "src/lib.rs"
[[bench]]
name = "orchestrator_bench"
harness = false
[[bench]]
name = "reservoir_bench"
harness = false
[[bench]]
name = "mlp_bench"
harness = false
[profile.release]
opt-level = "z" # Optimize for size (mobile constraint)
lto = true # Link-time optimization
codegen-units = 1 # Better optimization
strip = true # Strip symbols
panic = "abort" # Smaller binary
[profile.dev]
opt-level = 1 # Faster compilation in dev
# Android-optimized release profile (learned from neurophone)
# Use: cargo build --profile release-android --target aarch64-linux-android
[profile.release-android]
inherits = "release"
opt-level = "s" # Optimize for size (mobile storage constraints)
lto = "thin" # Faster linking than full LTO, still good optimization
strip = true
panic = "abort"
# RSR Compliance Metadata
[package.metadata.rsr]
compliance_level = "bronze"
safety_model = "type-safe + memory-safe"
offline_first = true
tpcf_perimeter = 3
formal_verification = "rust-compile-time"
zero_unsafe_blocks = true