Library versions and engine support
Current releases: jax4j 0.2.1 and Quant 0.4.0. A published engine, a validated implementation and an available device are separate things.
Which versions does this website use?
- The jax4j notebooks bundle jax4j-core 0.2.1 and use the
com.nablatensor.jax4jJava namespace. - The current API reference is generated from jax4j 0.2.1 and Quant 0.4.0. Old
nablatensor-*URLs remain an archive. - The finance lessons and QuantLab TeaVM calculators still bundle legacy NablaTensor 0.1.0-SNAPSHOT JARs. Their results and engine lists do not establish support in current jax4j or Quant.
- Quant 0.4.0 pins jax4j 0.1.0. jax4j 0.2.1 changed Java packages incompatibly. Replacing the dependency version alone is not a supported migration.
Native Java engines
These are jax4j 0.2.1 capabilities. CPU and scalar replay/JIT ship in core. Optional engines require their own JARs; native GPU libraries and drivers are not bundled. The release reran Vulkan and wgpu hardware suites. CUDA, ROCm and SIMD execution remains unverified for this release.
| Engine | Artifact | Support and evidence |
|---|---|---|
| CPU / cpu-jit | jax4j-core | Tensor CPU operations; scalar interpreter and bytecode replay. Included in core validation. |
| Vulkan | jax4j-engine-vulkan | Tensor and scalar replay implementations. Hardware validated for 0.2.1; matching Vulkan libraries required. |
| wgpu-native | jax4j-engine-wgpu | Tensor backend, hardware validated for 0.2.1. Requires compatible wgpu-native. No scalar AadEngine adapter. |
| CUDA | jax4j-engine-cuda | Tensor and scalar replay implementations. Builds in 0.2.1; execution last validated in 0.2.0. Requires NVIDIA driver and NVRTC. |
| ROCm / HIP | jax4j-engine-rocm | Tensor kernels and scalar replay are implemented and published. Hardware execution unverified; requires compatible AMD device, HIP runtime and HIPRTC. No claim of validated parity. |
| Vector API SIMD | jax4j-simd | Optional scalar tape replay implementation; no separate tensor placement. Published, but execution unverified for 0.2.1. Requires the incubator module flag. |
| OpenCL | None | No current jax4j module, provider or published engine artifact. Older NablaTensor articles describe a historical implementation. |
ROCm and SIMD are optional implementations with validation gaps. They are not default engines, and their presence in source does not mean a particular installation can run them. CUDA scalar replay also rejects multi-output tapes, uniform draws and named random streams.
Install and check availability
All listed current jax4j library JARs, including ROCm and SIMD, returned HTTP 200 from Maven Central on 21 October 2026. The 0.2.1 release note’s pending-publication statement predates that check.
<dependency>
<groupId>com.nablatensor</groupId>
<artifactId>jax4j-core</artifactId>
<version>0.2.1</version>
</dependency>Download jax4j-engine-wgpu 0.2.1 JAR from Google’s Maven Central mirror. This engine requires wgpu-native in a native Java installation. Browser notebooks use the bundled notebook:jax4j-webgpu:0.2.1 adapter.
Add the matching optional engine at version 0.2.1. Launch native GPU applications with --enable-native-access=ALL-UNNAMED. For scalar SIMD, add jax4j-simd and --add-modules jdk.incubator.vector. Source builds select -Pcuda, -Procm or -Psimd.
import com.nablatensor.jax4j.engine.AadEngines;
import com.nablatensor.jax4j.tensor.Tensors;
// Scalar replay providers, including unavailable ones:
AadEngines.discovered().forEach(e ->
System.out.println(e.name() + ": " + e.isAvailable()));
// Available tensor providers and their ordinal-zero placements:
Tensors.backends().forEach(b -> System.out.println(b.name()));
System.out.println(Tensors.devices());Probe your own process with its actual classpath, flags and drivers. An availability probe does not validate every operation or measure throughput. An explicit unavailable selection fails instead of silently substituting CPU.
Browser engines have a different boundary
The jax4j notebooks run CPU code in an emulated JVM. Their optional browser WebGPU bridge executes supported eager tensor primitives on a hardware adapter; it rejects generated JIT and device-region kernels. It does not load native CUDA, Vulkan, HIP or Vector API SIMD. Native wgpu support cannot be inferred from this bridge.
The older finance calculators use TeaVM and normally run only their portable CPU reference. The dedicated legacy WebGPU demo has its own bridge. Neither runtime makes OpenCL, ROCm or Vector API SIMD available in the browser.