Skip to content
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

feat: adapt active learning with small-text example to recent argilla version #3831

Conversation

chschroeder
Copy link
Contributor

@chschroeder chschroeder commented Sep 26, 2023

Description

This PR solves #3442 in which two notebooks should be updated. In the respective issue I just wanted to raise the small-text version since there have been new features, and more importantly, some bug fixes in small-text.

In the course of updating this, I noticed that the notebooks seemed to have issues when used with a recent argilla version:

  1. a legacy warning regarding rg.configure_dataset()
  2. an error regarding TextClassificationRecord which was passed ids of type np.int64, which seems to have become stricter and now requires int.

This could have been done in two three PRs but since it needs manual testing afterwards I decided to count it as "one update". I hope you are okay with this ;). Edit: I made separate entries in CHANGELOG.md. Feel free to rewrite/change it back.

The following two notebooks were updated:

Changes:

  • Raised small-text version
  • Replaced the call to rg.configure_dataset() with rg.configure_dataset_settings()
  • Changed ids to be of type int
  • Dataset name (i.e. the "project" in argilla) now uses hyphens instead of underscores to keep it consistent with the default project in hugging face spaces' argilla template.

Closes #3442

Type of change

  • Improvement (change adding some improvement to an existing functionality)

How Has This Been Tested

  • training-textclassification-smalltext-activelearning.ipynb has been tested with a local Jupyterlab against a Hugging Face Spaces argilla instance.
  • deploying-textclassification-colab-activelearning.ipynp has been testen in Google Colab (as it is required).

Checklist

  • I added relevant documentation
  • I followed the style guidelines of this project (<-- where?)
  • I did a self-review of my code
  • I made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • I filled out the contributor form (see text above)
  • I have added relevant notes to the CHANGELOG.md file (See https://keepachangelog.com/)

@chschroeder chschroeder changed the title feat: adapt active learning with small-text example to recent argilla… feat: adapt active learning with small-text example to recent argilla version Sep 27, 2023
@davidberenstein1957
Copy link
Member

This looks great. Thank you @chschroeder 💪🏽

@davidberenstein1957 davidberenstein1957 changed the base branch from develop to main September 27, 2023 07:17
@davidberenstein1957 davidberenstein1957 changed the base branch from main to develop September 27, 2023 07:17
@davidberenstein1957 davidberenstein1957 merged commit cb8713d into argilla-io:develop Sep 27, 2023
@chschroeder
Copy link
Contributor Author

I forgot:

For deploying-textclassification-colab-activelearning.ipynp the required command argilla server start did not seem to be enough. I had to run two commands before that: argilla server database migrate and argilla server database users create_default to get it working.

Not sure if this was my fault or if is it missing in the notebook description.

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.

[FEATURE] Update small-text tutorials
2 participants