René's URL Explorer Experiment


Title: paste_collapse | deepagents_code | LangChain Reference

Open Graph Title: paste_collapse | deepagents_code

X Title: paste_collapse | deepagents_code

Description: Python API reference for paste_collapse in deepagents_code. Part of the LangChain ecosystem.

Open Graph Description: Python API reference for paste_collapse in deepagents_code. Part of the LangChain ecosystem.

X Description: Python API reference for paste_collapse in deepagents_code. Part of the LangChain ecosystem.

Opengraph URL: https://reference.langchain.com/python/deepagents-code/paste_collapse

direct link

Domain: reference.langchain.com

og:imagehttps://reference.langchain.com/og/python/deepagents-code/paste_collapse
og:image:width1200
og:image:height630
og:image:altpaste_collapse | deepagents_code
og:typearticle
twitter:cardsummary_large_image
twitter:imagehttps://reference.langchain.com/og/python/deepagents-code/paste_collapse

Links:

LangChain Reference home pagehttps://reference.langchain.com/
GitHubhttps://github.com/langchain-ai
Main Docshttps://docs.langchain.com/oss/python/deepagents
Deep Agentshttps://reference.langchain.com/python/deepagents
LangChainhttps://reference.langchain.com/python/langchain/overview
LangGraphhttps://reference.langchain.com/python/langgraph/overview
Integrationshttps://reference.langchain.com/python/integrations/overview
LangSmithhttps://reference.langchain.com/python/langsmith
Deep Agents Codehttps://reference.langchain.com/python/deepagents-code
Deep Agents Codehttps://reference.langchain.com/python/deepagents-code
deepagents-codehttps://reference.langchain.com/python/deepagents-code
attributePASTE_THRESHOLD_CHARS: intMinimum character count for a paste to be collapsed into a placeholder.https://reference.langchain.com/python/deepagents-code/paste_collapse/PASTE_THRESHOLD_CHARS
attributePASTE_THRESHOLD_LINES: intMinimum line count (newline-separated) for a paste to be collapsed.https://reference.langchain.com/python/deepagents-code/paste_collapse/PASTE_THRESHOLD_LINES
attributePASTE_PLACEHOLDER_PATTERNRegex matching [Pasted text #N] or [Pasted text #N +M lines].https://reference.langchain.com/python/deepagents-code/paste_collapse/PASTE_PLACEHOLDER_PATTERN
functioncount_linesReturn the number of newline characters in text.https://reference.langchain.com/python/deepagents-code/paste_collapse/count_lines
functionshould_collapse_pasteReturn whether text should be collapsed into a placeholder. Collapses when the text exceeds the character threshold or the line threshold.https://reference.langchain.com/python/deepagents-code/paste_collapse/should_collapse_paste
functionformat_paste_refFormat a paste placeholder reference string.https://reference.langchain.com/python/deepagents-code/paste_collapse/format_paste_ref
functionexpand_paste_refsReplace all paste placeholders in text with their full content. Placeholders whose IDs are not in pasted_contents are left unchanged.https://reference.langchain.com/python/deepagents-code/paste_collapse/expand_paste_refs
classPastedContentStored content for a collapsed paste. The paste's numeric identifier is the key under which this record is stored in the input's paste map, so it is not duplicated on the record.https://reference.langchain.com/python/deepagents-code/paste_collapse/PastedContent
View source on GitHubhttps://github.com/langchain-ai/deepagents/blob/019900734024a7665fd65bd75235c6307d5da003/libs/code/deepagents_code/paste_collapse.py

Viewport: width=device-width, initial-scale=1


URLs of crawlers that visited me.