35 lines
1.9 KiB
Markdown
35 lines
1.9 KiB
Markdown
|
|
# Instructions for the AI coding agent
|
||
|
|
|
||
|
|
This file is the working contract for AI-assisted development in this repository. Read it and inspect the repository before editing.
|
||
|
|
|
||
|
|
## Rules
|
||
|
|
|
||
|
|
1. Make small, buildable changes and run the relevant tests after each change.
|
||
|
|
2. Do not replace or remove existing behavior without explaining why.
|
||
|
|
3. Keep audio engine, DSP, project model, graph, persistence, and public core APIs in C (C99 baseline).
|
||
|
|
4. Keep FLTK and GUI code in C++ only. The GUI must call the core through C headers.
|
||
|
|
5. Use C `snake_case`; prefer explicit ownership and small functions.
|
||
|
|
6. Validate pointers, sizes, IDs, enum values, and allocation results.
|
||
|
|
7. Never allocate/free memory, perform file I/O, log, block on a mutex, or call GUI APIs from an audio callback.
|
||
|
|
8. Do not mutate a graph while the audio thread is traversing it. Prepare and publish a safe immutable execution plan.
|
||
|
|
9. Do not add dependencies without explaining the need, license, maintenance status, and build impact.
|
||
|
|
10. Do not claim incomplete features are implemented. Distinguish prototype, stub, and finished behavior.
|
||
|
|
11. Do not copy energyXT code, artwork, or proprietary resources.
|
||
|
|
12. Before a task, briefly state the plan and affected files. After it, report files changed, commands run, test results, and limitations.
|
||
|
|
|
||
|
|
## Definition of done
|
||
|
|
|
||
|
|
- Builds with warnings enabled.
|
||
|
|
- Relevant tests pass.
|
||
|
|
- Error paths and cleanup are handled.
|
||
|
|
- Documentation is updated when APIs or behavior change.
|
||
|
|
- No unrelated functionality is removed.
|
||
|
|
- Unverified behavior is reported honestly.
|
||
|
|
|
||
|
|
## First task
|
||
|
|
|
||
|
|
Run `make clean all test`. Inspect compiler and `pkg-config` availability. Do not install packages or alter system configuration without permission. Report current state and propose the next smallest step.
|
||
|
|
|
||
|
|
## Roadmap
|
||
|
|
|
||
|
|
Follow `docs/ROADMAP.md` in order. The initial implementation should improve the graph and offline engine before introducing hardware audio I/O, recording, MIDI, or external plugin hosting.
|