langsmith.utils.ContextThreadPoolExecutor#
- class langsmith.utils.ContextThreadPoolExecutor(max_workers=None, thread_name_prefix='', initializer=None, initargs=())[source]#
ThreadPoolExecutor that copies the context to the child thread.
Initializes a new ThreadPoolExecutor instance.
- Parameters:
max_workers – The maximum number of threads that can be used to execute the given calls.
thread_name_prefix – An optional name prefix to give our threads.
initializer – A callable used to initialize worker threads.
initargs – A tuple of arguments to pass to the initializer.