AI-Powered Post Analysis Pipeline
The mobile app had tens of thousands of user posts with no structured classification: no way to surface quality content, flag problems, or feed downstream systems. I designed and built a fire-and-forget pipeline to fix that, using GPT-4o-mini to classify posts at scale without blocking the application layer.
The architecture prioritized cost and reliability: SHA-256 content hashing to skip reprocessing identical posts, token-optimized prompts to minimize API spend, and strict output validation to catch malformed model responses before they touched the database. Partial MongoDB indexes kept query performance tight on a growing collection, and processing ran asynchronously so classification never blocked the application layer.
Each classification carried the model's own confidence score. Posts that fell below a set threshold were surfaced in the mobile admin panel for manual review instead of flowing downstream unchecked, a human-in-the-loop safeguard against the pipeline silently trusting its weakest calls.
The entire thing was engineered within Node v10 constraints, which meant no OpenAI SDK: raw HTTPS requests only. That constraint forced a cleaner separation between transport, parsing, and business logic than the SDK would have encouraged. The pipeline processed the full backlog and new posts, feeding classification data into downstream features.