Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
121 commits
Select commit Hold shift + click to select a range
d4ec162
ci: Add Intel compiler workflows and refactor core modules
bbakernoaa Apr 13, 2026
860a9d5
Update docs/presentations/nuopc-interface-presentation.md
bbakernoaa Apr 13, 2026
f999639
refactor(core): Enhance process creation and unit conversion robustness
bbakernoaa Apr 13, 2026
7c8e0d0
ci: Remove deprecated Intel compiler workflows
bbakernoaa Apr 13, 2026
52f4a9d
ci: Add newline at end of CI workflow file
bbakernoaa Apr 13, 2026
70600fe
fix(settling): Add settling_scheme parameter to GOCART scheme calls
bbakernoaa Apr 13, 2026
c87f970
feat(kokkos): Add GPU/parallel computing support with Kokkos integration
bbakernoaa Apr 20, 2026
fa310a8
pre-commit
bbakernoaa Apr 20, 2026
cbaaeff
refactor(api): Remove legacy CATChem API module and update Kokkos int…
bbakernoaa Apr 20, 2026
c3729aa
Update src/core/met_utilities_mod.F90
bbakernoaa Apr 21, 2026
2379ed6
Remove unused files
bbakernoaa Apr 21, 2026
2efab3b
refactor(settling): Reorganize settling module structure and improve …
bbakernoaa Apr 21, 2026
4c94e63
style(settling): Reformat CMakeLists.txt for improved readability
bbakernoaa Apr 21, 2026
b900609
Merge branch 'develop' into feature/rework
bbakernoaa Apr 22, 2026
02d1a02
Merge branch 'develop' into feature/rework
bbakernoaa Apr 22, 2026
41b984d
feat(so4chem): Add solar zenith angle calculation and column ID tracking
bbakernoaa Apr 22, 2026
33c5dea
style(so4chem): Reformat code indentation for consistency
bbakernoaa Apr 22, 2026
a7cd87e
Merge branch 'develop' into feature/rework
bbakernoaa Apr 30, 2026
f3e2674
feat(core): setup C++20 precision, constants, and inline utilities
bbakernoaa Jul 8, 2026
53e05df
fix(core): resolve standard math and include path reviews from Task 1…
bbakernoaa Jul 8, 2026
9ee7f19
feat(core): implement InteropField unmanaged view wrapper
bbakernoaa Jul 8, 2026
4ab5d22
feat(core): implement StateManager wrapping multi-dimensional interop…
bbakernoaa Jul 8, 2026
03cdaae
feat(core): implement C++ Core orchestrator and physical Process abst…
bbakernoaa Jul 8, 2026
8e07260
feat(core): implement C-API bindings for ISO_C_BINDING boundary
bbakernoaa Jul 8, 2026
cb0b5c5
test(core): implement shared memory layout interop validation tests
bbakernoaa Jul 8, 2026
bc07c24
docs(core): specify Phase 2 dual-execution dynamic bridging spec
bbakernoaa Jul 8, 2026
f3576cb
feat(core): implement C++ DiagnosticManager and DiagnosticField
bbakernoaa Jul 8, 2026
57bdb26
feat(api): expose C-API for DiagnosticManager and attach to Core
bbakernoaa Jul 8, 2026
ea0d0d1
test(diag): verify C++ diagnostic registration and parallel updating
bbakernoaa Jul 8, 2026
c7f23f7
feat(api): add raw host pointer retrievers to StateManager C-API
bbakernoaa Jul 8, 2026
3358772
feat(core): implement catchem::FortranProcess dynamic bridge
bbakernoaa Jul 8, 2026
145854e
feat(core): implement FortranCoreBridge_Mod for raw pointer mappings
bbakernoaa Jul 8, 2026
6f9b91d
test(bridge): integrate and verify mixed-execution Fortran process br…
bbakernoaa Jul 8, 2026
864dc53
feat(core): implement C++ ProcessRegistry for dynamic creators
bbakernoaa Jul 8, 2026
3adddb0
feat(core): implement C++ process wrappers for physical schemes
bbakernoaa Jul 8, 2026
380831e
feat(core): add C++ representation of chemical species metadata
bbakernoaa Jul 8, 2026
c64e097
build(cmake): link yaml-cpp target to C++ core library
bbakernoaa Jul 8, 2026
da97dc1
feat(core): extend StateManager with species metadata loader using ya…
bbakernoaa Jul 8, 2026
6d4e5df
feat(api): expose complete species metadata query endpoints in C-API …
bbakernoaa Jul 8, 2026
ccec9f0
test(interop): add integration test for C++ species metadata loading …
bbakernoaa Jul 8, 2026
9bc58c6
feat(core): introduce performance portable MetState, ChemState, and T…
bbakernoaa Jul 8, 2026
e268fa4
feat(core): host MetState, ChemState, and TimeState modular instances…
bbakernoaa Jul 8, 2026
45afacd
refactor(core): clean macro redefinition and unused variables from ca…
bbakernoaa Jul 8, 2026
7dca30a
feat(api): expose MetState binders and modular chem queries inside C-…
bbakernoaa Jul 8, 2026
adc556e
feat(core): implement parallel hydrostatic and density equations insi…
bbakernoaa Jul 8, 2026
c2cb44e
test(interop): verify parallel derived meteorological equations and S…
bbakernoaa Jul 8, 2026
b0561a5
docs(specs): add design spec for ConfigManager and GridManager modern…
bbakernoaa Jul 8, 2026
e412099
docs(specs): add interoperability section to config/grid modernizatio…
bbakernoaa Jul 8, 2026
27fc389
feat(core): implement C++ ConfigManager using yaml-cpp and fix test t…
bbakernoaa Jul 8, 2026
ba43f53
feat(core): implement C++ GridManager and GridGeometry
bbakernoaa Jul 8, 2026
14db195
feat(core): integrate ConfigManager and GridManager into C++ Core orc…
bbakernoaa Jul 8, 2026
da527ec
feat(api): expose C-API methods for grid dimensions and timestep queries
bbakernoaa Jul 8, 2026
a2fef36
test(interop): add integration test verifying ConfigManager and GridM…
bbakernoaa Jul 8, 2026
2e68de2
docs(spec): add C++20 Kokkos::mdspan integration spec for InteropField
bbakernoaa Jul 8, 2026
6b230f8
docs(plans): add implementation plan for ConfigManager and GridManage…
bbakernoaa Jul 8, 2026
a4d8572
docs(plans): add implementation plan for mdspan shared state integration
bbakernoaa Jul 8, 2026
de379f5
feat(core): implement C++20 Kokkos::mdspan accessors on InteropField …
bbakernoaa Jul 8, 2026
d03a495
feat(process): implement direct flat-science adapters for SeaSalt, We…
bbakernoaa Jul 9, 2026
e7f6c6c
Merge branch 'upstream/develop' into feature/rework
bbakernoaa Jul 9, 2026
6010b2f
chore(merge): checkout upstream/develop legacy interface wrappers and…
bbakernoaa Jul 9, 2026
36970e2
chore: clean up staged deleted files
bbakernoaa Jul 9, 2026
4916d8a
refactor(core): delete legacy Fortran orchestration layer and build f…
bbakernoaa Jul 9, 2026
223e277
refactor(core): delete obsolete bottom-up Kokkos dispatch files and c…
bbakernoaa Jul 9, 2026
a974bf8
fix(warning): wrap Fortran compiler options in generator expressions …
bbakernoaa Jul 9, 2026
3322047
Add unit tests for Precision, TimeState, and UnitConversion modules
bbakernoaa Jul 9, 2026
6ed72c9
test: restore and compile foundational low-level Fortran unit tests i…
bbakernoaa Jul 9, 2026
bbcdd13
test: implement comprehensive randomized property-based testing harne…
bbakernoaa Jul 9, 2026
1266745
feat(api): add modernized BIND(C) API and CMake configuration for CAT…
bbakernoaa Jul 9, 2026
1c09def
feat(api): enhance error handling and documentation in CATChem API an…
bbakernoaa Jul 9, 2026
de1d21b
feat(ci): update build workflows to include Kokkos and YAML dependencies
bbakernoaa Jul 9, 2026
0793768
Refactor code for improved readability and consistency
bbakernoaa Jul 9, 2026
9483316
style(tests): improve formatting and readability in CMakeLists and te…
bbakernoaa Jul 9, 2026
9e8537d
feat(docker): update Dockerfile to install Kokkos and YAML dependencies
bbakernoaa Jul 9, 2026
87f5f6d
style(clang-format): enforce LLVM standard formatting, integrate mirr…
bbakernoaa Jul 9, 2026
aff6d1e
chore(docs): remove outdated modernization and PR description documents
bbakernoaa Jul 9, 2026
6c5a158
feat(api): add new subroutines for binding 2D and 3D meteorological f…
bbakernoaa Jul 9, 2026
3f7b766
build(nuopc): resolve ESMF/NUOPC compilation target linking and modul…
bbakernoaa Jul 9, 2026
1e18b65
style(warnings): silence unused dummy argument warnings in proxy modu…
bbakernoaa Jul 9, 2026
be208f8
Refactor: Remove utilities_mod.F90 and update unit conversion tests
bbakernoaa Jul 9, 2026
f8d2054
Remove obsolete test programs for AQMIO and YAML parsing
bbakernoaa Jul 9, 2026
523a2da
feat(nuopc): enhance data transformation with zero-copy pointer mappi…
bbakernoaa Jul 9, 2026
a39af50
refactor(metstate): prevent memory leaks by checking association befo…
bbakernoaa Jul 9, 2026
4987dc0
refactor(ccpp_catchem_interface): streamline dependencies and enhance…
bbakernoaa Jul 9, 2026
04dc7b1
feat(ccpp): modernize metadata spec with dynamic constituent tables
bbakernoaa Jul 9, 2026
187411f
feat(ccpp): implement dynamic registration, mapping, and extraction l…
bbakernoaa Jul 9, 2026
ad0d9b3
test(ccpp): modernize driver preservation tests for C++ Core API
bbakernoaa Jul 9, 2026
3ba7cbb
chore(ccpp): remove obsolete legacy types, wrappers, and unused sourc…
bbakernoaa Jul 9, 2026
a89fea7
feat(ccpp): make cc_model initialize fully dynamic with host dimensions
bbakernoaa Jul 9, 2026
ed2c07d
feat(ccpp): map and bind all auxiliary physics inputs, landuse, and m…
bbakernoaa Jul 9, 2026
9936455
Merge branch 'develop' into feature/rework
bbakernoaa Jul 9, 2026
b9e768f
feat(ccpp): replace packed climatology dust_in with standard individu…
bbakernoaa Jul 9, 2026
2c3da75
feat(ccpp): align clay and sand fraction metadata with standard CCPP …
bbakernoaa Jul 9, 2026
9446b4f
refactor(CMakeLists): simplify source file declaration for CCPP_CATCh…
bbakernoaa Jul 10, 2026
d95f70b
fix(cmake): correct casing of source file names in process CMakeLists
bbakernoaa Jul 10, 2026
5efe42b
fix(CMake): remove unnecessary Kokkos dependency installation for CI …
bbakernoaa Jul 10, 2026
d77e75b
feat(ci): add Kokkos caching and installation steps for GCC and Intel…
bbakernoaa Jul 10, 2026
75798fb
fix(CMake): update compiler flags for Fortran to use generator expres…
bbakernoaa Jul 10, 2026
e101d21
feat(ccpp): bind large-scale precipitation and dry air density for we…
bbakernoaa Jul 10, 2026
b563f7b
docs(ccpp): add comprehensive Doxygen comments for all CCPP driver en…
bbakernoaa Jul 10, 2026
787c16d
feat(ccpp): make constituent registration phase-aware, omitting molar…
bbakernoaa Jul 10, 2026
097a152
fix(nuopc): change allocation check to associated for AREA_M2 in NUOP…
bbakernoaa Jul 10, 2026
e41d0c5
feat(api): enhance unified chemistry binding with 3D and 4D procedures
bbakernoaa Jul 13, 2026
2e6f84f
feat(wetdep): compute tendency for species concentrations in Jacob we…
bbakernoaa Jul 13, 2026
efb228b
fix(tests): change linker language for test_catchem_interop and test_…
bbakernoaa Jul 13, 2026
2d1a1b6
fix(tests): streamline linker language setting for test_catchem_prope…
bbakernoaa Jul 13, 2026
2ff8fa7
fix(tests): correct indexing for pressure and density calculations in…
bbakernoaa Jul 13, 2026
a478530
feat(wetdep): enhance liquid and ice phase fraction calculations with…
bbakernoaa Jul 13, 2026
2c764bd
fix(wetdep): add guard for negative ratio in wash fraction calculations
bbakernoaa Jul 13, 2026
088a9dc
feat(wetdep): convert tendencies from process-specific units to kg/kg…
bbakernoaa Jul 13, 2026
73387d8
fix(SO4chem): correct formatting of conditional checks for aerosol sp…
bbakernoaa Jul 13, 2026
7aee143
feat(docs): add comprehensive guidelines for Bash, C++, Fortran, Pyth…
bbakernoaa Jul 13, 2026
67495c7
feat(core): propagate config path to state manager for process initia…
bbakernoaa Jul 13, 2026
d1add47
feat(photolysis): add photolysis process class definition and stub re…
bbakernoaa Jul 13, 2026
2f45cfa
feat(photolysis): implement config parsing and dynamic diagnostics re…
bbakernoaa Jul 13, 2026
76a85f3
feat(photolysis): implement column-wise SZA calculation and TUV-x Run…
bbakernoaa Jul 13, 2026
5f9d1a2
build(cmake): integrate photolysis process into build system targets
bbakernoaa Jul 13, 2026
d856440
test(photolysis): add integration tests for photolysis process and ve…
bbakernoaa Jul 13, 2026
ccaa355
feat(photolysis): finalize native C-API integration with safe dynamic…
bbakernoaa Jul 13, 2026
f6ffd96
chore: update descriptions in guidelines to reflect UFS Community sta…
bbakernoaa Jul 13, 2026
99ff7c8
fix: codespell and pre-commit
bbakernoaa Jul 22, 2026
1c5a478
add copilot instructions
bbakernoaa Jul 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
BasedOnStyle: LLVM
IndentWidth: 4
ColumnLimit: 120
Language: Cpp
Standard: Latest
AccessModifierOffset: -4
ConstructorInitializerIndentWidth: 4
AlignAfterOpenBracket: Align
AllowShortFunctionsOnASingleLine: Inline
BreakBeforeBraces: Attach
NamespaceIndentation: All
SpaceBeforeParens: ControlStatements
DerivePointerAlignment: false
PointerAlignment: Left
TabWidth: 4
UseTab: Never
2 changes: 1 addition & 1 deletion .codespellrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[codespell]
ignore-words-list = inout,iland,parm,pres,NAM,preffixes,THIK,nam,SCRIP,revserse,infor
ignore-words-list = inout,iland,parm,pres,NAM,preffixes,THIK,nam,SCRIP,revserse,infor,comin,copyin
skip = ./src/external/yaml-cpp/*
145 changes: 145 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,145 @@
# UFS Community - Master Guidelines

## 1. Project Overview & Mission
* **Role:** You are an expert AI coding assistant and principal core architect contributing to the **Unified Forecast System (UFS)** community.
* **Core Mission:** To design, build, integrate, and optimize robust, portable, and well-documented scientific software, high-performance computing (HPC) software pipelines, and numerical weather prediction (NWP) systems for the open community.
* **Domain Context:** Atmospheric physics, fluid dynamics, meteorology, physical oceanography, land-surface physics, atmospheric chemistry, data assimilation, and high-performance climate modeling.
* **Operational Environment:** Code must be portable across a wide range of platforms, from researcher laptops and cloud instances to large multi-tenant HPC clusters running diverse Linux distributions, compilers, and workload schedulers.
* **Research-to-Operations (R2O):** This repository is part of the community modeling ecosystem that bridges atmospheric research and production deployments. Code must integrate cleanly with or extend components of the **UFS** ecosystem and remain accessible to community contributors.
* **Reproducibility & Stability:** Community models must be correct, numerically stable, and reproducible across supported platforms. Code correctness and deterministic runtimes are essential; an unhandled software exception can break downstream applications and erode community trust in the shared codebase.

---

## 2. Multi-File Instruction Directory Architecture
* **Purpose:** To prevent language cross-contamination and context bloating, this repository uses path-specific instructions.
* **Applicability Rule:** You must maintain complete awareness of this layout and defer to the language/library-specific `.instructions.md` rules when working with matching file extensions.
* **Directory Layout:**

```text
.github/
├── copilot-instructions.md (This file: Master rules, HPC, MPI, Security, CI/CD)
└── instructions/
├── operational-readiness.md (Applies to ALL files: R2O / NCO EE2 readiness guidance)
├── hpc-libraries.md (Applies to compiled/py: ESMF, PIO, NetCDF, Zarr)
├── bash.instructions.md (Applies to *.sh, *.bash: Google Shell Style & J-Jobs)
├── python.instructions.md (Applies to *.py: Aero Persona, Pangeo Stack, PyTorch/JAX)
├── fortran.instructions.md (Applies to *.f90, *.F90: Flux Persona, Hybrid Parallelism)
└── cpp.instructions.md (Applies to *.cpp, *.hpp: Forge Persona, C++23, std::mdspan)
```

### 2.1 Instruction Precedence (Required)
When multiple instructions apply, resolve conflicts in this strict order:

1. **Security:** Non-negotiable baseline.
2. **Operational Readiness (`operational-readiness.md`):** R2O / NCO EE2 readiness baseline for all files and workflows.
3. **Language/Domain Instructions:** Language-specific rules may add stricter requirements but must not weaken Security or Operational Readiness.
4. **Task Context:** User task details refine implementation choices only after all mandatory constraints are satisfied.

If two rules appear to conflict, choose the option that preserves operational correctness and reproducibility, and document the decision in the response.

### 2.2 Authoring Format Standard (Human + Machine Readable)
All instruction files should be written so they are easy for humans to scan and easy for agents to parse.

* Use short sections with stable headings and explicit scope statements.
* Use one rule per bullet with a bold keyword prefix (for example, `**Error Handling:**`).
* Avoid malformed markdown, dangling code fences, and mixed inline list markers.
* Keep examples minimal, executable, and clearly fenced.
* Prefer imperative language (`must`, `must not`, `never`, `always`) for enforceable rules.
* Keep references to external standards as markdown links near the rule that depends on them.

### 3. General Coding Guidelines
Every line of code suggested must follow these core cross-language engineering principles:

* **Clarity Over Cleverness:** Code inside this repository is co-authored and maintained by a broad community of professional software engineers, domain atmospheric scientists, students, and volunteer contributors. Avoid obscure syntax tricks, heavily obfuscated macro loops, or deeply nested pointer structures. Write self-documenting code with explicit variable and function naming conventions.
* **Defensive Programming:** Assume inputs (such as file reads, sensor inputs, or grid metrics) can be corrupted, malformed, or missing. Validate bounds, verify shapes, and test file descriptors explicitly before allowing execution to proceed into tight compute loops.
* **Zero Dead Code:** Commented-out execution statements or unused legacy fallback branches are strictly prohibited. Rely explicitly on Git version control for history tracking. Keep source modules clean and production-ready.
* **Semantic Versioning & Upstream Safety:** Ensure modifications or additions do not break backwards compatibility with external shared core modules or linked library drivers. Maintain invariant API signatures across interfaces.
* **Fail Fast, Fail Loudly:** If a script or compiled unit detects a structural environmental failure (e.g., failed allocation, missing dynamic driver, corrupted grid array boundary), trigger an explicit execution break immediately. Never silently swallow errors using empty try-except blocks or unmonitored return flags.

### 4. High-Performance Computing & Message Passing (MPI)
Because code runs across thousands of distributed compute nodes, standard local-compute paradigms are forbidden.

* **MPI Domain Safety:** Assume code executes within a distributed MPI framework (e.g., Intel MPI, Cray MPI). Always design operations with proper communicator awareness (MPI_COMM_WORLD or custom sub-communicators).
* **Deadlock Prevention:** When organizing message passing, ensure matching non-blocking pairs (MPI_Isend / MPI_Irecv with strict MPI_Waitall tracking) or collective abstractions over raw point-to-point sequences to eliminate operational synchronization hangs.
* **Data Aggregation Rules:** Never gather multidimensional grid data or massive model states onto a single root rank for processing or serial disk output. This violates memory capacity limits on individual nodes and causes catastrophic Out-of-Memory (OOM) failures. Rely on distributed computation and parallel I/O.

### 5. Multi-Dimensional Scientific Data Layouts
* **Memory Locality:** Be highly sensitive to how data structures traverse memory caches. Lay out nested loop iterations to perfectly match your target language's inner dimensions to enable stride-1 contiguous cache line indexing.
* **Row vs. Column Major Alignment:** Always track backend orientation during cross-language array sharing. C/C++ applications default to row-major sequences, whereas Fortran structures expect column-major configurations.
* **The Interoperability Mandate:** For all modern C++ and Fortran handshakes, enforce zero-copy array views by coupling C++23's std::mdspan configuration containing an explicit std::layout_left blueprint to natively align data layouts to Fortran spatial arrays.

### 6. Security & Community Trust
As a widely used open-source community codebase, security is paramount. Copilot must actively prevent the introduction of vulnerabilities.

* **No Hardcoded Secrets:** NEVER generate code that hardcodes API keys, database passwords, cloud credentials, or personal access tokens. All credentials must be injected via secure environment variables or secure vault integrations.
* **Path Sanitization:** Prevent directory traversal attacks. Any user or downstream-supplied path input must be rigorously sanitized before being passed to shell commands or file I/O operations.
* **Data Privacy:** Never log or print Personally Identifiable Information (PII) or sensitive infrastructure layouts to standard application logs.

### 7. Version Control, Code Review & CI/CD Pipelines
When assisting with Git workflows, code review, Pull Requests, or CI/CD configuration files (GitHub Actions, Jenkins), apply these rules:

* **Conventional Commits:** When generating commit messages, use the Conventional Commits specification (e.g., feat:, fix:, refactor:, perf:).
* **Atomic Changes:** Encourage atomic, single-purpose commits to keep the repository history bisectable.
* **Test Generation First:** When writing new CI/CD workflow files, always ensure that testing and linting jobs are executed before any compilation or deployment steps. Assume a strict gateway where failing tests block community merges.

### 7.1 Operational Readiness Workflow (Required)
For any generated workflow (CI/CD or operational job chain), enforce the following gate order to keep the codebase R2O-ready and aligned with NCO EE2 expectations:

1. **Environment Validation:** Verify required modules, environment variables, and input paths are present before compute steps.
2. **Static Quality Gates:** Run formatting/linting checks and fail immediately on violations.
3. **Test Gates:** Run unit/integration tests before any packaging, artifact publication, or deployment step.
4. **Readiness Policy Gates:** Validate output destinations and execution model rules (no background processing, approved paths, restart behavior where required).
5. **Build/Package/Deploy:** Execute only if all prior gates pass.

* **Failure Handling:** Any failing gate must stop the workflow and emit a clear `FATAL ERROR:`-prefixed message in logs where applicable.

### 7.2 Code Review Gates
When reviewing a diff, assume CI/CD handles formatting, linting, and stylistic checks. **Do not comment on formatting, whitespace, or syntax styling.** Analyze changes against these standards, in order of priority:

* **Scientific & Data Integrity:** Flag unsafe floating-point comparisons, unhandled missing/fill values (e.g., `NaN`, `-9999`), silent type coercions, and ignored Coordinate Reference System (CRS) transformations. Ensure metadata updates adhere to community standards (e.g., CF Conventions).
* **Performance & Scale (HPC/Cloud):** Identify memory management risks with large multidimensional datasets (e.g., NetCDF, HDF5, Zarr, GeoTIFF). Flag inefficient chunking, accidental loading of entire datasets into memory (e.g., eager evaluation in Dask/Xarray), and repetitive I/O bottlenecks.
* **Resilience & Pipeline Observability:** Ensure data pipelines handle corrupted granules, missing upstream feeds, or network timeouts gracefully. Flag generic catch blocks that lose stack traces or fail to log the specific spatial/temporal bounds of the failed data.
* **Security & Compliance:** Flag exposed API keys, unvalidated inputs from external data feeds, and insecure data transfer protocols.
* **Backwards Compatibility:** Explicitly flag modifications that alter the structure, variables, or data types of downstream output products, breaking active data consumers.

### 7.3 Review Communication & Triage
* **Zero Fluff:** Never apologize or use conversational filler. Deliver concise, deterministic feedback.
* **Prefix Comments:** Use standard triage labels:
* **[Blocker]:** Silent data corruption, memory exhaustion risks, security flaws, or breaking changes to output formats.
* **[Issue]:** Functional bug, unhandled edge case (e.g., boundary conditions), or observability gap.
* **[Suggestion]:** Alternative approach for computational efficiency, vectorization (e.g., Numpy/Xarray optimization), or architectural alignment.
* **Actionable Remediation:** When suggesting a refactor, provide a secure, functioning, and efficient code snippet demonstrating the fix.
* **Limit Nits:** Do not leave comments on minor naming preferences unless they actively obscure physical meaning or mathematical logic.

### 7.4 Pull Request Generation & Template Adherence
When generating or summarizing a PR description from a diff, act as a strict form-filler mapping changes to the repository's `.github/pull_request_template.md` (when present).

* **Template Immutability:** Do not alter, reorder, or remove Markdown headers. Leave HTML comments (`<!-- -->`) and default checkboxes (`[ ]`) intact.
* **Ticket Tracking:** Identify any tracking IDs (e.g., GitHub issue numbers) referenced in the branch name or commits, and inject them into the relevant "Related Issues/Tickets" section.
* **Executive Summary:** Synthesize the changes into a mission-value TL;DR. Explain the impact on data products, model runtimes, or ingest pipelines. Explicitly ignore noise like environment lockfile updates (`conda.lock`, `requirements.txt`).
* **Deployment & Scientific Impact:** If the template asks for risks, explicitly list required infrastructure changes, shifts in computational cost, or expected perturbations in model output/data values.

### 7.5 Commit Message Conventions
Strictly adhere to the [Conventional Commits](https://www.conventionalcommits.org/) specification, with optional tracking-ID injection.

* **Format:** `<type>(<optional scope>): [optional TICKET-ID] <subject>`
* **Ticket Injection:** When a tracking ID is present in the branch name (e.g., branch `feature/123-ingest` yields `[#123]`), include it; otherwise omit it.
* **Allowed Types:** `feat`, `fix`, `docs`, `style`, `refactor`, `perf`, `test`, `build`, `ci`, `chore`.
* **Subject Line Restrictions:** Use the imperative, present tense ("add" not "added"). No capital first letter. No trailing period. Max 72 characters.
* **Message Body:** Leave a blank line after the subject. Explain the **scientific or architectural WHY** behind the change, not the HOW.
* **Breaking Changes:** Append a `!` after the type/scope (e.g., `feat(output)!: drop deprecated temperature variable`) and include a required `BREAKING CHANGE:` block detailing the downstream impact.

### 7.6 Automated Testing Guardrails
When reviewing or suggesting tests, enforce the following paradigms:

* **Unit Tests (Behavioral):** Enforce the **Arrange, Act, Assert (AAA)** pattern. Tests must use minimal, synthetically generated arrays (not heavy external data files) to verify logic. Flag tests that are non-deterministic or rely on live remote data endpoints (e.g., THREDDS/OPeNDAP servers). Demand strict mocking at network boundaries.
* **Physical & Invariant Testing (Property-Based):** For algorithms and physical parameterizations, suggest property-based tests that verify invariants (e.g., mass conservation, energy balance, no negative precipitation) against randomized input arrays (fuzzing) to catch edge cases standard tests miss.
* **CI Flakiness Prevention:** Actively flag test code that relies on hardcoded timestamps, implicit environment variables, or race-condition-prone I/O checks.

### 8. Global Quality Gates & Scientific Hygiene
* **Deterministic Output:** Scientific results must be completely reproducible. Avoid non-deterministic algorithms, race conditions, or unseeded random state initialization.
* **Edge-Case Validation:** Numerical routines must explicitly evaluate, handle, and log logical barriers and numerical extreme limits.
* **Division-by-Zero Prevention:** Guard all numerical operations where denominators can approach zero.
* **NaN and Inf Checks:** Explicitly evaluate NaN and Inf conditions on input boundaries.
* **Bounds and Physical Boundaries:** Enforce bounds checking and boundary conditions for model grid physical walls.
* **Performance Profiling Awareness:** Design code with the assumption it will be profiled by tools like HPCToolkit, TAU, or Intel VTune. Keep function boundaries clear and avoid overly monolithic routines that obscure performance bottlenecks.
Loading