Skip to content

Commit 5cf3788

Browse files
authored
docs: add notebooks to user guide page (#2505)
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [ ] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/python-bigquery-dataframes/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [ ] Code coverage does not decrease (if any source code was changed) - [ ] Appropriate docs were updated (if necessary) Fixes #<issue_number_goes_here> 🦕
1 parent a000425 commit 5cf3788

25 files changed

+9496
-9359
lines changed

.github/workflows/docs.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,3 @@ jobs:
3636
run: |
3737
python -m pip install --upgrade setuptools pip wheel
3838
python -m pip install nox
39-
- name: Run docfx
40-
run: |
41-
nox -s docfx

docs/conf.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,12 @@
5959
"sphinx.ext.todo",
6060
"sphinx.ext.viewcode",
6161
"sphinx_sitemap",
62-
"myst_parser",
62+
"myst_nb",
6363
]
6464

65+
# myst-nb configuration
66+
nb_execution_mode = "off"
67+
6568
# autodoc/autosummary flags
6669
autoclass_content = "both"
6770
autodoc_default_options = {"members": True}
@@ -269,12 +272,14 @@
269272

270273

271274
suppress_warnings = [
275+
# Allow unknown mimetype so we can use widgets in tutorial notebooks.
276+
"mystnb.unknown_mime_type",
272277
# Temporarily suppress this to avoid "more than one target found for
273278
# cross-reference" warning, which are intractable for us to avoid while in
274279
# a mono-repo.
275280
# See https://github.com/sphinx-doc/sphinx/blob
276281
# /2a65ffeef5c107c19084fabdd706cdff3f52d93c/sphinx/domains/python.py#L843
277-
"ref.python"
282+
"ref.python",
278283
]
279284

280285
# -- Options for LaTeX output ---------------------------------------------

docs/notebooks

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../notebooks

docs/user_guide/index.rst

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,116 @@ User Guide
99

