Skip to main content

Making Federal Regulations Readable with Python

Shashank Khandelwal (Consumer Financial Protection Bureau)
Python
E145
Average rating: ****.
(4.67, 6 ratings)
Slides:   external link

Federal regulations (or rules) are presented on the web as large
blocks of poorly-formatted text There is little visual structure, no
hyperlinks and a lack of ease-of-use. Regulations also change
frequently, but there is no easy way to track changes over time or
understand the nature of the changes

In this talk, we tour through some of the more interesting problems we
encountered building regulations for display and how we solved them
using open source software.

We aim to cover these topics (all with examples):

What is a regulation?

Problems with online regulations

  • Parsing, parsing and even more parsing: getting from regulation plain
    text to hierarchical actionable data
  • Layering information on top: definitions, citations and interpretations
  • Generating redline (diff) views of regulations
  • Displaying the regulation
  • Compiling versions of regulations from descriptions of changes
    (Federal Register notices): how we turn lawyer written statements
    about changes in regulations into actual actions (such as add, delete,
    move)

We finish by touching on how an in-house design and development team
can make development efficient, code effective, and close
collaboration easy with the very lawyers that write these federal
regulations.

Photo of Shashank Khandelwal

Shashank Khandelwal

Consumer Financial Protection Bureau

As a Design and Technology Fellow at the Consumer Financial Protection Bureau, Shashank Khandelwal develops software to make consumer financial products work for the American people. He have over eight years of software development experience and his career spans multiple domains, languages and technologies. More recently, Shashank used a data-driven approach to study human health behavior. He wrote software to collect large-scale social media data, filter, and analyze it using machine learning techniques, and released it as a disease surveillance platform for the academic, private, and government health community. One of his earlier Twitter-based studies has been featured on NPR (“What Twitter Knows about Flu” by Jordan Calmes on October 14, 2011). Previously, he wrote document management software and worked on the vacation packages team at Orbitz (in Chicago). Over the years, he has written software in Python, Java, PHP and other languages using a variety of tools, applications and libraries.