chore(openrouter): update URL/title (#36204)

This commit is contained in:
Mason Daugherty
2026-03-24 21:11:46 -04:00
committed by GitHub
parent d22df94537
commit 839f1df333
4 changed files with 409 additions and 373 deletions

View File

@@ -7,8 +7,8 @@
'ChatOpenRouter',
]),
'kwargs': dict({
'app_title': 'langchain',
'app_url': 'https://docs.langchain.com/oss',
'app_title': 'LangChain',
'app_url': 'https://docs.langchain.com',
'max_retries': 2,
'max_tokens': 100,
'model_name': 'openai/gpt-4o-mini',

View File

@@ -320,8 +320,8 @@ class TestChatOpenRouterInstantiation:
api_key=SecretStr("test-key"),
)
call_kwargs = mock_cls.call_args[1]
assert call_kwargs["http_referer"] == ("https://docs.langchain.com/oss")
assert call_kwargs["x_title"] == "langchain"
assert call_kwargs["http_referer"] == ("https://docs.langchain.com")
assert call_kwargs["x_title"] == "LangChain"
def test_user_attribution_overrides_defaults(self) -> None:
"""Test that user-supplied attribution overrides the defaults."""