🧵1/8 Here is how to build a pipeline that automates the process of creating, researching, improving & finalizing an article on any topic. I used #langchain & @OpenAI, Google Search and Google News API! Let's dive in!👇
🧵2/8 The pipeline starts by loading news articles on a chosen topic. In our example it is "Canada budget". It then creates a summary of these articles, which will be used as the basis for our first draft.
🧵3/8 The first draft is generated by using custom author and question chains in a sequential manner. The author chain creates a coherent narrative, while the question chain generates relevant questions to research further. #langchain #OpenAI
🧵4/8 After generating the first draft, it's time to find answers to the questions raised. The pipeline leverages Google searches to obtain relevant information for these questions.
🧵5/8 With the answers in hand, the extra information is added to the initial draft. This forms a more comprehensive article with a wider range of insights. #ContentCreation
🧵6/8 To polish the content further, the pipeline uses custom writer and editor chains sequentially. The writer chain adds depth to the article, while the editor chain refines the content, structure and format. #AIWriting
🧵7/8 Finally, the pipeline outputs both a final draft and a completed article. The final draft contains all the revisions and improvements, while the final article is ready to be published. #Automation
🧵8/8 By combining #langchain, @OpenAI, and Google Search API, this pipeline streamlines the process of generating high-quality articles on any topic. For example we are able to transform "Canada budget" query into the following .md file:
p.s. Liked this thread?
Please subscribe for more awesome content like this. 💪✅
Many have reached out to me about the full source code for the pipeline. Its quite messy but its works.
🥲
github.com/olliethedev/au…
Share this Scrolly Tale with your friends.
A Scrolly Tale is a new way to read Twitter threads with a more visually immersive experience.
Discover more beautiful Scrolly Tales like this.
