Demo: Steam Print
Steam Print is a portable 3D printing companion that transforms the Steam Deck into a full voice-driven modeling and printing workstation. It lets users load and explore 3D models, issue offline voice commands, and even generate brand-new designs on the fly using AI models like gpt-oss:20b and gpt-oss:120b. With a lightweight viewer on the Steam Deck, a local backend server for AI processing, and OctoPi handling slicing and printer control, the entire processβfrom idea to printed objectβcan be managed without relying on a traditional desktop setup.
The backend server for Steam Print, powering AI-driven 3D model generation from voice commands and managing 3D printing workflows. Runs locally on your PC or a server and communicates with the Steam Deck frontend.
-
Install Ollama: https://ollama.com/download
-
Pull a lightweight dev model for testing:
ollama pull gpt-oss:20bor
ollama pull gpt-oss:120b- Create Python virtual environment & install dependencies
python -m venv .venv
source .venv/bin/activate # Windows: ./venv/Scripts/activate
pip install -r requirements.txt- (Optional) Install Vosk model for offline speech-to-text
-
Download a Vosk model (e.g., vosk-model-small-en-us-0.15) from Vosk Models
If skipped, the backend will accept typed input from the Steam Deck UI.
- Add .env file Modify a .env file in the project root accordingly:
# AI Model to use with Ollama
MODEL_NAME=gpt-oss:20b
LLM_SERVER=http://192.168.0.67:5000
# Optional: Path to Vosk STT model folder
VOSK_MODEL_PATH=./vosk-model-small-en-us-0.15
# OCR path (if using text from images)
TESSERACT_PATH=C:\Program Files\Tesseract-OCR\tesseract.exe
# File server for STL transfer
FILE_SERVER=http://192.168.0.67:5000/files/
# Steam Deck connection details
STEAMDECK_USER=deck
STEAMDECK_IP=192.168.0.66
STEAMDECK_CURA_DIR=/home/deck/CuraIncoming
# OpenSCAD path for 3D model processing
OPENSCAD_PATH=C:\Program Files\OpenSCAD\openscad.exe
- You can swap MODEL_NAME between gpt-oss:20b and gpt-oss:120b to easily switch LLMs for speed vs. capability.
python -m backend.server- The server will listen for voice/text commands from the Steam Deck frontend.
- It dynamically generates STL models using the selected LLM.
- Generated models are returned to the Steam Deck app for viewing, slicing, and sending to OctoPi.
- Setup Raspberry Pi with OctoPi
- Install OctoPi on a Raspberry Pi connected to your 3D printer.
- Ensure your Steam Deck or backend server can reach the Pi via network.
- Use the Steam Print frontendβs Slice and Send button to send models directly to OctoPi.
- Optionally, connect a camera module to monitor prints.
- On the octopi.local webserver, make sure to install the plugin OctoPrint-Slic3r to allow for slicing directly on your raspberrypi. That way you can still game on your steam deck at full performance while the the model is slicing.
A lightweight STL viewer with AI voice interface, optimized for Steam Deck and Linux desktops.
- 3D STL Viewing: Interactive 3D viewer with rotate, pan, and zoom controls
- Voice Commands: Offline speech-to-text using vosk for AI interactions
- Touch-Friendly UI: Optimized for Steam Deck's touchscreen and controls
- Lightweight: Minimal dependencies, fast startup
- Extensible: Modular architecture for future features
- Python 3.8+
- Linux (tested on Steam Deck/Arch Linux)
- Audio input device (microphone)
- OpenGL support
# Clone the repository
git clone <repository-url>
cd frontend
# Install dependencies
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
# Run the application
bash run.sh# Install PyInstaller
pip install pyinstaller
# Create bundled executable
pyinstaller --onefile --windowed \
--add-data "ui:ui" \
--add-data "voice:voice" \
--add-data "utils:utils" \
--hidden-import trimesh \
--hidden-import vosk \
--hidden-import sounddevice \
main.py
# The executable will be in dist/main
./dist/main- Load STL File: Click "π Load Model" to browse and load STL files
- Voice Commands: Click "π€ Speak" to record voice commands (8 seconds)
- 3D Navigation:
- Mouse drag: Rotate view
- Mouse wheel: Zoom in/out
- Press 'R': Reset view
- "Load model" - Open file dialog
- "Rotate left/right" - Rotate current model
- "Scale up/down" - Resize model
- "Export model" - Save current model
- "Send to printer" - Forward to OctoPrint
stl-viewer-ai/
βββ main.py # Application entry point
βββ requirements.txt # Python dependencies
βββ setup.py # Package configuration
βββ ui/ # User interface modules
β βββ main_window.py # Main application window
β βββ control_panel.py # Left control panel
β βββ stl_viewer.py # 3D STL viewer widget
βββ voice/ # Voice input handling
β βββ voice_handler.py # Speech-to-text processing
βββ utils/ # Utility modules
βββ config.py # Configuration constants
βββ stl_utils.py # STL file operations
- PySide6: Cross-platform GUI framework
- trimesh: 3D mesh processing and loading
- OpenGL: Hardware-accelerated 3D rendering
- vosk: Offline speech recognition
- SoundDevice: Audio input/output
The application uses utils/config.py to manage its configuration. Key settings include:
HOME_DIR: User home directoryTEMP_DIR: Temporary working directory for STL ViewerMODELS_DIR: Folder for downloaded 3D modelsCACHE_DIR: Cache for application data
VOICE_RECORD_DURATION: Default recording duration (seconds)VOICE_SAMPLE_RATE: Sample rate for audio inputVOICE_CHANNELS: Number of audio channels (1 = mono)VOSK_MODEL_SIZE: Name/size of the offline speech-to-text model
LLM_SERVER: URL of the backend server handling AI model requestsFILE_SERVER: URL to send/receive STL filesLOCAL_STL_DIR: Directory on Steam Deck where STL files are stored
OCTOPI_URL: Address of OctoPi server connected to your 3D printerOCTOPI_API_KEY: API key for authenticating with OctoPi
WINDOW_MIN_WIDTH/WINDOW_MIN_HEIGHT: Minimum application window sizePANEL_MIN_WIDTH: Minimum width of control panelDEFAULT_BACKGROUND_COLOR: Background color of the 3D viewer (RGBA)DEFAULT_MESH_COLOR: Default color for loaded meshes (RGBA)
These constants control the behavior of the STL Viewer AI application, including audio capture, 3D rendering, file handling, server connections, and printer integration.
If voice input doesn't work:
# Check audio devices
arecord -l
# Test microphone
arecord -d 5 test.wav
aplay test.wav# Install system packages (Arch Linux/Steam Deck)
sudo pacman -S portaudio python-sounddevice
# Ubuntu/Debian
sudo apt-get install portaudio19-dev python3-sounddevice# Check OpenGL support
glxinfo | grep "OpenGL version"
# Install OpenGL libraries if needed
sudo pacman -S mesa mesa-utils # Arch Linux
sudo apt-get install mesa-utils # Ubuntu/Debian- OctoPrint Integration: Send models directly to 3D printer
- Basic Slicing: Preview layer cross-sections
- Model Editing: Scale, rotate, repair operations
- Cloud Integration: Fetch models from online repositories
- Print Settings: Configure slicing parameters
- Multiple File Formats: Support OBJ, PLY, 3MF
The app is designed to integrate with a Flask server for AI-powered model generation:
def send_to_server(voice_text: str) -> str:
"""Send voice command to AI server"""
response = requests.post("http://localhost:5000/generate",
json={"prompt": voice_text})
return response.json()["stl_path"]# Install test dependencies
pip install pytest pytest-qt
# Run tests
pytest tests/- Fork the repository
- Create feature branch
- Make changes with tests
- Submit pull request
This project is licensed under the MIT License - see the LICENSE file for details.
- trimesh for 3D mesh processing
- vosk for offline speech recognition
- PySide6 for cross-platform GUI
- Steam Deck community for testing and feedback
The following STL files were used in the demo video. Please replace with actual links and creators:
- Abandoned House with Broken Windows β Created by
Ilham3D - Old Classic Pokeball β Created by
Feyzii - Toy Monkey β Created by
SPolyModeler - Octopus β Created by
omrfrkcndn54 - Medieval Barrel β Created by
dimension Dazzle