Home / Function/ mset() — langchain Function Reference

mset() — langchain Function Reference

Architecture documentation for the mset() function in file_system.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  3a0a7a2c_34bc_b7f9_16d1_67eec3706628["mset()"]
  26189a3b_3a87_0b57_a7a3_341b06895b61["LocalFileStore"]
  3a0a7a2c_34bc_b7f9_16d1_67eec3706628 -->|defined in| 26189a3b_3a87_0b57_a7a3_341b06895b61
  60db82b3_b672_7a32_40bd_32b87d30a271["_get_full_path()"]
  3a0a7a2c_34bc_b7f9_16d1_67eec3706628 -->|calls| 60db82b3_b672_7a32_40bd_32b87d30a271
  83113a73_3791_1847_70bf_78cc40d77ca4["_mkdir_for_store()"]
  3a0a7a2c_34bc_b7f9_16d1_67eec3706628 -->|calls| 83113a73_3791_1847_70bf_78cc40d77ca4
  style 3a0a7a2c_34bc_b7f9_16d1_67eec3706628 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/langchain/langchain_classic/storage/file_system.py lines 127–138

    def mset(self, key_value_pairs: Sequence[tuple[str, bytes]]) -> None:
        """Set the values for the given keys.

        Args:
            key_value_pairs: A sequence of key-value pairs.
        """
        for key, value in key_value_pairs:
            full_path = self._get_full_path(key)
            self._mkdir_for_store(full_path.parent)
            full_path.write_bytes(value)
            if self.chmod_file is not None:
                full_path.chmod(self.chmod_file)

Domain

Subdomains

Frequently Asked Questions

What does mset() do?
mset() is a function in the langchain codebase, defined in libs/langchain/langchain_classic/storage/file_system.py.
Where is mset() defined?
mset() is defined in libs/langchain/langchain_classic/storage/file_system.py at line 127.
What does mset() call?
mset() calls 2 function(s): _get_full_path, _mkdir_for_store.

Analyze Your Own Codebase

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

Try Supermodel Free