# AI use cases for Glyd (surya-koritala/Glyd)

Repo: [surya-koritala/Glyd](https://github.com/surya-koritala/Glyd) | Use cases: 4 | Page: https://dedupedai.com/use-cases/surya-koritala-glyd/

Glyd is a Rust library and CLI that keeps bf16 model weights and KV cache in fewer bits on the GPU, restoring exact values as the model runs, and also serves as a lossless file compressor.

This file holds every use case of this repo. Each one starts with a "## " heading and ends with its URL.

- Run Qwen3.5-9B on a 24 GB GPU with long context: https://dedupedai.com/use-cases/surya-koritala-glyd/run-qwen35-9b-on-24gb-gpu/
- Serve Qwen3.5-9B through vLLM with Glyd quantization: https://dedupedai.com/use-cases/surya-koritala-glyd/serve-qwen35-9b-with-vllm/
- Load a bf16 model in Python with Glyd: https://dedupedai.com/use-cases/surya-koritala-glyd/load-bf16-model-in-python-with-glyd/
- Compress JSON event files smaller than zstd -3: https://dedupedai.com/use-cases/surya-koritala-glyd/compress-json-event-files-with-glyd/

## How to run Qwen3.5-9B on a 24 GB GPU with long context with Glyd

Repo: [surya-koritala/Glyd](https://github.com/surya-koritala/Glyd) | Difficulty: Intermediate | Time: 30 minutes | Basis: From the README

Fit Qwen3.5-9B on an RTX 4090 and chat in the terminal with more KV cache room.

**Who it is for:** A developer with a single 24 GB NVIDIA GPU who cannot load bf16 Qwen3.5-9B or get long context from it.

**The problem:** bf16 Qwen3.5-9B runs out of memory at start on a 24 GB RTX 4090, even at 4,096 tokens.

**The outcome:** A working terminal chat with Qwen3.5-9B, using Glyd's GPU-specific settings and the freed memory for KV cache.

### Steps

1. Confirm the machine runs Linux with an NVIDIA GPU (Ampere, Ada, Hopper or Blackwell) and driver 580 or newer.
2. Review the install script at https://getglyd.com/install.sh if you do not trust the host, then run `curl -LsSf https://getglyd.com/install.sh | sh`.
3. Run `glyd run Qwen/Qwen3.5-9B` to apply settings for your GPU and open a chat in the terminal.
4. Send a test question and confirm a reply comes back.
5. Note the context length Glyd sets up and compare it with the README's RTX 4090 result of 189,440 tokens.

### Prompt to paste into your agent

```text
Using the repo surya-koritala/Glyd on a Linux machine with <GPU model> and driver <driver version>, install Glyd with its install script from getglyd.com and run `glyd run Qwen/Qwen3.5-9B`. Report the context length Glyd sets up and the GPU settings it applies. Verify that the terminal chat opens and returns a reply to a test question.
```

### Caveat

The :swift suffix is not lossless, so keep the plain model name when you need bf16-exact weights.

Risk, remote script: The install step pipes a script from getglyd.com directly into sh, so read it first if the host is not one you trust.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/surya-koritala-glyd/run-qwen35-9b-on-24gb-gpu/

## How to serve Qwen3.5-9B through vLLM with Glyd quantization with Glyd

Repo: [surya-koritala/Glyd](https://github.com/surya-koritala/Glyd) | Difficulty: Advanced | Time: 45 minutes | Basis: From the README

Start a vLLM server for Qwen3.5-9B using the glyd quantization option.

**Who it is for:** A platform engineer who already serves models with vLLM and wants to fit more memory into the same GPU.

**The problem:** A vLLM deployment of bf16 Qwen3.5-9B uses about 17.66 GiB for weights, leaving less room for KV cache on a 24 GB card.

**The outcome:** A running vLLM server for Qwen3.5-9B with weights stored in Glyd's format and the freed memory available for KV cache.

### Steps

1. Confirm the GPU is an NVIDIA Ampere, Ada, Hopper or Blackwell card on Linux with driver 580 or newer.
2. Run `pip install "glyd[vllm]"`.
3. Run `vllm serve Qwen/Qwen3.5-9B --quantization glyd`.
4. Send one test prompt to the server's HTTP endpoint and confirm a response is returned. (inferred, check the README)

### Prompt to paste into your agent

```text
In the repo surya-koritala/Glyd, install the vLLM extra with `pip install "glyd[vllm]"` on a machine with <GPU model>, then start `vllm serve Qwen/Qwen3.5-9B --quantization glyd`. Report the weight memory vLLM logs and compare it with the bf16 figure of 17.66 GiB in the README. Verify that a test request to the server returns a completion.
```

### Caveat

The README's lossless claim covers the plain model name, and it does not list the vLLM syntax for the :swift or :kestrel suffixes, which it marks as not lossless.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/surya-koritala-glyd/serve-qwen35-9b-with-vllm/

## How to load a bf16 model in Python with Glyd with Glyd

Repo: [surya-koritala/Glyd](https://github.com/surya-koritala/Glyd) | Difficulty: Intermediate | Time: 30 minutes | Basis: From the README

Use glyd.from_pretrained to load Qwen3.5-9B from a Python script.

**Who it is for:** A machine learning engineer who writes Python inference code and wants smaller GPU memory use without changing the model.

**The problem:** Loading bf16 model weights in Python takes more GPU memory than the Glyd format needs.

**The outcome:** A Python object holding Qwen3.5-9B loaded through Glyd, ready for the engineer's own inference code.

### Steps

1. Confirm the GPU meets the README's requirements: NVIDIA Ampere, Ada, Hopper or Blackwell on Linux with driver 580 or newer.
2. Run `pip install "glyd[vllm]"`, as shown in the README's vLLM section.
3. In a Python file, run `import glyd` and then `model = glyd.from_pretrained("Qwen/Qwen3.5-9B")`.
4. Print the loaded object's type and run one short forward pass to confirm the model loads. (inferred, check the README)

### Prompt to paste into your agent

```text
In the repo surya-koritala/Glyd, install the package with `pip install "glyd[vllm]"` and run `import glyd` followed by `model = glyd.from_pretrained("Qwen/Qwen3.5-9B")` on a machine with <GPU model>. Report any errors and the GPU memory in use after loading. Verify that the model object is created without an exception.
```

### Caveat

The README gives Python usage only as a single line, so check the returned object's interface yourself before building on it.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/surya-koritala-glyd/load-bf16-model-in-python-with-glyd/

## How to compress JSON event files smaller than zstd -3 with Glyd

Repo: [surya-koritala/Glyd](https://github.com/surya-koritala/Glyd) | Difficulty: Intermediate | Time: 15 minutes | Basis: From the README

Use the Glyd CLI to shrink a large JSON file and restore it exactly.

**Who it is for:** A data engineer who stores large JSON event dumps and wants smaller files that still decompress to the original.

**The problem:** Large JSON event files take up storage and are slow to move, and the team wants a lossless format with faster reads.

**The outcome:** A .glyd file that is smaller than a zstd -3 copy and restores to the original JSON.

### Steps

1. Install the CLI with `brew install surya-koritala/glyd/glyd`, or download a release tarball.
2. Run `glyd --max events.json -o events.glyd` to compress the file.
3. Run `glyd -d events.glyd -o events.json` to restore it.
4. Compare the restored events.json with the original before deleting the source file.

### Prompt to paste into your agent

```text
Using the repo surya-koritala/Glyd, install the glyd CLI and compress <input file> to <output file>.glyd with `glyd --max <input file> -o <output file>.glyd`. Restore it with `glyd -d <output file>.glyd -o <restored file>`, then report both file sizes and whether the restored file matches the original. Verify that the restored file is byte-identical to the input.
```

### Caveat

The README's smaller-than-zstd claim comes from its own example, so test the size and speed on your own files before relying on it.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/surya-koritala-glyd/compress-json-event-files-with-glyd/
