[PR #3463] [CLOSED] docs: add langchain-collapse to community middleware #3511

Closed
opened 2026-06-05 18:23:20 -04:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/langchain-ai/docs/pull/3463
Author: @johanity
Created: 4/7/2026
Status: Closed

Base: mainHead: add-langchain-collapse


📝 Commits (1)

  • 771e0c3 docs: add langchain-collapse to community middleware

📊 Changes

1 file changed (+1 additions, -0 deletions)

View changed files

📝 src/oss/python/integrations/middleware/index.mdx (+1 -0)

📄 Description

Adds langchain-collapse to the community middleware integrations table.

What it does

Preventive context management middleware that collapses consecutive read/search tool-call groups into a short placeholder, keeping only the most recent result. Reduces context usage before SummarizationMiddleware needs to fire.

  • 92% token reduction on realistic coding sessions
  • SummarizationMiddleware triggers 4.2x later when CollapseMiddleware runs first
  • Stateless, no LLM calls
  • PyPI · Source · CI

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/langchain-ai/docs/pull/3463 **Author:** [@johanity](https://github.com/johanity) **Created:** 4/7/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `add-langchain-collapse` --- ### 📝 Commits (1) - [`771e0c3`](https://github.com/langchain-ai/docs/commit/771e0c3c9818170e83098e11380c1a7c9e6d8b19) docs: add langchain-collapse to community middleware ### 📊 Changes **1 file changed** (+1 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `src/oss/python/integrations/middleware/index.mdx` (+1 -0) </details> ### 📄 Description Adds [langchain-collapse](https://github.com/johanity/langchain-collapse) to the community middleware integrations table. ## What it does Preventive context management middleware that collapses consecutive read/search tool-call groups into a short placeholder, keeping only the most recent result. Reduces context usage before `SummarizationMiddleware` needs to fire. - 92% token reduction on realistic coding sessions - `SummarizationMiddleware` triggers 4.2x later when `CollapseMiddleware` runs first - Stateless, no LLM calls - [PyPI](https://pypi.org/project/langchain-collapse/) · [Source](https://github.com/johanity/langchain-collapse) · [CI](https://github.com/johanity/langchain-collapse/actions) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-06-05 18:23:20 -04:00
yindo closed this issue 2026-06-05 18:23:20 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langchain-ai/docs#3511