How to use from the
Use from the
Keras library
# Available backend options are: "jax", "torch", "tensorflow".
import os
os.environ["KERAS_BACKEND"] = "jax"

import keras

model = keras.saving.load_model("hf://kerasformers/roberta_base")

RoBERTa (roberta_base)

A pure Keras 3 port of RoBERTa, converted from FacebookAI/roberta-base (Hugging Face Transformers).

The weights are backend-agnostic: the same checkpoint loads and runs identically under the JAX, TensorFlow, or PyTorch Keras backend (KERAS_BACKEND=jax|tensorflow|torch), via kerasformers.

Usage

from kerasformers.models.roberta import RobertaModel

model = RobertaModel.from_weights("kerasformers/roberta_base")
Downloads last month
-
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for kerasformers/roberta_base

Finetuned
(2375)
this model

Collection including kerasformers/roberta_base