Legislative Coordinating Commission

Generative AI at the Minnesota State Legislature

Presented by Chris Cantey / @chriscantey / github/ccantey

Agenda

About LCC-GIS Staff
Who we support
Breadth of our work
AI Toolbox Code
Data Processing
System Administration
Enterprise Translations ChatGPT
AI Strategy

Who Am I?

Information Systems Manager

Bachelor's Degree

Land Surveying & Mapping Science

Minors in Computer Programming and GIS

Master's Degree in Cartography & GIS

LCC-GIS Staff

Julius Menchikov: Systems Admin, M365, GIS

Yuki Kawahara: Junior Developer, Media Services, AI

Minnesota Legislature

Legislative Coordinating Commission (LCC)

The Legislative Coordinating Commission was created to coordinate the legislative activities of the Senate and House of Representatives and the joint legislative commissions, committees, offices, and task forces.

Joint Offices and Commissions

LCC-GIS Core Services

Geographic Information Systems

Information Technology

Web and Application Development

Media Services

GIS Technology

FOSS4G

Lee Meilleur

PostGIS

QGIS

Mapserver

Proprietary GIS

ArcGIS

Maptitude

Mapbox

Google Geocoding API

Legislative Data

Legislative Data

Who Represents Me?

Beyond Boundaries - Demographic Profiles

Beyond Boundaries - Spatial Queries

Data Downloads

Research and Analysis

Member Research

Redistricting

2022 Legislative Plans

2022 Adopted Plans

Boundary Adjustments

Maps

Interactive Maps

Legacy

Elections

Who Represents Me?

Web Development

Information Technology

Microsoft 365

Security

Malware

Phishing

Ransomware

Denial of Service

SQL Injection

The list goes on...

Servers

Linux & Windows

Database

Print

Domain Controllers

Mail

Virtual Machines

Tech Support

Media Services

Zoom

Teams

YouTube

Closed Captioning

Live Interpretations

A typical day

AI Pilot Projects

AI Pilot Projects

Google Translation Hub

ChatGPT

Copilot

Otter.ai & Fireflies

ChatGPT

Writing Code with ChatGPT

Development Time

Writing Code with ChatGPT

APIs

Writing Code with ChatGPT

Syntax across languages and APIs


import React, { useState } from 'react';

function Example() {
const [count, setCount] = useState(0);

return (
<div>
<p>You clicked {count} times</p>
<button onClick={() => setCount(count + 1)}>
Click me
</button>
</div>
);
}

function SecondExample() {
const [count, setCount] = useState(0);

return (
<div>
<p>You clicked {count} times</p>
<button onClick={() => setCount(count + 1)}>
Click me
</button>
</div>
);
}

Writing Code with ChatGPT

Documentation

Writing Code with ChatGPT

Python - Automation

Database administration with ChatGPT

From flat tables...

Database administration with ChatGPT

To complex schemas...

Complete with triggers and functions

ChatGPT in Action: Data processing

Complex data problems

ChatGPT Excels at this

Data processing with ChatGPT

Office of the Economic Status of Women

Problem: Map childcare capacity over time

Data: Licensed facilities (DEED),
Under 5 population (Census)

Expectation: Decline over time

Goal: Determine areas/detect trends in childcare capacity across Minnesota

Data processing with ChatGPT

Data Problem: Childcare facilities

Data processing with ChatGPT

Data Problem: Capacity over time

Data processing with ChatGPT

Data Problem: 65,000 records

Data Problem: Need capacity by year

Data Problem: Need to pivot

Data Problem: Complex nested Excel functions

Data processing with ChatGPT

Data solution: pandas.py

Data processing with ChatGPT

Data analysis with ChatGPT

Solved the data problem

On to the analysis

Data analysis with ChatGPT

I have a dataset of census tracts with under 5 population. I also have a dataset of childcare facilities and their capacity. I combined the datasets in GIS. So most census tracts will have x children under 5 years old and the total childcare capacity per census tract.

Data analysis with ChatGPT

How do I analyze and present the disparity of a resource and parse out statistically significant information? I can show capacity/population of 5 year olds, for example: capacity in tract of 20, and there are 100 kids. So 20/100 = 1/5. One daycare spot for 5 kids. One problem I have is that some tracts have zero capacity. So 0/100. The number zero does not really show the disparity like 1/1000.

Data analysis with ChatGPT

Data analysis with ChatGPT

GPT Translation Services

