LLM Caption
This CLI script creates caption files for all images of a folder. Its saves captions with the same name of the image with txt extension.
Installation
mkdir venv
python3 -m venv ./venv
source venv/bin/activate
pip install -r requirements.txt
Dependencies
Google SigLIP (3.5GB) will be downloaded automatically from https://huggingface.co/google/siglip-so400m-patch14-384 Uncensored LEXI LAMA Llama-3.1-8b-Instruct (5.5GB) will be downloaded automatically from https://huggingface.co/John6666/Llama-3.1-8B-Lexi-Uncensored-V2-nf4 The Joy Caption model is on the checkpoint folder
Usage
python3 ./caption.py ./test \
--prompt "Describe this image in detail within 50 words."
python3 ./caption.py ./test
Default prompt
In one paragraph, write a very descriptive caption for this image, describe all objects, characters and their actions, describe in detail what is happening and their emotions. Include information about lighting, the style of this image and information about camera angle within 200 words. Don't create any title for the image.