Skip to content

docs(nf12): de-duplicate the credits block in the HIP file headers - #3650

Merged
Qubitium merged 1 commit into
ModelCloud:mainfrom
Qubitium:feat/nf12-header-clean
Nov 8, 2026
Merged

Qubitium merged 1 commit into
ModelCloud:mainfrom
Qubitium:feat/nf12-header-clean

Conversation

@Qubitium

@Qubitium Qubitium commented Nov 8, 2026

Copy link
Copy Markdown
Collaborator

Mirrors dphnAI/nf12#3. Pure cleanup — no code, no behaviour change.

The problem

Every HIP header stated the same three facts twice, and three of them repeated the authorship sentence that the SPDX block already makes:

// SPDX-FileCopyrightText: 2026 ModelCloud.ai
// SPDX-FileCopyrightText: 2026 AlpinDale and the nf12 contributors   <- kept
// SPDX-License-Identifier: Apache-2.0                                 <- kept
// ---------------------------------------------------------------------------
// NF12-AD (NyoomFloat12) decode for AMD RDNA4 ...
//
// Algorithm: "NyoomFloat12: Accelerating LLM Inference via Lossless 12-bit
// Weight Compression", Liberman, Fang, Zhang, Dao, and Fu (Together AI, 2026).
// Together AI: https://www.together.ai/
//
// Original NF12 reference implementation and CUDA kernels:
//   https://github.com/dphnAI/nf12                                     <- dup
//   Copyright (c) 2026 AlpinDale and the nf12 contributors.            <- EXACT dup
//   Licensed under the Apache License, Version 2.0.                    <- EXACT dup
//
// This HIP port was written for GPT-QModel (ModelCloud.ai) and consumes the <- dup

The fix

One three-line block, each party named exactly once:

// SPDX-FileCopyrightText: 2026 ModelCloud.ai
// SPDX-FileCopyrightText: 2026 AlpinDale and the nf12 contributors
// SPDX-License-Identifier: Apache-2.0
// ---------------------------------------------------------------------------
// NF12-AD (NyoomFloat12) decode for AMD RDNA4 (gfx1200 / gfx1201 / gfx1250).
//
// Credits: NyoomFloat12 algorithm by Liberman, Fang, Zhang, Dao and Fu
// (Together AI, 2026), https://www.together.ai/. NF12 format, reference codec
// and CUDA kernels by AlpinDale, https://github.com/dphnAI/nf12 (Apache-2.0).
//
// It consumes the same NF12-AD byte stream as the CUDA kernels ...

Both required credits are preserved — Together AI (NyoomFloat12) and AlpinDale (dphnAI/nf12) — and each file now mentions each of them exactly once.

Also

  • gfx1200/gfx1200/gfx1250 → gfx1200/gfx1201/gfx1250 in the format header.
  • The encode section headed "Why the port is not a copy" is now "Port notes" — the paragraph directly above it already says the port is a transliteration producing byte-identical output, so the old heading read as a contradiction.

Net −28 lines across the five files.

Verification

pytest tests/test_nf12_ad_codec.py tests/test_backend_naming.py '\
       tests/test_quant_bits_validation.py tests/test_rocm_llc.py
# 235 passed, 1 skipped

No functional change, so no perf or accuracy numbers to report.

Mirrors dphnAI/nf12#3. Each header stated the same three facts twice: an
SPDX copyright line and then 'Copyright (c) 2026 AlpinDale and the nf12
contributors', an SPDX licence identifier and then 'Licensed under the
Apache License, Version 2.0', and the dphnAI/nf12 URL both inside the
reference-kernel block and one line above it. Three files also repeated
the 'written for GPT-QModel (ModelCloud.ai)' sentence that the SPDX line
above already makes.

Collapse all of that into one three-line credits block that names each
party once. Net -28 lines, no content lost. Also fix the
gfx1200/gfx1200/gfx1250 typo and retitle the encode section from 'Why the
port is not a copy' to 'Port notes'.
@Qubitium
Qubitium merged commit 91b15c4 into ModelCloud:main Nov 8, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant