Deep learning models have achieved impressive prediction performance but often sacrifice interpretability, a critical consideration in high-stakes domains such as healthcare or policymaking. In contrast, generalized additive models (GAMs) can maintain interpretability but often suffer from poor prediction performance due to their inability to effectively capture feature interactions. In this work, we aim to bridge this gap by using pre-trained neural language models to extract embeddings for each input before learning a linear model in the embedding space. The final model (which we call Emb-GAM) is a transparent, linear function of its input features and feature interactions. Leveraging the language model allows Emb-GAM to learn far fewer linear coefficients, model larger interactions, and generalize well to novel inputs. Across a variety of natural-language-processing datasets, Emb-GAM achieves strong prediction performance without sacrificing interpretability.

Features

  • For finer control, you can instead clone and install this repo from source
  • Interpretable linear model that leverages a pre-trained language model to better learn interactions
  • One-line fit function
  • Emb-GAM uses a pre-trained language model to extract features from text data
  • Combines features in order to extract out a simple, linear model
  • The best way to use Emb-GAM is through the imodelsx package
  • Emb-GAM achieves strong prediction performance without sacrificing interpretability

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow Emb-GAM

Emb-GAM Web Site

Other Useful Business Software
Our Free Plans just got better! | Auth0 Icon
Our Free Plans just got better! | Auth0

With up to 25k MAUs and unlimited Okta connections, our Free Plan lets you focus on what you do best—building great apps.

You asked, we delivered! Auth0 is excited to expand our Free and Paid plans to include more options so you can focus on building, deploying, and scaling applications without having to worry about your security. Auth0 now, thank yourself later.
Try free now
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Emb-GAM!

Additional Project Details

Programming Language

Python

Related Categories

Python Large Language Models (LLM), Python Natural Language Processing (NLP) Tool, Python Generative AI

Registered

2023-03-22