From c6df6344e13ebbe16edb35e8a976be1d591885ed Mon Sep 17 00:00:00 2001 From: burtenshaw Date: Tue, 25 Jun 2024 19:36:58 +0200 Subject: [PATCH] [DOCS] swap extra_headers for headers in updated sdk docs (#5100) This PR passes the extra headers pass to `Argilla` down to the http client so that argilla sdk can be used with authenticate deployment like provate HF spaces. - Bug fix (non-breaking change which fixes an issue) **How Has This Been Tested** **Checklist** - I added relevant documentation - follows the style guidelines of this project - I did a self-review of my code - I made corresponding changes to the documentation - I confirm My changes generate no new warnings - I have added tests that prove my fix is effective or that my feature works - I have added relevant notes to the CHANGELOG.md file (See https://keepachangelog.com/) Co-authored-by: Ben Burtenshaw --- argilla/docs/getting_started/installation.md | 2 +- argilla/docs/getting_started/quickstart.md | 2 +- argilla/docs/tutorials/text_classification.ipynb | 2 +- docs/_source/_common/snippets/start_page.md | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/argilla/docs/getting_started/installation.md b/argilla/docs/getting_started/installation.md index bd4056a33f..a851a581c1 100644 --- a/argilla/docs/getting_started/installation.md +++ b/argilla/docs/getting_started/installation.md @@ -43,7 +43,7 @@ import argilla as rg client = rg.Argilla( api_url="", api_key="", - # extra_headers={"Authorization": f"Bearer {HF_TOKEN}"} + # headers={"Authorization": f"Bearer {HF_TOKEN}"} ) ``` diff --git a/argilla/docs/getting_started/quickstart.md b/argilla/docs/getting_started/quickstart.md index d7fa361974..0c9d672c86 100644 --- a/argilla/docs/getting_started/quickstart.md +++ b/argilla/docs/getting_started/quickstart.md @@ -49,7 +49,7 @@ import argilla as rg client = rg.Argilla( api_url="", api_key="" - # extra_headers={"Authorization": f"Bearer {HF_TOKEN}"} + # headers={"Authorization": f"Bearer {HF_TOKEN}"} ) ``` diff --git a/argilla/docs/tutorials/text_classification.ipynb b/argilla/docs/tutorials/text_classification.ipynb index 37acc89c1d..a6cbadf700 100644 --- a/argilla/docs/tutorials/text_classification.ipynb +++ b/argilla/docs/tutorials/text_classification.ipynb @@ -120,7 +120,7 @@ "client = rg.Argilla(\n", " api_url=\"https://[your-owner-name]-[your_space_name].hf.space\",\n", " api_key=\"owner.apikey\"\n", - " # extra_headers={\"Authorization\": f\"Bearer {HF_TOKEN}\"}\n", + " # headers={\"Authorization\": f\"Bearer {HF_TOKEN}\"}\n", ")" ] }, diff --git a/docs/_source/_common/snippets/start_page.md b/docs/_source/_common/snippets/start_page.md index 8b7b1ef96f..f17c1e02de 100644 --- a/docs/_source/_common/snippets/start_page.md +++ b/docs/_source/_common/snippets/start_page.md @@ -37,7 +37,7 @@ import argilla as rg client = rg.Argilla( api_url="", api_key="" - # extra_headers={"Authorization": f"Bearer {HF_TOKEN}"} + # headers={"Authorization": f"Bearer {HF_TOKEN}"} ) ```