Skip to content

Commit

Permalink
generateReadme: Refresh
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed Dec 21, 2023
1 parent 852c30a commit 2ae67da
Show file tree
Hide file tree
Showing 5 changed files with 146 additions and 86 deletions.
48 changes: 24 additions & 24 deletions .github/push_templates_to_algolia.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@
"id": "aa0e3e6f-1260-4452-8abf-7c084e26c8a4",
"metadata": {
"execution": {
"iopub.execute_input": "2023-12-21T10:17:33.736888Z",
"iopub.status.busy": "2023-12-21T10:17:33.736701Z",
"iopub.status.idle": "2023-12-21T10:17:33.782775Z",
"shell.execute_reply": "2023-12-21T10:17:33.782198Z"
"iopub.execute_input": "2023-12-21T10:30:07.174237Z",
"iopub.status.busy": "2023-12-21T10:30:07.174045Z",
"iopub.status.idle": "2023-12-21T10:30:07.220293Z",
"shell.execute_reply": "2023-12-21T10:30:07.219714Z"
},
"papermill": {},
"tags": []
Expand Down Expand Up @@ -95,10 +95,10 @@
"id": "cfa97168-63eb-4e8c-89c3-0a5d26f47740",
"metadata": {
"execution": {
"iopub.execute_input": "2023-12-21T10:17:33.785617Z",
"iopub.status.busy": "2023-12-21T10:17:33.785070Z",
"iopub.status.idle": "2023-12-21T10:17:33.788440Z",
"shell.execute_reply": "2023-12-21T10:17:33.787925Z"
"iopub.execute_input": "2023-12-21T10:30:07.222614Z",
"iopub.status.busy": "2023-12-21T10:30:07.222423Z",
"iopub.status.idle": "2023-12-21T10:30:07.225745Z",
"shell.execute_reply": "2023-12-21T10:30:07.225219Z"
},
"papermill": {},
"tags": []
Expand Down Expand Up @@ -141,10 +141,10 @@
"id": "7a9c86c2-931d-4113-abbc-31b3f517b6c4",
"metadata": {
"execution": {
"iopub.execute_input": "2023-12-21T10:17:33.791055Z",
"iopub.status.busy": "2023-12-21T10:17:33.790647Z",
"iopub.status.idle": "2023-12-21T10:17:33.874413Z",
"shell.execute_reply": "2023-12-21T10:17:33.873725Z"
"iopub.execute_input": "2023-12-21T10:30:07.228268Z",
"iopub.status.busy": "2023-12-21T10:30:07.228097Z",
"iopub.status.idle": "2023-12-21T10:30:07.312387Z",
"shell.execute_reply": "2023-12-21T10:30:07.311633Z"
},
"tags": []
},
Expand Down Expand Up @@ -178,10 +178,10 @@
"id": "c50e96b2-4403-413c-a99a-9243be0c0a04",
"metadata": {
"execution": {
"iopub.execute_input": "2023-12-21T10:17:33.877223Z",
"iopub.status.busy": "2023-12-21T10:17:33.876817Z",
"iopub.status.idle": "2023-12-21T10:17:35.503447Z",
"shell.execute_reply": "2023-12-21T10:17:35.502784Z"
"iopub.execute_input": "2023-12-21T10:30:07.314969Z",
"iopub.status.busy": "2023-12-21T10:30:07.314773Z",
"iopub.status.idle": "2023-12-21T10:30:07.867294Z",
"shell.execute_reply": "2023-12-21T10:30:07.866605Z"
},
"tags": []
},
Expand Down Expand Up @@ -230,10 +230,10 @@
"id": "da661ba3-fd15-4abc-bd4f-d13ae77b82b0",
"metadata": {
"execution": {
"iopub.execute_input": "2023-12-21T10:17:35.506298Z",
"iopub.status.busy": "2023-12-21T10:17:35.506056Z",
"iopub.status.idle": "2023-12-21T10:17:38.594237Z",
"shell.execute_reply": "2023-12-21T10:17:38.593616Z"
"iopub.execute_input": "2023-12-21T10:30:07.870007Z",
"iopub.status.busy": "2023-12-21T10:30:07.869791Z",
"iopub.status.idle": "2023-12-21T10:30:08.581172Z",
"shell.execute_reply": "2023-12-21T10:30:08.580519Z"
},
"tags": []
},
Expand All @@ -260,10 +260,10 @@
"id": "f1482a8f-4ce5-4e04-93c8-ddd883375d67",
"metadata": {
"execution": {
"iopub.execute_input": "2023-12-21T10:17:38.596761Z",
"iopub.status.busy": "2023-12-21T10:17:38.596570Z",
"iopub.status.idle": "2023-12-21T10:17:38.766615Z",
"shell.execute_reply": "2023-12-21T10:17:38.766045Z"
"iopub.execute_input": "2023-12-21T10:30:08.583702Z",
"iopub.status.busy": "2023-12-21T10:30:08.583488Z",
"iopub.status.idle": "2023-12-21T10:30:08.688352Z",
"shell.execute_reply": "2023-12-21T10:30:08.687641Z"
},
"tags": []
},
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4287,6 +4287,7 @@ We are committed to sharing templates and giving shout outs to the contributors
* [Get Artist Top Tracks](https://github.com/jupyter-naas/awesome-notebooks/blob/master/Spotify/Spotify_Get_Artists_Top_Tracks.ipynb)
* [Get New Releases](https://github.com/jupyter-naas/awesome-notebooks/blob/master/Spotify/Spotify_Get_New_Releases.ipynb)
* [Get Recently Played Tracks](https://github.com/jupyter-naas/awesome-notebooks/blob/master/Spotify/Spotify_Get_Recently_Played_Tracks.ipynb)
* [Get User Top Items](https://github.com/jupyter-naas/awesome-notebooks/blob/master/Spotify/Spotify_Get_User_Top_Items.ipynb)
* [Search for Item](https://github.com/jupyter-naas/awesome-notebooks/blob/master/Spotify/Spotify_Search_for_Item.ipynb)
* [Setup connection](https://github.com/jupyter-naas/awesome-notebooks/blob/master/Spotify/Spotify_Setup_connection.ipynb)

Expand Down
93 changes: 76 additions & 17 deletions Spotify/Spotify_Get_User_Top_Items.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,21 @@
{
"cell_type": "markdown",
"id": "17b6bb99-2896-4773-a017-93fcb6a9d09a",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"<img width=\"8%\" alt=\"Spotify.png\" src=\"https://raw.githubusercontent.com/jupyter-naas/awesome-notebooks/master/.github/assets/logos/Spotify.png\" style=\"border-radius: 15%\">"
]
},
{
"cell_type": "markdown",
"id": "faadb329-be43-4b38-8295-79fee5d6ff55",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"# Spotify - Get User Top Items\n",
"<a href=\"https://app.naas.ai/user-redirect/naas/downloader?url=https://raw.githubusercontent.com/jupyter-naas/awesome-notebooks/master/Spotify/Spotify_Get_User_Top_Items.ipynb\" target=\"_parent\"><img src=\"https://naasai-public.s3.eu-west-3.amazonaws.com/Open_in_Naas_Lab.svg\"/></a><br><br><a href=\"https://bit.ly/3JyWIk6\">Give Feedback</a> | <a href=\"https://github.com/jupyter-naas/awesome-notebooks/issues/new?assignees=&labels=bug&template=bug_report.md&title=Spotify+-+Get+User+Top+Items:+Error+short+description\">Bug report</a>"
Expand All @@ -20,39 +26,54 @@
{
"cell_type": "markdown",
"id": "447e14b0-90d5-47cb-857d-19db420905dc",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**Tags:** #spotify #api #gettopitems #webapi #reference #snippet"
]
},
{
"cell_type": "markdown",
"id": "35d783ed-8b09-4418-8423-3822b2ff271e",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**Author:** [Alton Liew](https://www.linkedin.com/in/alton-liew-749944182/)"
]
},
{
"cell_type": "markdown",
"id": "9dbe7032-188e-4889-b049-ae727732ddfe",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**Last update:** 2023-12-14 (Created: 2023-12-10)"
]
},
{
"cell_type": "markdown",
"id": "ae3f7f8e-8789-4339-ab6c-63d36fd9c523",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**Description:** This notebook retrieve the current user's top artists or tracks based on calculated affinity."
]
},
{
"cell_type": "markdown",
"id": "b76e0005-5175-466b-b912-cbdfe7483e86",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**References:**\n",
"- [Spotify Web API Reference - Get User Top Items](https://developer.spotify.com/documentation/web-api/reference/get-users-top-artists-and-tracks)\n",
Expand All @@ -62,15 +83,21 @@
{
"cell_type": "markdown",
"id": "3528794c-6bcc-40ad-a836-5412656c4b08",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"## Input"
]
},
{
"cell_type": "markdown",
"id": "c0d95abe-03ba-4161-8b16-e10c1a124807",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Import libraries"
]
Expand All @@ -79,7 +106,10 @@
"cell_type": "code",
"execution_count": null,
"id": "595c14e7-69e4-4108-96aa-f6c2550080c9",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
"source": [
"try:\n",
Expand All @@ -96,7 +126,10 @@
{
"cell_type": "markdown",
"id": "e2f967d0-4871-40de-93f8-09601653c85d",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Setup variables\n",
"- `client_id`: Your Spotify API client ID. [Get your client ID](https://developer.spotify.com/documentation/general/guides/app-settings/#register-your-app)\n",
Expand All @@ -110,7 +143,10 @@
"cell_type": "code",
"execution_count": null,
"id": "a85464c9-9731-4227-9597-ab45681a1452",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
"source": [
"client_id = \"YOUR_SPOTIFY_CLIENT_ID\"\n",
Expand All @@ -124,15 +160,21 @@
{
"cell_type": "markdown",
"id": "dd3919f3-0c2c-4c2f-8914-b16d86c3dabe",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"## Model"
]
},
{
"cell_type": "markdown",
"id": "c974d949-274e-420f-be08-83f827f543e7",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Get user top items\n",
"* Retrieve current logged in user's top items both tracks and artists.\n",
Expand All @@ -145,6 +187,7 @@
"execution_count": null,
"id": "6a9e38d6-92a4-4891-8b5c-0a7135d9704a",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand Down Expand Up @@ -207,7 +250,9 @@
"iopub.status.idle": "2023-12-10T12:11:14.608299Z",
"shell.execute_reply": "2023-12-10T12:11:14.607649Z",
"shell.execute_reply.started": "2023-12-10T12:11:14.600442Z"
}
},
"papermill": {},
"tags": []
},
"source": [
"## Output"
Expand All @@ -216,7 +261,10 @@
{
"cell_type": "markdown",
"id": "d0585798-7543-485d-af14-b5c520620871",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Display result\n",
"* Calls the `authenticate_spotify` function to authenticate user then stores the client in the `spotify_client` variable.\n",
Expand All @@ -228,6 +276,7 @@
"execution_count": null,
"id": "b5c9703e-cc72-48a2-9856-1f846c036cdc",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand Down Expand Up @@ -255,8 +304,18 @@
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.6"
},
"naas": {
"notebook_id": "f2bd0eb943b85c12b078802bb98a9f138b194f6180a8224ade557b3b6e017519",
"notebook_path": "Spotify/Spotify_Get_User_Top_Items.ipynb"
},
"papermill": {
"default_parameters": {},
"environment_variables": {},
"parameters": {},
"version": "2.5.0"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
}
Loading

0 comments on commit 2ae67da

Please sign in to comment.