-
-
Notifications
You must be signed in to change notification settings - Fork 144
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
API for topics #1023
API for topics #1023
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think these functions should be marked private (i.e. underscore prefix and not imported/added to __all__
in __init__.py
to avoid accidental imports). This allows the code itself to signal to users that it shouldn't be used by them.
Not writing an example is fine, given we don't expect a regular user to use this functionality. However, for later reference it might be good to add a section to the api
documentation with admin-only functions.
I would like @mfeurer to weigh in on this though. What are your thoughts on how to add admin-only operations? The main alternative I considered would be to perhaps add a separate submodule for them, but as long as there aren't many of them this makes more sense to me.
I don't have a strong opinion on this, but it looks like it would be a bit nicer in a separate admins package. |
Okay, in that case I propose to just go with the private methods for now, and refactor to an |
* initial commit * private functions
Reference Issue
What does this PR implement/fix? Explain your changes.
Topic APIs - For adding topics for datasets based on a topic model
We are going to use this in the new website to group datasets/filter datasets by topic.
This API can be accessed only by admin users.
In future, we will add a get API to get topics per dataset or list datasets by topic.
.
How should this PR be tested?
Any other comments?