Bindings
Code from outside Clay that Clay code can use: handlers for abilities, faster stand-ins, data, and Clay’s own built-ins.
How bindings work · what they are, the four ways, publishing
Most of what a Clay program uses is other Clay code, shared by its hash. Some things can’t be written in Clay yet, or run far faster as native code: a matrix multiply on a GPU, a Parquet reader, a model’s weights. This site lists them. Each binding pins the exact bytes, says how Clay may use them and where they run, and is signed.
Answers an ability: the program asks for something (a sum on a GPU, a file, a socket) and the handler does it.
<Tensor> programasks →native program answersRuns instead of one exact Clay definition, only faster. The Clay code stays the meaning.
Json.fromTextruns as →native entry pointFiles a handler reads, such as a model’s weights, pinned by fingerprint.
model.safetensorsread by →the Tensor handlerLoaded by Clay’s own tools: the editor, Phaistos, the runner. Your programs don’t call it.
More: where it runs, form, licence, same answer every time
-
clay-kernel0.0.1
Clay’s own engine: checks types, computes the hash of code and runs programs.
Built inAccelerator3 definitionsBrowserNativeCPUWebAssembly2.2 MBNone declaredYes -
clay-tensor-host0.0.1
Does the number crunching for machine learning, and turns text into tokens and back.
HandlerTensor, TokenizerNativeCPUmacOS arm64Native program4.9 MBNone declaredYes -
gpt2-small-weights607a30d
The learned numbers of GPT-2 small and its tokenizer files, pinned to one published copy.
Datafor TensorNativeCPUmacOS arm64Data files548 MBnot kept hereMITYes -
hyparquet1.32.0
Reads Parquet files, for tables in Phaistos.
Built inBrowserNativeCPUJavaScript305 KBMITYes -
hyparquet-compressors1.1.3
Decompression (snappy, gzip, zstd and others) for hyparquet.
Built inBrowserNativeCPUJavaScript162 KBMITYes -
loro-crdt-wasm1.17.1
Merges edits to shared state in Phaistos, so two people can change a page at once.
Built inBrowserCPUWebAssembly3.6 MBMITYes -
web-tree-sitter-runtime0.26.11
Reads Clay source text in the page and on a server.
Built inBrowserNativeCPUWebAssembly201 KBMITYes - No bindings match.Try fewer filters, or