-
Notifications
You must be signed in to change notification settings - Fork 983
Open
Labels
Description
Background
- QDP: GPU-accelerated quantum state encoding with a Rust core (
qdp-core), CUDA kernels (qdp-kernels), and PyO3 bindings (qumat.qdp/_qdp). Keeping the Rust stack in good shape and visible (e.g. via rustdoc) is part of project health. - Website: Built with Docusaurus;
docs/is the source of truth. Work here includes site code (config, scripts, components), fixing link and nav issues, integrating API docs, and CI.
Project context
- QDP encodings:
qdp/qdp-core/src/gpu/encodings/—QuantumEncodertrait,get_encoder, encodings: amplitude, angle, basis, iqp. - Website: Docusaurus 3.x; source of truth
docs/(sync script copies intowebsite/before build). - QDP API: Encoding methods
"amplitude" | "angle" | "basis" | "iqp" | "iqp-z"; seedocs/qdp/api.md.
Concrete improvements
Rust (QDP)
- Unsafe scope refactor: Narrow
unsafeblocks; keep setup/teardown outside; add// SAFETY:where needed; avoid new broadunsaferegions. - Doc coverage: Add or fix
//////!for public items (first-line summary; optional# Examples/# Panics). Usecargo doc --no-deps→target/doc/. - Lints and style: Fix
cargo clippywarnings; remove dead code and unused imports;rustfmt. - Small refactors: Extract helpers, clarify names, shorten long functions; no behavior change.
- Tests: Add or tighten unit tests where coverage is low; keep tests fast and deterministic.
Website
- Link errors: Fix broken links, wrong URLs, and redirect issues in
docs/and the built site. - Site programming: Fix or improve Docusaurus config, sync scripts, or components.
- Nav and sidebar: Align labels and order with content; fix inconsistencies.
- Doc build in CI: Run
cargo doc --no-deps(and optionally Python doc generation); fail on errors. - Placeholders: Replace "TODO: Add API reference" with a link or short summary.
Deliverables (suggested)
- Rust: At least one concrete improvement (e.g. unsafe refactor, doc coverage, or small refactor) with tests; notes in PR where useful.
- Rust docs: Public API in
qdp-coredocumented forcargo doc --no-deps; optionally wired into the doc pipeline. - Website: At least one of: site programming, link fixes, API doc integration, or CI doc builds.
- Docs: Short note in
docs/or CONTRIBUTING on Rust doc conventions and where to find rustdoc.
References (official dev docs)
| Resource | URL |
|---|---|
| Rust | doc.rust-lang.org |
| rustdoc | doc.rust-lang.org/rustdoc/ |
| How to write documentation | doc.rust-lang.org/rustdoc/how-to-write-documentation.html |
| cargo doc | doc.rust-lang.org/cargo/commands/cargo-rustdoc.html |
| RFC 505 (API comments) | rust-lang.github.io/rfcs/0505-api-comment-conventions.html |
| Rust CUDA (guide) | rust-gpu.github.io/rust-cuda |
| NVIDIA CUDA best practices | docs.nvidia.com/cuda/cuda-c-best-practices-guide |
| Docusaurus | docusaurus.io |
Reactions are currently unavailable