1010
Getting Started <https://docs.cloud.google.com/bigquery/docs/dataframes-quickstart>
1111
Cloud Docs User Guides <https://docs.cloud.google.com/bigquery/docs/bigquery-dataframes-introduction>
12+
13+
.. toctree::
14+
:caption: Getting Started
15+
:maxdepth: 1
16+
17+
Quickstart Template <../notebooks/getting_started/bq_dataframes_template.ipynb>
18+
Getting Started <../notebooks/getting_started/getting_started_bq_dataframes.ipynb>
19+
Magics <../notebooks/getting_started/magics.ipynb>
20+
ML Fundamentals <../notebooks/getting_started/ml_fundamentals_bq_dataframes.ipynb>
21+
22+
.. toctree::
23+
:caption: DataFrames
24+
:maxdepth: 1
25+
26+
Anywidget Mode <../notebooks/dataframes/anywidget_mode.ipynb>
27+
Dataframe <../notebooks/dataframes/dataframe.ipynb>
28+
Index Col Null <../notebooks/dataframes/index_col_null.ipynb>
29+
Integrations <../notebooks/dataframes/integrations.ipynb>
30+
Pypi <../notebooks/dataframes/pypi.ipynb>
31+
32+
.. toctree::
33+
:caption: Data Types
34+
:maxdepth: 1
35+
36+
Array <../notebooks/data_types/array.ipynb>
37+
Json <../notebooks/data_types/json.ipynb>
38+
Struct <../notebooks/data_types/struct.ipynb>
39+
Timedelta <../notebooks/data_types/timedelta.ipynb>
40+
41+
.. toctree::
42+
:caption: Generative AI
43+
:maxdepth: 1
44+
45+
AI Functions <../notebooks/generative_ai/ai_functions.ipynb>
46+
AI Forecast <../notebooks/generative_ai/bq_dataframes_ai_forecast.ipynb>
47+
LLM Code Generation <../notebooks/generative_ai/bq_dataframes_llm_code_generation.ipynb>
48+
LLM KMeans <../notebooks/generative_ai/bq_dataframes_llm_kmeans.ipynb>
49+
LLM Output Schema <../notebooks/generative_ai/bq_dataframes_llm_output_schema.ipynb>
50+
LLM Vector Search <../notebooks/generative_ai/bq_dataframes_llm_vector_search.ipynb>
51+
Drug Name Generation <../notebooks/generative_ai/bq_dataframes_ml_drug_name_generation.ipynb>
52+
Large Language Models <../notebooks/generative_ai/large_language_models.ipynb>
53+
54+
.. toctree::
55+
:caption: Machine Learning
56+
:maxdepth: 1
57+
58+
ML Cross Validation <../notebooks/ml/bq_dataframes_ml_cross_validation.ipynb>
59+
Linear Regression <../notebooks/ml/bq_dataframes_ml_linear_regression.ipynb>
60+
Linear Regression BBQ <../notebooks/ml/bq_dataframes_ml_linear_regression_bbq.ipynb>
61+
Linear Regression Big <../notebooks/ml/bq_dataframes_ml_linear_regression_big.ipynb>
62+
Easy Linear Regression <../notebooks/ml/easy_linear_regression.ipynb>
63+
Sklearn Linear Regression <../notebooks/ml/sklearn_linear_regression.ipynb>
64+
Timeseries Analysis <../notebooks/ml/timeseries_analysis.ipynb>
65+
66+
.. toctree::
67+
:caption: Visualization
68+
:maxdepth: 1
69+
70+
COVID Line Graphs <../notebooks/visualization/bq_dataframes_covid_line_graphs.ipynb>
71+
Tutorial <../notebooks/visualization/tutorial.ipynb>
72+
73+
.. toctree::
74+
:caption: Geospatial Data
75+
:maxdepth: 1
76+
77+
Geoseries <../notebooks/geo/geoseries.ipynb>
78+
79+
.. toctree::
80+
:caption: Regionalized BigQuery
81+
:maxdepth: 1
82+
83+
Regionalized <../notebooks/location/regionalized.ipynb>
84+
85+
.. toctree::
86+
:caption: Multimodal
87+
:maxdepth: 1
88+
89+
Multimodal Dataframe <../notebooks/multimodal/multimodal_dataframe.ipynb>
90+
91+
.. toctree::
92+
:caption: Remote Functions
93+
:maxdepth: 1
94+
95+
Remote Function <../notebooks/remote_functions/remote_function.ipynb>
96+
Remote Function Usecases <../notebooks/remote_functions/remote_function_usecases.ipynb>
97+
Remote Function Vertex Claude Model <../notebooks/remote_functions/remote_function_vertex_claude_model.ipynb>
98+
99+
.. toctree::
100+
:caption: Streaming
101+
:maxdepth: 1
102+
103+
Streaming Dataframe <../notebooks/streaming/streaming_dataframe.ipynb>
104+
105+
.. toctree::
106+
:caption: Experimental
107+
:maxdepth: 1
108+
109+
AI Operators <../notebooks/experimental/ai_operators.ipynb>
110+
Semantic Operators <../notebooks/experimental/semantic_operators.ipynb>
111+
112+
.. toctree::
113+
:caption: Apps
114+
:maxdepth: 1
115+
116+
Synthetic Data Generation <../notebooks/apps/synthetic_data_generation.ipynb>
117+
118+
.. toctree::
119+
:caption: Kaggle
120+
:maxdepth: 1
121+
122+
AI Forecast <../notebooks/kaggle/bq_dataframes_ai_forecast.ipynb>
123+
Describe Product Images <../notebooks/kaggle/describe-product-images-with-bigframes-multimodal.ipynb>
124+
Vector Search Over National Jukebox <../notebooks/kaggle/vector-search-with-bigframes-over-national-jukebox.ipynb>

notebooks/dataframes/dataframe.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"id": "13861abc-120c-4db6-ad0c-e414b85d3443",
5050
"metadata": {},
5151
"source": [
52-
"### Select a subset of the DF"
52+
"## Select a subset of the DF"
5353
]
5454
},
5555
{

notebooks/dataframes/index_col_null.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@
358358
"id": "13861abc-120c-4db6-ad0c-e414b85d3443",
359359
"metadata": {},
360360
"source": [
361-
"### Select a subset of the DataFrame\n",
361+
"## Select a subset of the DataFrame",
362362
"\n",
363363
"Filter columns by selecting a list of columns from the DataFrame.\n",
364364
"\n",

notebooks/experimental/ai_operators.ipynb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
{
22
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"id": "title-cell",
6+
"metadata": {},
7+
"source": [
8+
"# AI Operators (Experimental)"
9+
]
10+
},
311
{
412
"cell_type": "code",
513
"execution_count": 1,

notebooks/experimental/semantic_operators.ipynb

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
{
22
"cells": [
3+
{
4+
"cell_type": "markdown",
5+
"id": "title-cell",
6+
"metadata": {},
7+
"source": [
8+
"# Semantic Operators (Experimental)"
9+
]
10+
},
311
{
412
"cell_type": "code",
513
"execution_count": null,

notebooks/generative_ai/bq_dataframes_ai_forecast.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
"cell_type": "markdown",
6161
"metadata": {},
6262
"source": [
63-
"### Setup"
63+
"## Setup"
6464
]
6565
},
6666
{

0 commit comments

Comments
 (0)