Diversity, Inclusion, Accessibility, and Language Services

(DIAL Team)

About DIAL Translation Services

For one written language to another.

For legislative staff and members

No Campaign materials

Not for bills/legal documents

But it would be very good for bill summaries

Language Needs

English: 4,750,000

Spanish: 235,000

Hmong: 186,000

Somali: 155,000

Language Challenges

Spanish is very well supported, but Somali and Hmong are not as prominent on internet, so many A.I. models are not well trained on them.

Language Challenges: Context

Chamber: either houses of the legislature, or the room in which the bodies meet.

Tails: an estimate of future revenue that serves as base amounts in the next biennium

Jackets: A sheet prepared by Revisor of Statues attached to the official physical copy of a bill, records all action related to the bill

Why GPT? Pros

  • Adam Taha Enterprise Translations Office
  • Good model on Hmong and Somali – good accuracy
  • Can guide translations based on rules with engineered prompts
  • You can upload glossaries and other supplementary materials

Why GPT? Cons

  • No custom interface – must use it as any other LLM – careful prompting and analysis

How we use GPT

  • ChatGPT has a “Create GPT” feature
    • Configure prompts, upload documents that apply specifically to that GPT
    • Have a GPT for each language – may need to prompt specific grammar rules for each language
    • Each GPT prompted to convert into Plain Language, then the language desired
    • Print out Plain Language and the original
      • Feed by Paragraph
      • Give context of original document
GPT Menu

Plain Language and role in AI Translation

  • Every document will be put through plain language to reduce confusion, idioms, slang, and increase accuracy of meaning.
    • Each language has different nuances and ways of passing information
  • Nuance can be lost through A.I. Translation
    • Human translators are irreplaceable for interpreting tone, nuance, intent.
  • A.I. helps speed up the process, especially for larger documents

GPT Translation Services

GPT Configuration

Hmong Translation Config

  • 0. Preface:
    • Reply in English, unless asked otherwise.
    • If no instructions are given before a chunk of text, translate it as follows:
      • Translate the given text into Hmong. If the given text is in Hmong, translate it into English.
    • Do not continue on if there is missing context needed for the process, or there are conflicting instructions.

Hmong Translation Config

  • 1. Context:
    • The translations will be for making documents originally written in English to be translated into Hmong.
    • The documents will be read by people in the state of Minnesota, USA.
    • Hmong used should be White Hmong as used in Minnesota, USA.
    • Output should be appropriate for official, public government documents, letters, and notices.
    • If the original input has a specific tone, identify the tone and match the tone in the output language.

Hmong Translation Config

  • 2. Instructions and Clarifications:
    • If not identified, ask what kind of document the translation will be used for. Otherwise, identify it. (Is it a survey? Is it a letter?)
    • Convert prompts to plain language first, and show this version before proceeding with translation.
    • If any terms, vocabulary, or word choices are unclear, ask before generating a translation.
    • If acronyms and context are unclear, ask before generating a translation.
    • Avoid profanity and informal terms unless asked to. Avoid violence or innuendos.
    • If profanity or violence or innuendos are detected, notify the user.
    • If specific language nuances or cultural references that may cause confusion or require elaboration arise, ask for clarification and provide examples if possible.

Hmong Translation Config

  • 3. Additional Documents:
    • Use the Legal Glossary-Hmong CSV for legal specific terms that may come up. The first column is English, and the next column is the related Hmong term. Conjugate if appropriate.
    • The Legal Glossary-Hmong CSV file contains a glossary of words specific to the state legislative context. Many of the documents to be translated will be within this context.

Hmong Translation Config

  • 4. Readability:
    • The translated content should be easily understandable and legible.
Example

Towards an AI Strategy

Sanity Check

Towards an AI Strategy

Overwritten code

Destructive database operations

Unexpected system states

This is a known failure pattern

Towards an AI Strategy

AI offers a confident answer

This doesn’t mean you should stop using AI

The relationship needs a protocol

Towards an AI Strategy

  • Prompt Engineering
    • Google
    • Stack Overflow
    • Programmer Logical Workflows
GPT Menu

Towards an AI Strategy

Work in a development environment

Towards an AI Strategy

Take backups

Towards an AI Strategy

Don't mindlessly copy and paste

Treat AI like a power tool and use safety goggles — not like an autopilot

Towards an AI Strategy

Towards an ai strategy

What comes next?

Agenetic AI

Artificial General Intelligence - AGI

The Singularity?

THE End