Skip to content

Commit

Permalink
AS-171 readthedocs, 2
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Mooring committed Jan 29, 2025
1 parent b3271d6 commit 2d075b5
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 22 deletions.
25 changes: 3 additions & 22 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -1,32 +1,13 @@
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the OS, Python version and other tools you might need
build:
os: ubuntu-24.04
tools:
python: "3.13"
# You can also specify other tool versions:
# nodejs: "23"
# rust: "1.82"
# golang: "1.23"

# Build documentation in the "docs/" directory with Sphinx
sphinx:
configuration: docs/conf.py

# Optionally build your docs in additional formats such as PDF and ePub
# formats:
# - pdf
# - epub

# Optional but recommended, declare the Python requirements required
# to build your documentation
# See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
# python:
# install:
# - requirements: docs/requirements.txt
python:
install:
- requirements: docs/requirements.txt
28 changes: 28 additions & 0 deletions docs/config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
import os
import sys
sys.path.insert(0, os.path.abspath('..'))

project = 'OpenParse'
copyright = '2024'
author = 'Michael Mooring'
release = '0.7.2'

extensions = [
'sphinx.ext.autodoc', # API documentation
'sphinx.ext.napoleon', # Support for Google/NumPy docstrings
'sphinx.ext.viewcode', # Add links to source code
'myst_parser', # Support markdown files
]

# Source file parsers
source_suffix = {
'.rst': 'restructuredtext',
'.md': 'markdown',
}

# Theme settings
html_theme = 'sphinx_rtd_theme'

# Output options
templates_path = ['_templates']
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ dependencies = [
"requests",
"backoff",
"markitdown",
"sphinx,
sphinx-rtd-theme",
]

[project.urls]
Expand Down
2 changes: 2 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ pypdf>=4.0.0
pdfminer.six>=20200401
tiktoken>=0.3
openai>=1.0.0
sphinx>=7.0.0
sphinx-rtd-theme>=2.0.0
numpy
torch
transformers
Expand Down

0 comments on commit 2d075b5

Please sign in to comment.