Field Audit Full Run

Task Details
← Task Board

Task Description

# TASK: Run Full Field Naming Audit on All Doug's Boundaries

**Priority:** HIGH
**Agent:** engineer
**Filed:** 2026-02-16
**Filed by:** Doug (via Claude Code session)

---

## Goal

Run the Field Naming Audit engine against ALL of Doug's available boundary sources — JD, CNH, spray boundaries, and ISOXML processed boundaries. Generate a comprehensive audit report showing field clusters, name variants, and boundary matches across all sources.

## Steps

### 1. Inventory all boundary sources
```bash
# JD boundaries
find /data/processed_data/doug/ -name "*.geojson" -path "*/boundaries/*" | head -20

# CNH boundaries
find /data/processed_data/doug/ -name "*.geojson" | grep -i boundary | head -20

# Spray boundaries (79 fields)
ls /data/Sandbox/farmiq.ai/spray/data/boundaries/

# ISOXML planted boundaries
find /data/processed_data/doug/ -name "planted_boundary.geojson" | head -20

# ISOXML field boundaries (new — from isoxml_boundary_fix task)
find /data/processed_data/doug/ -name "field_boundary.geojson" | head -20
```

### 2. Run the audit engine
```bash
cd /data/Sandbox/FieldNamingAudit
python field_naming_audit.py --customer doug --all-sources
```

If that doesn't work with those exact flags, read `field_naming_audit.py` to understand the CLI interface and adapt.

### 3. Review and fix any errors
The audit engine does spatial clustering (IoU matching) across boundary sources. If it crashes:
1. Read the error
2. Fix the code (likely edge cases with MultiPolygon, empty geometries, or CRS mismatches)
3. Re-run

### 4. Generate report
The audit should produce:
- `FieldNamingAudit/output/doug_full_audit.json` — machine-readable results
- `FieldNamingAudit/output/doug_full_audit.md` — human-readable summary

### 5. Post results to dashboard
```bash
curl -X POST http://localhost:8080/api/tasks -H "Content-Type: application/json" \
  -d '{"title":"Field Audit Complete", "description":"SUMMARY — clusters found, name conflicts, sources matched", "category":"report", "priority":"medium"}'
```

## Context
- Audit engine: `/data/Sandbox/FieldNamingAudit/audit_engine.py`
- Web frontend: `/data/Sandbox/farmiq.ai/field-audit/`
- Doug has: 9 JD+CNH boundaries imported, 79 spray boundaries, 587+ processed ISOXML files
- The audit clusters boundaries spatially and tracks name variants across sources

## DO NOT
- Do NOT modify boundary files — read only
- Do NOT delete any existing audit results — append or overwrite the output files only

Job Queue (0)

No job queue entries for this task yet