Instructions to use keras/roberta_base_en with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- KerasHub
How to use keras/roberta_base_en with KerasHub:
import keras_hub # Load TextClassifier model text_classifier = keras_hub.models.TextClassifier.from_preset( "hf://keras/roberta_base_en", num_classes=2, ) # Fine-tune text_classifier.fit(x=["Thilling adventure!", "Total snoozefest."], y=[1, 0]) # Classify text text_classifier.predict(["Not my cup of tea."])import keras_hub # Create a MaskedLM model task = keras_hub.models.MaskedLM.from_preset("hf://keras/roberta_base_en")import keras_hub # Create a Backbone model unspecialized for any task backbone = keras_hub.models.Backbone.from_preset("hf://keras/roberta_base_en") - Keras
How to use keras/roberta_base_en with Keras:
# !pip install -U keras tensorflow huggingface_hub # Keras needs TensorFlow installed to read "hf://" paths, so the tensorflow backend is selected here; # "jax" and "torch" also work for computation once TensorFlow is installed. import os os.environ["KERAS_BACKEND"] = "tensorflow" import keras model = keras.saving.load_model("hf://keras/roberta_base_en") - Notebooks
- Google Colab
- Kaggle
Commit History
-
Update README.md with new model card content
Verified signaturefb45d08
-
Upload folder using huggingface_hub
Verified signatureda04892
-
Update README.md with new model card content
Verified signatureae5a6ee
-
Update README.md
Verified signature170da0f
-
Update README.md
Verified signature9343a76
-
Update README.md with new model card content
Verified signaturebbce384
-
Update README.md with new model card content
Verified signature29a177a -
Update README.md with new model card content
Verified signature6241bc8 -
Update README.md with new model card content
Verified signature2369f6d -
Update README.md with new model card content
Verified signature5a0334f -
Update README.md with new model card content
Verified signature1288f84 -
Update README.md with new model card content
Verified signature677f63f -
Update README.md with new model card content
Verified signature29aa9ba -
Update README.md with new model card content
Verified signature7b26f42 -
Update README.md with new model card content
Verified signaturecc531af -
Update README.md with new model card content
Verified signature601ac64 -
Update README.md with new model card content
Verified signature2dc13e4 -
Update README.md with new model card content
Verified signature9b7fb4e -
Update README.md with new model card content
Verified signature93c0217 -
Update README.md with new model card content
Verified signature07318b4 -
Update README.md with new model card content
Verified signaturef5f8a85 -
Update README.md with new model card content
Verified signature4735bec -
Upload folder using huggingface_hub
Verified signaturecfa7ba2 -
initial commit
Verified signature965b1d2