Conversation
There was a problem hiding this comment.
Pull request overview
Adds an AGENTS.md guide intended to document repo-specific guardrails for AI-assisted changes, with emphasis on format compatibility and performance-sensitive code paths in the Rust workspace.
Changes:
- Introduces a new
AGENTS.mdfile describing key entry points and workflows (build/test/bench). - Documents on-disk format compatibility considerations (bincode, versioning guidance).
- Adds performance guidance for working in hot paths and using Criterion benches.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
worryg0d
left a comment
There was a problem hiding this comment.
This PR introduces rules for AI agents. I'm not really an AI expert, but it looks good from my point of view. It covers the format and its breaking changes, explicit frame versioning, and testing.
👍
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| - **Changing the shape/order of `Encode`/`Decode` structs is format-breaking**, even if Rust still compiles. | ||
| - High-risk types include (non-exhaustive): `atsc::data::CompressedStream`, `atsc::frame::CompressorFrame`, `atsc::header::CompressorHeader`, and any compressor frame types in `atsc/src/compressor/*` (e.g. `FFT`, `FrequencyPoint`). |
There was a problem hiding this comment.
In the “High-risk types” list, atsc::data::CompressedStream is called out as an Encode/Decode struct, but in the code it’s not bincode-encoded (it has custom to_bytes/from_bytes and only the Vec<CompressorFrame> is bincode-encoded). Suggest tweaking the wording to distinguish: (1) bincode-encoded types where field order is format-breaking (e.g. CompressorFrame, compressor structs), and (2) format-critical types with custom serialization (CompressedStream, CompressorHeader).
| - **Changing the shape/order of `Encode`/`Decode` structs is format-breaking**, even if Rust still compiles. | |
| - High-risk types include (non-exhaustive): `atsc::data::CompressedStream`, `atsc::frame::CompressorFrame`, `atsc::header::CompressorHeader`, and any compressor frame types in `atsc/src/compressor/*` (e.g. `FFT`, `FrequencyPoint`). | |
| - **Changing the shape/order of bincode `Encode`/`Decode` structs is format-breaking**, even if Rust still compiles. | |
| - **Bincode-encoded, order-sensitive types** include (non-exhaustive): `atsc::frame::CompressorFrame` and compressor frame structs in `atsc/src/compressor/*` (e.g. `FFT`, `FrequencyPoint`). | |
| - **Format-critical types with custom serialization** include: `atsc::data::CompressedStream`, `atsc::header::CompressorHeader` (they use manual `to_bytes`/`from_bytes`-style logic; changing their layout or encoding is also format-breaking). |
Summary
AGENTS.mdwith repo-specific AI guardrails (format compatibility, performance expectations, key entry points).Test plan
Made with Cursor