state-spaces/mamba ? reverse-engineered prompt

Reverse engineered prompt

Build me a usable Python setup for this Mamba repo on a Linux machine with an NVIDIA GPU. I want to be able to install it with my existing CUDA PyTorch, import the core model blocks for Mamba, Mamba 2, and Mamba 3, and run a simple smoke test on GPU that feeds in random tensors and confirms the output shapes match the inputs.

If pretrained checkpoints are already supported, please also add one small example that pulls a public model from Hugging Face and runs a basic text generation or evaluation command so I can see the full flow working. Please handle any native build steps that are required, including the faster causal convolution option if it is available.

Keep it practical and easy to run, with clear setup notes and one or two scripts I can launch to verify everything end to end. If anything is version sensitive, use the current docs online and make sensible choices.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab