Files
Kathryn May 68a794b106 WIP Draft nav + sidebar updates for langsmith platform (#651)
This PR updates the docs for LangSmith Platform, folding in LGP.
Specifically:

- Update to tab arrangement.
- Big content changes in Deployments tab (now Agent deployment as well
as Platform infrastructure deployment).
- Changing the name of the Studio feature.
- Overhaul of home page.
- Updates to tab landing pages to follow the same card format
consistently.
- Moving LGP content into the LS directory in the docs.

## Latest preview:


https://langchain-5e9cc07a-preview-langsm-1760109143-df9b7ef.mintlify.app/langsmith/home
2025-10-14 10:21:52 -04:00

36 lines
1.1 KiB
Python

import glob
def update_mdx_files():
# Get all MDX files in the specified directories
mdx_files = []
for root in ["oss", "langsmith"]:
mdx_files.extend(glob.glob(f"{root}/**/*.mdx", recursive=True))
for file_path in mdx_files:
try:
with open(file_path) as f:
content = f.read()
# Only add if the placeholder heading is not already present
if "## Placeholder heading" not in content:
# Add the placeholder heading and text after the first heading
if "# " in content:
parts = content.split("# ", 1)
new_content = (
parts[0]
+ "# "
+ parts[1]
+ "\n\n## Placeholder heading\n\nThis is an example"
)
with open(file_path, "w") as f:
f.write(new_content)
print(f"Updated {file_path}")
except Exception as e:
print(f"Error processing {file_path}: {e!s}")
if __name__ == "__main__":
update_mdx_files()