CruxBit
Back to catalog
MediumTechnologyeducation

Decision Tree Survival Modeling App With Interactive Pruning Controls

Added Jun 2025 3 design docs

Decision trees are the most explainable models in machine learning, which makes them ideal for teaching — but only if learners can actually see the tree and watch it change. This project builds a web application around that idea using the classic Titanic passenger dataset, where every split has an interpretable story.

The intern develops a Flask backend that trains a decision tree classifier with scikit-learn to predict passenger survival, served through a frontend built with HTML, CSS, and JavaScript. Users view a rendered visualization of the fitted tree, adjust pruning parameters such as maximum depth and minimum samples per split, and watch the tree restructure and its predictions change in real time — a direct demonstration of the overfitting-versus-generalization trade-off. Jupyter notebooks accompany the app to document data preparation and experimentation, and per-passenger predictions let users test scenarios interactively.

The intern learns how tree construction, overfitting, and pruning interact — knowledge made durable by manipulating it directly — while gaining full-stack experience: serving a model with Flask, wiring a JavaScript frontend to a Python API, and packaging an educational tool others can learn from.

Related projects

You might also like

TechnologyEasy

Lightweight Text Generation API Built With LangServe

The gap between a working LangChain script and a service other software can call is deployment, and LangServe exists to close it: it turns chains into REST APIs with typed endpoints, streaming, and an interactive playground almost for free. Knowing this path from notebook to network service is essential for any developer who wants their AI work used by anyone other than themselves, and this project walks it end to end at a friendly scale. The intern builds a FastAPI project in Python that exposes a text generation chain through LangServe. The intern first constructs the chain itself with LangChain, a prompt template feeding a language model with configurable parameters such as topic and style, then mounts it as a LangServe route, gaining automatically generated endpoints for invocation, batching, and streaming. Around this core the intern adds a health check, request logging, and clear API documentation, then exercises the service from the built-in playground and from an external client script to prove the full round trip works. The project teaches deployment fundamentals for LLM applications: how chains become HTTP services, how FastAPI and LangServe divide responsibilities, what streaming responses look like on the wire, and how to structure a small AI service so that adding the next endpoint is easy, foundations the intern will reuse in every production AI role.

educationfastapigenerative-ailangchain+1
PRD · HLD · LLD includedView