docs: clarify placeholder convention in resolve-pr-threads skill#42
Conversation
…ntion
Resolves AI confusion between template placeholders and GraphQL variables
by adopting GitHub's own `gh api` camelCase convention ({owner}, {repo},
{number}, {threadId}) instead of SCREAMING_CASE ({OWNER}, {REPO}, etc.).
Changes:
- Add "Placeholder Convention" section in graphql-queries.md with:
* Table of all placeholders with types, example values, and sources
* WRONG/CORRECT examples showing GraphQL $variable vs string substitution
* Explicit warning against using GraphQL $variable syntax with --raw-field
- Update all skill files to use camelCase placeholders
- Remove shell variable inference blocks from query templates (keep in orchestrator only)
- Add cross-references to placeholder convention from related files
- Update parameter tables and examples to match new convention
Files modified:
- github-workflows/skills/resolve-pr-threads/graphql-queries.md
- github-workflows/skills/resolve-pr-threads/SKILL.md
- github-workflows/skills/resolve-pr-threads/rest-api-patterns.md
- github-workflows/skills/finalize-prs/SKILL.md
Verification:
- markdownlint-cli2: all files pass
- No SCREAMING_CASE template placeholders remain (grep verified)
- Resolve thread mutation section provides clear guidance on substitution
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Important
Looks good to me! 👍
Reviewed everything up to 33de8e2 in 8 seconds. Click for details.
- Reviewed
309lines of code in4files - Skipped
0files when reviewing. - Skipped posting
0draft comments. View those below. - Modify your settings and rules to customize what types of comments Ellipsis leaves. And don't forget to react with 👍 or 👎 to teach Ellipsis.
Workflow ID: wflow_JUFld6cW1CsfyktJ
You can customize by changing your verbosity settings, reacting with 👍 or 👎, replying to comments, or adding code review rules.
Summary of ChangesHello @JacobPEvans, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly enhances the clarity and consistency of documentation within the Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request does a great job of standardizing placeholders to camelCase to improve clarity and prevent confusion for AI agents. The added documentation about direct string substitution versus GraphQL variables is also very helpful. I've added a couple of suggestions to further improve consistency by aligning shell variable names in examples with the new camelCase placeholder convention across the documentation files. Overall, these are excellent improvements to the skill's documentation.
There was a problem hiding this comment.
Pull request overview
This PR standardizes placeholder naming conventions in GraphQL query documentation from SCREAMING_CASE to camelCase (e.g., {OWNER} → {owner}, {REPO} → {repo}), aligning with GitHub's gh api convention. The primary goal is to prevent AI agents from confusing template placeholders with GraphQL $variable syntax, which causes type coercion errors when used with --raw-field.
Changes:
- Added comprehensive "Placeholder Convention" section with table, examples, and explicit warnings against GraphQL
$variablesyntax - Updated all template placeholders to camelCase across resolve-pr-threads and finalize-prs skills
- Removed shell context inference blocks from query templates (kept only in orchestrator)
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| github-workflows/skills/resolve-pr-threads/graphql-queries.md | Added Placeholder Convention section with WRONG/CORRECT examples; updated all placeholders to camelCase; removed context inference blocks |
| github-workflows/skills/resolve-pr-threads/rest-api-patterns.md | Added cross-reference to placeholder convention; updated all placeholders and examples to camelCase |
| github-workflows/skills/resolve-pr-threads/SKILL.md | Added warning about direct string substitution; updated placeholders in REST API pattern and output format |
| github-workflows/skills/finalize-prs/SKILL.md | Updated {TIMESTAMP} to {timestamp} for consistency |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Improves consistency with the camelCase placeholder convention by renaming
shell variables in code examples to match their corresponding placeholders:
- THREAD_ID -> threadId (matches {threadId} placeholder)
- thread_id -> threadId
- comment_id -> commentId (matches {commentId} placeholder)
This makes the examples clearer and reinforces the camelCase convention
throughout the documentation.
Addresses review feedback from gemini-code-assist.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
|
Re: copilot-pull-request-reviewer's feedback on graphql-queries.md:53-54 Thank you for catching this inconsistency! However, this concern was already addressed in commit 463a054, which standardized ALL shell variables to camelCase across both files: graphql-queries.md (this file):
rest-api-patterns.md:
Rationale: Shell variables now match the camelCase placeholder convention ( Note: Compound words like Commit 463a054 applied this consistently throughout both files. |
AI agents already have full context and don't need to save output to files. Removed the instruction to save JSON reports to /tmp/ directory. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Summary
Standardizes all placeholders to camelCase convention (
{owner},{repo},{number},{threadId}) throughout the resolve-pr-threads skill to prevent AI agents from confusing template placeholders with GraphQL$variablesyntax.Problem
AI agents were writing incorrect GraphQL queries like:
gh api graphql --raw-field 'query=mutation($threadId: ID!) { ... }'This fails because
--raw-fieldsends queries as-is without variable processing. The SCREAMING_CASE placeholders ({OWNER},{REPO}) looked like shell environment variables, leading AIs to reach for GraphQL's$variablesyntax instead of direct string substitution.Solution
gh apiitself uses camelCase placeholders like{owner},{repo},{branch}(see gh api manual)$variablesyntax with--raw-field"Files Changed
github-workflows/skills/resolve-pr-threads/graphql-queries.md- Added convention section, updated all placeholdersgithub-workflows/skills/resolve-pr-threads/SKILL.md- Added warning bullet, updated placeholdersgithub-workflows/skills/resolve-pr-threads/rest-api-patterns.md- Added cross-reference, updated all placeholdersgithub-workflows/skills/finalize-prs/SKILL.md- Updated{TIMESTAMP}to{timestamp}Test Plan
Impact
Low risk - Documentation-only change. The skill functionality remains identical; only the documentation format has been clarified to prevent AI misinterpretation.
🤖 Generated with Claude Code
Important
Standardizes placeholder conventions to camelCase in
resolve-pr-threadsdocumentation to prevent AI misinterpretation.{owner},{repo},{number},{threadId}) acrossresolve-pr-threadsskill.graphql-queries.mdwith a table of placeholders, types, example values, and sources.graphql-queries.md,SKILL.md, andrest-api-patterns.mdinresolve-pr-threadsto reflect camelCase placeholders.$variablesyntax with--raw-field.SKILL.mdinfinalize-prsto change{TIMESTAMP}to{timestamp}.This description was created by
for 33de8e2. You can customize this summary. It will automatically update as commits are pushed.