This commit is contained in:
Dane Sabo 2025-02-19 23:09:14 -05:00
parent bdd945fb5f
commit 878606c9c5

View File

@ -124,9 +124,10 @@ for dir in "${dirs[@]}"; do
# Query LLM for Summary
#################
prompt="Based on the following table of contents, provide a short summary description of what this directory is about:
$(cat "$tmp_static")"
$(cat "$tmp_static"). This will go into a readme file and be read as a descriptor. Thank you!"
# Query the model using the Ollama CLI with the llama3.2:latest model.
summary=$(ollama run llama3.2:1b "$prompt")
echo "Creating summary..."
# Build the full new content: static portion + summary section.
{
@ -134,6 +135,7 @@ $(cat "$tmp_static")"
echo "## Summary"
echo "$summary"
echo ""
echo "Generated by llama3.2:1b"
} > "$readme"
rm "$tmp_static"