Skip to content

Commit db1eefa

Browse files
KyleAMathewsclaude
andcommitted
fix: feedback skill submits directly via gh, no CLI intermediary
The feedback-collection skill now instructs agents to use gh issue create directly (or tell the user how to submit manually) instead of routing through the intent feedback CLI. Simpler, fewer failure modes, better formatting. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 9eba700 commit db1eefa

File tree

3 files changed

+69
-70
lines changed

3 files changed

+69
-70
lines changed

packages/intent/meta/feedback-collection/SKILL.md

Lines changed: 67 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,11 @@ description: >
44
Collect structured feedback about skill usage after completing a coding task.
55
Activate at the end of any session where one or more SKILL.md files were
66
loaded. Captures agent signals (gaps, errors, corrections, human interventions)
7-
and brief human input, then submits via the intent feedback CLI.
7+
and brief human input, then submits directly via gh CLI or provides manual
8+
submission instructions.
89
metadata:
9-
version: '1.0'
10+
version: '2.0'
1011
category: meta-tooling
11-
output_artifacts:
12-
- intent-feedback.json
1312
---
1413

1514
# Skill Feedback Collection
@@ -83,74 +82,80 @@ If the human gives an explicit rating, use that instead.
8382

8483
---
8584

86-
## Phase 3 — Build the Payload
87-
88-
Construct one JSON payload per skill used. The schema must match exactly:
89-
90-
```json
91-
{
92-
"skill": "<skill name from SKILL.md frontmatter>",
93-
"package": "<npm package name that contains the skill>",
94-
"skillVersion": "<metadata.version from SKILL.md frontmatter, or library_version>",
95-
"task": "<one-sentence summary of what the human asked you to do>",
96-
"whatWorked": "<patterns/instructions from the skill that were accurate and helpful>",
97-
"whatFailed": "<errors from 1b — what the skill got wrong>",
98-
"missing": "<gaps from 1a — what the skill should have covered>",
99-
"selfCorrections": "<fixes you applied from 1b + interventions from 1c>",
100-
"userRating": "good | mixed | bad",
101-
"userComments": "<optional — direct quotes or paraphrased human input from Phase 2>"
102-
}
103-
```
85+
## Phase 3 — Build the Feedback
10486

