Skip to content

Further improvement of AI instructions#2739

Open
MichaelHuth wants to merge 3 commits into
mainfrom
feature/2739-improve_ai_instructions
Open

Further improvement of AI instructions#2739
MichaelHuth wants to merge 3 commits into
mainfrom
feature/2739-improve_ai_instructions

Conversation

@MichaelHuth

@MichaelHuth MichaelHuth commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

If it occurs in reviews or other AI answers regarding Igor code that the answer is plainly wrong, please mention it here.

So the instructions can be improved.

  • add that the same waveref may not appear on LHS and RHS in the same assignment
  • add that MultiThread works with every wave type
  • clarify that when auto-indexing the index strictly counts upwards by one each iteration
  • clarify the equivalence of for(elem : wv) loops to indexed ones with elem = wv[i] and the ordering of it

@MichaelHuth MichaelHuth self-assigned this Jul 8, 2026
Copilot AI review requested due to automatic review settings July 8, 2026 14:04
@MichaelHuth
MichaelHuth requested review from t-b and timjarsky as code owners July 8, 2026 14:04

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the internal Igor Pro wave/datafolder reference guidance to reduce AI-generated mistakes by clarifying two common language gotchas: (1) when WAVE statements raise runtime errors (only when executed without /Z and the RHS can’t resolve), and (2) what size Make creates when /N is omitted.

Changes:

  • Documented Igor’s function-level scoping/default-initialization behavior for reference-typed locals (WAVE, NVAR, SVAR, DFREF, FUNCREF) with illustrative examples.
  • Added a concise explanation of the runtime-error distinction between an unexecuted WAVE statement vs an executed-but-unresolvable RHS (and when to use /Z).
  • Documented Make default sizing rules when /N is omitted (128-point default vs initializer-sized).

Comment thread .claude/skills/igor-wave-dfref/SKILL.md
Copilot AI review requested due to automatic review settings July 8, 2026 17:28

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

Comment thread .claude/skills/igor-wave-dfref/SKILL.md
Copilot AI review requested due to automatic review settings July 8, 2026 23:15
@MichaelHuth
MichaelHuth force-pushed the feature/2739-improve_ai_instructions branch from 07e1078 to d126605 Compare July 8, 2026 23:15

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

.claude/skills/igor-wave-dfref/SKILL.md:798

  • Same issue here: the "Reference URLs" table row uses the URL column for a statement. Converting it to a link (or moving the statement into the body text) would keep the table’s meaning consistent.
| NVAR_Exists | https://docs.wavemetrics.com/igorpro/commands/nvar_exists |
| SVAR_Exists | https://docs.wavemetrics.com/igorpro/commands/svar_exists |
| `Concatenate` destination when every source across a loop is 0-row | Destination wave is still created, with 0 rows — never left null |

Comment on lines 784 to 787
| Programming Techniques (DF patterns) | https://docs.wavemetrics.com/igorpro/programming/programming-techniques |
| WAVE keyword | https://docs.wavemetrics.com/igorpro/commands/wave |
| Conditionally-assigned WAVE ref used after the block | Safe — defaults to null if the branch didn't run, not an error |
| NewFreeWave | https://docs.wavemetrics.com/igorpro/commands/newfreewave |
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants