From 6b4e382e41cb695043bb15e12c94ac4d6206e0be Mon Sep 17 00:00:00 2001 From: Arun Sharma Date: Mon, 18 May 2026 21:12:44 -0700 Subject: [PATCH 1/3] Fix broken URL with huggingface dataset URL --- src/content/docs/tutorials/example-database.md | 4 ++-- src/content/docs/tutorials/python/index.mdx | 4 ++-- src/content/docs/tutorials/rust/index.mdx | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/content/docs/tutorials/example-database.md b/src/content/docs/tutorials/example-database.md index 9de26ae..ca80fa4 100644 --- a/src/content/docs/tutorials/example-database.md +++ b/src/content/docs/tutorials/example-database.md @@ -9,10 +9,10 @@ The dataset used in the tutorials is a social network dataset of users and posts ## Download the data -You can download the zipped data by clicking on [this link](https://lbugdb.github.io/data/tutorial/tutorial_data.zip), +You can download the zipped data by clicking on [this link](https://huggingface.co/datasets/ladybugdb/python-tutorial/resolve/main/tutorial_data.zip), or use curl as shown below. Once downloaded, unzip the files to your current working directory. ```bash -curl -o tutorial_data.zip https://lbugdb.github.io/data/tutorial/tutorial_data.zip +curl -o tutorial_data.zip https://huggingface.co/datasets/ladybugdb/python-tutorial/resolve/main/tutorial_data.zip unzip tutorial_data.zip ``` diff --git a/src/content/docs/tutorials/python/index.mdx b/src/content/docs/tutorials/python/index.mdx index c48e8b8..a40535c 100644 --- a/src/content/docs/tutorials/python/index.mdx +++ b/src/content/docs/tutorials/python/index.mdx @@ -27,9 +27,9 @@ source .venv/bin/activate pip install ladybug ``` -Next, [download the zipped data](https://lbugdb.github.io/data/tutorial/tutorial_data.zip) and unzip the files. +Next, [download the zipped data](https://huggingface.co/datasets/ladybugdb/python-tutorial/resolve/main/tutorial_data.zip) and unzip the files. ```bash -curl -o tutorial_data.zip https://lbugdb.github.io/data/tutorial/tutorial_data.zip +curl -o tutorial_data.zip https://huggingface.co/datasets/ladybugdb/python-tutorial/resolve/main/tutorial_data.zip unzip tutorial_data.zip rm tutorial_data.zip ``` diff --git a/src/content/docs/tutorials/rust/index.mdx b/src/content/docs/tutorials/rust/index.mdx index 36db4de..dfff20f 100644 --- a/src/content/docs/tutorials/rust/index.mdx +++ b/src/content/docs/tutorials/rust/index.mdx @@ -27,9 +27,9 @@ cd lbug_social_network cargo add lbug ``` -Next, [download the zipped data](https://lbugdb.github.io/data/tutorial/tutorial_data.zip) and unzip the files. +Next, [download the zipped data](https://huggingface.co/datasets/ladybugdb/python-tutorial/resolve/main/tutorial_data.zip) and unzip the files. ```bash -curl -o tutorial_data.zip https://lbugdb.github.io/data/tutorial/tutorial_data.zip +curl -o tutorial_data.zip https://huggingface.co/datasets/ladybugdb/python-tutorial/resolve/main/tutorial_data.zip unzip tutorial_data.zip rm tutorial_data.zip ``` From 351dc57ed3b859e42423e036f1b631034e0fccdf Mon Sep 17 00:00:00 2001 From: Arun Sharma Date: Mon, 18 May 2026 22:14:55 -0700 Subject: [PATCH 2/3] Update tutorial follower count outputs --- src/content/docs/tutorials/python/index.mdx | 14 +++++++++----- src/content/docs/tutorials/rust/index.mdx | 17 +++++++++++------ 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/src/content/docs/tutorials/python/index.mdx b/src/content/docs/tutorials/python/index.mdx index a40535c..6fd4e27 100644 --- a/src/content/docs/tutorials/python/index.mdx +++ b/src/content/docs/tutorials/python/index.mdx @@ -217,10 +217,10 @@ LIMIT 5 ``` ``` ['u2.username', 'follower_count'] -['darkdog878', 6] -['epicking81', 3] -['fastgirl798', 4] +['mysticwolf198', 4] ['stormcat597', 2] +['coolking201', 3] +['brightninja683', 5] ['epiccat105', 4] ``` @@ -237,11 +237,11 @@ LIMIT 1 ``` ``` ['u2.username', 'follower_count'] -['stormninja678', 6] +['darkdog878', 6] ``` This dataset has multiple users with the greatest follower count of `6`. So, we are -excluding other users with the same follower count as `stormninja678` (or whoever appeared first). +excluding other users with the same follower count as `darkdog878` (or whoever appeared first). If you want to retrieve all of them, the query becomes a bit longer: ```cypher MATCH (u1:User)-[f:FOLLOWS]->(u2:User) @@ -252,6 +252,10 @@ WITH u2, COUNT(u1) as follower_count, max_count WHERE follower_count = max_count RETURN u2.username, follower_count ``` +``` +['stormninja678', 6] +['darkdog878', 6] +``` ### Q2: What is the shortest path between two users? We might also be interested in finding the shortest path between two users. For example, how diff --git a/src/content/docs/tutorials/rust/index.mdx b/src/content/docs/tutorials/rust/index.mdx index dfff20f..39e4dbc 100644 --- a/src/content/docs/tutorials/rust/index.mdx +++ b/src/content/docs/tutorials/rust/index.mdx @@ -234,11 +234,11 @@ println!("{}", result2); Returns ``` u2.username|follower_count -coolwolf752|3 -stormfox762|5 +mysticwolf198|4 stormcat597|2 +coolking201|3 brightninja683|5 -stormqueen831|4 +epiccat105|4 ``` This is a lot more useful! We can now clearly see how many followers each user has. @@ -256,11 +256,11 @@ println!("{}", result3); Returns: ``` u2.username|follower_count -stormninja678|6 +darkdog878|6 ``` This dataset has multiple users with the greatest follower count of `6`. So, we are -excluding other users with the same follower count as `stormninja678` (or whoever appeared first). +excluding other users with the same follower count as `darkdog878` (or whoever appeared first). If you want to retrieve all of them, the query becomes a bit longer: ```cypher MATCH (u1:User)-[f:FOLLOWS]->(u2:User) @@ -271,6 +271,11 @@ WITH u2, COUNT(u1) as follower_count, max_count WHERE follower_count = max_count RETURN u2.username, follower_count ``` +``` +u2.username|follower_count +stormninja678|6 +darkdog878|6 +``` ### Q2: What is the shortest path between two users? We might also be interested in finding the shortest path between two users. @@ -507,4 +512,4 @@ fn main() -> Result<(), Error> { ``` - \ No newline at end of file + From e50bfd0efef05c47a214d01d861fc48952bc0ca3 Mon Sep 17 00:00:00 2001 From: Arun Sharma Date: Mon, 18 May 2026 22:24:19 -0700 Subject: [PATCH 3/3] Link Python tutorial notebook --- src/content/docs/tutorials/index.mdx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/content/docs/tutorials/index.mdx b/src/content/docs/tutorials/index.mdx index dd2b178..f4b2d93 100644 --- a/src/content/docs/tutorials/index.mdx +++ b/src/content/docs/tutorials/index.mdx @@ -31,6 +31,12 @@ description="Tutorial for Ladybug's Python API" href="/tutorials/python" /> + + ### Colab notebooks We've compiled a series of Google Colab