An open API service indexing awesome lists of open source software.

https://github.com/ruisizhang123/emmark

[DAC'24] EmMark: Robust Watermarks for IP Protection of Embedded Quantized Large Language Models
https://github.com/ruisizhang123/emmark

Last synced: 3 months ago
JSON representation

[DAC'24] EmMark: Robust Watermarks for IP Protection of Embedded Quantized Large Language Models

Awesome Lists containing this project

README

        

# EmMark

**[DAC'24] EmMark: Robust Watermarks for IP Protection of Embedded Quantized Large Language Models**

[Paper](https://arxiv.org/abs/2402.17938)

#### Experiment

**INT4 Quantization WM**

For environment setups, plz refer to [AWQ](https://github.com/mit-han-lab/llm-awq)

Step1: Preprocess to acquire the quantized model along with the activations

```bash
$ cd int4_wm
$ bash scripts/opt_watermark.sh opt-2.7b ours /path/save/llm
```

Step2: Watermark the model

Change `status` variable from `save` to `watermark`.

```bash
$ bash scripts/opt_watermark.sh opt-2.7b ours /path/save/llm
```

**INT8 Quantization WM**

For environment setups, plz refer to [LLM.int8()](https://github.com/TimDettmers/bitsandbytes) and [SmoothQuant](https://github.com/mit-han-lab/smoothquant)

Step1: Preprocess to acquire the quantized model along with the activations

```bash
$ cd int8_wm
$ bash scripts/opt_watermark.sh opt-2.7b ours /path/save/llm
```

Step2: Watermark the model

Change `status` variable from `save` to `watermark`.

```bash
$ bash scripts/opt_watermark.sh opt-2.7b ours /path/save/llm
```

#### Acknowledge

Our code builds heavily upon [AWQ](https://github.com/mit-han-lab/llm-awq), [LLM.int8()](https://github.com/TimDettmers/bitsandbytes) and [SmoothQuant](https://github.com/mit-han-lab/smoothquant). We thank the authors for open-sourcing the code.

#### Citation

If you found our code/paper helpful, please kindly cite:

```latex
@inproceedings{zhang2024emmark,
title={EmMark: Robust watermarks for IP protection of embedded quantized large language models},
author={Zhang, Ruisi and Koushanfar, Farinaz},
booktitle={Proceedings of the 61st ACM/IEEE Design Automation Conference},
pages={1--6},
year={2024}
}
```