Home / Function/ lc_secrets() — langchain Function Reference

lc_secrets() — langchain Function Reference

Architecture documentation for the lc_secrets() function in base.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  1fccb9a1_c872_c345_1b0f_dcc9618ca884["lc_secrets()"]
  29c504f8_01a0_5f4c_3ec6_14bbf14b96eb["ChatOpenAI"]
  1fccb9a1_c872_c345_1b0f_dcc9618ca884 -->|defined in| 29c504f8_01a0_5f4c_3ec6_14bbf14b96eb
  style 1fccb9a1_c872_c345_1b0f_dcc9618ca884 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/partners/openai/langchain_openai/chat_models/base.py lines 3000–3002

    def lc_secrets(self) -> dict[str, str]:
        """Mapping of secret environment variables."""
        return {"openai_api_key": "OPENAI_API_KEY"}

Domain

Subdomains

Frequently Asked Questions

What does lc_secrets() do?
lc_secrets() is a function in the langchain codebase, defined in libs/partners/openai/langchain_openai/chat_models/base.py.
Where is lc_secrets() defined?
lc_secrets() is defined in libs/partners/openai/langchain_openai/chat_models/base.py at line 3000.

Analyze Your Own Codebase

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

Try Supermodel Free