howcase: DM Co-Pilot - An AI D&D Campaign Manager built with Streamlit, Pandas, and Groq (Llama 3.1)

Hi everyone!

I recently built a workflow automation app to help Dungeons & Dragons Game Masters cut down their weekly prep time from 4 hours to about 30 minutes.

I wanted to see how far I could push Streamlit by combining structured data visualization with lightning-fast AI inference.

The App: https://dm-copilot-app.streamlit.app/ The Repo: https://github.com/Cmccombs01/DM-Copilot-App

How I built it:

  • Data Filtering & Vis: I used @st.cache_data to load a CSV of 400+ monsters. The user slides a custom Challenge Rating filter, and Pandas instantly updates an interactive scatter plot showing Hit Points vs. Armor Class.

  • AI Integration: I integrated the Groq API (running Meta Llama 3.1) for unstructured text processing. Users paste in their messy session notes, and the AI reformats it into a clean journal entry.

  • Dynamic Assets: I used Streamlit’s native download buttons to let users export the AI-generated NPCs and Magic Items instantly to text files.

The biggest challenge was getting the prompt engineering tight enough so the AI wouldn’t break the Streamlit markdown formatting when generating tables.

I would love any feedback from this community on the code structure or UI layout!