Kernels documentation
kernels generate-readme
Getting started
Using kernels
QuickstartUsing LayersLocking Kernel VersionsEnvironment VariablesFAQMigrating from older versionsIntegrating kernels into a project
Building kernels
Writing KernelsBuilding kernelsLocal DevelopmentKernel RequirementsSecurityWhy Nix?Metal NotesBuild VariantsBuilding kernels with agents
API Reference
CLI Reference
You are viewing main version, which requires installation from source. If you'd like
regular pip install, checkout the latest stable version (v0.14.1).
kernels generate-readme
Use kernels generate-readme to automatically generate documentation snippets for a kernel’s public functions.
Usage
kernels generate-readme <repo_id> [--revision <rev>]
What It Does
- Downloads the specified kernel from the Hub
- Inspects the kernel’s public API
- Generates markdown documentation snippets showing function signatures and usage
Examples
Generate README snippets for a kernel:
kernels generate-readme kernels-community/activation > README.md
Example Output
README.md snippet for kernels-community/activation:
---
tags:
- kernels
---
## Functions
### Function `fatrelu_and_mul`
`(out: torch.Tensor, x: torch.Tensor, threshold: float = 0.0) -> None`
No documentation available.
### Function `gelu`
`(out: torch.Tensor, x: torch.Tensor) -> None`
No documentation available.
### Function `gelu_and_mul`
`(out: torch.Tensor, x: torch.Tensor) -> None`
No documentation available.
### Function `gelu_fast`
`(out: torch.Tensor, x: torch.Tensor) -> None`
No documentation available.
...