Home / Function/ _atransform() — langchain Function Reference

_atransform() — langchain Function Reference

Architecture documentation for the _atransform() function in xml.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  32340f36_d7fb_913d_0253_43b61c3f0b73["_atransform()"]
  b51fd3dc_a25e_9ad9_8893_3725f5d436f0["XMLOutputParser"]
  32340f36_d7fb_913d_0253_43b61c3f0b73 -->|defined in| b51fd3dc_a25e_9ad9_8893_3725f5d436f0
  32340f36_d7fb_913d_0253_43b61c3f0b73["_atransform()"]
  32340f36_d7fb_913d_0253_43b61c3f0b73 -->|calls| 32340f36_d7fb_913d_0253_43b61c3f0b73
  32340f36_d7fb_913d_0253_43b61c3f0b73["_atransform()"]
  32340f36_d7fb_913d_0253_43b61c3f0b73 -->|calls| 32340f36_d7fb_913d_0253_43b61c3f0b73
  6ac405fd_5160_74ca_d2a3_72428bbea335["close()"]
  32340f36_d7fb_913d_0253_43b61c3f0b73 -->|calls| 6ac405fd_5160_74ca_d2a3_72428bbea335
  e9426db7_ce58_59db_1f0b_befb5eb1d7ae["parse()"]
  32340f36_d7fb_913d_0253_43b61c3f0b73 -->|calls| e9426db7_ce58_59db_1f0b_befb5eb1d7ae
  style 32340f36_d7fb_913d_0253_43b61c3f0b73 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/core/langchain_core/output_parsers/xml.py lines 260–267

    async def _atransform(
        self, input: AsyncIterator[str | BaseMessage]
    ) -> AsyncIterator[AddableDict]:
        streaming_parser = _StreamingParser(self.parser)
        async for chunk in input:
            for output in streaming_parser.parse(chunk):
                yield output
        streaming_parser.close()

Domain

Subdomains

Called By

Frequently Asked Questions

What does _atransform() do?
_atransform() is a function in the langchain codebase, defined in libs/core/langchain_core/output_parsers/xml.py.
Where is _atransform() defined?
_atransform() is defined in libs/core/langchain_core/output_parsers/xml.py at line 260.
What does _atransform() call?
_atransform() calls 3 function(s): _atransform, close, parse.
What calls _atransform()?
_atransform() is called by 1 function(s): _atransform.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free