tenferro-compute
SkillProductivityWrite Rust programs that use tenferro for tensor computation, autodiff, einsum, linear algebra, and explicit backend execution.
Available today. Use it from your connected AI after setup.
No other account needed.
Connect ahel once, and every AI you use reads what you have installed.
Then ask your AI: use the tenferro-compute skill
What this skill tells your AI
The instructions your AI receives, as published by tensor4all/tenferro-rs in .agents/skills/tenferro-compute/SKILL.md and read by ahel’s review.
Load this skill when the task is to use tenferro from downstream Rust code, not when changing tenferro itself.
Fast path
- Choose the API tier: direct concrete tensors, eager tensors, or traced graphs. The same operation has different receivers and arities at each tier.
- Add the direct crates for that tier. There is no root
tenferrofacade; import operation families such astenferro-einsumandtenferro-linalgdirectly. - Bring the operation's public
*Exttrait into scope. An E0599 saying that a method does not exist usually means the right extension trait is missing. - If an older example mentions a removed module/free function or a constructor signature that no longer compiles, read the API migration guide.
- Read only the relevant reference below before writing the program.
| Need | Read |
|---|---|
| Crates, features, CPU providers, scratch crates | crate selection |
| Tier arities and extension-trait imports | API cheatsheet |
| Backend/executor reuse and compile-once/run-many | performance idioms |
| Column-major data, einsum syntax, registration, and setup traps | pitfalls |
Non-negotiable defaults
- Column-major storage. Dense buffers are column-major: the leftmost
dimension varies fastest. Row-major data passed to
from_vec_col_majoris silently reinterpreted as column-major — permuted/wrong values, never rejected. - No facade crate.
cargo add tenferrofails by design; depend on the crates you need (tenferro-runtime,tenferro-cpu, and operation crates). - Explicit execution owner. Concrete operations take a borrowed session
inside
backend.with_backend_session(...)(BackendSessionHostimport). Construct the backend/runtime once and reuse it — per-call construction discards the buffer pool. Eager tensors retain their runtime instead. - Representation is not reuse. Integer einsum labels still plan. For a
repeated compatible equation/input count/dtype/shape, prepare a
ConcreteEinsumPlanonce, even from a string; see performance idioms. Do not flatten parenthesized contraction order into label arrays. - Einsum dialect. Equations need the explicit arrow (
"ij,jk->ik"). Flat notation supports one right-aligned, broadcastable...ellipsis per term;EinsumNotationprovides the programmatic form. - Result-returning operators. Traced operators return
Result; propagate with?. - CPU/GPU transfers are explicit; unsupported GPU operations do not silently fall back to CPU.
- Traced standard extensions need an explicitly installed extension module and a matching registered runtime engine.
- Keep a scratch crate in its own Cargo workspace (use an empty
[workspace]table when it lives inside a checkout), and enable exactly one BLAS provider when usingcpu-blas.
The executable Rust examples in the references are extracted from
docs/tutorial-code/src/bin/tenferro_compute_skill.rs and compiled by the
existing tutorial-binary test.
Signals
- GitHub stars
- 77
- Forks
- 4
- Last commit
- Sep 2026
Advanced
- Catalog kind
- skill
- Gateway key
tenferro-compute- Source
- github.com/tensor4all/tenferro-rs