Skip to content
Arboracle-EcosystemPublic

About

Open-standards arboricultural field assessment, root-zone protection (ANSI A300 / ISA BMP), allometric ecosystem valuation, and municipal tree ordinance engine.

Topics

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

29 Commits

Folders and files

Repository files navigation

Open Arbor

Open-Standards Arboricultural Field Assessment, Root Zone Protection (ANSI A300 / ISA BMP), Allometric Ecosystem Valuation, and Municipal Tree Ordinance Engine

License: AGPL v3 Standards: ANSI A300 / ISA BMP GeoJSON: OGC CRS84


Overview

Proprietary arboriculture and urban forestry software often locks field observations, municipal tree protection rules, and preservation plans inside closed cloud databases. When a practitioner, municipal forester, or researcher cannot inspect the underlying allometric equations, verify statutory ordinance citations, or export standard GeoJSON directly into QGIS or ArcGIS Field Maps, the software becomes a barrier rather than an instrument.

Open Arbor (v2.1) refactors the core deterministic engines developed for the Arboracle platform into a zero-dependency, local-first open-standards library, field portal, and dataset. Every calculation traces to a published arboricultural standard (ANSI A300, ISA BMP, AS 4970, BS 5837), peer-reviewed urban forestry literature (Nowak, McPherson & Simpson, Xiao, John White FCIN12, Claus Mattheck), or a cited municipal code section.


Architecture & Open-Standards Modules

openarbor/
├── bin/
│   ├── openarbor-rap.mjs       # Zero-dependency RAP Field Compiler, Counter-Notice, Economics & Badge Attester CLI
│   └── openarbor-rca.mjs       # Backward-compatible CLI shim delegating to openarbor-rap.mjs
├── data/
│   └── ordinances/
│       ├── central_texas_ordinances.json       # Verified open ordinance rules (Austin, Georgetown, Liberty Hill, Cedar Park, Round Rock)
│       └── rogue_valley_oregon_ordinances.json # Verified open ordinance rules (Ashland, Medford, Grants Pass)
├── examples/
│   └── ashland_oregon_white_oak_rap_v2.json    # Complete schema-valid RAP-Spec v2.0 reference payload (105 cm Quercus garryana)
├── schemas/
│   ├── municipal-ordinance.schema.json         # JSON Schema (Draft 2020-12) for community-contributed municipal tree codes
│   ├── rap_assessment.schema.json              # JSON Schema (Draft 2020-12) for RAP-Spec v2.0 five-domain diagnostic assessments
│   ├── rap_field_observation.schema.json       # JSON Schema (Draft 2020-12) for local-first PII-stripped observation cohort logs
│   └── rap_openbadge_v3.schema.json            # JSON-LD Schema (Open Badges 3.0 / W3C VC) for RAPPER attestation
├── src/
│   └── core/
│       ├── rootZone.js                         # CRZ, TPZ, SRZ, multi-stem, and spatial union de-duplication
│       ├── ordinanceEngine.js                  # Declarative municipal tree protection and mitigation ledger
│       ├── ecosystemBenefits.js                # Nowak allometrics, Xiao hydrology, and OGC GeoJSON exporter
│       ├── soilFunction.js                     # Optional soil_function provenance validator and NRCS vadose sponge estimator
│       ├── fieldObservationLog.js              # Local-first PII-stripped RAP cohort logger (6-char Plus Code + canonical SHA-256)
│       ├── rapEngine.js                        # RAP-Spec v2.0 Mattheck t/R biomechanics, dual valuation, economics, and CLI compilers
│       └── leoRapEngine.js                     # LEO-RAP Profile 01 6-slot compiler, 3-stage phased triage, oracle verifier, and handoff briefs
├── tests/
│   ├── verify_openarbor.mjs                    # Core deterministic Node.js verification suite (11 PASS groups)
│   ├── verify_soil_function.mjs                # Soil provenance and GeoJSON backward-parity suite (4 PASS groups)
│   ├── verify_mcp.mjs                          # Subprocess MCP JSON-RPC 2.0 suite (10 PASS groups)
│   └── verify_masterwork_100x.mjs              # Live build, permalink, offline SW, and LEO-RAP suite (9 PASS groups)
└── docs/                                       # Architectural blueprints and practice specifications (docs/13_RAP_PRACTICE_SPECIFICATION_v1.md)

1. Root Zone & Structural Stability Engine (src/core/rootZone.js)

  • Critical Root Zone (CRZ) & Inner/Quarter Root Zones: Computes full, half (1/2 CRZ), and quarter (1/4 CRZ) radii and areas in both imperial (ft, sq ft) and metric (m, sq m) units, honoring municipal minimum radius floors.
  • International Tree Protection Zone (TPZ) Standards: Supports US 1:1 (1.0 ft/in DBH), US 1:1.5 (1.5 ft/in DBH for mature/sensitive species), Australian AS 4970 (12x DBH, clamped 2m to 15m), and UK BS 5837:2012.
  • Structural Root Zone (SRZ): Implements the AS 4970 / Mattheck windthrow stability equation (D * 50)^0.42 * 0.64 from Root Flare Diameter (DRF).
  • Multi-Stem DBH Aggregation: Supports both ISA/CTLA quadratic mean (sqrt(d1^2 + d2^2 + ...)) and municipal largest-stem-plus-half formulas (d_max + 0.5 * sum(d_rest)).
  • Spatial Root Zone Union (unionRootZoneArea): Uses 1-ft spatial grid sampling across GPS coordinates so overlapping root zones in dense groves are never double-counted when calculating pneumatic air-tilling (AirSpade), compost, or mulch volumes.

