Update README.md
Browse files
README.md
CHANGED
|
@@ -1,3 +1,51 @@
|
|
| 1 |
-
---
|
| 2 |
-
license: apache-2.0
|
| 3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
base_model:
|
| 6 |
+
- state-spaces/mamba2-1.3b
|
| 7 |
+
pipeline_tag: question-answering
|
| 8 |
+
---
|
| 9 |
+
|
| 10 |
+
|
| 11 |
+
# Mamba Retriever
|
| 12 |
+
|
| 13 |
+
This repository contains model checkpoint for [Mamba Retriever](https://github.com/MambaRetriever/MambaRetriever)
|
| 14 |
+
|
| 15 |
+
The model architecture is built upon [mamba](https://github.com/state-spaces/mamba), and is trained from [mamba2-1.3b](https://huggingface.co/state-spaces/mamba2-1.3b)
|
| 16 |
+
|
| 17 |
+
|
| 18 |
+
# Usage
|
| 19 |
+
|
| 20 |
+
We highly recommend creating a new conda environment first:
|
| 21 |
+
```
|
| 22 |
+
conda create -n mamba_retriever python=3.10.14
|
| 23 |
+
conda activate mamba_retriever
|
| 24 |
+
```
|
| 25 |
+
|
| 26 |
+
Then, run the following in your terminal:
|
| 27 |
+
```
|
| 28 |
+
git clone https://github.com/state-spaces/mamba.git
|
| 29 |
+
conda install cudatoolkit==11.8 -c nvidia
|
| 30 |
+
pip install -r requirements.txt
|
| 31 |
+
pip3 install torch==2.1.1 torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
|
| 32 |
+
pip install accelerate -U
|
| 33 |
+
cd mamba
|
| 34 |
+
pip install .
|
| 35 |
+
```
|
| 36 |
+
|
| 37 |
+
Next, download and install the following two files from https://github.com/state-spaces/mamba/releases and https://github.com/Dao-AILab/causal-conv1d/releases:
|
| 38 |
+
```
|
| 39 |
+
mamba_ssm-2.2.2+cu118torch2.1cxx11abiFALSE-cp310-cp310-linux_x86_64.whl
|
| 40 |
+
causal_conv1d-1.4.0+cu118torch2.1cxx11abiFALSE-cp310-cp310-linux_x86_64.whl
|
| 41 |
+
```
|
| 42 |
+
|
| 43 |
+
You can install them using
|
| 44 |
+
```
|
| 45 |
+
pip install mamba_ssm-2.2.2+cu118torch2.1cxx11abiFALSE-cp310-cp310-linux_x86_64.whl
|
| 46 |
+
pip install causal_conv1d-1.4.0+cu118torch2.1cxx11abiFALSE-cp310-cp310-linux_x86_64.whl
|
| 47 |
+
```
|
| 48 |
+
|
| 49 |
+
## Evaluation
|
| 50 |
+
|
| 51 |
+
All evaluation code and details are available at [Mamba Retriever Github](https://github.com/MambaRetriever/MambaRetriever)
|