Skip to content

Commit

Permalink
docs: Add telemetry reference to the tutorials to track usage (#4262)
Browse files Browse the repository at this point in the history
<!-- Thanks for your contribution! As part of our Community Growers
initiative 🌱, we're donating Justdiggit bunds in your name to reforest
sub-Saharan Africa. To claim your Community Growers certificate, please
contact David Berenstein in our Slack community or fill in this form
https://tally.so/r/n9XrxK once your PR has been merged. -->

# Description

This PR adds an "Enable Telemetry" section to the tutorials for the new
`tutorial_running` method.

Closes #4234 

**Type of change**

(Remember to title the PR according to the type of change)

- [ ] Documentation update

**How Has This Been Tested**

(Please describe the tests that you ran to verify your changes.)

- [ ] `sphinx-autobuild` (read [Developer
Documentation](https://docs.argilla.io/en/latest/community/developer_docs.html#building-the-documentation)
for more details)

**Checklist**

- [ ] I added relevant documentation
- [ ] I followed the style guidelines of this project
- [ ] I did a self-review of my code
- [ ] I made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I filled out [the contributor form](https://tally.so/r/n9XrxK)
(see text above)
- [ ] I have added relevant notes to the `CHANGELOG.md` file (See
https://keepachangelog.com/)
  • Loading branch information
kursathalat authored Nov 16, 2023
1 parent 7bf732f commit f2418f7
Show file tree
Hide file tree
Showing 48 changed files with 701 additions and 17 deletions.
4 changes: 4 additions & 0 deletions docs/_source/reference/telemetry.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ Additionally, we report the usage of integration for our Python library:

* `ArgillaTrainer` framework usage and NLP task-type.

We also report the usage of our tutorials by `tutorial_running`:

* The tutorial usage count and its name.

For transparency, you can inspect the source code where this is performed [here](https://github.com/argilla-io/argilla/blob/main/src/argilla/utils/telemetry.py).

If you have any doubts, don't hesitate to join our [Slack channel](https://join.slack.com/t/rubrixworkspace/shared_invite/zt-whigkyjn-a3IUJLD7gDbTZ0rKlvcJ5g) or open a GitHub issue. We'd be very happy to discuss how we can improve this.
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,21 @@
"from typing import List"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,21 @@
"print('\\n\\nYour runtime has {:.1f} gigabytes of available RAM\\n'.format(ram_gb))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "Qq_uSvy_BUf-",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,21 @@
"app = FastAPI()"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"metadata": {
Expand Down
17 changes: 16 additions & 1 deletion docs/_source/tutorials/notebooks/labelling-spacy-llm.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,22 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"### `spacy-llm` pipeline\n",
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## `spacy-llm` pipeline\n",
"\n",
"To be able to use GPT3.5 and other models from OpenAI with spacy-llm, we'll need an API key from [openai.com](https://openai.com) and set it as an environment variable."
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,21 @@
"import pandas as pd"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,21 @@
"from argilla.metrics.commons import text_length"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "2697c2cd-d6d1-45fb-97b6-2bf2b97d60c0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,21 @@
"from datasets import load_dataset"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,21 @@
"from PIL import Image"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,21 @@
"from setfit import SetFitModel, SetFitTrainer"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,21 @@
"from argilla.labeling.text_classification import Rule, WeakMultiLabels, add_rules, delete_rules, update_rules, MajorityVoter"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "f37c0bbe-904a-49de-9443-234252f0acb0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,21 @@
"from sklearn import metrics"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "99f8cf20",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,21 @@
")"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,21 @@
")"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,21 @@
"from flair.data import Sentence"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "adc0dc5c-b925-4b77-85ac-1fab6f8c0994",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,21 @@
"from skweak.utils import docbin_writer"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "a6fabf5e",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,21 @@
"from tqdm.auto import tqdm"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,21 @@
"os.environ[\"OPENAI_API_KEY\"] = <YOUR_OPENAI_API_KEY>"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Enable Telemetry\n",
"\n",
"We gain valuable insights from how you interact with our tutorials. To improve ourselves in offering you the most suitable content, using the following lines of code will help us understand that this tutorial is serving you effectively. Though this is entirely anonymous, you can choose to skip this step if you prefer. For more info, please check out the [Telemetry](../../reference/telemetry.md) page.\n",
"\n",
"```python\n",
"from argilla.utils.telemetry import tutorial_running\n",
"\n",
"tutorial_running()\n",
"```"
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down
Loading

0 comments on commit f2418f7

Please sign in to comment.