105-
### Field derivation guide
87+
Write one Markdown feedback file per skill used. Only include skills that were
88+
actually used during the session — skip any that were loaded but never
89+
referenced.
90+
91+
### Template
92+
93+
```markdown
94+
# Skill Feedback: [skill name from SKILL.md frontmatter]
95+
96+
**Package:** [npm package name that contains the skill]
97+
**Skill version:** [metadata.version or library_version from frontmatter]
98+
**Rating:** [good | mixed | bad]
99+
100+
## Task
101+
[one-sentence summary of what the human asked you to do]
102+
103+
## What Worked
104+
[patterns/instructions from the skill that were accurate and helpful]
105+
106+
## What Failed
107+
[from 1b — skill instructions that produced errors]
108+
109+
## Missing
110+
[from 1a — gaps where the skill should have covered]
106111

107-
| Field | Source |
108-
| ----------------- | ------------------------------------------------------------------ |
109-
| `skill` | Frontmatter `name` field of the SKILL.md you loaded |
110-
| `package` | The npm package the skill lives in (e.g. `@tanstack/query-intent`) |
111-
| `skillVersion` | Frontmatter `metadata.version` or `library_version` |
112-
| `task` | Summarize the human's original request in one sentence |
113-
| `whatWorked` | List skill sections/patterns that were correct and useful |
114-
| `whatFailed` | From 1b — skill instructions that produced errors |
115-
| `missing` | From 1a — gaps where the skill was silent |
116-
| `selfCorrections` | From 1b fixes + 1c human interventions, combined |
117-
| `userRating` | From Phase 2 sentiment analysis or explicit rating |
118-
| `userComments` | From Phase 2 answers, keep brief |
119-
120-
### Example
121-
122-
```json
123-
{
124-
"skill": "tanstack-query/core",
125-
"package": "@anthropic/tanstack-query-intent",
126-
"skillVersion": "1.0",
127-
"task": "Add optimistic updates to a mutation with rollback on error",
128-
"whatWorked": "Setup pattern was correct. onMutate/onError/onSettled lifecycle was accurate.",
129-
"whatFailed": "Cache key format used array syntax that doesn't match v5 — had to switch to queryOptions pattern.",
130-
"missing": "No guidance on TypeScript generics for mutation variables. Had to read source.",
131-
"selfCorrections": "Fixed cache key format. Human corrected the rollback type to include undefined.",
132-
"userRating": "mixed",
133-
"userComments": "The optimistic update pattern was helpful but the cache key thing wasted 10 minutes."
134-
}
112+
## Self-Corrections
113+
[from 1b fixes + 1c human interventions, combined]
114+
115+
## User Comments
116+
[optional — direct quotes or paraphrased human input from Phase 2]
135117
```
136118

137-
If multiple skills were loaded, produce one payload per skill. Only include
138-
skills that were actually used during the session — skip any that were loaded
139-
but never referenced.
119+
### Field derivation guide
120+
121+
| Field | Source |
122+
| ---------------- | ------------------------------------------------------------------ |
123+
| Skill name | Frontmatter `name` field of the SKILL.md you loaded |
124+
| Package | The npm package the skill lives in (e.g. `@tanstack/query-intent`) |
125+
| Skill version | Frontmatter `metadata.version` or `library_version` |
126+
| Task | Summarize the human's original request in one sentence |
127+
| What Worked | List skill sections/patterns that were correct and useful |
128+
| What Failed | From 1b — skill instructions that produced errors |
129+
| Missing | From 1a — gaps where the skill was silent |
130+
| Self-Corrections | From 1b fixes + 1c human interventions, combined |
131+
| Rating | From Phase 2 sentiment analysis or explicit rating |
132+
| User Comments | From Phase 2 answers, keep brief |
140133

141134
---
142135

143136
## Phase 4 — Submit
144137

145-
1. Save the payload to `intent-feedback.json` in the project root.
146-
If multiple skills, save as a JSON array.
138+
Determine the target repo from the skill's package. The repo is typically
139+
derivable from the `repository` field in the package's `package.json`, or
140+
from the `sources` field in the SKILL.md frontmatter.
141+
142+
### If `gh` CLI is available
143+
144+
Submit directly as a GitHub issue:
145+
146+
```bash
147+
gh issue create --repo [owner/repo] --title "Skill Feedback: [skill-name] ([rating])" --label "feedback:[skill-name]" --body-file intent-feedback.md
148+
```
149+
150+
If the label doesn't exist, omit the `--label` flag — don't let a missing
151+
label block submission.
147152

148-
2. Submit:
153+
If submission succeeds, delete the feedback file.
149154

150-
```bash
151-
npx intent feedback --submit --file intent-feedback.json
152-
```
155+
### If `gh` CLI is not available
153156

154-
3. If the submission succeeds, delete `intent-feedback.json`.
157+
Tell the human:
155158

156-
4. If it fails, tell the human and leave the file for manual retry.
159+
> "I've written skill feedback to `intent-feedback.md`. To submit it,
160+
> open an issue at https://github.com/[owner/repo]/issues and paste the
161+
> contents."

packages/intent/src/cli.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -172,10 +172,7 @@ async function cmdList(args: string[]): Promise<void> {
172172
console.log(`Feedback:`)
173173
console.log(` After completing your task, collect feedback on skill usage.`)
174174
console.log(
175-
` Instructions: node_modules/@tanstack/intent/meta/feedback-collection/SKILL.md`,
176-
)
177-
console.log(
178-
` Submit: npx intent feedback --submit --file intent-feedback.json`,
175+
` Load: node_modules/@tanstack/intent/meta/feedback-collection/SKILL.md`,
179176
)
180177
console.log()
181178

packages/intent/src/intent-library.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -152,10 +152,7 @@ async function cmdList(): Promise<void> {
152152
console.log(`Feedback:`)
153153
console.log(` After completing your task, collect feedback on skill usage.`)
154154
console.log(
155-
` Instructions: node_modules/@tanstack/intent/meta/feedback-collection/SKILL.md`,
156-
)
157-
console.log(
158-
` Submit: npx intent feedback --submit --file intent-feedback.json`,
155+
` Load: node_modules/@tanstack/intent/meta/feedback-collection/SKILL.md`,
159156
)
160157
console.log()
161158

0 commit comments

Comments
 (0)