Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copilot Coding Agent Instructions

You are working on **PyAutoConf**, the configuration, serialization and I/O
foundation of the PyAuto ecosystem (package `autoconf`).
You are working on **PyAutoNerves**, the configuration, serialization and I/O
foundation of the PyAuto ecosystem (package `autonerves`).

The canonical, agent-agnostic instructions for this repo live in **`AGENTS.md`** at
the repository root — build and test commands, architecture, the base-layer config
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ jobs:
unittest:
uses: PyAutoLabs/PyAutoHeart/.github/workflows/lib-tests.yml@main
with:
package: autoconf
package: autonerves
secrets: inherit
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
test_autoconf/unit/json_prior/code/priors/
test_autonerves/unit/json_prior/code/priors/

test/autofit/test_fit
# Byte-compiled / optimized / DLL files
Expand Down
2 changes: 1 addition & 1 deletion .url_check_allowlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@
http://geekfeminism.wikia.com/wiki/Conference_anti-harassment/Policy # CODE_OF_CONDUCT.md:305

# Internal PyAuto docs — pages renamed, need editorial fix
https://pyautofit.readthedocs.io/en/latest/general/adding_a_model_component.html # autoconf/directory_config.py:235
https://pyautofit.readthedocs.io/en/latest/general/adding_a_model_component.html # autonerves/directory_config.py:235
42 changes: 21 additions & 21 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# PyAutoConf — Agent Instructions
# PyAutoNerves — Agent Instructions

Canonical, agent-agnostic instructions for this repo. `CLAUDE.md` imports this
file; any tool that does not process `@`-imports should read this directly.

**This repo is the Nerves organ of the PyAuto organism** — the base
configuration/serialization layer (`autoconf`) that every scientific library
configuration/serialization layer (`autonerves`) that every scientific library
imports. It is a full organ (promoted to the seventh organ 2026-07); the
organism map below is generated from `PyAutoMind/repos.yaml`.

Expand All @@ -25,7 +25,7 @@ Canonical boundaries live in `PyAutoBrain/ORGANISM.md`; the full body map
| **Heart** | PyAutoHeart | Health/readiness — the authoritative "is it safe to release?" verdict. |
| **Memory** | PyAutoMemory | Long-term scientific/software/project knowledge (see science pointer below). |
| **Gut** | PyAutoGut | Owns the lifecycle of condemned self-material (stale branches, stashes, dead code/tests): holds it as durable, recoverable git refs through a transit window and voids it on a sweep. The storage mirror of Memory (retention vs release). |
| **Nerves** | PyAutoConf | The Nerves — the configuration/serialization layer connecting workspace conventions to libraries (layered config, version handshake, test_mode), delivered as the `autoconf` package. |
| **Nerves** | PyAutoNerves | The Nerves — the configuration/serialization layer connecting workspace conventions to libraries (layered config, version handshake, test_mode), delivered as the `autonerves` package. |

Call chain (always this order): **Brain → Heart (gate) → Build (execute)**. Brain agents are **conductors** (front-door; a human drives them; they decide *and* act) or **faculties** (read-only opinions the conductors consult; they judge and stop). New capability grows as a faculty, not a new organ, unless it owns state or effects no existing organ can.

Expand All @@ -34,46 +34,46 @@ Generated from `PyAutoMind/repos.yaml` + `PyAutoBrain/ORGANISM.md`; edit there,

## What this repo is

**PyAutoConf** (package `autoconf`) is the configuration, serialization, and
**PyAutoNerves** (package `autonerves`) is the configuration, serialization, and
I/O foundation of the PyAuto ecosystem: layered config with overrides,
dict/JSON/CSV serialization, FITS I/O, JSON-based priors, and the shared
`jax_wrapper` / `test_mode` utilities.

Dependency direction: autoconf is the **base layer**. It does **not** import
Dependency direction: autonerves is the **base layer**. It does **not** import
`autofit`, `autoarray`, `autogalaxy`, or `autolens`. All four of those depend
on autoconf, so any public-API change here ripples downstream.
on autonerves, so any public-API change here ripples downstream.

## Related repos

- **Source siblings (downstream):** PyAutoFit, PyAutoArray, PyAutoGalaxy,
PyAutoLens — all depend on autoconf.
PyAutoLens — all depend on autonerves.
- No `_workspace`, `_workspace_test`, or HowTo companion repo.
- No `docs/` / RTD site — the package source and `test_autoconf/` are the
- No `docs/` / RTD site — the package source and `test_autonerves/` are the
authoritative reference.

## Architecture

- `autoconf/conf.py` — layered config system (`Config` / `conf.instance`).
- `autoconf/dictable.py` — dict / JSON serialization (`output_to_json` / `from_json`).
- `autoconf/fitsable.py` — FITS I/O (`output_to_fits` / `ndarray_via_fits_from`).
- `autoconf/json_prior/` — JSON-based priors.
- `autoconf/tools/` — shared decorators and helpers.
- `test_autoconf/` — test suite.
- `autonerves/conf.py` — layered config system (`Config` / `conf.instance`).
- `autonerves/dictable.py` — dict / JSON serialization (`output_to_json` / `from_json`).
- `autonerves/fitsable.py` — FITS I/O (`output_to_fits` / `ndarray_via_fits_from`).
- `autonerves/json_prior/` — JSON-based priors.
- `autonerves/tools/` — shared decorators and helpers.
- `test_autonerves/` — test suite.

## Quick commands

```bash
pip install -e ".[dev]" # install with dev/test extras
python -m pytest test_autoconf/ # full test suite
python -m pytest test_autoconf/tools/test_decorators.py # one focused test
black autoconf/ # formatter (advisory — not gated)
python -m pytest test_autonerves/ # full test suite
python -m pytest test_autonerves/tools/test_decorators.py # one focused test
black autonerves/ # formatter (advisory — not gated)
```

In a sandboxed / restricted environment, point numba and matplotlib at
writable caches:

```bash
NUMBA_CACHE_DIR=/tmp/numba_cache MPLCONFIGDIR=/tmp/matplotlib python -m pytest test_autoconf/
NUMBA_CACHE_DIR=/tmp/numba_cache MPLCONFIGDIR=/tmp/matplotlib python -m pytest test_autonerves/
```

## CI / definition of green
Expand All @@ -84,11 +84,11 @@ is no black/ruff/flake8 gate — formatting is advisory. (`requires-python` in

## Public API

The public surface is defined authoritatively in `autoconf/__init__.py` — read
The public surface is defined authoritatively in `autonerves/__init__.py` — read
it rather than trusting a hand-maintained list. Canonical import:

```python
from autoconf import conf
from autonerves import conf
```

Key surfaces: `Config` / `conf.instance`, `output_to_json` / `from_json`
Expand All @@ -106,7 +106,7 @@ Key surfaces: `Config` / `conf.instance`, `output_to_json` / `from_json`

1. Read the issue description and any linked plan.
2. Identify affected files and make the change.
3. Run the full suite: `python -m pytest test_autoconf/`.
3. Run the full suite: `python -m pytest test_autonerves/`.
4. If you changed public API, say so explicitly — PyAutoFit, PyAutoArray,
PyAutoGalaxy, and PyAutoLens all depend on this package and may need updates.
5. Ensure all tests pass before opening a PR.
Expand Down
2 changes: 1 addition & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# PyAutoConf — agent instructions
# PyAutoNerves — agent instructions
The canonical, agent-agnostic instructions live in `AGENTS.md`. Claude Code loads them
via the import below; if your tool does not process `@`-imports, open `AGENTS.md` in
this directory and read it directly.
Expand Down
Loading
Loading