Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs[patch]: update links w/ new langgraph API ref #26961

Merged
merged 5 commits into from
Oct 3, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 13 additions & 15 deletions docs/scripts/generate_api_reference_links.py
Original file line number Diff line number Diff line change
Expand Up @@ -316,26 +316,24 @@ def _get_imports(
namespace = "prebuilt"
elif module.startswith("langgraph.errors"):
namespace = "errors"
elif module.startswith("langgraph.types"):
namespace = "types"
else:
# Likely not documented yet
# Unable to determine the namespace
continue

if module.startswith("langgraph.errors"):
# Has different URL structure than other modules
url = (
_LANGGRAPH_API_REFERENCE
+ namespace
+ "/#langgraph.errors."
+ class_name # Uses the actual class name here.
)
else:
if (module, class_name) not in WELL_KNOWN_LANGGRAPH_OBJECTS:
# Likely not documented yet
continue
url = (
_LANGGRAPH_API_REFERENCE + namespace + "/#" + class_name.lower()
)
if (module, class_name) not in WELL_KNOWN_LANGGRAPH_OBJECTS:
# Likely not documented yet
continue
url = (
_LANGGRAPH_API_REFERENCE
+ namespace
+ "/#"
+ module
+ "."
+ class_name
)
else:
raise ValueError(f"Invalid package ecosystem: {package_ecosystem}")

Expand Down
Loading