Async Client for interacting with the LangSmith API.
| Name | Type | Description |
|---|---|---|
api_url | Optional[str] | Default: NoneURL for the LangSmith API. |
api_key | Optional[str] | Default: NoneAPI key for the LangSmith API. |
timeout_ms | Optional[Union[int, tuple[Optional[int], Optional[int], Optional[int], Optional[int]]]] | Default: None |
retry_config | Optional[Mapping[str, Any]] | Default: None |
web_url | Optional[str] | Default: None |
headers | Optional[dict[str, str]] | Default: None |
disable_prompt_cache | bool | Default: False |
cache | Optional[Union[bool, AsyncPromptCache]] | Default: None |
| Name | Type |
|---|---|
| api_url | Optional[str] |
| api_key | Optional[str] |
| timeout_ms | Optional[Union[int, tuple[Optional[int], Optional[int], Optional[int], Optional[int]]]] |
| retry_config | Optional[Mapping[str, Any]] |
| web_url | Optional[str] |
| headers | Optional[dict[str, str]] |
| disable_prompt_cache | bool |
| cache | Optional[Union[bool, AsyncPromptCache]] |
Create a new prompt.
Does not attach prompt object, just creates an empty prompt.
Pull a prompt and return it as a LangChain PromptTemplate.
This method requires langchain-core.
Timeout for requests in milliseconds.
Retry configuration.
URL for the LangSmith web app.
Additional HTTP headers to include in all requests.
These headers will be merged with the default headers (Content-Type, x-api-key, etc.). Custom headers will not override the default required headers.
Disable prompt caching for this client.
[Deprecated] Control prompt caching behavior.
This parameter is deprecated. Use configure_global_async_prompt_cache() to
configure caching, or disable_prompt_cache=True to disable it.
True: Enable caching with the global singletonFalse: Disable caching (equivalent to disable_prompt_cache=True)AsyncCache(...)/AsyncPromptCache(...): Use a custom cache instance