Datasets:
Download DATA_REMEDIATION_LOG.md from drdavidprivacy/reachfirst-data: direct link, hf CLI and curl.
- Browser
- Download file 14.9 kB
-
https://huggingface.co/datasets/drdavidprivacy/reachfirst-data/resolve/main/DATA_REMEDIATION_LOG.md
- Command line
-
hf download hf://datasets/drdavidprivacy/reachfirst-data/DATA_REMEDIATION_LOG.md
-
curl -L -o DATA_REMEDIATION_LOG.md https://huggingface.co/datasets/drdavidprivacy/reachfirst-data/resolve/main/DATA_REMEDIATION_LOG.md
ReachFirst working file: data remediation log (Week 3)
CROSSWIND WORKFORCE PARTNERSHIP: LARKSPUR ANALYTICS, LLC, DATA SCIENCE VENDOR
REACHFIRST PILOT EXTRACT: DATA REMEDIATION LOG
Prepared by Larkspur Analytics, LLC, the contracted data science vendor, for the ReachFirst program file, in response to the Week 2 review and under the Chief AI Officer's Week 2 memo. One row per change the vendor has now made to the extract before the first model is trained, and one row per finding the vendor chose to document rather than change. Two terms are used the same way in every row. The working file is every column the vendor holds after remediation: the fields as loaded, the fields added beside them, and the outcome. The model inputs are the subset of those columns the model will be trained on. A field can be in the working file and not a model input. Two rules apply to every row. The raw field is never overwritten. A field held out of the model inputs stays in the working file for measurement. The vendor takes the label off the record, not the record out of the file. Rows leave only under a written rule, and only one row of this log removes any.
Extract: 48,842 rows and 15 columns as loaded (14 fields and the outcome). 48,790 rows and 18 columns in the working file after remediation (52 rows removed under the one rule in R-6, 3 columns added). Those 18 columns are 10 model inputs, 7 fields held out of the inputs, and the outcome column. Outcome: income, as recorded, the person's own annual income above or at or below the 50,000 line. Above the line ">50K," the value the notebook's rates count: 23.9 percent of 48,790. At or below the line "<=50K," the side ReachFirst is built to reach and the reporting positive class fixed in R-1: 76.1 percent.
| Row | Field or fields | What the Week 2 review found | Operation performed | Reason | Options considered and not taken | Before and after | Where it lands | Notebook |
|---|---|---|---|---|---|---|---|---|
| R-1 | income | The dictionary defines the label as the person's own income at the 50,000 line, while Crosswind's eligibility rules are written for households. The notebook counts records above the line and the program is built to find the side at or below it, and one Week 2 log swapped the two | Define the label window: the person's own annual income, above (">50K") or at or below ("<=50K") the 50,000 line, as documented. Fix "at or below the line" as the reporting positive class for every evaluation-stage metric and for the datasheet's language | The documentation wins under the flowchart, and it says the person, not the household. How the line stands in for household eligibility is open, because no field bridges the two. The direction is fixed once so that no later metric reads a group's low rate above the line as a low share of eligible households. The label's "yes" is the program's "no" | Relabel the outcome as "eligible" (asserts the mapping nobody has confirmed). Reverse the coding of the column (rewrites a raw field) | No change to the outcome column. Above the line: 11,687 of 48,842, 23.9 percent. At or below: 37,155, 76.1 percent | The outcome column, as recorded. The reporting direction is not a field, a rule recorded for the evaluation stage | 11.1 |
| R-2 | relationship | Values describe the person's role relative to the household's reference person. Husband is Male in 19,715 of 19,716 records and Wife is Female in 2,328 of 2,331, so the field encodes sex by construction. The extract holds 19,716 Husband records and 2,331 Wife records | Recode a proxy to remove the protected content: Husband and Wife become one level, Spouse, in a new field, relationship_model, beside the raw field. The raw field leaves the inputs and stays in the working file | The recode keeps the household structure the label tracks and removes the direct encoding of sex. The count gap is documentation, not a defect: the source extraction kept only adults with recorded income of their own, a positive weight, and hours above zero, so non-earning spouses are absent. Whether the rest of the file still recovers sex is the watch list's fourth item, tested at the evaluation stage | Keep relationship as recorded as an input (a field that is sex in all but four records). Drop the field from the working file (the watch list reports by household role) | Six levels, then five. Spouse: 22,047 records (19,716 Husband plus 2,331 Wife), of which 2,329 are recorded Female and 19,718 Male. Rows 48,842 before and after | Raw in the working file, not a model input. relationship_model: model input, added | 11.2 |
| R-3 | capital-gain, hours-per-week, age | Three largest values have the shape of ceilings: 99,999 in capital-gain (244 records, every one above the line), 99 hours, and age 90. The dictionary documented the last two and not the first | Keep top-codes and document them. Add a flag field, capital_gain_topcoded, beside capital-gain: 1 at the ceiling, 0 otherwise. The dictionary now documents all three ceilings | All three are recording ceilings of the source system (documentation). A ceiling is information about the recording system, and the 244 records are real high earners. The flag lets a model and the evaluation stage treat "at the ceiling" as what it is, not as an amount of 99,999 | Cap or trim the values (hides the ceiling). Delete the 244 records (removes real records under no rule). Treat 99,999 as a missing code (the documentation says it is not) | Records at each ceiling: capital-gain 244, hours-per-week 137, age 55. No value changed. capital_gain_topcoded: 1 in 244 records, 0 in 48,598 | All three raw fields: model inputs, unchanged. capital_gain_topcoded: model input, added | 11.3 |
| R-4 | fnlwgt | A sampling weight describing how the record was drawn into the extract, not an attribute of the person. Association with the outcome 0.025, flat across its fifths, 28,523 distinct values | Drop the field from the inputs. Keep it in the working file for reweighting to the population | A weight describes the drawing, not the person, and a model given it learns noise. The weight is exactly what reweighting to the population at the evaluation stage needs, so the column stays. Whether the prototype as built used it is open: the build record lists every field as passed to the training routine and does not log what the routine kept | Keep it as an input. Delete it from the working file (loses the only description of the extract's design) | 15 candidate inputs, then 14. fnlwgt still in the working file. Rows 48,842 before and after | In the working file, not a model input | 11.4 |
| R-5 | workclass, occupation, native-country | The placeholder "?" marks a field not captured: workclass 2,799 records, occupation 2,809, native-country 857. Every record missing workclass is also missing occupation. Those records sit at 9.5 percent above the line against 24.8 percent for the rest, and they are the youngest and the oldest | Treat as a category, not as missing. Leave as is and document: "?" stays as its own level in all three fields | The gap is patterned toward the households outreach wants to find. Imputing erases the pattern. Dropping erases the households. The watch list's sixth item tests how the model scores the "?" group. What the source system records for a person who is not employed is open | Impute the most common value. Drop the 3,620 rows with any placeholder. Add a separate missing flag (the level is already its own flag) | No change. Values imputed 0, rows dropped 0. "?" rates above the line: workclass 9.5 percent, occupation 9.4 percent, native-country 25.7 percent | All three fields: workclass and occupation are model inputs, unchanged. native-country leaves the inputs under R-8 | 11.5 |
| R-6 | All rows | 52 of 48,842 rows repeat another row exactly on all 15 fields, including the weight with 28,523 distinct values. No identifier field, so a repeat cannot be told from a coincidence by other means | Drop rows under a stated rule: exact duplicate on all fields, keeping the first copy of each. Executed before the split rule in R-11 | Duplicates that straddle the train/test split let the held-back test set hold rows the model was trained on. This is the only row removal in the log. Why the duplicates exist is open | Keep them (inflates the evaluation numbers). Drop every row involved in a repeat (removes 101 rows and loses 49 distinct records under no rule) | 48,842 rows before, 48,790 after, 52 removed. Base rate before 23.9 percent above the line (11,687), after 23.9 percent (11,681). At or below the line 37,155 before, 37,109 after | Not a field. Rows removed under the rule stated, the outcome re-aligned to the rows that remain | 11.6 |
| R-7 | Vintage, mapping to the outreach universe | The dictionary says the extract came from an older records system and that its age is noted, not smoothed over. No field dates a record, and no field links a record to Crosswind's service area | Leave as is and document, as two limitations in the datasheet | The source documentation places the records decades before the current labor market, and nothing in the file can narrow that. Nothing in the file can measure drift, and the monitoring stage is where it shows. How the records map onto the current outreach universe is open | Reweight to the current population (no current population data in the program file). Drop the oldest records (nothing dates them) | No change. Date or time fields 0, identifier fields 0, fields linking a record to the service area 0 | Not a field. Two limitations recorded in the datasheet | 11.7 |
| R-8 | native-country | Country of origin. Carries race at 0.402 and the outcome at 0.096. One value holds nine records in ten, and 26 of the 41 recorded values have fewer than 100 records, 1,211 records between them | Drop the field from the inputs, keep it for measurement. Add a measurement copy, native_country_report, in which values under 100 records become "all other" and the placeholder stays its own level. Neither is a model input | A field that carries race and cannot be tested for 26 of its 41 values does not belong in the inputs of a public program. The watch list reports by country of origin and publishes the list of values too small to test, which the copy makes possible | Group into regions as an input (asserts groupings nobody documented). Keep as an input. Delete from the working file (the watch list reports by it) | 41 recorded values plus "?" then, in the copy, 17 levels: 15 values with 100 records or more, "all other" with 1,211 records, "?" with 856. Rows 48,790 before and after | Raw in the working file, not a model input. native_country_report: in the working file, not a model input | 11.8 |
| R-9 | sex, race (and marital-status, age kept under a test) | Sex 0.215 and race 0.100 with the outcome. Race, color, and national origin are protected under Title VI of the Civil Rights Act, and sex and age under the Workforce Innovation and Opportunity Act (WIOA) section 188. The Week 1 Use Case Assessment's red line: the race, sex, and national origin fields are never model inputs. Marital status carries sex at 0.459 | Hold protected attributes out of the inputs, keep them for measurement: sex and race leave the inputs and stay in the working file. Marital status and age stay as inputs on the condition of the evaluation-stage proxy test | You cannot measure what you deleted. The watch list reports contact rates and the false "above the line" rate by sex and by race, and tests how well the score still finds each with the field out. The vendor takes the label off the record, not the record out of the file: every record stays in the training data with all of its other fields, and the model is never told the person's sex or race. Marital status and age are legitimate outreach signals, and whether they stay is the AI Governance Lead's call after the proxy test | Delete sex and race from the working file. Keep them as inputs and test later (the Week 1 red line says never). Hold marital status and age out now (the memo keeps them in until tested) | 13 candidate inputs, then 11. Both fields still in the working file. Rows 48,790 before and after | sex and race: in the working file, not model inputs. marital-status and age: model inputs, under a recorded test | 11.9 |
| R-10 | education, education-num | The highest education level is recorded twice, as 16 labels and 16 ranks, one to one in both directions | Leave as is and document: keep the label as the model input, read in the order the rank gives it. education-num leaves the inputs and stays in the working file as that ordering | Two names for one thing double-count nothing but produce two reasons for one fact, and a reason code that says "education and also education rank" cannot be explained at a front desk. The label's words are readable in a reason | Keep both as inputs. Drop the label and keep the rank (a rank is not a readable reason) | 11 candidate inputs, then 10. No value changed. 16 labels, 16 ranks | education: model input, unchanged. education-num: in the working file, not a model input (the ordering of education) | 11.10 |
| R-11 | Train/test split | No identifier and no date, so records cannot be grouped by person or household or ordered by time. The 52 duplicates would have straddled a split | Record the rule for the train/test split: random by row, after the duplicate drop in R-6, stratified on the outcome, 80 percent training and 20 percent held back as the test set, fixed seed. Recorded now, executed at the modeling stage | The split decides whether the evaluation numbers are honest. With no entity key and no time key, random stratified is the only defensible rule, and the datasheet says so as a limitation. The held-back test set is never used for training | Split by household (no identifier exists). Split by time (no dates exist). Split before deduplication (puts the same row on both sides) | Expected sizes: 39,032 training rows (about 29,687 at or below the line), 9,758 in the held-back test set (about 7,422 at or below, about 2,336 above). Smallest measurement groups in the held-back set: Married-AF-spouse about 7 of 37, race Other about 81 of 406, the "all other" country values about 242 of 1,211. Not executed this week | Not a field. A rule recorded for the modeling stage | 11.11 |
Open items carried in the datasheet, not resolved by any row above: how the 50,000 line on a person's own income maps onto Crosswind's household eligibility rules, what the source system records for a person who is not employed and so what "?" stands for in any one record, why the 52 duplicate rows exist, whether the prototype as built used the sampling weight, and how the extract maps onto the current outreach universe. Section 12 of the notebook prints the same five.
End of log. Questions about any row go to Larkspur Analytics through the AI Governance Office.