CoolFace
Apppublic

Agents-MCP-Hackathon/3D-Game-Environment-Builder

sourceHugging Facemitupdated 1y agoView on Hugging Face
11likes
App README

Hackathon team members

  • castlebbs@
  • stargarnet@
  • zinkenite@

Demo videos

  • Youtube video: https://www.youtube.com/watch?v=09Dk9OL65bc
  • Recording of Gradio use: https://www.youtube.com/watch?v=JbpwDwk8IcI

🎮 3D Scene Asset Generator

Our participation to the 2025 Gradio Agent MCP Hackathon

Transform player biographies into personalized 3D environments using LLM-powered analysis and 3D asset generation models pipelines.

🌟 Project Overview

This hackathon project creates a 3D scene generator that analyzes player biographies and automatically generates personalized 3D environments. By combining the power of LLM analysis with generation models (FLUX + Trellis), we create unique, contextual 3D assets that reflect each player's personality, interests, and background.

✨ Key Features

  • 🤖 AI-Powered Analysis: LLM analyzes player biographies to understand personality and interests
  • 🎨 3D Generation: FLUX + Trellis pipeline generates high-quality, contextual 3D assets
  • 🌐 Interactive Web Interface: Gradio interface with real-time generation and examples
  • 🔧 MCP Integration: Supports Model Context Protocol for enhanced interactions
  • ⚡ Optimized Pipeline: Uses GGUF quantization and LoRA models for fast, efficient generation
  • 📱 User-Friendly: Simple input → AI analysis → 3D asset generation workflow

🏗️ Architecture

MCP Hackaton-3

Technology Stack

  • Frontend: Gradio with custom CSS styling
  • AI Analysis: Anthropic Claude Sonnet 4
  • 3D Generation: FLUX + Trellis on Modal
  • Output Format: GLB (3D models compatible with most engines)

🚀 Quick Start

Prerequisites

  • Python 3.8+
  • Anthropic API key
  • Modal account

Installation

  1. 1.Clone the repository
  1. 1.Set up the Gradio application
bash
   cd gradio
   pip install -r requirements.txt
  1. 1.Configure API keys
bash
   export ANTHROPIC_API_KEY="your-anthropic-api-key"
  1. 1.Set up Modal
bash
   modal setup
  1. 1.Deploy the Modal function
bash
   cd ../modal
   modal deploy flux-trellis-GGUF-text-to-3d.py
  1. 1.Run the application
bash
  
   python app.py

💡 Usage Example

Input Biography:

"Marcus is a tech enthusiast and gaming streamer who loves mechanical keyboards and collecting vintage arcade games. He's also a coffee connoisseur who roasts his own beans and enjoys late-night coding sessions."

Generated 3D Assets:

  • Vintage arcade cabinet with classic game artwork
  • Premium mechanical keyboard with RGB backlighting
  • Professional coffee roasting station with custom setup
  • Gaming chair with LED accents and streaming equipment
  • Retro-futuristic desk lamp with adjustable lighting

📁 Project Structure

/
│-─ app.py                     # Core application logic
│── requirements.txt           # Python dependencies
│── README.md                  # Detailed app documentation
│── images/                    # UI assets and examples
├── modal/                     # Modal cloud functions
│   ├── flux-trellis-GGUF-text-to-3d.py  # 3D generation pipeline
│   └── README.md            # Modal setup documentation
├── LICENSE                  # MIT License
└── README.md                # This file

Please note that the source code of the demo Godot application is available on GitHub: https://github.com/castlebbs/gradio-mcp-hackathon

🔧 Technical Details

AI Pipeline

  • Text Analysis: Claude Sonnet processes biographical text to extract personality traits and interests
  • Prompt Generation: AI creates detailed, contextual prompts for 3D asset generation
  • Asset Creation: FLUX + Trellis pipeline generates high-quality 3D models

Optimizations

  • GGUF Quantization: Reduces model size while maintaining quality
  • LoRA Models: Hyper FLUX 8Steps for faster inference, Game Assets LoRA for better 3D results
  • Modal Scaling: Automatic scaling for concurrent requests

🏆 Hackathon Team

  • castlebbs@
  • stargarnet@
  • zinkenite@

Built with ❤️ for the 2025 Gradio Agent MCP Hackathon

Links

  • GitHub: https://github.com/castlebbs/gradio-mcp-hackathon
  • https://huggingface.co/black-forest-labs/FLUX.1-dev
  • https://huggingface.co/microsoft/TRELLIS-image-large
  • https://huggingface.co/spaces/gokaygokay/Flux-TRELLIS Thank you to gokaygokay for the GGUF

Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference