fix(plan): reviewer round 3 — tggn/tgnn module mapping, exit code, canonical imports

- B1: Add LIB_FILTER mapping for tggn→tgnn module name (prevents zero-test false positive)
- W1: Replace ml_supervised:: imports with canonical ml:: paths in supervised_gpu_smoke_test
- W4: Use clean pass/fail exit code instead of raw failure count

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
jgrusewski
2026-03-13 11:51:58 +01:00
parent 18fe480e8f
commit 6a2b2d9dbe

View File

@@ -610,7 +610,7 @@ fn test_tft_gpu_smoke() {
println!("=== TFT GPU Smoke ===");
use ml::tft::trainable_adapter::TrainableTFT;
use ml_supervised::tft::TFTConfig;
use ml::tft::TFTConfig;
let feature_dim = 10;
let mut config = TFTConfig::default();
@@ -647,7 +647,7 @@ fn test_mamba2_gpu_smoke() {
println!("=== Mamba2 GPU Smoke ===");
use ml::mamba::trainable_adapter::Mamba2TrainableAdapter;
use ml_supervised::mamba::Mamba2Config;
use ml::mamba::Mamba2Config;
let mut config = Mamba2Config::default();
config.d_model = 32;
@@ -674,7 +674,7 @@ fn test_tggn_gpu_smoke() {
println!("=== TGGN GPU Smoke ===");
use ml::tgnn::trainable_adapter::TGGNTrainableAdapter;
use ml_supervised::tgnn::TGGNConfig;
use ml::tgnn::TGGNConfig;
let config = TGGNConfig {
node_dim: 10,
@@ -733,7 +733,7 @@ fn test_liquid_gpu_smoke() {
println!("=== Liquid GPU Smoke ===");
use ml::liquid::adapter::LiquidTrainableAdapter;
use ml_supervised::liquid::candle_cfc::CfCTrainConfig;
use ml::liquid::CfCTrainConfig;
use ml::gpu::DeviceConfig;
let config = CfCTrainConfig {
@@ -794,7 +794,7 @@ fn test_xlstm_gpu_smoke() {
println!("=== xLSTM GPU Smoke ===");
use ml::xlstm::trainable::XLSTMTrainableAdapter;
use ml_supervised::xlstm::config::XLSTMConfig;
use ml::xlstm::config::XLSTMConfig;
let config = XLSTMConfig {
input_dim: 10,
@@ -1160,8 +1160,11 @@ spec:
;;
*)
# Supervised models (TFT, Mamba2, TGGN, TLOB, Liquid, KAN, xLSTM, Diffusion)
# Map model names to Rust module names where they differ
LIB_FILTER="$MODEL"
[ "$MODEL" = "tggn" ] && LIB_FILTER="tgnn"
if [ "$SCOPE" = "lib" ] || [ "$SCOPE" = "all" ]; then
run_tests "${MODEL}-lib" cargo test -p ml --features cuda --lib -- "$MODEL"
run_tests "${MODEL}-lib" cargo test -p ml --features cuda --lib -- "$LIB_FILTER"
fi
if [ "$SCOPE" = "integration" ] || [ "$SCOPE" = "all" ]; then
run_tests "${MODEL}-gpu" cargo test -p ml --features cuda --test supervised_gpu_smoke_test -- "test_${MODEL}_gpu_smoke"
@@ -1192,7 +1195,7 @@ spec:
printf "$RESULTS" > /tmp/outputs/results
echo "$FAILURES" > /tmp/outputs/failures
exit $FAILURES
[ "$FAILURES" -gt 0 ] && exit 1 || exit 0
# ── notify-result: post test outcome to Mattermost (onExit) ──
- name: notify-result