Skip to content

Conversation

kanpuriyanawab
Copy link
Collaborator

Partially Fixes #812



@keras.utils.register_keras_serializable(package="keras_nlp")
@keras_nlp_export("keras_nlp.models.albert.AlbertBackbone")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should use the public path (as documented on keras.io, e.g. https://keras.io/api/keras_nlp/models/albert/albert_backbone/#albertbackbone-class). Here it is "keras_nlp.models.AlbertBackbone". Same for the other symbols!

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure ! will make the change

Copy link
Collaborator

@fchollet fchollet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you for the contribution!



@keras.utils.register_keras_serializable(package="keras_nlp")
@keras_nlp_export("keras_nlp.models.Task")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's fine to export this one, though it's not in the init file. As a general rule to apply the next time: please only include symbols that are currently in the init file, e.g. models/__init__.py.

@fchollet fchollet merged commit 8684351 into keras-team:master Mar 9, 2023
@kanpuriyanawab kanpuriyanawab deleted the api-export-models branch March 10, 2023 06:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add public API export statements
2 participants