+"""
+
+
+class CustomCardStart(Directive):
+ def run(self):
+ para = nodes.paragraph()
+ self.state.nested_parse(
+ StringList(_CARDLIST_START.split("\n")), self.content_offset, para
+ )
+ return [para]
+
+
+class CustomCardItem(Directive):
+ option_spec = {
+ "header": directives.unchanged,
+ "image": directives.unchanged,
+ "link": directives.unchanged,
+ "card_description": directives.unchanged,
+ "tags": directives.unchanged,
+ }
+
+ def run(self):
+ for key in ["header", "card_description", "link"]:
+ if key not in self.options:
+ raise ValueError(f"Key: `{key}` is missing")
+
+ header = self.options["header"]
+ link = self.options["link"]
+ card_description = self.options["card_description"]
+ tags = self.options.get("tags", "")
+
+ if "image" in self.options:
+ image = ""
+ else:
+ image = "_static/img/thumbnails/default.png"
+
+ card_rst = _CARD_TEMPLATE.format(
+ header=header,
+ image=image,
+ link=link,
+ card_description=card_description,
+ tags=tags,
+ )
+ card_list = StringList(card_rst.split("\n"))
+ card = nodes.paragraph()
+ self.state.nested_parse(card_list, self.content_offset, card)
+ return [card]
+
+
+class CustomCardEnd(Directive):
+ def run(self):
+ para = nodes.paragraph()
+ self.state.nested_parse(
+ StringList(_CARDLIST_END.split("\n")), self.content_offset, para
+ )
+ return [para]
diff --git a/docs/source/export-overview.md b/docs/source/export-overview.md
new file mode 100644
index 00000000000..6a1f88c920a
--- /dev/null
+++ b/docs/source/export-overview.md
@@ -0,0 +1,3 @@
+# Exporting to ExecuTorch
+
+TBA
diff --git a/docs/source/export-user-guide.md b/docs/source/export-user-guide.md
new file mode 100644
index 00000000000..b2d34a600a8
--- /dev/null
+++ b/docs/source/export-user-guide.md
@@ -0,0 +1,3 @@
+# Export User Guide
+
+TBA
diff --git a/docs/source/getting-started-architecture.md b/docs/source/getting-started-architecture.md
new file mode 100644
index 00000000000..351faa6e828
--- /dev/null
+++ b/docs/source/getting-started-architecture.md
@@ -0,0 +1,3 @@
+# High-level Architecture and Components of ExecuTorch
+
+TBA
diff --git a/docs/source/getting-started-setup.md b/docs/source/getting-started-setup.md
new file mode 100644
index 00000000000..3663bf95cb9
--- /dev/null
+++ b/docs/source/getting-started-setup.md
@@ -0,0 +1,3 @@
+# Setting Up ExecuTorch
+
+TBA
diff --git a/docs/source/index.rst b/docs/source/index.rst
new file mode 100644
index 00000000000..d65cdc9055f
--- /dev/null
+++ b/docs/source/index.rst
@@ -0,0 +1,184 @@
+.. _home:
+
+Welcome to the ExecuTorch Documentation
+=======================================
+
+**ExecuTorch** is a PyTorch platform that provides infrastructure to run
+PyTorch programs everywhere from on-frame for Smart Glasses and wearables
+to standard on-device iOS and Android mobile deployments. One of the main
+goals for ExecuTorch is to enable wider customization and deployment
+capabilities of the PyTorch programs.
+
+Executorch heavily relies on such PyTorch technologies as TorchDynamo
+and torch.export. If you are not familiar with these APIs, you might want
+to read about them in the PyTorch documentation before diving into
+the ExecuTorch documentation.
+
+Features described in this documentation are classified by release status:
+
+ *Stable:* These features will be maintained long-term and there should
+ generally be no major performance limitations or gaps in documentation.
+ We also expect to maintain backwards compatibility (although
+ breaking changes can happen and notice will be given one release ahead
+ of time).
+
+ *Beta:* These features are tagged as Beta because the API may change based on
+ user feedback, because the performance needs to improve, or because
+ coverage across operators is not yet complete. For Beta features, we are
+ committing to seeing the feature through to the Stable classification.
+ We are not, however, committing to backwards compatibility.
+
+ *Prototype:* These features are typically not available as part of
+ binary distributions like PyPI or Conda, except sometimes behind run-time
+ flags, and are at an early stage for feedback and testing.
+
+Getting Started
+~~~~~~~~~~~~~~~
+
+Topics in this section will help you get started with ExecuTorch.
+
+.. grid:: 3
+
+ .. grid-item-card:: :octicon:`file-code;1em`
+ What is ExecuTorch?
+ :img-top: _static/img/card-background.svg
+ :link: intro-overview.html
+ :link-type: url
+
+ A gentle introduction to ExecuTorch. In this section,
+ you will learn about main features of ExecuTorch
+ and how yo can use them in your projects.
+
+ .. grid-item-card:: :octicon:`file-code;1em`
+ Getting started with ExecuTorch
+ :img-top: _static/img/card-background.svg
+ :link: getting-started-setup.html
+ :link-type: url
+
+ A step-by-step tutorial on how to get started with
+ ExecuTorch.
+
+ .. grid-item-card:: :octicon:`file-code;1em`
+ ExecuTorch Intermediate Representation API
+ :img-top: _static/img/card-background.svg
+ :link: ir-exir.html
+ :link-type: url
+
+ Learn about EXIR, a graph-based intermediate
+ representation (IR) of PyTorch programs.
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Introduction
+ :hidden:
+
+ intro-overview
+ intro-how-it-works
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Getting Started
+ :hidden:
+
+ getting-started-architecture
+ getting-started-setup
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Exporting to ExecuTorch
+ :hidden:
+
+ export-overview
+ export-user-guide
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Intermediate Representation (IR) Specification
+ :hidden:
+
+ ir-exir
+ ir-ops-set-definition
+ ir-high-order-operators
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Compiler Entry Points
+ :hidden:
+
+ compiler-delegate-and-partitioner
+ compiler-kernel-fusion-pass
+ compiler-custom-compiler-passes
+ compiler-memory-planning
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Runtime
+ :hidden:
+
+ runtime-overview
+ runtime-build-and-cross-compilation
+ runtime-backend-delegate-implementation-and-linking
+ runtime-api
+ runtime-custom-memory-allocator
+ runtime-error-handling
+ runtime-platform-abstraction-layer
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Quantization
+ :hidden:
+
+ quantization-custom-quantization
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Kernel Library
+ :hidden:
+
+ kernel-library-overview
+ kernel-library-custom-aten-kernel
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: SDK
+ :hidden:
+
+ sdk-profiling
+ sdk-debugging
+ sdk-bundled-io
+ sdk-delegate-integration
+
+.. toctree::
+ :glob:
+ :maxdepth: 1
+ :caption: Tutorials
+ :hidden:
+
+ tutorials/template_tutorial
+
+Tutorials and Examples
+~~~~~~~~~~~~~~~~~~~~~~
+
+Ready to experiment? Check out some of the interactive
+ExecuTorch tutorials.
+
+.. customcardstart::
+
+.. customcarditem::
+ :header: Template Tutorial
+ :card_description: A template tutorial. To be deleted.
+ :image: _static/img/generic-pytorch-logo.png
+ :link: tutorials/template_tutorial.html
+ :tags: Template
+
+.. customcardend::
+
diff --git a/docs/source/intro-how-it-works.md b/docs/source/intro-how-it-works.md
new file mode 100644
index 00000000000..52ef441c41e
--- /dev/null
+++ b/docs/source/intro-how-it-works.md
@@ -0,0 +1,3 @@
+# How it works
+
+TBA
diff --git a/docs/source/intro-overview.md b/docs/source/intro-overview.md
new file mode 100644
index 00000000000..a9fe9ba4eea
--- /dev/null
+++ b/docs/source/intro-overview.md
@@ -0,0 +1,3 @@
+# ExecuTorch Overview
+
+TBA
diff --git a/docs/source/ir-exir.md b/docs/source/ir-exir.md
new file mode 100644
index 00000000000..3cb7554c055
--- /dev/null
+++ b/docs/source/ir-exir.md
@@ -0,0 +1,3 @@
+# EXIR
+
+Title TBA
diff --git a/docs/source/ir-high-order-operators.md b/docs/source/ir-high-order-operators.md
new file mode 100644
index 00000000000..94d445a367b
--- /dev/null
+++ b/docs/source/ir-high-order-operators.md
@@ -0,0 +1,3 @@
+# High-order Operators
+
+TBA
diff --git a/docs/source/ir-ops-set-definition.md b/docs/source/ir-ops-set-definition.md
new file mode 100644
index 00000000000..730d27c0846
--- /dev/null
+++ b/docs/source/ir-ops-set-definition.md
@@ -0,0 +1,3 @@
+# OpSet definition
+
+TBA
diff --git a/docs/source/kernel-library-custom-aten-kernel.md b/docs/source/kernel-library-custom-aten-kernel.md
new file mode 100644
index 00000000000..fa2d7f14c6f
--- /dev/null
+++ b/docs/source/kernel-library-custom-aten-kernel.md
@@ -0,0 +1,3 @@
+# Custom ATen Compliant Kernel Implementation and Linking
+
+TBA
diff --git a/docs/source/kernel-library-overview.md b/docs/source/kernel-library-overview.md
new file mode 100644
index 00000000000..1c1de8d90a7
--- /dev/null
+++ b/docs/source/kernel-library-overview.md
@@ -0,0 +1,3 @@
+# Kernel Library Overview
+
+TBA
diff --git a/docs/source/quantization-custom-quantization.md b/docs/source/quantization-custom-quantization.md
new file mode 100644
index 00000000000..2a7feb57cc2
--- /dev/null
+++ b/docs/source/quantization-custom-quantization.md
@@ -0,0 +1,3 @@
+# Custom Quantization
+
+TBA
diff --git a/docs/source/runtime-api.md b/docs/source/runtime-api.md
new file mode 100644
index 00000000000..ba49788a23e
--- /dev/null
+++ b/docs/source/runtime-api.md
@@ -0,0 +1,3 @@
+# Runtime API
+
+TBA (This might need to be an .rst file)
diff --git a/docs/source/runtime-backend-delegate-implementation-and-linking.md b/docs/source/runtime-backend-delegate-implementation-and-linking.md
new file mode 100644
index 00000000000..5d1a3435030
--- /dev/null
+++ b/docs/source/runtime-backend-delegate-implementation-and-linking.md
@@ -0,0 +1,3 @@
+# Backend Delegate Implementation and Linking
+
+TBA
diff --git a/docs/source/runtime-build-and-cross-compilation.md b/docs/source/runtime-build-and-cross-compilation.md
new file mode 100644
index 00000000000..c4f4f544339
--- /dev/null
+++ b/docs/source/runtime-build-and-cross-compilation.md
@@ -0,0 +1,3 @@
+# Build and cross-compilation
+
+TBA
diff --git a/docs/source/runtime-custom-memory-allocator.md b/docs/source/runtime-custom-memory-allocator.md
new file mode 100644
index 00000000000..5c72a8db526
--- /dev/null
+++ b/docs/source/runtime-custom-memory-allocator.md
@@ -0,0 +1,3 @@
+# Custom Memory Allocator
+
+TBA
diff --git a/docs/source/runtime-error-handling.md b/docs/source/runtime-error-handling.md
new file mode 100644
index 00000000000..f87d302140f
--- /dev/null
+++ b/docs/source/runtime-error-handling.md
@@ -0,0 +1,3 @@
+# Runtime Error Handling
+
+TBA
diff --git a/docs/source/runtime-overview.md b/docs/source/runtime-overview.md
new file mode 100644
index 00000000000..0f0ff2c594b
--- /dev/null
+++ b/docs/source/runtime-overview.md
@@ -0,0 +1,3 @@
+# Runtime Overview
+
+TBA
diff --git a/docs/source/runtime-platform-abstraction-layer.md b/docs/source/runtime-platform-abstraction-layer.md
new file mode 100644
index 00000000000..df8c8e4fd72
--- /dev/null
+++ b/docs/source/runtime-platform-abstraction-layer.md
@@ -0,0 +1,3 @@
+# Platform Abstraction Layer
+
+TBA
diff --git a/docs/source/sdk-bundled-io.md b/docs/source/sdk-bundled-io.md
new file mode 100644
index 00000000000..50e6947344b
--- /dev/null
+++ b/docs/source/sdk-bundled-io.md
@@ -0,0 +1,3 @@
+# BundledIO
+
+TBA
diff --git a/docs/source/sdk-debugging.md b/docs/source/sdk-debugging.md
new file mode 100644
index 00000000000..732d06504ab
--- /dev/null
+++ b/docs/source/sdk-debugging.md
@@ -0,0 +1,3 @@
+# Debugging
+
+TBA
diff --git a/docs/source/sdk-delegate-integration.md b/docs/source/sdk-delegate-integration.md
new file mode 100644
index 00000000000..59eaf832f7c
--- /dev/null
+++ b/docs/source/sdk-delegate-integration.md
@@ -0,0 +1,3 @@
+# Delegate Integration
+
+TBA
diff --git a/docs/source/sdk-profiling.md b/docs/source/sdk-profiling.md
new file mode 100644
index 00000000000..534f60d5220
--- /dev/null
+++ b/docs/source/sdk-profiling.md
@@ -0,0 +1,3 @@
+# Profiling
+
+TBA
diff --git a/docs/source/tutorials_source/README.txt b/docs/source/tutorials_source/README.txt
new file mode 100644
index 00000000000..87fe1edbbbc
--- /dev/null
+++ b/docs/source/tutorials_source/README.txt
@@ -0,0 +1,6 @@
+Tutorials
+---------
+
+1. tutorials/*
+ Getting Starrted Tutorials
+ https://pytorch.org/executorch/tutorials/template_tutorial.html
diff --git a/docs/source/tutorials_source/template_tutorial.py b/docs/source/tutorials_source/template_tutorial.py
new file mode 100644
index 00000000000..520bd40eb03
--- /dev/null
+++ b/docs/source/tutorials_source/template_tutorial.py
@@ -0,0 +1,92 @@
+# -*- coding: utf-8 -*-
+
+"""
+Template Tutorial
+=================
+
+**Author:** `FirstName LastName `_
+
+.. grid:: 2
+
+ .. grid-item-card:: :octicon:`mortar-board;1em;` What you will learn
+
+ * Item 1
+ * Item 2
+ * Item 3
+
+ .. grid-item-card:: :octicon:`list-unordered;1em;` Prerequisites
+
+ * PyTorch v2.0.0
+ * GPU ???
+ * Other items 3
+
+If you have a video, add it here like this:
+
+.. raw:: html
+
+
+
+
+
+To test your tutorial locally, you can do one of the following:
+
+* You can control specific files that generate the results by using
+ ``GALLERY_PATTERN`` environment variable. The GALLERY_PATTERN variable
+ respects regular expressions.
+ For example to run only ``neural_style_transfer_tutorial.py``,
+ use the following command:
+
+ .. code-block:: sh
+
+ GALLERY_PATTERN="neural_style_transfer_tutorial.py" make html
+
+ or
+
+ .. code-block:: sh
+
+ GALLERY_PATTERN="neural_style_transfer_tutorial.py" sphinx-build . _build
+
+* Make a copy of this repository and add only your
+ tutorial to the `beginner_source` directory removing all other tutorials.
+ Then run ``make html``.
+
+Verify that all outputs were generated correctly in the created HTML.
+"""
+
+#########################################################################
+# Overview
+# --------
+#
+# Describe Why is this topic important? Add Links to relevant research papers.
+#
+# This tutorial walks you through the process of....
+#
+# Steps
+# -----
+#
+# Example code (the output below is generated automatically):
+#
+import torch
+x = torch.rand(5, 3)
+print(x)
+
+######################################################################
+# (Optional) Additional Exercises
+# -------------------------------
+#
+# Add additional practice exercises for users to test their knowledge.
+# Example: `NLP from Scratch `__.
+#
+
+######################################################################
+# Conclusion
+# ----------
+#
+# Summarize the steps and concepts covered. Highlight key takeaways.
+#
+# Further Reading
+# ---------------
+#
+# * Link1
+# * Link2
+