Ojas C's Senior Project Blog

Project Title: Shooting Through the Text: Uncovering Sentiments in Congressional Gun Legislation
BASIS Advisor: Travis May
Internship Location: Arizona State University
Onsite Mentor: Hua Wei, Ph.D.



Project Abstract

Have you ever wondered about the power of words in shaping public opinion on contentious issues like gun control? Perhaps you hadn't considered their impact at all. My project delves into the emotional and rhetorical dynamics of U.S. Congressional bills on gun issues, spanning from the 107th to the 117th sessions (2001-2023). We aim to strip back the layers of legislative language, uncovering how the debate on gun control and rights is framed and its potential sway over societal attitudes. At the ASU Data Mining and Reinforcement Learning Lab under the expert guidance of Professor Hua Wei, I work on projects that focus on sim-to-real transfer and human-AI collaboration, specifically in optimizing traffic signal control through advanced reinforcement learning techniques. This experience sharpens my ability to navigate complex data and apply machine learning models, skills I use to dissect and analyze the sentiment of legislative texts in my own project on Congressional gun legislation. As we dissect the emotional tones and persuasive strategies within these texts, we're doing more than scrutinizing laws; we're revealing the narratives that fuel national discourse and mold public perception. The ultimate goal? To offer a lens through which we can better understand the polarized landscape of gun legislation, providing insights that could reshape how policies are communicated and perceived. Join us in this exploration of linguistic power, where every word in a bill carries the weight of conviction and the potential to shift the tides of public opinion!

    My Posts:

  • The End

    Hey guys. I just wanted to thank each and every one of you for tuning into my journey for this project, and hope you learned some valuable insights that you can utilize yourself in the future. Below is a question asked by my AP Research teacher Dr. Travis May, and I decided to share my... Read More

  • Research Paper — Writing And Statistics

    Last week, I finished generating my results and creating graphs for an analysis of my results. However, while the analysis of the graphs had some interesting results, the main question of the project still wasn't answered: To what extent do the sentiments expressed in pro-control versus pro-rights congressional gun legislation differ? To understand how the... Read More

  • Sentiment Analysis — Graphing Results and Conducting Analysis Part 2

    Last week, I finalized all of my results from the sentiment analysis models and started my analysis. As a recap, the time graph plotted with sentiment scores to see how the overall legislation sentiment changed over time proved that there was essentially no change in sentiment over time. The graph proves that the sentiments of... Read More

  • Sentiment Analysis — Graphing Results and Conducting Analysis

    This week was dedicated to first finishing up the results section of my project and then working on a practice presentation for rehearsals. As I mentioned in last week's blog, there are 3 types of sentiment analysis models: Rule-based, Machine Learning, and Transformers. After some additional research, I decided to not go down the Machine... Read More

  • Sentiment Analysis Models — Researching Rule-Based, Machine Learning, and Transformer Models

    This week marked the completion of my classification script execution on all legislative text data from 2001 to 2023. Each piece of legislation has now been classified as either 'control' or 'rights'. Due to the OpenAI rate limits, which I previously discussed in last week's blog, I had to operate the script continuously on my... Read More

  • Classification Challenges and Advances: Navigating API Limits and Precision in Legislative Sentiment Analysis

    This week was entirely dedicated to developing a classification script that effectively assigns each piece of legislation a label indicating whether it supports gun rights or advocates for gun control. I originally introduced this concept in my fourth blog, 'Data Collection Progress: Legislative Text Acquisition And Preliminary Classification Efforts', but to summarize, this step ensures... Read More

  • Sentiment Analysis Models — Learning Python Libraries

    This week, my focus has been on learning major Python libraries that will be useful for my project. First, I have been working on learning PyTorch, a famous open-source machine-learning library that provides a high-level interface for building and training deep-learning models. There are many alternatives to it, but the main reason I chose PyTorch... Read More

  • Data Collection Progress: Legislative Text Acquisition and Preliminary Classification Efforts

    This week marked a significant milestone in my project, as I completed the initial phase of data collection by acquiring the text from congressional legislation. Resolving the VPN issue enabled access to ASU's supercomputer Sol, where I executed my script to retrieve all necessary data in JSON format. This data is now prepared for analysis... Read More

  • Literature Review & Data Collection – Legislation Duplicates

    This week, I successfully finalized my data collection script to gather congressional gun legislation texts. However, integrating this script with ASU's supercomputer, Sol, presented unexpected challenges. Connecting to the ASU VPN to access Sol encountered technical issues, prompting me to submit a support ticket to the ASU IT Department while awaiting a resolution to resume... Read More

  • Data Collection – API Exploration and Web Scraping Strategies

    This week, I've progressed with my data collection efforts for the sentiment analysis models. As outlined in my previous blog post, my objective was to leverage the ProPublica Congress API to identify legislation pertaining to the term 'gun'. Initially, I anticipated that the API would grant access to both metadata and the legislation text. However,... Read More

  • Data Collection – API and Pipelines

    This week, my focus has centered on two main areas: understanding the ProPublica Congress API and understanding the methodology for gun control data pipelines. The ProPublica API is crucial for accessing congressional legislation in my project. I was able to create a direct system using the API to get any legislation relating to the word... Read More