Skip to content

Commit edcdd91

Browse files
Extract refln into a dedicated experiment category (#163)
* Add powder Refln category plan * Record powder Refln category decisions * Add plan workflow instructions * Add powder Refln category Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Wire powder Refln into Bragg experiments Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Extract Cryspy powder reflection records Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Populate powder Refln during calculation Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Use powder Refln for Bragg ticks Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Document powder Refln Bragg ticks Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Update powder Refln implementation plan Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Fix powder Refln CWL tick units Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Fix powder Refln d-spacing ticks Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Scale Bragg panel height with the number of phases * Add powder Refln verification tests Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Verify powder Refln implementation Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Finalize powder Refln plan Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Remove completed powder plot plans Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Reverse Bragg tick row order Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Fix powder refln lifecycle and Bragg scaling Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Extract refln into a dedicated experiment categor * Fix linting, formatting and tests * Fix refln category extraction * Remove completed plan * Restore refln compatibility entry points * Keep refln API break and fix Plotly height * Restore default Plotly composite height --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 7c81e5d commit edcdd91

40 files changed

Lines changed: 2543 additions & 523 deletions

β€Ž.github/copilot-instructions.mdβ€Ž

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,50 @@
120120

121121
## Workflow
122122

123+
### Planning Workflow
124+
125+
- When asked to create a plan, first gather enough repository context to
126+
make the plan concrete. Ask all ambiguous, potentially ambiguous, or
127+
unclear questions in one concise batch, and record unresolved
128+
questions in the plan if the user wants the plan saved before
129+
answering them.
130+
- Save plans as Markdown files in `docs/dev` with the filename pattern
131+
`plan_<feature-name>.md`. The `<feature-name>` part uses lowercase
132+
words separated by dashes, for example
133+
`docs/dev/plan_background-refactor.md`.
134+
- Use the same `<feature-name>` to create the implementation branch,
135+
normally `feature/<feature-name>`. Do not push the branch unless the
136+
user explicitly asks.
137+
- Each plan must include a status checklist with `[ ]` items. Mark each
138+
item as `[x]` as it is completed during implementation.
139+
- Plans for non-trivial work must separate the work into two phases:
140+
- **Phase 1 β€” Implementation:** the agent works independently through
141+
all implementation steps, updating the plan checklist as it goes. Do
142+
not create tests or run tests in this phase unless the user
143+
explicitly asks. When Phase 1 is complete, stop and ask the user to
144+
review the implementation.
145+
- **Phase 2 β€” Verification:** after user approval, add/update tests,
146+
run formatting, linting, unit tests, integration tests, and script
147+
or notebook checks requested by the plan.
148+
- Every completed implementation step must end with a local commit.
149+
Stage only the files modified for that step, using explicit paths
150+
where practical. Do not include data files, project files, CIF files,
151+
or other generated artifacts created by integration tests, script
152+
tests, or notebook execution unless the user explicitly asked to
153+
update those artifacts.
154+
- Keep commits atomic, single-purpose, and aligned with plan steps. Use
155+
imperative commit messages, no type prefix, and keep the subject line
156+
at or below 72 characters.
157+
- Before each commit, inspect the worktree and avoid staging unrelated
158+
user changes. If unrelated dirty files exist, leave them untouched and
159+
mention them only when relevant.
160+
- The plan should be easy to maintain while working: include concrete
161+
files likely to change, decisions already made, open questions,
162+
verification commands for Phase 2, and a short suggested commit
163+
message or branch name when useful.
164+
165+
### General Workflow
166+
123167
- Two-phase workflow for non-trivial changes:
124168
- **Phase 1 β€” Implementation:** code, docs, architecture updates. Do
125169
not create new tests or run existing tests. Present for review and

β€Ždocs/architecture/package-structure-full.mdβ€Ž

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
β”‚ β”œβ”€β”€ πŸ“ calculators
77
β”‚ β”‚ β”œβ”€β”€ πŸ“„ __init__.py
88
β”‚ β”‚ β”œβ”€β”€ πŸ“„ base.py
9+
β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PowderReflnRecord
910
β”‚ β”‚ β”‚ └── 🏷️ class CalculatorBase
1011
β”‚ β”‚ β”œβ”€β”€ πŸ“„ crysfml.py
1112
β”‚ β”‚ β”‚ └── 🏷️ class CrysfmlCalculator
@@ -169,9 +170,6 @@
169170
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PdDataBase
170171
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PdCwlData
171172
β”‚ β”‚ β”‚ β”‚ β”‚ └── 🏷️ class PdTofData
172-
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ bragg_sc.py
173-
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class Refln
174-
β”‚ β”‚ β”‚ β”‚ β”‚ └── 🏷️ class ReflnData
175173
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ factory.py
176174
β”‚ β”‚ β”‚ β”‚ β”‚ └── 🏷️ class DataFactory
177175
β”‚ β”‚ β”‚ β”‚ └── πŸ“„ total_pd.py
@@ -257,6 +255,20 @@
257255
β”‚ β”‚ β”‚ β”‚ β”‚ └── 🏷️ class TotalGaussianDampedSinc
258256
β”‚ β”‚ β”‚ β”‚ └── πŸ“„ total_mixins.py
259257
β”‚ β”‚ β”‚ β”‚ └── 🏷️ class TotalBroadeningMixin
258+
β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“ refln
259+
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ __init__.py
260+
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ bragg_pd.py
261+
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PowderReflnBase
262+
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PowderCwlRefln
263+
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PowderTofRefln
264+
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PowderReflnDataBase
265+
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class PowderCwlReflnData
266+
β”‚ β”‚ β”‚ β”‚ β”‚ └── 🏷️ class PowderTofReflnData
267+
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ bragg_sc.py
268+
β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ 🏷️ class Refln
269+
β”‚ β”‚ β”‚ β”‚ β”‚ └── 🏷️ class ReflnData
270+
β”‚ β”‚ β”‚ β”‚ └── πŸ“„ factory.py
271+
β”‚ β”‚ β”‚ β”‚ └── 🏷️ class ReflnFactory
260272
β”‚ β”‚ β”‚ └── πŸ“„ __init__.py
261273
β”‚ β”‚ β”œβ”€β”€ πŸ“ item
262274
β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ __init__.py

β€Ždocs/architecture/package-structure-short.mdβ€Ž

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,6 @@
8585
β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“ data
8686
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ __init__.py
8787
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ bragg_pd.py
88-
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ bragg_sc.py
8988
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ factory.py
9089
β”‚ β”‚ β”‚ β”‚ └── πŸ“„ total_pd.py
9190
β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“ diffrn
@@ -128,6 +127,11 @@
128127
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ tof_mixins.py
129128
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ total.py
130129
β”‚ β”‚ β”‚ β”‚ └── πŸ“„ total_mixins.py
130+
β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“ refln
131+
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ __init__.py
132+
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ bragg_pd.py
133+
β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ bragg_sc.py
134+
β”‚ β”‚ β”‚ β”‚ └── πŸ“„ factory.py
131135
β”‚ β”‚ β”‚ └── πŸ“„ __init__.py
132136
β”‚ β”‚ β”œβ”€β”€ πŸ“ item
133137
β”‚ β”‚ β”‚ β”œβ”€β”€ πŸ“„ __init__.py

β€Ždocs/architecture/plan-threePanelPowderPlot.prompt.mdβ€Ž

Lines changed: 0 additions & 252 deletions
This file was deleted.
File renamed without changes.

0 commit comments

Comments
Β (0)