In a previous article, I presented a comparison of DeepSeek-R1-Distill-Llama-70b with the DeepSeek-R1-Distill-Qwen-32B for text classification and summarization.
Both these models are distilled versions of the original DeepSeek R1 model. Recently, I wanted to try the original version of the DeepSeek R1 model using the DeepSeek API. However, I was not able to test it because the DeepSeek API was not allowing requesting the model due to high demand. My other option was to access the model via the Hugging Face API, but I could not run that either since it requires very high memory.
Finally, I found a solution via the FireworksAI API. Fireworks AI provides access to the DeepSeek R1
model hosted inside the United States, so you do not have to worry about sending your data to undesired locations.
In this article, you will see a comparison of the original DeepSeek R1 model with Llama 3.1-405B model for text classification and summarization.
So, let's begin without ado.
The following script installs the Fireworks Python library and the other libraries required to run scripts in this article.
!pip install --upgrade fireworks-ai
!pip install rouge-score
!pip install --upgrade openpyxl
!pip install pandas openpyxl
The script below imports the required libraries into your Python application.
You will also need the Fireworks API key to access the Fireworks API via the Python library.
from fireworks.client import Fireworks
import os
import pandas as pd
import time
from rouge_score import rouge_scorer …