A Guide to Leveraging BERT for Extractive Text Summarization on Lectures
A technical guide to using BERT for extractive summarization on lectures that outperforms other NLP models
As the marketing copy generation space was heating up, keap.com was looking to build an Ai product that allows users of their platform to create a huge variety of marketing “plays” that use generative ai to generate the copy to move customer through an automated workflow such as follow up sequences, lead magnet sequences, new customer welcomes, and much more.
Keap.com wanted these features to be different from the standard ones you see in other ai marketing copy products. They wanted the features to be niched into specific workflows instead of generic “email generators” or “social media post” that use simple GPT-3 models. These features are specific to plays and workflows that can generate niched pieces of the puzzle such as product benefits generators, upsell offers, product focused testimonial requests and more. The output is “plays” that are made up of these niched features and models that automate unique marketing funnels. As we’ve talked about before in articles like our CTA generator, niching these models makes for more accurate customer generations and reduces lag between what a customer thinks the correct output should be for a given step, and what is actually produced.
Width.ai built 17 generative ai pipelines for use in the Keap.com marketing copy generation product. These are used throughout the plays and are the backbone of creating these workflows. We focused on building highly creative models that generate jaw-dropping and unique copy that looks and performs much better than generic ai copy generators.
The pipelines focus on being able to understand the goal output of a given input set through fine-tuning and dynamic data that gives the pipeline an idea of relevant outputs that contain a high level of uniqueness and variance. This powerful combination general tuning to better understand a wide range of variance for our task but be able to generate extremely unique outputs for common use cases.
This concept makes adding differentiation between variables much easier that leads to the outputs having more variety. The generated copy is completely different for an age variable set to 50-75 and 18-34. This is the level of variability your outputs can have when refining generative ai to focus on specific domains (like this article).
We deployed state of the art knowledge on understanding and leveraging the combination of log probabilities and token level semantic relevance to maximize the variation and “uniqueness” of outputs while following a learned relationship based structured format. This build came from SOTA research at the time plus existing knowledge we had of how to maximize a similar workflow.
We built data management pipelines that allow you to easily incorporate real in-context user runs of your product into the ML model training process. This use of actual user data is a great way to start steering your generative ai outputs towards what your customers consider a good result.
The prompt engineering and design experts at Width.ai handcrafted powerful prompts for each of these generative ai systems. We focused on building prompts that cover as much data variance as possible before ever relying on fine-tuning our model. The goal of this process is to prove out the system's ability to rely on the prompt structure to generate high quality responses on edge cases that fine-tuning is unable to cover.
We’ve built a number of custom ai marketing copy generators for different companies with various model use cases. The above architecture outline comes from our most recent work in this space focused on generating CTAs in a pipeline that can auto optimize over time based on conversion metrics. This is an extension of our standard generative ai architecture that allows customers to get super refined outputs for their marketing copy generations. Let’s look at a quick overview of the parts of the pipeline we build to end up with a production pipeline for ai marketing copy generation.
What inputs we choose and how we structure our inputs to the models is a huge part of how we reach accurate marketing copy generations that users love. These LLMs are pretty much just a language API that tries to complete a task based on prompt instructions and any other knowledge that is provided (prompt examples/variables/fine-tuning). The work done upstream to build the prompt that contains our inputs is the real equation in production generative ai systems.
We spend a ton of time choosing input variables such as product name, marketing piece type, and copy tone that maximize the quality of the outputs for the specific marketing copy generation operation. With those variables we then focus on how we structure our prompts to best leverage the key fields that guide the model the most towards a correct output. This is also the step in the process where we can handle any extraction of text from URLs or images for additional fields.
We built a custom module focused on transforming these raw text inputs into a structured format for our GPT-3 prompt. This structured format is built during the early stages of our prompt engineering where we use concepts like “Hard prompts made easy” to build powerful prompts that guide our model towards a deep understanding of the variables we just provided. This module just focuses on the input variable part of our prompt.
One of the key preprocess steps covered here is our ability to create “tags” that wrap around specific lines of text in the input variables. These tags provide the underlying LLM with a bit more contextual information about what keywords or phrases are extra meaningful to the outputs.
In low data environments or environments trying to create a very specific and niched output such as a “per industry” or “per user” output, prompt design and iterating the quality of the prompt is the most important part of our process. This is what allows us to generate outputs with high variance between different variables and generate copy that much better follows the examples we provided. This is the difference between generating high quality marketing copy that fits specifically your use case and generalized copy you see from the leading products.
Token sequencing is a huge part of any large language model. We even spend time optimizing the order of our variables in the prompt to promote more important variables to the instructions. We can use the natural biases towards tokens being at the beginning or end of our prompt to our advantage to put more emphasis on specific variables.
Dynamic prompt optimization frameworks are trained algorithms we build with the goal of dynamically building our prompt at runtime for each unique input that is provided to maximize the optimization available and the model's understanding of our task. This allows us to go from static prompts that will struggle with edge cases and general data variance coverage to a more flexible system that covers wide data variance much better. These algorithms work upstream to the actual LLM and build the prompt for us.
Here’s a few common issues that you run into with prompt based LLMs that prompt optimization fixes:
With users running the ai marketing copy generator you can store information about the variables they provided and the outputs that were generated to make further optimizations and training easier. By storing data such as the inputs, prompts, and generated outputs you can quickly turn it into a fine-tuning dataset for GPT-3 or other LLMs you might want to leverage.
Considering the format for fine-tuning GPT-3 is a single prompt and completion this makes taking our stored prompts and user generated outputs and turning them into a training set much easier. Fine-tuning is going to allow you to show these task agnostic models how to refine into your specific task and generate outputs that your users consider high quality, instead of what the base model considers high quality based on your prompt instructions.
Model parameters available for large language models are one of the best ways to refine the levels of creativity and boundaries your copy generations can have. These parameters essentially take the most deterministic copy generation available and allow you to decide how much you want it to venture away from the highest probability output.
Temperature is the most common parameter adjusted to affect the levels of creativity you allow your model to use. Temperature decides how often lower probability tokens are used in the output. Lower probability tokens are generally more random and more “unique” based on a baseline idea of what the goal output GPT-3 thinks is correct.
GPT-3 predicts the most probable next token in a sequence and as we can see above, we can review the tokens that had a lower probability. Leveraging these tokens instead of the most probable are a great way to increase uniqueness in your generated copy and ensure your copy is different for each user.
Width.ai builds customer NLP and CV software for everyone from Fortune 50 to pre-funding startups. We’ve the leading experts in GPT-3 and other LLMs and have been building production level products with these exact tools since 2020. Schedule a call today with our “Contact Us” page to learn more about how we can build your own marketing copy generator.
A technical guide to using BERT for extractive summarization on lectures that outperforms other NLP models
Discover how prompt based LLMs like GPT-3 & GPT-4 are transforming news summarization with its zero-shot capabilities and adaptability to specialized tasks like keyword-based summarization. Learn about the limitations of current evaluation metrics and the potential future directions in text summarization research.
Discover the PEZ method for learning hard prompts through optimization, a powerful technique that enhances generative models for image generation and language tasks, improves transferability, and enables few-shot learning
A deep look at how recurrent feature reasoning outperforms other image inpainting methods for difficult use cases and popular datasets.
See a comparison of GPT-3 vs. GPT-J, a self-hosted, customizable, open-source transformer-based large language model you can use for your business workflows.
Discover how transformer networks are revolutionizing image and video segmentation, and get insights on modern semantic segmentation vs. instance segmentation.
Discover how the state-of-the-art mask-aware transformer produces visually stunning and semantically meaningful images and how it stacks up against Stable Diffusion & DALL-E for large-hole inpainting
Unlock the full potential of spaCy with this guide to building production-grade text classification pipelines for business data.
We compare 12 AI text summarization models through a series of tests to see how BART text summarization holds up against GPT-3, PEGASUS, and more.
Let’s take a look at what intent classification is in conversational ai and how you can build a GPT-3 intent classification model for conversational ai and chatbot pipelines.
Discover the capabilities of zero-shot object detection, which enables anyone to use a model out-of-the-box without any training and generate production-grade results.
What is facial expression recognition and what SOTA models are being used today in production
Get a simple TensorFlow facial recognition model up & running quickly with this tutorial aimed at using it in your personal spaces on smartphones & IoT devices.
Explore accurate classification algorithms using the latest innovations in deep learning, computer vision, and natural language processing.
Learn what human activity recognition means, how it works, and how it’s implemented in various industries using the latest advances in artificial intelligence.
What is the the SetFit architecture and how does it outperform GPT-3 and other few shot large language models
What is image classification and how we build production level TensorFlow image classification systems for recognizing various products on a retail shelf.
Explore the application of intelligent document processing (IDP) in different industries and dive in-depth on intelligent document pipelines.
How to build an image classification model in PyTorch with a real world use case. How you can perform product recognition with image classification
Let's build a custom CTA generator that you'll actually want to use for your website copy
We’re going to look at how we built a state of the art NLP pipeline for blended summarization and NER to process master service agreements (MDAs) that vary the outputs based on the input document and what is deemed important information.
Get a comprehensive overview of a purchase order vs. invoice, including when businesses use each, what information goes in them, and more.
Learn what Google Shopping categories are used for and how you can automate fitting products to this taxonomy using ai.
Automatically categorize your Shopify store products to the Shopify Product Taxonomy instantly with ai based PIM software
Dive deep into 3-way invoice matching, including how it works, eight benefits for your business, and the problems with doing it manually.
Smart farming using computer vision and deep learning provides the most promising path forward in the slow-moving industry of agriculture.
How we leveraged large language models to build a legal clause rewriting pipeline that generates stronger language and more clarity in legal clauses
Using ai for document information extraction to automate various parts of the loan process.
Apply AI to your favorite sport with this guide. Learn how automated ball tracking can change the game for coaches and players.
Categorize your ecommerce products to the 2021 google product taxonomy tree instantly with our Ai software
Surveying the current landscape of ecommerce automation and how you can use ai to automate huge chunks of your product management.
Classify your product data against an existing product category database or generate categories and tags in seconds using artificial intelligence
Warehouse automation plays a crucial role across your supply chain. Learn about how machine learning and ai software can be integrated into your warehouse automation stack.
4 different NLP methods of summarizing longer input text into different methods such as extractive, abstractive, and blended summarization
iscover an invoice OCR tool that will revolutionize the way you handle invoices. There’s no human intervention needed & a dramatically lower per-invoice cost.
Instead of invoice matching taking upwards of a week, it could take mere seconds with the proper automation solution. Learn more here.
Manual and template-based invoicing are riddled with low accuracy and required human intervention. Learn how to systematically eliminate these issues with the right invoice data capture software.
A complete walkthrough guide on how to use visual search in ecommerce stores to create more sales and real examples of companies already using it.
Automating the extraction of data from invoices can reduce the stress of your accountants by finding inaccuracies, digitizing paper invoices, and more.
How you can use machine learning based data matching to compare data features in a scalable architecture for deduping, record merging, and operational efficiency
Learn how lifetime value or LTV prediction can improve your marketing strategies. Then, discover the best statistical & machine learning models for your predictions.
A deep understanding of how we use gpt-3 and other NLP processes to build flexible chatbot architectures that can handle negotiation, multiple conversation turns, and multiple sales tactics to increase conversions.
The popular HR company O.C. Tanner, which has been in business since 1927 and has over 1500 employees, was looking to research and design two GPT-3 software products to be used as internal tools with their clients. GPT-3 based products can be difficult to outline and design given the sheer lack of publicly available information around optimizing and improving these systems to a production level.
We’ll compare Tableau vs QlikView in terms of popularity, integrations, ease of use, performance, security, customization, and more.
With a context-aware recommender system, you can plan ways to recreate some of the contextual conditions that persuade them to buy more from you.
We’re going to walk through building a production level twitter sentiment analysis classifier using GPT-3 with the popular tweet dataset Sentiment140.
Find out how machine learning in medical imaging is transforming the healthcare world and making it more efficient with three use cases.
Discover ways that machine learning in health care informatics has become indispensable. Review the results of two case studies and consider two key challenges.
Accelerate your growth by pivoting key areas of your business to AI. Your business outcomes will be achieved quicker & you’ll see benefits you didn’t plan for.
We built a GPT-3 based software solution to automate raw data processing and data classification. Our model handles keyword extraction, named entity recognition, text classification | Case Study
We built a custom GPT-3 pipeline for key topic extraction for an asset management company that can be used across the financial domain | Case Study
How you can use GPT-3 to create higher order product categorization and product tagging from your ecommerce listings, and how you can create a powerful product taxonomy system with ai.
5 ways you can use product matching software in ecommerce to create real value that raises your sales metrics and improves your workflow operations.
Data mining and machine learning in cybersecurity enable businesses to ensure an acceptable level of data security 24/7 in highly dynamic IT environments. Learn how data security is getting increasingly automated.
Product recognition software has tremendous potential to improve your profits and slash your costs in your retail business. Find out just how useful it is.
Big data has evolved from hype to a crucial part of scaling your organization in every modern industry. Learn more about how big data is transforming organizations and providing business impacts.
Learn how natural language processing can benefit everybody involved in education from individual students and teachers to entire universities and mass testing agencies.
Here’s how automated data capture systems can benefit your business in some key ways and some real-life examples of what it looks like in practice.
Use these power ai and machine learning tools to create business intelligence in your marketing that pushes your business understanding and analytics past your competition.
We built a custom ML pipeline to automate information extraction and fine tuned it for the legal document domain.
In this practical guide, you'll get to know the principles, architectures, and technologies used for building a data lake implementation.
Find out how machine learning in biology is accelerating research and innovation in the areas of cancer treatment, medical devices, and more.
An enterprise data warehouse (EDW) is a repository of big data for an enterprise. It’s almost exclusive to business and houses a very specific type of data.
Dlib is a versatile and well-diffused facial recognition library, with perhaps an ideal balance of resource usage, accuracy and latency, suited for real-time face recognition in mobile app development. It's becoming a common and possibly even essential library in the facial recognition landscape, and, even in the face of more recent contenders, is a strong candidate for your computer vision and facial recognition or detection framework.
Learn how to utilize machine learning to get a higher customer retention rate with this step-by-step guide to a churn prediction model.
Machine learning algorithms are helping the oil and gas industry cut costs and improve efficiency. We'll show you how.
We’ll show you the difference between machine learning vs. data mining so you know how to implement them in your organization.
Here’s why you should use deep learning algorithms in your business, along with some real-world examples to help you see the potential.
Beam search is an algorithm used in many NLP and speech recognition models as a final decision making layer to choose the best output given target variables like maximum probability or next output character.
Best Place For was looking for an image recognition based software solution that could be used to detect and identify different food dishes, drinks, and menu items in images sourced from blogs and Instagram. The images would be pulled from restaurant locations on Instagram and different menu items would be identified in the images. This software solution has to be able to handle high and low quality images and still perform at the highest production level, while accounting for runtime as well as accuracy.
Deep learning recommendation system architectures make use of multiple simpler approaches in order to remediate the shortcomings of any single approach to extracting, transforming and vectorizing a large corpus of data into a useful recommendation for an end user.
Let's take a look at the architecture used to build neural collaborative filtering algorithms for recommendation systems
GPT-3 is one of the most versatile and transformative components that you can include in your framework, application or service. However, sensational headlines have obscured its wide range of capabilities since its launch. Let’s take a look at the ways that companies and researchers are achieving real-world results with GPT-3, and examine the untapped potential of this 'celebrity AI'.
How to get started with machine learning based dynamic pricing algorithms for price optimization and revenue management
Let's take a look at how you can use spaCy, a state of the art natural language processing tool, to build custom software tools for your business that increase ROI and give you data insights your competitors wish they had.
The landscape for AI in ecommerce has changed a lot recently. Some of the most popular products and approaches have been compromised or undermined in a very short time by a new global impetus for privacy reform, and by the way that the COVID-19 pandemic has transformed the nature of retail.
Extremely High ROI Computer Vision Applications Examples Across Different Industries
Building Data Capture Services To Collect High ROI Business Data With Machine Learning and AI
Software packages and Inventory Data tools that you definitely need for all automated warehouse solutions
Inventory automation with computer vision - how to use computer vision in online retail to automate backend inventory processes