Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
isahers1 committed Jun 13, 2024
1 parent 2cec8f9 commit 094074d
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion docs/scripts/check_templates.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
)
DOCUMENT_LOADER_REGEX = r".*".join(DOCUMENT_LOADER_HEADERS)


def check_chat_model(path: Path) -> None:
with open(path, "r") as f:
doc = f.read()
Expand All @@ -39,6 +40,7 @@ def check_chat_model(path: Path) -> None:
f"instructions on how to correctly format a ChatModel Integration page."
)


def check_document_loader(path: Path) -> None:
with open(path, "r") as f:
doc = f.read()
Expand All @@ -56,7 +58,10 @@ def main(*new_doc_paths: Union[str, Path]) -> None:
if CURR_DIR.parent / "docs" / "integrations" / "chat" in path.parents:
print(f"Checking chat model page {path}")
check_chat_model(path)
elif CURR_DIR.parent / "docs" / "integrations" / "document_loaders" in path.parents:
elif (
CURR_DIR.parent / "docs" / "integrations" / "document_loaders"
in path.parents
):
print(f"Checking document loader page {path}")
check_document_loader(path)
else:
Expand Down

0 comments on commit 094074d

Please sign in to comment.