Skip to content

docs(langgraph): add Pramagent tool policy guide - #4806

Merged
Naomi Pentrel (npentrel) merged 5 commits into
langchain-ai:mainfrom
sriram7737:sriram7737/docs/pramagent-langgraph-tool-policy
Aug 11, 2026
Merged

Naomi Pentrel (npentrel) merged 5 commits into
langchain-ai:mainfrom
sriram7737:sriram7737/docs/pramagent-langgraph-tool-policy

Conversation

@sriram7737

@sriram7737 sriram rampelli (sriram7737) commented Jul 9, 2026 •

Copy link
Copy Markdown
Contributor

Adds a LangGraph production-pattern guide for placing Pramagent at the tool-execution boundary.

Why:

  • shows how to validate model-proposed tool calls before side effects execute
  • connects ToolGuard decisions to LangGraph interrupts and idempotency guidance
  • keeps LangGraph as the orchestration layer and Pramagent as an optional external policy gate

Validation:

  • git diff --check

@github-actions github-actions Bot added langgraph For docs changes to LangGraph oss external User is not a member of langchain-ai labels Jul 9, 2026
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

❌ Import check failed

This PR contains imports from langchain_core that should be imported from langchain instead.

Detailed issues
Analyzing diff for import issues...
 Found 1 import issues:

File: src/oss/langgraph/pramagent-tool-policy.mdx
Line: 74
Issue: Import from langchain.tools instead of langchain_core.tools
Current:   from langchain_core.tools import tool
Suggested: from langchain.tools import tool
--------------------------------------------------------------------------------

 Found 1 import issues that need to be fixed.

Why this is a problem

The langchain package re-exports many modules and classes from langchain_core. When possible, imports should use langchain instead of langchain_core for:

  • Better user experience (single import source)
  • Consistency across documentation
  • Reduced cognitive load for users

How to fix

Replace the imports as suggested above. For example:

  • ❌ from langchain_core.messages import HumanMessage
  • ✅ from langchain.messages import HumanMessage

🤖 Automated check

This check is based on the latest analysis of langchain re-exports from langchain_core.

@sriram7737
sriram rampelli (sriram7737) marked this pull request as ready for review July 9, 2026 13:45
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Thanks for opening a docs PR, sriram rampelli (@sriram7737)! When it's ready for review, please add the relevant reviewers:

  • @npentrel or @lnhsingh (LangGraph)

@sriram7737

Copy link
Copy Markdown
Contributor Author

This is ready for review. Tagging Lauren Hirata Singh (@lnhsingh) for LangGraph review, per the contributor guidance above.

@sriram7737

Copy link
Copy Markdown
Contributor Author

Keeping this PR active and ready for LangGraph docs review.

Current state from my side: the automated checks are passing, including the earlier import check, and I tagged the requested LangGraph reviewer above. The guide is scoped as an external policy layer pattern for LangGraph tool calls.

Could a maintainer please review when possible, or let me know if this should be smaller, moved elsewhere, or reframed to better fit the docs? I am happy to revise quickly.

@sriram7737

sriram rampelli (sriram7737) commented Aug 3, 2026 •

Copy link
Copy Markdown
Contributor Author

Still active and ready for maintainer review.

Quick update from my side: Pramagent is now published as 0.8.6, and the related Google Gemini Cookbook recipe has been merged. This PR is still intended as a small, practical guide for adding a deterministic policy/trust layer around LangGraph tool calls rather than changing LangGraph core behavior.

Happy to revise the scope, wording, or placement if a maintainer prefers a different fit.

@sriram7737

Copy link
Copy Markdown
Contributor Author

Pushed a small docs cleanup: removed the optional �ction_label kwarg from the Pramagent �alidate_tool(...) example so the snippet uses the simplest public call shape.

@sriram7737

Copy link
Copy Markdown
Contributor Author

Hi Lauren Hirata Singh (@lnhsingh) / Naomi Pentrel (@npentrel) , quick follow-up now that the PR is green again.

All visible checks are passing, including the earlier import check, and the branch is cleanly mergeable with main. I’ll avoid pushing further changes unless requested so the review state stays stable.

It looks like the remaining blockers are maintainer approval and GitHub code scanning finishing/refreshing for the latest commits. Could you please review when you get a chance, or let me know if the guide should be shortened, moved, or reframed?

@npentrel
Naomi Pentrel (npentrel) force-pushed the sriram7737/docs/pramagent-langgraph-tool-policy branch from 25e8203 to 7c3353d Compare August 11, 2026 13:42

@npentrel Naomi Pentrel (npentrel) left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi there, we've made a change to the effect that we no longer add external integration docs to our docs and instead link out to your docs directly from the overview table. I've made those changes here and will merge the PR once tests pass. Thanks!

@github-actions github-actions Bot added integration For docs updates for LangChain integrations langchain For docs changes to LangChain python For content related to the Python version of LangChain projects and removed langgraph For docs changes to LangGraph labels Aug 11, 2026
@langchain-oss-automated-triage

Copy link
Copy Markdown
Contributor

Thanks for contributing a new integration docs page, sriram rampelli (@sriram7737)!

As of July 28, 2026, we have changed how we accept external integrations submissions. Please review the new integration submission process for more information.

We receive a large number of PRs and review them as quickly as we can. Please bear with us as we work through the queue.

If you have already tagged a maintainer on this PR, do not tag them again.

@npentrel
Naomi Pentrel (npentrel) merged commit d5d98e4 into langchain-ai:main Aug 11, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

external User is not a member of langchain-ai integration For docs updates for LangChain integrations langchain For docs changes to LangChain oss python For content related to the Python version of LangChain projects

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants