What if your database never had to see your data to work with it?
Today we released AmateRS 0.1.0 — a next-generation distributed database with Fully Homomorphic Encryption (FHE) that lets you compute on encrypted data without ever exposing plaintext to the server.
No C. No Fortran. No SEAL or OpenFHE bindings dragged in through a forest of -sys crates. No plaintext-requiring cloud database quietly assuming it gets to read everything you store. AmateRS is 100% Pure Rust by default. It uses oxicode for serialization instead of bincode, and the only bincode that appears anywhere is feature-gated behind the TFHE serialization path — off unless you ask for it. It compiles to a single static binary you can drop onto a server and run. The mythology behind the name fits the design: like Amaterasu hiding in the Heavenly Rock Cave (Iwato), your data stays sealed inside a cryptographic shell while the computational light still shines.
Why AmateRS 0.1.0 matters
Every cloud database today asks for the same thing: your plaintext. To filter, to index, to compute, the server has to decrypt. That single requirement is the root of the privacy-versus-utility trade-off — you either keep data useful (and trust the operator to read it) or keep it private (and give up computing on it). AmateRS exists to remove that trade-off. The server never holds your keys, never decrypts, and still does useful work.
This first release is early but solid. Here is what is already real in 0.1.0:
- An LSM-tree storage engine with WiscKey value separation, a write-ahead log for crash recovery, leveled compaction, bloom filters, and an LRU block cache — backed by 116 storage tests.
- An FHE compute engine with a circuit builder over encrypted
U8/U16/U32/U64/U128/Booltypes, comparison gates (Eq/Gt/Lt/Gte/Lte), logical gates (And/Or/Not), and arithmetic gates (Add/Sub/Mul) — backed by 30 FHE tests. - An AQL predicate compiler that turns a query filter into an FHE circuit, so a
WHERE-style condition can be evaluated against ciphertext. - Raft consensus (Phase 1) — leader election with randomized timeouts and log replication via AppendEntries — laying the groundwork for multi-node clusters.
- gRPC with mTLS over HTTP/2, connection pooling with retry and backoff, health checks, and a Prometheus metrics endpoint.
All of it sits on top of 600+ tests passing at a 100% pass rate. We are not publishing benchmark numbers yet — at 0.1.0 we would rather under-promise on performance and let the architecture speak.
Technical Deep Dive
AmateRS is organized into four components, each named after a piece of the Amaterasu myth and each mapping to one layer of the system.
Iwato (岩戸) — the Heavenly Rock Cave — Storage Engine. A from-scratch LSM-tree. Writes land in a skip-list memtable and the WAL, flush into SSTables guarded by bloom filters, and settle through multi-level leveled compaction running on background threads. WiscKey value separation keeps large values out of the LSM levels so compaction stays cheap, and an LRU block cache keeps hot blocks resident. Crash recovery replays the WAL.
Yata (八咫鏡) — the Eight-Span Mirror — Compute Engine. This is where computation in the dark happens. Built on TFHE-rs, Yata exposes a circuit builder over encrypted integer and boolean types, a predicate compiler that lowers an AQL filter into an FHE circuit, server-side (multi-tenant) key management, and circuit caching plus optimization so repeated work is not recompiled from zero. There is also runtime GPU detection for future acceleration.
Ukehi (宇気比) — the Sacred Pledge — Consensus. A Raft implementation in its first phase: leader election with randomized election timeouts, log replication, node discovery and membership, and a network abstraction layer. This is the foundation the distributed story is built on.
Musubi (結び) — the Knot — Network Layer. gRPC over HTTP/2 via tonic 0.14, TLS and mutual TLS through rustls and webpki, connection pooling with retry and backoff, graceful shutdown, liveness/readiness health checks, and a Prometheus metrics endpoint.
Getting Started
Add the facade crate to a project, or build the server and CLI straight from the repository.
# As a library dependency
cargo add amaters
# Or build from source
git clone https://github.com/cool-japan/amaters
cd amaters
cargo build --release
# Start the server
cargo run --bin amaters-server -- start --data-dir ./data
# Use the CLI (flat commands)
cargo run --bin amaters-cli -- set my_key "encrypted_data"
cargo run --bin amaters-cli -- get my_key
# Filter query syntax
cargo run --bin amaters-cli -- query "collection('users').filter(age > 18)"
From Rust, connect with the SDK and read and write keys:
use amaters_sdk_rust::AmateRSClient;
#[tokio::main]
async fn main() -> anyhow::Result<()> {
let client = AmateRSClient::connect("http://localhost:7878").await?;
client.set("my_key", "encrypted_data").await?;
let value = client.get("my_key").await?;
println!("{value:?}");
Ok(())
}
What’s inside
Grouped by component, here is what 0.1.0 actually ships:
- Storage (Iwato): LSM-tree with a skip-list memtable, SSTables with bloom filters, multi-level leveled compaction, WAL crash recovery, WiscKey value separation for values over 4KB, an LRU block cache, and background compaction threads.
- FHE compute (Yata): a circuit builder over encrypted
U8–U128andBool; comparison, logical, and arithmetic gates; an AQL-predicate-to-FHE-circuit compiler; multi-tenant server-side key management; and circuit caching and optimization. - Network (Musubi): gRPC over HTTP/2 (tonic 0.14), TLS/mTLS (rustls + webpki), connection pooling with retry and backoff, graceful shutdown, liveness and readiness health checks, and a Prometheus metrics endpoint.
- Query (AQL): CRUD
Set/Get/Delete/Range, filter queries with FHE predicate evaluation, batch operations, streaming results, collection-based organization, and query versioning. - Consensus (Ukehi, Phase 1): leader election with randomized timeouts, log replication via AppendEntries, node discovery and membership, and a network abstraction layer.
- SDKs and CLI: a Rust SDK (builder config, async on tokio, connection pooling, exponential-backoff retry, circuit breaker,
SdkError; 15+ tests), a TypeScript SDK (protobuf-generated, promise-based; 12+ tests), and a CLI covering CRUD, FHE key management (gen/import/export/list/delete), admin operations (backup/restore/compact/stats/verify/logs), JSON and table output, a config file, and health checks. - Server: authentication (API keys hashed with BLAKE3; JWT HS256/RS256/ES256; mTLS X.509), RBAC (Admin/User/Reader) with per-resource permissions and audit logging; observability via tracing, Prometheus, and health endpoints; and configuration through TOML plus
AMATERS_*environment overrides, with a choice of Memory or LSM backend and tunable compaction/WAL settings.
Known issue at 0.1.0 — honest disclosure. Client-side FHE filtering is not yet wired into the wire protocol. The encrypted predicate is compiled and computed, but it is not carried in the protobuf message, so filter queries currently return all rows rather than the filtered set. The plumbing for genuine end-to-end encrypted filtering exists; connecting it through the protocol is next on the list. We would rather ship 0.1.0 with this stated plainly than pretend the loop is closed.
Tips
- Use the Memory storage backend for tests, LSM for production. The backend is selectable via config — Memory gives you fast, ephemeral runs in the test suite without touching disk, while LSM is what you want for durability.
- Configure with
AMATERS_*environment overrides. Anything in the TOML config can be overridden by an environment variable, which keeps secrets and per-environment knobs out of committed files. - FHE compute is feature-gated. The compute engine lives behind the
computefeature (which pulls intfhe). If you only need the storage and protocol layers, leave it off and stay lean. - WiscKey value separation kicks in for large values. Values over 4KB are stored out of the LSM levels, so write-heavy workloads with big payloads keep compaction cheap. Size your values with that 4KB boundary in mind.
- Bloom filters make negative lookups fast. Reads for keys that do not exist are answered without touching SSTable blocks — worth remembering when your access pattern probes for absence.
This is the foundation
AmateRS is the confidential-computing layer of the COOLJAPAN ecosystem. Its most direct tie is a real dependency: serialization runs through oxicode, our Pure Rust replacement for bincode, so AmateRS inherits the same no--sys, no-C posture as the rest of the stack. It sits alongside siblings like OxiARC, OxiBLAS, SciRS2, and Legalis-RS — all Pure Rust, all sovereign by default. For a 0.1.0 that is as much of the ecosystem story as we want to tell; the point of this release is the database itself, not the company it keeps.
Repository: https://github.com/cool-japan/amaters
Star the repo if a database that never sees your plaintext is the kind of thing you have been waiting for — and tell us what you build on it.
Pure Rust confidential computing is here — fast, safe, and sovereign.
— KitaSan at COOLJAPAN OÜ January 19, 2026