mirror of
https://github.com/langchain-ai/langchain.git
synced 2026-10-05 01:15:09 +03:00
docs(langchain): clarify model ID usage for reliable behavior (#34718)
Clarify the preference for using exact model IDs from provider documentation over aliases to ensure reliable behavior in face of upstream backend changes.
This commit is contained in:
1 parent
6bcc4a1af1
commit
1dc2600cd4
1 file changed
+3
@@ -220,6 +220,9 @@ def init_chat_model(
|
||||
Args:
|
||||
model: The model name, optionally prefixed with provider (e.g., `'openai:gpt-4o'`).
|
||||
|
||||
Prefer exact model IDs from provider docs over aliases for reliable behavior
|
||||
(e.g., dated versions like `'...-20250514'` instead of `'...-latest'`).
|
||||
|
||||
Will attempt to infer `model_provider` from model if not specified.
|
||||
|
||||
The following providers will be inferred based on these model prefixes:
|
||||
|
||||
Reference in new issue
Block a user