2. Data-Driven Municipal Ordinance & Mitigation Engine (src/core/ordinanceEngine.js)

Rather than hardcoding city logic in application code, Open Arbor reads declarative JSON records conforming to schemas/municipal-ordinance.schema.json:

  • Tiered Protection & Species Exceptions: Evaluates each stem against general and species-specific Protected, Legacy, and Heritage DBH thresholds while automatically excluding listed invasive or nuisance species (such as Celtis occidentalis, Melia azedarach, Triadica sebifera).
  • CRZ Encroachment & Seasonal Oak Wilt Guards: Flags trees when construction disturbance exceeds municipal CRZ limits (e.g., > 30% in Liberty Hill or > 50% in Austin/Georgetown), cut/fill exceeds 4 inches inside 1/2 CRZ, or Quercus pruning is scheduled during prohibited Ceratocystis fagacearum (Oak Wilt) vector months.
  • Ascending Diameter Exemption & Mitigation Ledger: Implements whole-tree ascending diameter exemption caps (such as Liberty Hill UDC § 6.07.01(c)(5)(B) 20% cap), retained hardwood credits, replacement caliper inches, cash-in-lieu schedules, and unpermitted removal civil penalty disclosures.
  • Bioregional Coverage: Ships with verified ordinances for Central Texas (Austin, Georgetown, Liberty Hill, Cedar Park, Round Rock) and Southern Oregon (Ashland AMC 18.4.5, Medford MMC 6.700, Grants Pass Development Code Art. 13).

3. Allometric Ecosystem Benefits, Veteran Tree Age & GeoJSON Exporter (src/core/ecosystemBenefits.js)

  • Biomass & Carbon Accounting: Generalized urban hardwood allometric equations (Nowak 1994, Cairns et al. 1997) computing above-ground and below-ground dry biomass, stored carbon (lbs), and annual growth sequestration.
  • Hydrology, Air Quality & Shade Energy: Canopy rainfall interception and avoided stormwater runoff (Xiao et al. 2000), dry deposition removal of O3, NO2, SO2, PM2.5, and CO (Nowak et al. 2006), building shade cooling savings (McPherson & Simpson 1999, calibrated to ISA ~80 kWh/tree baseline), and CTLA compensatory structural value.
  • Veteran Tree Age Estimation: Implements the John White (FCIN12) site-modified growth factor model across parkland, woodland, and urban street environments.
  • OGC GeoJSON Export: Converts evaluated inventories directly into urn:ogc:def:crs:OGC:1.3:CRS84 FeatureCollection payloads ready for QGIS, ArcGIS, or Leaflet.

4. Regenerative Arboriculture Protocol Engine (src/core/rapEngine.js)

Implements the Regenerative Arboriculture Protocol (RAP-Spec v2.0) diagnostic and appraisal standards governed by docs/13_RAP_PRACTICE_SPECIFICATION_v1.md, building upon ANSI A300, ISA BMP/TRAQ, Shigo CODIT, Mattheck t/R, CTLA 10th Edition, and the ASCA 7-part evidentiary structure:

  • Mattheck Shell-Wall Physics (evaluateBiomechanicsAndRhizosphere): Evaluates the hollow-cylinder safety factor t/R >= 0.30 and calculates radial pneumatic decompaction (AirSpade at 150 psi) and biological amendments (pre-charged biochar, fungal humates, ramial woodchip mulch) scaled to the Tree Influence Zone (TIZ).
  • Living Asset Equity vs. CTLA Dual Valuation (computeHolobiontValuation): Computes classical CTLA 10th Edition depreciated cost and Regenerative Holobiont Biological Equity. Applies the veteran keystone habitat multiplier (1.0 to 3.5) so ancient hollow trees appreciate rather than depreciate.
  • Sanctuary Scorecard Rollup (computeSanctuaryScorecardRollup): Aggregates tree-level rhizosphere records into the five property-level Scorecard dimensions (Soil Health Index, Canopy Coverage, Water Dynamics, Biodiversity Baseline, Restoration Potential Score) with spatial root-zone union de-duplication.
  • Evidentiary Linter (lintRapEvidentiaryReport): Enforces ASCA 7-part evidentiary rigor and blocks un-justified removals when t/R >= 0.30 and root-zone remediation is viable.
  • Local-First Cohort Logger (src/core/fieldObservationLog.js): Coarsens GPS Plus Codes to 6-character watershed cells (XXXXXX00+), strips client PII keys and free-text contacts, enforces explicit null when internal decay is visual_only_unmeasured, seals each observation with a canonical SHA-256 digest, and exports .jsonl.

Platform: engines, MCP, and the ordinance commons

npm: v2.1.0 (local) MCP: Compatible (8 Tools) Ordinance Commons: 8 Cities

Open Arbor packages its seven zero-dependency calculation modules as subpath exports (openarbor/root-zone, openarbor/ordinance-engine, openarbor/ecosystem-benefits, openarbor/soil-function, openarbor/rap-engine, openarbor/leo-rap, and openarbor/field-observation-log, plus backward-compatible ./rca-engine and ./leo-rca aliases) under AGPL-3.0-only. Any Node.js application, GIS script, or research pipeline can import the deterministic functions directly without cloud keys or native binary compilation. See docs/14_OPENARBOR_PLATFORM_100X.md for the platform architecture and dual-surface licensing model.

For AI assistants and local agents, server/mcp/openarbor-mcp.mjs exposes the deterministic engines and the municipal ordinance catalog over newline-delimited stdio JSON-RPC 2.0 (calculate_root_zone, evaluate_ordinance, calculate_ecosystem_benefits, rap_biomechanics, rap_lint, lookup_ordinance, validate_soil_function, and leo_rap_verify, while continuing to accept legacy rca_biomechanics, rca_lint, and leo_rca_verify aliases). Register the server in Claude Desktop or Hermes using the snippets in server/mcp/README.md and verify subprocess protocol conformance with npm run test:mcp.

The Municipal Ordinance Commons (data/ordinances/) encodes municipal tree preservation statutes into machine-readable JSON validated against schemas/municipal-ordinance.schema.json. The commons currently ships with six full-rule cities (Austin, Georgetown, and Liberty Hill in Texas; Ashland, Medford, and Grants Pass in Oregon) plus two baseline threshold-and-fee records (Cedar Park and Round Rock). Contributors can validate new or updated city records locally with node scripts/validate-ordinance.mjs following data/ordinances/CONTRIBUTING_DATA.md.


Quick Start & Verification

Open Arbor's core library uses standard ECMAScript Modules (ESM) with zero external npm dependencies required at runtime.

# Run the deterministic verification suite (Node.js >= 18)
npm test

# Compile a legal-grade 10-section RAP Evidentiary Dossier from a schema-valid JSON assessment
node bin/openarbor-rap.mjs compile examples/ashland_oregon_white_oak_rap_v2.json --municipality or-ashland

# Generate an Anti-Liquidation Preservation Counter-Notice challenging an un-evidenced removal bid
node bin/openarbor-rap.mjs counter-notice examples/ashland_oregon_white_oak_rap_v2.json --competitor-bid 3900 --municipality or-ashland

# Compare 5-year Regenerative Stewardship economics against a one-time removal bid
node bin/openarbor-rap.mjs economics examples/ashland_oregon_white_oak_rap_v2.json --removal-bid 3911

Example Usage

import fs from 'node:fs';
import { evaluateTreeInventory, computeMitigationPlan, estimateRootZoneRemediation } from './src/core/ordinanceEngine.js';
import { toGeoJSONFeatureCollection } from './src/core/ecosystemBenefits.js';

const ordinances = JSON.parse(fs.readFileSync('./data/ordinances/central_texas_ordinances.json', 'utf8'));
const libertyHill = ordinances.municipalities.find((m) => m.id === 'tx-liberty-hill');

const stand = [
  { tag: 'T-101', species_common: 'Live Oak', species_scientific: 'Quercus virginiana', stems_inches: [26], lat: 30.6653, lng: -97.9250, removal: false },
  { tag: 'T-102', species_common: 'Cedar Elm', species_scientific: 'Ulmus crassifolia', stems_inches: [9], lat: 30.6654, lng: -97.9251, removal: true },
  { tag: 'T-103', species_common: 'Post Oak', species_scientific: 'Quercus stellata', stems_inches: [15], lat: 30.6655, lng: -97.9252, removal: true }
];

const evaluated = evaluateTreeInventory(stand, libertyHill);
const mitigation = computeMitigationPlan(evaluated, libertyHill);
const remediation = estimateRootZoneRemediation(evaluated);
const geojson = toGeoJSONFeatureCollection(evaluated, { municipality: 'Liberty Hill, TX' });

License

The Open Arbor engine (src/) and web application layer (web/, server/) are licensed under AGPL-3.0-only (LICENSE). All files under schemas/ and data/ are dedicated to the public domain under CC0-1.0 (LICENSE-DATA, see NOTICE) so cities and vendors can adopt the data formats without the network clause.

Maintainer

George Steward
ISA Certified Arborist (TX-362025A, Oak Wilt Qualified) | Founder, Soil Grower
Master of Natural Resources (MNR) Candidate in Forests and Climate Change, Oregon State University
Practice: soilgrower.com

About

Open-standards arboricultural field assessment, root-zone protection (ANSI A300 / ISA BMP), allometric ecosystem valuation, and municipal tree ordinance engine.

Topics

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages