Skip to main contentü¶úÔ∏èüîó LangChainDocsUse casesIntegrationsAPICommunityChat our docsLangSmithJS/TS DocsSearchCTRLKProvidersAnthropicAWSGoogleMicrosoftOpenAIMoreComponentsLLMsChat modelsDocument loadersDocument transformersText embedding modelsVector storesRetrieversToolsAgents and toolkitsMemoryCallbacksChat loadersDiscordFacebook MessengerGMailiMessageFine-Tuning on LangSmith Chat DatasetsFine-Tuning on LangSmith LLM RunsSlacktelegramTwitter (via Apify)WeChatWhatsAppComponentsChat loadersDiscordOn this pageDiscordThis notebook shows how to create your own chat loader that works on copy-pasted messages (from dms) to a list of LangChain messages.The process has four steps:Create the chat .txt file by copying chats from the Discord app and pasting them in a file on your local computerCopy the chat loader definition from below to a local file.Initialize the DiscordChatLoader with the file path pointed to the text file.Call loader.load() (or loader.lazy_load()) to perform the conversion.1. Create message dump‚ÄãCurrently (2023/08/23) this loader only supports .txt files in the format generated by copying messages in the app to your clipboard and pasting in a file. Below is an example.discord_chats.txttalkingtower ‚Äî 08/15/2023 11:10 AMLove music! Do you like jazz?reporterbob ‚Äî 08/15/2023 9:27 PMYes! Jazz is fantastic. Ever heard this one?WebsiteListen to classic jazz track...talkingtower ‚Äî Yesterday at 5:03 AMIndeed! Great choice. üé∑reporterbob ‚Äî Yesterday at 5:23 AMThanks! How about some virtual sightseeing?WebsiteVirtual tour of famous landmarks...talkingtower ‚Äî Today at 2:38 PMSounds fun! Let's explore.reporterbob ‚Äî Today at 2:56 PMEnjoy the tour! See you around.talkingtower ‚Äî Today at 3:00 PMThank you! Goodbye! üëãreporterbob ‚Äî Today at 3:02 PMFarewell! Happy exploring.2. Define chat loader‚ÄãLangChain currently does not support import loggingimport refrom typing import Iterator, Listfrom langchain.schema import BaseMessage,
This notebook shows how to create your own chat loader that works on copy-pasted messages (from dms) to a list of LangChain messages.
This notebook shows how to create your own chat loader that works on copy-pasted messages (from dms) to a list of LangChain messages. ->: Skip to main contentü¶úÔ∏èüîó LangChainDocsUse casesIntegrationsAPICommunityChat our docsLangSmithJS/TS DocsSearchCTRLKProvidersAnthropicAWSGoogleMicrosoftOpenAIMoreComponentsLLMsChat modelsDocument loadersDocument transformersText embedding modelsVector storesRetrieversToolsAgents and toolkitsMemoryCallbacksChat loadersDiscordFacebook MessengerGMailiMessageFine-Tuning on LangSmith Chat DatasetsFine-Tuning on LangSmith LLM RunsSlacktelegramTwitter (via Apify)WeChatWhatsAppComponentsChat loadersDiscordOn this pageDiscordThis notebook shows how to create your own chat loader that works on copy-pasted messages (from dms) to a list of LangChain messages.The process has four steps:Create the chat .txt file by copying chats from the Discord app and pasting them in a file on your local computerCopy the chat loader definition from below to a local file.Initialize the DiscordChatLoader with the file path pointed to the text file.Call loader.load() (or loader.lazy_load()) to perform the conversion.1. Create message dump‚ÄãCurrently (2023/08/23) this loader only supports .txt files in the format generated by copying messages in the app to your clipboard and pasting in a file. Below is an example.discord_chats.txttalkingtower ‚Äî 08/15/2023 11:10 AMLove music! Do you like jazz?reporterbob ‚Äî 08/15/2023 9:27 PMYes! Jazz is fantastic. Ever heard this one?WebsiteListen to classic jazz track...talkingtower ‚Äî Yesterday at 5:03 AMIndeed! Great choice. üé∑reporterbob ‚Äî Yesterday at 5:23 AMThanks! How about some virtual sightseeing?WebsiteVirtual tour of famous landmarks...talkingtower ‚Äî Today at 2:38 PMSounds fun! Let's explore.reporterbob ‚Äî Today at 2:56 PMEnjoy the tour! See you around.talkingtower ‚Äî Today at 3:00 PMThank you! Goodbye! üëãreporterbob ‚Äî Today at 3:02 PMFarewell! Happy exploring.2. Define chat loader‚ÄãLangChain currently does not support import loggingimport refrom typing import Iterator, Listfrom langchain.schema import BaseMessage,