mars

Binding ABI and API Contract

This contract defines the narrow shared boundary for the language bindings. It keeps the public API stable while making the Rust core responsible for the portable model semantics.

Scope

The ABI boundary is intentionally narrow:

Ownership

Rust owns the shared computational semantics for supported portable models:

Host wrappers own compatibility glue:

Memory Ownership

Memory ownership stays explicit and local to each boundary:

Error Handling

Errors are surfaced as structured status codes plus owned error text:

Batch Interchange

The current batch interchange contract is row-major and explicit:

Version Negotiation

The C ABI surface exposes a queryable version contract so host bindings can negotiate compatibility before using the boundary:

Arrow Decision

Apache Arrow is not part of the current ABI contract.

See Binding ABI and Arrow Decision for the decision record and feasibility notes.

Stability Guarantees

The ABI contract must preserve: