--- displayed_sidebar: developersSidebar sidebar_position: 1 --- import ZoomableMermaid from '@site/src/components/ZoomableMermaid'; # Data Model & Entity Relationship Diagram Comprehensive overview of all data entities extracted, processed, and uploaded to HuggingFace datasets. ## � HuggingFace Dataset Structure ### Current Datasets Being Uploaded ``` open-navigator-data/ ├── jurisdictions/ # Core jurisdiction data │ ├── cities # 19,000+ incorporated places │ ├── counties # 3,144 U.S. counties │ ├── states # 50 states + DC, territories │ ├── school_districts # 13,000+ districts (NCES data) │ └── census_data # Basic FIPS codes & census year reference │ ├── demographics/ # Comprehensive demographic data (U.S. Census) │ ├── population # Total population, age distribution │ ├── race_ethnicity # Race and ethnicity breakdowns │ ├── income_economics # Income, poverty, SNAP benefits │ ├── education # Educational attainment levels │ ├── housing # Housing units, ownership, values │ ├── employment # Unemployment, labor force participation │ └── health_insurance # Insurance coverage (uninsured, Medicaid, Medicare) │ ├── social/ # Social media presence │ ├── twitter # Twitter/X accounts │ ├── facebook # Facebook pages │ ├── instagram # Instagram accounts │ └── linkedin # LinkedIn pages │ ├── videos/ # Video & streaming platforms │ ├── youtube_channels # Government YouTube channels │ ├── vimeo # Vimeo accounts │ └── livestreams # Live meeting streams │ ├── platforms/ # Meeting management systems │ ├── legistar # Legistar URLs │ ├── granicus # Granicus links │ ├── suiteone # SuiteOne systems │ └── civicplus # CivicPlus platforms │ ├── domains/ # Official government websites │ ├── gsa_domains # .gov domain registry │ ├── municipal_websites # City/county websites │ └── state_portals # State government sites │ ├── events/ # Meetings, Hearings & Public Events │ ├── events # Government meetings, public hearings, community forums, town halls │ ├── participants # Officials and organizations participating in events │ ├── event_agenda_items # Individual agenda topics discussed │ ├── events_documents # Agendas, minutes, presentations, handouts │ ├── event_media # Video recordings, livestreams, audio files │ └── event_bills # Bills discussed or considered at meetings │ ├── person/ # All People - Officials, Candidates, Donors, Constituents │ ├── officials # Elected and appointed officials (mayors, council members, legislators) │ ├── official_roles # Current and historical positions held │ ├── official_contacts # Email, phone, office addresses │ ├── official_identifiers # External IDs (Twitter, OpenStates, Ballotpedia) │ ├── official_links # Websites, social media profiles │ ├── candidates # Political candidates (House, Senate, President - FEC data) │ ├── nonprofit_donors # Nonprofit leadership political giving (FEC analysis) │ └── constituents # Donors, volunteers, members, beneficiaries (all people) │ ├── nonprofits/ # Nonprofit organizations & churches │ ├── irs_eobmf # IRS EO-BMF bulk data (1.9M+ organizations) - PRIMARY SOURCE │ ├── irs_nonprofits # Legacy IRS 990 data (deprecated - use irs_eobmf) │ ├── propublica_data # ProPublica API (financials, NTEE codes) │ ├── everyorg_data # Every.org API (missions, causes, logos) │ ├── nonprofit_990s # Detailed Form 990 financials (yearly filings) │ ├── congregations # Church & congregation data (ARDA, HIFLD, NCS) │ ├── constituents # Donors, volunteers, members, beneficiaries (Microsoft CDM) │ ├── donations # Financial contributions and in-kind gifts (Microsoft CDM) │ ├── campaigns # Fundraising campaigns and appeals (Microsoft CDM) │ ├── memberships # Member enrollment and renewals (Microsoft CDM) │ ├── volunteer_activities # Volunteer hours and activities (Microsoft CDM) │ ├── program_delivery # Programs and services delivered (Microsoft CDM) │ └── program_outcomes # Impact metrics and outcome measurements (Microsoft CDM) │ ├── grants/ # Grant funding transactions │ ├── nonprofit_grants # Grants to nonprofits (from 990 Schedule I) │ ├── government_grants # Government grants to orgs/jurisdictions │ ├── foundation_grants # Private foundation grants │ └── federal_grants # Federal funding programs │ ├── causes/ # Cause & category taxonomy │ ├── ntee_codes # IRS NTEE classification system │ └── everyorg_causes # Every.org cause tags │ ├── budgets/ # Government budgets & finances │ ├── city_budgets # City/municipal budgets & spending │ ├── county_budgets # County budgets & expenditures │ ├── state_budgets # State government finances │ ├── school_budgets # School district finances (NCES F-33) │ ├── bond_debt # Municipal bonds & debt obligations │ ├── budget_line_items # Detailed budget categories & line items │ └── budget_deltas # Budget-to-Minutes Delta analysis (political economy) │ ├── decisions/ # Policy decisions & political economy analysis │ ├── policy_decisions # Extracted decisions from meetings │ ├── decision_frames # Frame analysis (rhetoric patterns) │ ├── decision_options # Options considered & rejected │ ├── decision_tradeoffs # Tradeoffs discussed (cost vs benefit, etc.) │ ├── stakeholder_positions # Who spoke for/against (Influence Radar) │ ├── decision_votes # Detailed vote records per decision │ ├── deferral_patterns # Stalling detection (same topic, multiple deferrals) │ ├── deferral_instances # Individual tabling events linked to patterns │ ├── keyword_density # Quantitative indicators (grant/taxpayer/emergency) │ └── deferral_patterns # Tabled/delayed decisions (temporal analysis) │ ├── elections/ # Election cycles & temporal analysis │ ├── election_cycles # Election dates & periods │ └── election_influences # Pre/post-election decision patterns │ ├── campaigns/ # Political campaign finance (FEC data) │ ├── committees # PACs, Super PACs, campaign committees │ └── contributions # Individual political contributions $200+ │ ├── civic/ # Google Civic & Wikidata │ ├── civic_divisions # OCD divisions │ ├── representatives # From Google Civic API │ ├── wikidata_entities # Structured entities │ └── dbpedia_resources # Wikipedia infobox data │ ├── ballots/ # Ballot initiatives & referendums │ ├── state_measures # State propositions (fluoridation votes!) │ ├── local_measures # City/county ballot questions │ └── election_results # Historical voting outcomes │ ├── bills/ # Legislation & Lawmaking │ ├── bills # Bills and resolutions (1.5M+ from all 50 states) │ ├── bill_actions # Bill history (introduced, committee, floor vote, signed) │ ├── bill_sponsorships # Primary sponsors and co-sponsors │ ├── bill_abstracts # Bill summaries and descriptions │ ├── bill_versions # Different versions of bill text (introduced, amended, enrolled) │ ├── bill_version_links # Links to PDF/HTML bill text │ ├── bill_documents # Supporting documents (fiscal notes, amendments, analysis) │ ├── bill_document_links # Links to supporting documents │ ├── bill_subjects # Subject/topic tags per bill │ ├── legislative_sessions # Session identifiers (2023 Regular, 2024 Special, etc.) │ ├── vote_events # Roll call votes on bills │ ├── vote_counts # Vote tallies (yes, no, abstain, absent) │ └── individual_votes # Individual legislator votes (yes/no/abstain) │ ├── topics/ # Advocacy causes & campaigns │ ├── topic_definitions # Validated survey questions from Roper Center │ ├── survey_questions # Public opinion question wording library │ ├── jurisdiction_topics # What each city is discussing │ └── advocacy_alerts # Opportunities for engagement │ ├── surveys/ # Public opinion research & polling data │ ├── survey_providers # Polling organizations (Gallup, Pew, Roper, etc.) │ ├── survey_studies # Individual survey studies/waves │ ├── survey_variables # Questions/items asked in surveys │ ├── survey_responses # Aggregate and individual response data │ ├── ipoll_metadata # Roper iPoll catalog metadata │ └── survey_crosstabs # Breakdowns by demographics, geography │ ├── factchecks/ # Yes Fact-checking & claim verification │ ├── claim_reviews # Google Fact Check API (ClaimReview schema) │ ├── politifact # PolitiFact Truth-O-Meter ratings │ ├── factcheck_org # FactCheck.org verified claims │ └── verified_claims # Aggregated fact-check database │ ├── civic_tech/ # Open source projects & hackathons │ ├── github_repositories # Civic tech projects (GitHub API) │ ├── project_metadata # Code for America, USDR, Civic Tech Field Guide │ ├── contributors # Maintainers and core contributors │ ├── project_issues # Good first issues, contribution opportunities │ ├── hackathons # Civic hackathon events │ ├── hackathon_projects # Projects built at hackathons │ ├── brigade_chapters # Code for America brigade locations │ └── project_funding # GitHub Sponsors, grants, OpenCollective │ ├── community_solutions/ # Community engagement & use cases │ ├── engagement_spectrum # Spectrum of Community Engagement to Ownership │ ├── use_case_catalog # Harvard Data-Smart City Solutions examples │ ├── data_academies # Brookings Institution training programs │ ├── success_stories # Real-world outcomes (Providence, Portland, Tempe) │ ├── metric_templates # Pre-built analytics for common challenges │ └── workflow_guides # Step-by-step community data workflows │ ├── analytics/ # Time dimensions & metric views │ ├── date_dimension # Date/time reference table (YYYY-MM-DD, day_of_week, fiscal_year) │ ├── temporal_relationships # Time-series joins for all entities │ ├── metric_views # Pre-computed analytics (advocacy, spending, nonprofit impact) │ ├── aggregated_stats # Monthly/quarterly/yearly rollups │ └── dashboard_metrics # Real-time dashboard data feeds │ ├── standards/ # Schema.org, Popolo, CEDS, IATI exports │ ├── schema_org_jsonld # JSON-LD exports (Event, Person, Organization, Legislation, ClaimReview) │ ├── popolo_exports # Popolo-compliant JSON (Person, Organization, Membership, VoteEvent) │ ├── ceds_aligned # CEDS-compliant education data (Element IDs, Option Sets) │ ├── ocd_divisions # Open Civic Data division IDs │ ├── iati_activities # IATI Standard v2.03 XML (programs, grants, humanitarian aid) │ └── rdf_triples # RDF/Turtle semantic web exports │ ├── vocabulary/ # OMOP-inspired concept & terminology (SYSTEM-INTERNAL) │ ├── concept # Master concept table (cities, causes, officials) │ ├── vocabulary # Vocabulary sources (OCD_ID, IRS_NTEE, US_Census) │ ├── concept_class # Concept classifications (City, County, 501c3, Mayor) │ ├── concept_relationship # Relationships (City → County, Topic → Legislation) │ └── domain # Domain groupings (Jurisdiction, Nonprofit, Policy) │ └── exports/ # API-ready formatted exports ├── csv_bulk # CSV downloads for all datasets ├── json_api # REST API JSON responses ├── graphql_schema # GraphQL schema definitions └── parquet_optimized # Compressed Parquet (default format) ``` ### Parquet File Naming Convention **Rule:** Use underscores (`_`) consistently, NOT hyphens (`-`) **Format:** `{category}_{subcategory}.parquet` **Examples:** ``` Yes CORRECT (using underscores): jurisdictions_cities.parquet jurisdictions_counties.parquet jurisdictions_states.parquet jurisdictions_school_districts.parquet social_twitter.parquet social_facebook.parquet videos_youtube_channels.parquet events_events.parquet person_official.parquet bills_bills.parquet nonprofits_organizations.parquet nonprofits_financials.parquet nonprofits_programs.parquet nonprofits_locations.parquet nonprofits_irs_eobmf.parquet nonprofits_constituents.parquet nonprofits_donations.parquet nonprofits_campaigns.parquet # Nonprofit fundraising campaigns (NOT political) person_candidates.parquet # Political candidates (FEC) person_nonprofit_donors.parquet # Nonprofit leadership political giving (FEC analysis) person_constituents.parquet # Donors, volunteers, members, beneficiaries campaigns_committees.parquet # Political committees/PACs (FEC) campaigns_contributions.parquet # Political contributions (FEC) nonprofits_memberships.parquet nonprofits_volunteer_activities.parquet nonprofits_program_delivery.parquet nonprofits_program_outcomes.parquet grants_federal_grants.parquet person_official.parquet person_official_roles.parquet person_official_contacts.parquet person_official_identifiers.parquet person_official_links.parquet person_candidates.parquet person_nonprofit_donors.parquet person_constituents.parquet bills_bills.parquet bills_bill_actions.parquet bills_bill_sponsorships.parquet bills_bill_abstracts.parquet bills_bill_versions.parquet bills_bill_version_links.parquet bills_bill_documents.parquet bills_bill_document_links.parquet bills_bill_subjects.parquet bills_legislative_sessions.parquet bills_vote_events.parquet bills_vote_counts.parquet bills_individual_votes.parquet events.parquet events_participants.parquet event_agenda_items.parquet events_documents.parquet event_media.parquet event_bills.parquet budgets_city_budgets.parquet surveys_national_polls.parquet surveys_roper_questions.parquet surveys_survey_providers.parquet surveys_survey_studies.parquet surveys_survey_variables.parquet surveys_survey_responses.parquet surveys_ipoll_metadata.parquet factchecks_claim_reviews.parquet factchecks_politifact.parquet analytics_date_dimension.parquet analytics_metric_views.parquet analytics_temporal_relationships.parquet standards_schema_org_jsonld.parquet standards_popolo_exports.parquet standards_ceds_aligned.parquet standards_iati_activities.parquet vocabulary_concept.parquet vocabulary_vocabulary.parquet vocabulary_concept_class.parquet vocabulary_concept_relationship.parquet No INCORRECT (using hyphens): jurisdictions-cities.parquet social-twitter.parquet meetings-government-meetings.parquet surveys-national-polls.parquet factchecks-claim-reviews.parquet analytics-date-dimension.parquet standards-schema-org.parquet ``` **Why Underscores?** - Yes Python-friendly variable names (can use `data.jurisdictions_cities`) - Yes SQL-compatible column names - Yes Consistent with folder structure (`school_districts`, not `school-districts`) - Yes Better for programmatic access - Yes Avoids shell escaping issues **Repository Name Exception:** - HuggingFace repo: `CommunityOne/open-navigator-data` (hyphen is fine for URLs) - File names inside repo: Use underscores (`jurisdictions_cities.parquet`) ## Data Extraction Pipeline ### Phase 1: Discovery (Bronze Layer) 1. **Census Data** → Jurisdictions list 2. **GSA Domains** → Government websites 3. **NCES** → School districts with financial data (F-33 forms) 4. **IRS EO-BMF** → ALL 1.9M+ U.S. tax-exempt organizations (PRIMARY SOURCE) 5. **IRS TEOS** → Legacy nonprofit EINs (deprecated - use IRS EO-BMF) 6. **Census of Governments** → Municipal budgets & finances 7. **URL Discovery** → Meeting platforms, YouTube, budget PDFs 8. **Social Media** → Twitter, Facebook accounts ### Phase 2: Enrichment (Silver Layer) 1. **IRS EO-BMF** → Complete nonprofit registry with 28 data fields per organization 2. **ProPublica Nonprofit Explorer** → Enhanced financial data, detailed 990 filings 3. **Every.org API** → Nonprofit causes, missions, logos 3. **ARDA (Association of Religion Data Archives)** → Congregation characteristics, health ministries 4. **HIFLD Places of Worship** → Geospatial church locations (350K+ congregations) 5. **National Congregations Study** → Social service provision patterns 6. **NCES F-33 Finance Survey** → School district budgets, per-pupil spending 7. **Census Annual Survey** → State/local government finances 8. **Municipal Securities Rulemaking Board (EMMA)** → Bond debt data 9. **YouTube API** → Channel statistics 10. **Open States PostgreSQL Database** → Complete legislative data (~10 GB monthly dump) - **8,600+ people** (legislators, governors, mayors) across all 50 states + DC + Puerto Rico - **1.5M+ bills** with full text and history - **13M+ bill actions** (introduced, committee, amendments, floor votes, signed) - **7.2M+ sponsorships** (primary sponsors and co-sponsors) - **3.5M+ bill versions** (as introduced, committee substitute, enrolled, enacted) - **180K+ events** (legislative meetings, hearings, committee sessions) - **835K+ event participants** (who spoke, testified, or attended) - **524K+ agenda items** from meetings - **Vote events** with individual legislator positions - **Organizations** (legislative bodies, committees) - **Jurisdictions** (states, territories) - Updated monthly from https://data.openstates.org/postgres/monthly/ 11. **OpenStates People Repository** → Current legislator contact info - GitHub repo: https://github.com/openstates/people - YAML files with email, phone, district offices - Social media profiles and website links - Updated daily via automated scrapers 12. **Wikidata SPARQL** → Entity relationships 12. **DBpedia** → Wikipedia structured data 13. **Google Civic** → Representatives 14. **OpenFEC API** → Political contributions, candidates, committees (campaign finance) 15. **GitHub API** → Civic tech projects, contributors, issues 16. **Civic Tech Field Guide** → Curated project taxonomy 17. **Code for America** → Brigade projects and hackathons 18. **Digital Public Goods Alliance** → DPG-certified open source projects ### Phase 3: Processing (Gold Layer) 1. **Meeting Extraction** → Agenda/minutes text 2. **Video Transcripts** → YouTube captions 3. **Document Analysis** → Keyword detection 4. **Relationship Mapping** → Entity connections 5. **Oral Health Filtering** → Topic classification 6. **Temporal Indexing** → Date dimension table, time-series relationships 7. **Metric View Creation** → Pre-computed analytics (advocacy activity, government spending, nonprofit impact) 8. **Schema.org JSON-LD** → Structured data exports (Event, Person, Organization, Legislation, ClaimReview) 9. **Popolo Compliance** → Open government standard exports (Person, Organization, Membership, VoteEvent) 10. **CEDS Alignment** → Education data mapping to NCES Element IDs and Option Sets ### New Dataset Categories Explained #### Analytics Datasets **Purpose:** Enable time-series analysis, trend detection, and dashboard metrics without complex SQL queries. | Dataset | Description | Refresh Frequency | |---------|-------------|-------------------| | `analytics_date_dimension` | Calendar reference table with fiscal years, quarters, day-of-week, holidays | Static (updated annually) | | `analytics_temporal_relationships` | Pre-joined date keys for all time-based entities (meetings, votes, budgets, filings) | Daily | | `analytics_metric_views` | Pre-computed analytics like advocacy_activity, government_spending, nonprofit_impact | Hourly | | `analytics_aggregated_stats` | Monthly/quarterly/yearly rollups (meeting counts, budget totals, grant sums) | Daily | | `analytics_dashboard_metrics` | Real-time feeds for dashboards (active meetings today, trending topics, hot ballot measures) | Every 5 minutes | **Example Use Case:** ```sql -- Instead of complex joins, use metric view: SELECT * FROM analytics_metric_views WHERE metric_name = 'advocacy_activity' AND jurisdiction_id = 'ocd-division/country:us/state:al/place:birmingham' AND date_period = '2024-Q1'; ``` #### Standards-Compliant Exports **Purpose:** Maximum interoperability with civic tech platforms, search engines, and semantic web tools. | Dataset | Standard | Use Case | Consumers | |---------|----------|----------|-----------| | `standards_schema_org_jsonld` | Schema.org JSON-LD | Google Search rich results, voice assistants | Google, Bing, Alexa, Siri | | `standards_popolo_exports` | Popolo Project | Civic tech platform integration | mySociety, OpenNorth, Sunlight Foundation | | `standards_ceds_aligned` | Common Education Data Standards | Education data exchange, NCES reporting | State education depts, Ed-Fi, IMS Global | | `standards_ocd_divisions` | Open Civic Data IDs | Cross-platform jurisdiction referencing | Google Civic, Ballotpedia, Vote Smart | | `standards_rdf_triples` | RDF/Turtle | Linked open data, knowledge graphs | DBpedia, Wikidata, SPARQL endpoints | **Example Schema.org Export:** ```json { "@context": "https://schema.org", "@type": "GovernmentOrganization", "name": "Birmingham City Council", "address": { "@type": "PostalAddress", "addressLocality": "Birmingham", "addressRegion": "AL" }, "event": [{ "@type": "Event", "name": "Regular City Council Meeting", "startDate": "2024-01-15T18:00:00-06:00" }] } ``` #### Yes Fact-Checking Datasets **Purpose:** Verify claims made in meetings, legislation, and political speech. | Dataset | Source | Fields | Update Frequency | |---------|--------|--------|------------------| | `factchecks_claim_reviews` | Google Fact Check API | claimReviewed, reviewRating, author, datePublished | Daily | | `factchecks_politifact` | PolitiFact web scraping | claim, ruling, truth_o_meter, context | Daily | | `factchecks_factcheck_org` | FactCheck.org API/scraping | claim, verdict, analysis, sources | Daily | | `factchecks_verified_claims` | Aggregated + deduplicated | claim_text, consensus_rating, verification_sources | Daily | **Integration with Meetings:** - Cross-reference meeting transcripts with verified claims - Flag unverified statements in legislative debates - Track politician accuracy scores over time ## � Complete Data Model (ERD)