conf.py 2.47 KB
Newer Older
1
2
3
4
# -*- coding: utf-8 -*-
import os
import sys

5
# import tlcpack_sphinx_addon
6
7
8
9
10

# -- General configuration ------------------------------------------------

sys.path.insert(0, os.path.abspath("../tilelang"))
sys.path.insert(0, os.path.abspath("../"))
11
12

autodoc_mock_imports = ["torch", "tilelang.language.ast", "tilelang.language.parser"]
13
14

# General information about the project.
15
project = "Tile Language <br>"
16
17
18
19
20
author = "Tile Lang Contributors"
copyright = "2025-2025, %s" % author

# Version information.

21
# TODO: use the version from project metadata
22
23
24
with open("../VERSION", "r") as f:
    version = f.read().strip()
release = version
25
26
27
28
29
30
31

extensions = [
    "sphinx_tabs.tabs",
    "sphinx_toolbox.collapse",
    "sphinxcontrib.httpdomain",
    "sphinx.ext.autodoc",
    "sphinx.ext.napoleon",
32
    "sphinx.ext.intersphinx",
33
    "sphinx_reredirects",
34
35
    "sphinx.ext.mathjax",
    "sphinx.ext.autosummary",
36
37
38
39
40
41
42
43
44
45
46
    "myst_parser",
]

source_suffix = {
    '.rst': 'restructuredtext',
    '.md': 'markdown',
}

myst_enable_extensions = [
    "colon_fence",
    "deflist",
47
48
49
50
]

redirects = {"get_started/try_out": "../index.html#getting-started"}

51
source_suffix = [".md", ".rst"]
52
53
54

language = "en"

55
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "README.md", "**/*libinfo*", "**/*version*"]
56
57
58
59
60
61
62
63
64
65

# The name of the Pygments (syntax highlighting) style to use.
pygments_style = "sphinx"

# A list of ignored prefixes for module index sorting.
# If true, `todo` and `todoList` produce output, else they produce nothing.
todo_include_todos = False

# -- Options for HTML output ----------------------------------------------

66
html_theme = "furo"
67
68
69

templates_path = []

70
html_static_path = ["_static"]
71
72
73
74
75

footer_copyright = "© 2025-2025 Tile Language"
footer_note = " "

html_theme_options = {
76
77
    "light_logo": "img/logo-row.svg",
    "dark_logo": "img/logo-row.svg",
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
}

header_links = [
    ("Home", "https://github.com/tile-ai/tilelang"),
    ("Github", "https://github.com/tile-ai/tilelang"),
]

html_context = {
    "footer_copyright": footer_copyright,
    "footer_note": footer_note,
    "header_links": header_links,
    "display_github": True,
    "github_user": "tile-ai",
    "github_repo": "tilelang",
    "github_version": "main/docs/",
    "theme_vcs_pageview_mode": "edit",
    # "header_logo": "/path/to/logo",
    # "header_logo_link": "",
    # "version_selecter": "",
}

99
100
101
# # add additional overrides
# templates_path += [tlcpack_sphinx_addon.get_templates_path()]
# html_static_path += [tlcpack_sphinx_addon.get_static_path()]