Gig Scam Shield, a new open-source web app submitted to the Hacktoberfest Open-Source AI Challenge, is proving that local inference can replace expensive API calls for niche utility tools. Built by developer asosa933, the application runs Google's EmbeddingGemma model directly in the user's browser to analyze job postings for signs of fraud. The tool targets a specific pain point for side-gig hunters: the time and risk associated with evaluating potentially fraudulent opportunities from Facebook groups, Telegram channels, and niche job boards.
Hybrid Detection Engine
The architecture employs a dual-layer approach to maximize accuracy while maintaining transparency. First, a rules engine written in plain JavaScript checks for classic red flags such as upfront fees, requests for ID photos before interviews, and the use of gift cards for payments. This layer supports both English and Italian. Second, if the rules engine flags a post as 'Caution' or if the text is ambiguous, the app invokes EmbeddingGemma via transformers.js. The model generates an embedding vector for the input text and performs a 5-nearest-neighbor vote against a local dataset of labeled examples. Crucially, the AI can only raise the severity of the verdict by one step; it cannot downgrade a scam flagged by the rules, ensuring that obvious traps remain blocked.
Privacy and Cost Advantages
By running the 300-million-parameter model entirely client-side, the developer eliminated the need for a backend server and API keys. The initial model download is approximately 200 MB, cached thereafter for instant access. This design choice has significant economic implications for the target audience. The developer argues that group admins and small job boards, who might check hundreds of posts daily, cannot sustain per-call API pricing. With zero marginal cost per check, the tool can be offered for a nominal monthly fee, making it viable for community moderators. The use of WebGPU accelerates inference on capable hardware, while a WASM fallback ensures compatibility on standard CPUs.
Lessons from Model Selection
The project documentation offers a practical case study in model selection for browser-based applications. The developer initially attempted to use generative Gemma models (270M and 1B parameters) for classification but found them unreliable at those sizes due to quantization limitations and inconsistent outputs. A notable technical hurdle involved the GatherBlockQuantized operator in 4-bit exports, which the WASM backend does not support, forcing the use of fp16 or int8 weights. Switching to an embedding-based nearest-neighbor approach not only resolved these reliability issues but also reduced the model footprint and improved explainability by showing the most similar reference post.
Key Takeaways
- EmbeddingGemma runs locally in the browser using transformers.js, supporting both WebGPU and WASM backends.
- The hybrid rules-and-AI approach ensures that clear scams are always caught while allowing the model to identify nuanced, reworded frauds.
- Client-side inference eliminates API costs and privacy concerns, making the tool economically viable for community moderators and small job boards.
- The developer switched from generative models to embeddings after finding the former unreliable for classification tasks at small parameter sizes.
The Bottom Line
Gig Scam Shield demonstrates that open-weight models can power practical, privacy-first tools without the overhead of cloud infrastructure, offering a compelling blueprint for future client-side AI applications.