alef

Generate typed language bindings from Rust libraries via alef.toml.

91|16|Updated Mar 31, 2026
One-click install
npx skills add https://github.com/kreuzberg-dev/alef --skill alef
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: alef
Source: https://github.com/kreuzberg-dev/alef/tree/main/skills/alef
Command: npx skills add https://github.com/kreuzberg-dev/alef --skill alef

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Alef eliminates the repetitive, error-prone work of manually writing and keeping multi-language bindings in sync with a Rust codebase, so your generated APIs stay accurate as your Rust sources evolve.

Core Features & Use Cases

  • One config, many languages: Generate fully-typed language bindings from a single Rust-focused source-of-truth configuration for 16 backends (e.g., Python, Node/TypeScript, WASM, Ruby, PHP, Go, Java, C#, Kotlin, Elixir, Gleam, R, Swift, Dart, Zig, C).
  • End-to-end pipeline: Extract API surface, generate bindings and type stubs, scaffold packages, generate per-language READMEs/docs, and optionally create fixture-driven e2e test suites.
  • CI-friendly freshness guarantees: Use verify/diff to detect stale generated outputs via embedded per-file hashes, preventing silently diverging bindings across languages.
  • Advanced interoperability patterns: Configure DTO styles, trait bridges, adapter patterns, FFI layers, version syncing, and pre-commit hooks to fit real-world library publishing workflows.

Quick Start

Run alef generate to produce the configured language bindings from your Rust crate and alef.toml configuration.

Frequently Asked Questions about alef

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate Rust language bindings for multiple target languages?

Use a single alef.toml configuration to generate fully-typed Rust bindings across multiple target languages, keeping packages synced as your Rust sources evolve.

What is the best way to keep FFI bindings in sync with an evolving Rust codebase?

Use a single configuration to generate polyglot language bindings from Rust sources, using embedded per-file hashing to detect and prevent stale generated outputs across ecosystems.

Can I generate type stubs and package scaffolding for Python and Node from a Rust library?

Yes, generate type stubs and scaffold packages for 16 backends including Python and Node/TypeScript from one Rust library configuration, including per-language READMEs and documentation generation.

Does this binding generation pipeline support CI verification for stale outputs?

Yes, the pipeline supports CI verification through verify/diff commands that detect stale generated outputs via embedded per-file hashes, preventing silently diverging bindings across target languages.

What languages are supported for Rust FFI code generation?

Rust FFI code generation supports 16 backends including Python, Node/TypeScript, WASM, Ruby, PHP, Go, Java, C#, Kotlin, Elixir, Gleam, R, Swift, Dart, Zig, and C.

How do I set up fixture-driven e2e testing for multi-language Rust bindings?

Set up fixture-driven e2e test suites for multi-language Rust bindings by configuring extraction and deterministic codegen, generating test fixtures across many target language ecosystems.