# Small model, end to end

Haiku-class, by estimate: tens of billions of parameters fit one 8-GPU server. Two GPU servers (prefill, decode), services, storage. One copy, no spares.

40 devices, 0 cables.

## Devices

| Name | Model | Id in the file |
| --- | --- | --- |
| BMC, rack 1 | [Patch panel, 24 ports, feed-through](https://portspec.dev/catalog/generic/feedthrough-panel-24.md) | `g1-copper` |
| GPU server 1, rack 1 | [GPU server, 6U, 8 GPUs](https://portspec.dev/catalog/generic/server-6u-gpu.md) | `g1-gpu-1` |
| GPU server 2, rack 1 | [GPU server, 6U, 8 GPUs](https://portspec.dev/catalog/generic/server-6u-gpu.md) | `g1-gpu-2` |
| Management, rack 1 | [Switch, 48 ports](https://portspec.dev/catalog/generic/switch-48.md) | `g1-mgmt` |
| GPU fabric 1–12, rack 1 | [Fibre panel, 12 MPO](https://portspec.dev/catalog/generic/fibre-panel-mpo-12.md) | `g1-mpo-a` |
| GPU fabric 13–16, front end, rack 1 | [Fibre panel, 12 MPO](https://portspec.dev/catalog/generic/fibre-panel-mpo-12.md) | `g1-mpo-b` |
| PDU A, rack 1 | [PDU, 8 outlets](https://portspec.dev/catalog/generic/pdu-8.md) | `g1-pdu-a` |
| PDU B, rack 1 | [PDU, 8 outlets](https://portspec.dev/catalog/generic/pdu-8.md) | `g1-pdu-b` |
| Front end, rack 1 | [Switch, 1U, 32 × 400G](https://portspec.dev/catalog/generic/switch-32x400g.md) | `g1-tor` |
| Internet edge A | [MikroTik CRS812 DDQ](https://portspec.dev/catalog/mikrotik/crs812-8ds-2dq-2ddq-rm.md) | `s-edge-a` |
| Internet edge B | [MikroTik CRS812 DDQ](https://portspec.dev/catalog/mikrotik/crs812-8ds-2dq-2ddq-rm.md) | `s-edge-b` |
| Management | [Switch, 48 ports](https://portspec.dev/catalog/generic/switch-48.md) | `s-mgmt` |
| PDU A | [PDU, 8 outlets](https://portspec.dev/catalog/generic/pdu-8.md) | `s-pdu-a` |
| PDU B | [PDU, 8 outlets](https://portspec.dev/catalog/generic/pdu-8.md) | `s-pdu-b` |
| Front-end spine A | [Switch, 1U, 32 × 400G](https://portspec.dev/catalog/generic/switch-32x400g.md) | `s-spine-a` |
| Front-end spine B | [Switch, 1U, 32 × 400G](https://portspec.dev/catalog/generic/switch-32x400g.md) | `s-spine-b` |
| API gateway 1 | [Server, 1U, 10G](https://portspec.dev/catalog/generic/server-1u-10g.md) | `s-svc-1` |
| API gateway 2 | [Server, 1U, 10G](https://portspec.dev/catalog/generic/server-1u-10g.md) | `s-svc-2` |
| Tokenizer | [Server, 1U, 10G](https://portspec.dev/catalog/generic/server-1u-10g.md) | `s-svc-3` |
| Request router | [Server, 1U, 10G](https://portspec.dev/catalog/generic/server-1u-10g.md) | `s-svc-4` |
| Scheduler 1 | [Server, 1U, 10G](https://portspec.dev/catalog/generic/server-1u-10g.md) | `s-svc-5` |
| Scheduler 2 | [Server, 1U, 10G](https://portspec.dev/catalog/generic/server-1u-10g.md) | `s-svc-6` |
| Cache 1 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-1` |
| Cache 2 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-2` |
| Cache 3 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-3` |
| Cache 4 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-4` |
| Cache 5 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-5` |
| Cache 6 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-6` |
| Cache 7 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-7` |
| Cache 8 | [Cache server, 1U, NVMe, 100G](https://portspec.dev/catalog/generic/server-1u-nvme-100g.md) | `st1-cache-8` |
| Servers | [Fibre panel, 24 LC duplex](https://portspec.dev/catalog/generic/fibre-panel-lc-24.md) | `st1-fibre` |
| Management | [Switch, 48 ports](https://portspec.dev/catalog/generic/switch-48.md) | `st1-mgmt` |
| PDU A | [PDU, 8 outlets](https://portspec.dev/catalog/generic/pdu-8.md) | `st1-pdu-a` |
| PDU B | [PDU, 8 outlets](https://portspec.dev/catalog/generic/pdu-8.md) | `st1-pdu-b` |
| Storage 1 | [Storage server, 4U, 36 large drives](https://portspec.dev/catalog/generic/server-4u-36lff.md) | `st1-store-1` |
| Storage 2 | [Storage server, 4U, 36 large drives](https://portspec.dev/catalog/generic/server-4u-36lff.md) | `st1-store-2` |
| Storage 3 | [Storage server, 4U, 36 large drives](https://portspec.dev/catalog/generic/server-4u-36lff.md) | `st1-store-3` |
| Storage 4 | [Storage server, 4U, 36 large drives](https://portspec.dev/catalog/generic/server-4u-36lff.md) | `st1-store-4` |
| Top of rack A | [MikroTik CRS520-4XS-16XQ-RM](https://portspec.dev/catalog/mikrotik/crs520-4xs-16xq-rm.md) | `st1-tor-a` |
| Top of rack B | [MikroTik CRS520-4XS-16XQ-RM](https://portspec.dev/catalog/mikrotik/crs520-4xs-16xq-rm.md) | `st1-tor-b` |

## YAML

The whole rack is one file in the portspec YAML format: devices, cables and the scenes drawn from them.

```yaml
network: 1
imports:
  - ../../catalog/index.network.yaml
cables:
  mpo-fabric:  { extends: mpo, color: "#7b5cb8" }
  mpo-front:   { extends: mpo, color: "#2a9bb0" }
  lc-cache:    { extends: lc-duplex, color: "#2a9bb0" }
  cat6-yellow: { extends: cat6, color: "#d9a520" }
racks:
  gpu-1:
    type: rack-cabinet
    door: none
    units: 42
    panels:
      brush-37: { u: 37, type: brush }
      blank-3:  { u: 3, type: blank }
      blank-4:  { u: 4, type: blank }
      blank-5: { u: 5, type: blank }
      blank-6: { u: 6, type: blank }
      blank-7: { u: 7, type: blank }
      blank-8: { u: 8, type: blank }
      blank-9: { u: 9, type: blank }
      blank-10: { u: 10, type: blank }
      blank-11: { u: 11, type: blank }
      blank-12: { u: 12, type: blank }
      blank-13: { u: 13, type: blank }
      blank-14: { u: 14, type: blank }
      blank-15: { u: 15, type: blank }
      blank-16: { u: 16, type: blank }
      blank-17: { u: 17, type: blank }
      blank-18: { u: 18, type: blank }
      blank-19: { u: 19, type: blank }
      blank-20: { u: 20, type: blank }
      blank-21: { u: 21, type: blank }
      blank-22: { u: 22, type: blank }
      blank-23: { u: 23, type: blank }
      blank-24: { u: 24, type: blank }
  services:
    type: rack-cabinet
    door: none
    units: 42
    panels:
      brush-38: { u: 38, type: brush }
  store-1:
    type: rack-cabinet
    door: none
    units: 42
    panels:
      brush-37: { u: 37, type: brush }
      vent-28:  { u: 28, type: vent }
      blank-4: { u: 4, type: blank }
      blank-5: { u: 5, type: blank }
      blank-6: { u: 6, type: blank }
      blank-7: { u: 7, type: blank }
      blank-8: { u: 8, type: blank }
      blank-9: { u: 9, type: blank }
      blank-10: { u: 10, type: blank }
      blank-11: { u: 11, type: blank }
devices:
  g1-tor: { model: switch-32x400g, name: "Front end, rack 1", in: gpu-1, u: 42, ports: { qsfpdd1..8: { module: qsfpdd-mpo-400g }, qsfpdd31..32: { module: qsfpdd-mpo-400g } } }
  g1-mgmt: { model: switch-48, name: "Management, rack 1", in: gpu-1, u: 41 }
  g1-mpo-a: { model: fibre-panel-mpo-12, name: "GPU fabric 1–12, rack 1", in: gpu-1, u: 40 }
  g1-mpo-b: { model: fibre-panel-mpo-12, name: "GPU fabric 13–16, front end, rack 1", in: gpu-1, u: 39 }
  g1-copper: { model: feedthrough-panel-24, name: "BMC, rack 1", in: gpu-1, u: 38 }
  g1-gpu-1: { model: server-6u-gpu, name: "GPU server 1, rack 1", in: gpu-1, u: 31, ports: { osfp1..4: { module: osfp-mpo-800g }, qsfp1..2: { module: qsfpdd-mpo-400g } } }
  g1-gpu-2: { model: server-6u-gpu, name: "GPU server 2, rack 1", in: gpu-1, u: 25, ports: { osfp1..4: { module: osfp-mpo-800g }, qsfp1..2: { module: qsfpdd-mpo-400g } } }
  g1-pdu-a: { model: pdu-8, name: "PDU A, rack 1", in: gpu-1, u: 2 }
  g1-pdu-b: { model: pdu-8, name: "PDU B, rack 1", in: gpu-1, u: 1 }
  s-edge-a: { model: mikrotik/crs812-8ds-2dq-2ddq-rm, name: "Internet edge A", in: services, u: 42 }
  s-edge-b: { model: mikrotik/crs812-8ds-2dq-2ddq-rm, name: "Internet edge B", in: services, u: 41 }
  s-spine-a: { model: switch-32x400g, name: "Front-end spine A", in: services, u: 40 }
  s-spine-b: { model: switch-32x400g, name: "Front-end spine B", in: services, u: 39 }
  s-svc-1: { model: server-1u-10g, name: "API gateway 1", in: services, u: 37 }
  s-svc-2: { model: server-1u-10g, name: "API gateway 2", in: services, u: 36 }
  s-svc-3: { model: server-1u-10g, name: "Tokenizer", in: services, u: 35 }
  s-svc-4: { model: server-1u-10g, name: "Request router", in: services, u: 34 }
  s-svc-5: { model: server-1u-10g, name: "Scheduler 1", in: services, u: 33 }
  s-svc-6: { model: server-1u-10g, name: "Scheduler 2", in: services, u: 32 }
  s-mgmt: { model: switch-48, name: "Management", in: services, u: 4 }
  s-pdu-a: { model: pdu-8, name: "PDU A", in: services, u: 2 }
  s-pdu-b: { model: pdu-8, name: "PDU B", in: services, u: 1 }
  st1-tor-a: { model: mikrotik/crs520-4xs-16xq-rm, name: "Top of rack A", in: store-1, u: 42, ports: { qsfp28-1-1: { module: qsfp28-lc-100g }, qsfp28-2-1: { module: qsfp28-lc-100g }, qsfp28-3-1: { module: qsfp28-lc-100g }, qsfp28-4-1: { module: qsfp28-lc-100g }, qsfp28-5-1: { module: qsfp28-lc-100g }, qsfp28-6-1: { module: qsfp28-lc-100g }, qsfp28-7-1: { module: qsfp28-lc-100g }, qsfp28-8-1: { module: qsfp28-lc-100g }, qsfp28-16-1: { module: qsfp28-lc-100g }, sfp28-1..4: { module: sfp28-lc-25g } } }
  st1-tor-b: { model: mikrotik/crs520-4xs-16xq-rm, name: "Top of rack B", in: store-1, u: 41, ports: { qsfp28-1-1: { module: qsfp28-lc-100g }, qsfp28-2-1: { module: qsfp28-lc-100g }, qsfp28-3-1: { module: qsfp28-lc-100g }, qsfp28-4-1: { module: qsfp28-lc-100g }, qsfp28-5-1: { module: qsfp28-lc-100g }, qsfp28-6-1: { module: qsfp28-lc-100g }, qsfp28-7-1: { module: qsfp28-lc-100g }, qsfp28-8-1: { module: qsfp28-lc-100g }, qsfp28-16-1: { module: qsfp28-lc-100g }, sfp28-1..4: { module: sfp28-lc-25g } } }
  st1-fibre: { model: fibre-panel-lc-24, name: "Servers", in: store-1, u: 40 }
  st1-mgmt: { model: switch-48, name: "Management", in: store-1, u: 39 }
  st1-cache-1: { model: server-1u-nvme-100g, name: "Cache 1", in: store-1, u: 36, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-cache-2: { model: server-1u-nvme-100g, name: "Cache 2", in: store-1, u: 35, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-cache-3: { model: server-1u-nvme-100g, name: "Cache 3", in: store-1, u: 34, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-cache-4: { model: server-1u-nvme-100g, name: "Cache 4", in: store-1, u: 33, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-cache-5: { model: server-1u-nvme-100g, name: "Cache 5", in: store-1, u: 32, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-cache-6: { model: server-1u-nvme-100g, name: "Cache 6", in: store-1, u: 31, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-cache-7: { model: server-1u-nvme-100g, name: "Cache 7", in: store-1, u: 30, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-cache-8: { model: server-1u-nvme-100g, name: "Cache 8", in: store-1, u: 29, ports: { qsfp1..2: { module: qsfp28-lc-100g } } }
  st1-store-1: { model: server-4u-36lff, name: "Storage 1", in: store-1, u: 24, ports: { sfp28-1..2: { module: sfp28-lc-25g } } }
  st1-store-2: { model: server-4u-36lff, name: "Storage 2", in: store-1, u: 20, ports: { sfp28-1..2: { module: sfp28-lc-25g } } }
  st1-store-3: { model: server-4u-36lff, name: "Storage 3", in: store-1, u: 16, ports: { sfp28-1..2: { module: sfp28-lc-25g } } }
  st1-store-4: { model: server-4u-36lff, name: "Storage 4", in: store-1, u: 12, ports: { sfp28-1..2: { module: sfp28-lc-25g } } }
  st1-pdu-a: { model: pdu-8, name: "PDU A", in: store-1, u: 2 }
  st1-pdu-b: { model: pdu-8, name: "PDU B", in: store-1, u: 1 }
scenes:
  front: { title: "Small model, end to end", layout: [gpu-1, services, store-1] }
```

## Files

- Page: https://portspec.dev/racks/llm-small/
- JSON: https://portspec.dev/racks/llm-small.json
- YAML: https://portspec.dev/racks/llm-small.yaml
- Front drawing: https://portspec.dev/g/r/llm-small.svg (SVG), https://portspec.dev/g/r/llm-small.l.png (PNG), https://portspec.dev/g/r/llm-small.real.l.webp (realistic)
- Rear drawing: https://portspec.dev/g/r/llm-small.rear.svg (SVG), https://portspec.dev/g/r/llm-small.rear.l.png (PNG), https://portspec.dev/g/r/llm-small.rear.real.l.webp (realistic)
- All racks: https://portspec.dev/racks.md
