Skip to main content
This command-line assistant keeps conversation history in a named thread. Install and configure Marvin first.
Restarting with the same thread ID and database resumes the history. Use a distinct thread ID for each conversation in an application. The agent can refer to earlier messages in this thread. For facts that should be searchable across conversations, attach a memory with a persistent provider. A thread is enough for this example; the default vector-memory provider is ephemeral. To expose external data, add a real Python function to the agent’s tools. A prompt that asks for current weather or web research does not provide access to those sources. For async applications, use await assistant.say_async(message, thread=thread).