mirror of
https://github.com/hwchase17/langchain
synced 2024-11-02 09:40:22 +00:00
c5296fd42c
… (#14723) - **Description:** Minor updates per marketing requests. Namely, name decisions (AI Foundation Models / AI Playground) - **Tag maintainer:** @hinthornw Do want to pass around the PR for a bit and ask a few more marketing questions before merge, but just want to make sure I'm not working in a vacuum. No major changes to code functionality intended; the PR should be for documentation and only minor tweaks. Note: QA model is a bit borked across staging/prod right now. Relevant teams have been informed and are looking into it, and I'm placeholdered the response to that of a working version in the notebook. Co-authored-by: Vadim Kudlay <32310964+VKudlay@users.noreply.github.com>
52 lines
1.5 KiB
Python
52 lines
1.5 KiB
Python
import json
|
|
import sys
|
|
import os
|
|
|
|
LANGCHAIN_DIRS = {
|
|
"libs/core",
|
|
"libs/langchain",
|
|
"libs/experimental",
|
|
"libs/community",
|
|
}
|
|
|
|
if __name__ == "__main__":
|
|
files = sys.argv[1:]
|
|
dirs_to_run = set()
|
|
|
|
for file in files:
|
|
if any(
|
|
file.startswith(dir_)
|
|
for dir_ in (
|
|
".github/workflows",
|
|
".github/tools",
|
|
".github/actions",
|
|
"libs/core",
|
|
".github/scripts/check_diff.py",
|
|
)
|
|
):
|
|
dirs_to_run.update(LANGCHAIN_DIRS)
|
|
elif "libs/community" in file:
|
|
dirs_to_run.update(
|
|
("libs/community", "libs/langchain", "libs/experimental")
|
|
)
|
|
elif "libs/partners" in file:
|
|
partner_dir = file.split("/")[2]
|
|
if os.path.isdir(f"libs/partners/{partner_dir}"):
|
|
dirs_to_run.update(
|
|
(
|
|
f"libs/partners/{partner_dir}",
|
|
"libs/langchain",
|
|
"libs/experimental",
|
|
)
|
|
)
|
|
# Skip if the directory was deleted
|
|
elif "libs/langchain" in file:
|
|
dirs_to_run.update(("libs/langchain", "libs/experimental"))
|
|
elif "libs/experimental" in file:
|
|
dirs_to_run.add("libs/experimental")
|
|
elif file.startswith("libs/"):
|
|
dirs_to_run.update(LANGCHAIN_DIRS)
|
|
else:
|
|
pass
|
|
print(json.dumps(list(dirs_to_run)))
|