langchain-cn-models
LangChain CN Models
Help developers write LangChain integration classes for a specified Chinese model (e.g., Qwen, GLM, DeepSeek, Moonshot) using the OpenAI-compatible interface.
[!CAUTION] Never read, write, or access user configuration files such as
.env,.env.local,credentials.json, or any other files that may contain secrets or sensitive information. API Keys and other credentials must always be filled in by the user themselves — do not peek into or modify these files under any circumstances.
Step 1: Gather Information
First, confirm the following details with the user:
- Model Name — lowercase, e.g.,
qwen,glm,deepseek. Used for directory names, class names, and_llm_type. - API Base URL — the model's OpenAI-compatible endpoint URL.
- API Key Environment Variable Name — e.g.,
QWEN_API_KEY.
If the user does not explicitly provide any of these, use reasonable defaults.
Additionally, inspect the project directory structure to determine the Python package manager (uv.lock → uv, poetry.lock → poetry, requirements.txt → pip, etc.).