Thread
Using the with statement
If you prefer to have more flexibility in logging Threads, you can use the with statement. You can create a thread and execute code within it using the with statement:
thread method:
Using the Literal AI API client
You can also create Threads using theliteralai_client.api.create_thread() method.