This is a Streamlit application that generates scripts based on user-provided topics using the Groq API and few-shot prompting. The application also evaluates the generated scripts using various metrics such as F1 score, precision, recall, true positives, and false positives.
- Python 3.7 or higher
- Groq API key
-
Clone the repository or download the script.
-
Install the required packages:
pip install -r requirements.txt
-
Set your Groq API key as an environment variable:
export GROQ_API_KEY="your_actual_api_key_here"
-
Save your dataset as
dataset.csv
in the same directory as the script. -
Run the Streamlit application:
streamlit run script_generator.py
-
Open the provided URL in your browser to access the application.
- Enter a topic in the input field.
- Click the "Generate Script" button.
- View the generated script and evaluation metrics.
streamlit
pandas
scikit-learn
groq
fpdf
To generate a script for the topic "content creation":
- Enter "content creation" in the input field.
- Click "Generate Script".
- View the generated script and evaluation metrics.
This project is licensed under the MIT License.