@skedulo/memory-hub-mcp 0.2.19 → 0.2.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/skills/ask/SKILL.md +114 -20
- package/assets/skills/ask/references/consultant.md +27 -0
- package/assets/skills/ask/references/delivery.md +47 -0
- package/assets/skills/ask/references/developer.md +27 -0
- package/assets/skills/ask/references/qa.md +33 -0
- package/dist/ask-prompt.js +14 -1
- package/package.json +1 -1
- package/skill-guide.md +7 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: ask
|
|
3
|
-
description: Use when someone asks what the team, a project or the hub knows, e.g. "what do we know about the Welbehealth rostering rules?", "ask the hub how job allocation works", "why did we stop syncing contacts for Acme?", "has anyone solved the token refresh problem?". It answers from
|
|
3
|
+
description: Use when someone asks what the team, a project or the hub knows, e.g. "what do we know about the Welbehealth rostering rules?", "ask the hub how job allocation works", "why did we stop syncing contacts for Acme?", "has anyone solved the token refresh problem?", "where is the Acme release at?", "which test cases cover manual entry?", "is bulk cancel in scope for Acme?". It answers as a delivery lead, developer, QA or consultant, picked from the question, from hub knowledge, inside or outside a project folder, fixes what it relies on when the code, a cited document, a ticket or a PR moved, and saves what it learns when the hub did not know.
|
|
4
4
|
argument-hint: "<question>"
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -8,13 +8,14 @@ argument-hint: "<question>"
|
|
|
8
8
|
|
|
9
9
|
Answer a question from what the hub already knows, for anyone: a developer in a repo, or someone in
|
|
10
10
|
Claude Desktop with no project folder open. Keeping knowledge current is one of the hub's core
|
|
11
|
-
principles, so this skill also fixes what it relies on when the code
|
|
12
|
-
it did not know.
|
|
11
|
+
principles, so this skill also fixes what it relies on when the code, a cited document, a ticket or
|
|
12
|
+
a PR moved, and grows the hub when it did not know. It answers in the role the question needs
|
|
13
|
+
(delivery lead, developer, QA or consultant), which changes what it reads and how it answers.
|
|
13
14
|
|
|
14
15
|
- **Plain language.** The person may not be a developer. Short sentences, no jargon they did not
|
|
15
|
-
use, and no tool names in the answer.
|
|
16
|
+
use, and no tool names in the answer, unless the role's file says otherwise.
|
|
16
17
|
- **Ask only for: joining a team, which repo when it is unclear, and which sources to read**
|
|
17
|
-
(steps 3,
|
|
18
|
+
(steps 3, 9 and 7). Everything else you decide. Joining is the person's choice, so never join
|
|
18
19
|
without their yes.
|
|
19
20
|
- **Never paste SOW or Slack text.** Say what it means in your own words and name where it came from.
|
|
20
21
|
- **Never reveal others' Private items.** The hub never returns them; never guess at them either.
|
|
@@ -36,7 +37,33 @@ server is older than this release. Stop, do nothing else, and say it must be upd
|
|
|
36
37
|
|
|
37
38
|
## 1. Read the question
|
|
38
39
|
|
|
39
|
-
Note the project or customer it names, if any
|
|
40
|
+
Note the project or customer it names, if any. A link names it too: a Linear project or ticket, a
|
|
41
|
+
GitHub PR, or a Confluence or Drive document is the question's subject. Find the project's repos
|
|
42
|
+
with `memory_listRepos`, called without a query, by keeping those whose team is the project or
|
|
43
|
+
customer: a repo's own name often does not include it.
|
|
44
|
+
|
|
45
|
+
Then pick the role to answer as, and read its file in this skill's folder before step 2 (as a
|
|
46
|
+
prompt, the role files follow this skill):
|
|
47
|
+
|
|
48
|
+
- **delivery** (`references/delivery.md`): progress, dates, milestones, risks, releases, what is
|
|
49
|
+
blocked or left;
|
|
50
|
+
- **developer** (`references/developer.md`): how the code works, where something lives, how to
|
|
51
|
+
change or fix it;
|
|
52
|
+
- **qa** (`references/qa.md`): test cases, UAT, defects, what to test or what is untested;
|
|
53
|
+
- **consultant** (`references/consultant.md`): rules, scope, what the customer asked for or
|
|
54
|
+
agreed, what not to build, bug or change.
|
|
55
|
+
|
|
56
|
+
The person's own words decide first ("as a PM", "as a dev", "as QA", "as a BA"), then the question.
|
|
57
|
+
When the question fits none clearly, use the default in the persona's `preferences` (a line
|
|
58
|
+
"ask role: <role>", from `memory_sessionContext`); with none, answer without a role file. A question
|
|
59
|
+
that plainly spans two roles uses both files, never more. When you inferred the role, name it in
|
|
60
|
+
the answer's first line so the person can redirect it.
|
|
61
|
+
|
|
62
|
+
When the person asks to make a role their default, take the persona's `preferences` from
|
|
63
|
+
`memory_sessionContext`, add or replace its "ask role: <role>" line, and pass the whole text back
|
|
64
|
+
with `memory_upsertPersona`, which replaces the field.
|
|
65
|
+
|
|
66
|
+
Pick the types to search, starting with those the role's file names:
|
|
40
67
|
|
|
41
68
|
- **Facts and Scenarios** for decisions, history and "why did we…";
|
|
42
69
|
- **Skills** for how-tos and architecture maps ("how does X work", "how do I…");
|
|
@@ -46,7 +73,7 @@ When unsure, search all four.
|
|
|
46
73
|
|
|
47
74
|
Note too whether you have a checkout of the project's repo and the project-knowledge skill
|
|
48
75
|
(`memory-hub:project-knowledge` when installed as a plugin). In Claude Desktop you have neither, and
|
|
49
|
-
steps 4 to
|
|
76
|
+
steps 4 to 7 say what changes.
|
|
50
77
|
|
|
51
78
|
## 2. Search the hub
|
|
52
79
|
|
|
@@ -66,7 +93,7 @@ teams the person is on) before treating it as unrecorded. If none of their teams
|
|
|
66
93
|
say that its knowledge may be shared with its team only, and that saying "join the <team> team"
|
|
67
94
|
shows it, using the project's name as the team name when you know no better. Call `memory_joinTeam`
|
|
68
95
|
only after they say yes, since joining changes who reads what; then go back to step 2. If it says no
|
|
69
|
-
such team exists, or they do not say yes, carry on to step
|
|
96
|
+
such team exists, or they do not say yes, carry on to step 7 with what you have.
|
|
70
97
|
|
|
71
98
|
## 4. Check what you rely on
|
|
72
99
|
|
|
@@ -100,7 +127,7 @@ answer that the hub's memory was behind it. Then:
|
|
|
100
127
|
- **Project page:** it is never edited here. Without a checkout of the project's repo or the
|
|
101
128
|
project-knowledge skill (for example in Claude Desktop), never hand off: answer from the reread
|
|
102
129
|
document, save a Fact on the page's repo that names the page and entry ID and says what the
|
|
103
|
-
document now says (step
|
|
130
|
+
document now says (step 9), and tell the person a developer can update the project page with
|
|
104
131
|
"update the <Project> knowledge". With both, hand the change to project-knowledge's targeted
|
|
105
132
|
update, which owns the page and its Sources line. Hand over what you took from the reread document as the change list. Add the document's
|
|
106
133
|
new version (Confluence `version.number`, or Drive `modifiedTime`) only when you read the whole
|
|
@@ -118,7 +145,74 @@ text: say what it means in your own words and name the document.
|
|
|
118
145
|
|
|
119
146
|
Keep each fix (uid and what changed) for the closing line.
|
|
120
147
|
|
|
121
|
-
## 6.
|
|
148
|
+
## 6. Check the live state of work
|
|
149
|
+
|
|
150
|
+
A memory about work in progress is a snapshot. Tickets move and PRs merge or close after it was
|
|
151
|
+
saved, and work that never went through a hub session (a teammate's, a QA move, a PR closed by hand)
|
|
152
|
+
is not in the hub at all. Do this step:
|
|
153
|
+
|
|
154
|
+
- always for the delivery and QA roles;
|
|
155
|
+
- for any role, when the question is about progress, status, or what is open, done or released;
|
|
156
|
+
- for any role, when the answer rests on an item that states a ticket or PR status ("Status as
|
|
157
|
+
of…", "PR #n open", "In QA").
|
|
158
|
+
|
|
159
|
+
The role's file says what else to list.
|
|
160
|
+
|
|
161
|
+
1. **List recent work.** Pick the window: the last 14 days, or since the oldest status date among
|
|
162
|
+
the items you rely on when that is earlier, never more than 30 days. Pick the repos: those of
|
|
163
|
+
the items you rely on and, for a progress or status question that names a project, its team's
|
|
164
|
+
repos from `memory_listRepos`. In each, list the PRs opened, merged or closed in the window:
|
|
165
|
+
`gh pr list -R <owner/name> --state all --limit 100 --search "updated:>=<date>" --json
|
|
166
|
+
number,title,state,author,mergedAt,closedAt,updatedAt,headRefName`, and drop those whose author
|
|
167
|
+
is a bot (`author.is_bot`, or a login ending in `[bot]`). For a status question that names a
|
|
168
|
+
project, also list the tickets updated in the window, at most 100 in all: those in the Linear
|
|
169
|
+
projects, or under the parent tickets, of the tickets the memories cite (a name search misses
|
|
170
|
+
stories whose titles do not name the customer), plus a search by the project or customer name.
|
|
171
|
+
2. **Check what the memories cite.** Match each ticket and PR an item you rely on names against
|
|
172
|
+
those lists, and look up only the ones they missed: at most 20 calls in all, and flag the rest
|
|
173
|
+
as not checked.
|
|
174
|
+
- A ticket (its `externalRef`, or a ticket ID in its text): one Linear or Jira call for its
|
|
175
|
+
status, assignee and last update.
|
|
176
|
+
- A PR written as `<owner/name>#<n>` or as a link: `gh pr view <n> -R <owner/name> --json
|
|
177
|
+
state,mergedAt,closedAt,title,headRefName`.
|
|
178
|
+
- A bare `#<n>` may be in any of the project's repos. Take a PR as the one cited only when its
|
|
179
|
+
title or branch names a ticket the item cites; otherwise say in the answer that you could not
|
|
180
|
+
tell which PR it is.
|
|
181
|
+
3. **Read more only where it matters.** Read the comments of at most five tickets: those whose status
|
|
182
|
+
changed since the hub's note, those whose PR was closed without merging, and those waiting on a
|
|
183
|
+
decision. Read nothing else.
|
|
184
|
+
|
|
185
|
+
Then:
|
|
186
|
+
|
|
187
|
+
- **Which state wins.** A merged PR or a recorded release beats any ticket status. A ticket beats
|
|
188
|
+
the memory only when the ticket's last update is later than the memory's status date (its "as of"
|
|
189
|
+
date, else its `lastModifiedDate`). Never move a memory backward on a ticket alone, for example
|
|
190
|
+
from shipped to "Ready for Prod": tickets are often left behind. When a ticket disagrees and does
|
|
191
|
+
not win, say in the answer that the ticket may be behind, and change nothing.
|
|
192
|
+
- **A memory whose status is now wrong:** add a status note to it under the guide's "Stale
|
|
193
|
+
memories" rules: one `memory_update` that adds a dated line at the top saying where the work now
|
|
194
|
+
stands and where that was seen ("UPDATE <date> (GitHub): PR #123 closed without merging"), and
|
|
195
|
+
keeps the rest. Say what is true now; never write that the rest is out of date. Flag, instead of
|
|
196
|
+
editing, an item those rules say you cannot edit. A project page is never edited here: handle it
|
|
197
|
+
as step 5 handles a project page that is behind its document. Status notes are not among step
|
|
198
|
+
4's three fixes. At most five status notes per question; flag the rest in the answer.
|
|
199
|
+
- **What the hub had no memory of** goes into step 9 as the project's status snapshot: one Fact on
|
|
200
|
+
the project's repo that starts "<Project> status snapshot, <date>", with ticket statuses, PR
|
|
201
|
+
states, open decisions and newly seen tickets, and `externalRef` set to the main ticket when
|
|
202
|
+
there is one. Find the last snapshot first (`memory_recall type=Fact scope=team` for
|
|
203
|
+
"<Project> status snapshot") and pass its uid as `supersedes`, so the hub keeps one.
|
|
204
|
+
- **In the answer,** say which live sources you checked and when. Anything you did not check keeps
|
|
205
|
+
the date the hub gave it.
|
|
206
|
+
|
|
207
|
+
Without a shell (for example in Claude Desktop), check PRs through a GitHub connector if one is
|
|
208
|
+
attached. If Linear, Jira or GitHub cannot be reached, say in the answer what was not checked and
|
|
209
|
+
use the memories as they are. Never paste ticket comments: say what they mean and name the ticket.
|
|
210
|
+
|
|
211
|
+
Keep each correction (uid and what changed) for the closing line.
|
|
212
|
+
|
|
213
|
+
## 7. When the hub has nothing
|
|
214
|
+
|
|
215
|
+
If step 6 found the answer, skip this step: answer (step 8) and save it (step 9).
|
|
122
216
|
|
|
123
217
|
If nothing found answers the question, say so plainly, then ask which sources to read:
|
|
124
218
|
links or names of documents, tickets, Slack channels or repos. In the
|
|
@@ -130,23 +224,23 @@ team when it is about a project.
|
|
|
130
224
|
- Read only the sources they give.
|
|
131
225
|
- If they say "search everything" after that warning, and you have a checkout of the project's
|
|
132
226
|
repo and the project-knowledge skill, run it for that project, then answer from the pages it
|
|
133
|
-
saved. It saves those pages itself: step
|
|
227
|
+
saved. It saves those pages itself: step 9 saves nothing more. Without them (for example in
|
|
134
228
|
Claude Desktop), explain that searching everything needs Claude Code opened in the project's
|
|
135
229
|
repo, and offer to read the sources they name instead.
|
|
136
|
-
- If they give no sources, answer that the hub does not know, and
|
|
230
|
+
- If they give no sources, answer that the hub does not know, and close as step 10 says.
|
|
137
231
|
|
|
138
|
-
Then answer (step
|
|
232
|
+
Then answer (step 8), and save what you found (step 9) without asking again.
|
|
139
233
|
|
|
140
|
-
##
|
|
234
|
+
## 8. Answer
|
|
141
235
|
|
|
142
|
-
Answer briefly, in plain language. Back each claim with the item it came from: its uid, its title
|
|
236
|
+
Answer briefly, shaped as the role's file says, in plain language unless it says otherwise. Back each claim with the item it came from: its uid, its title
|
|
143
237
|
and, when it has one, its source as `<owner/name>@<short commit>`. Say plainly what the hub does not
|
|
144
|
-
know. Mention anything flagged in steps 4
|
|
238
|
+
know. Mention anything flagged in steps 4 to 6.
|
|
145
239
|
|
|
146
|
-
##
|
|
240
|
+
## 9. Save what was learned
|
|
147
241
|
|
|
148
|
-
Save only what came from the sources read in steps 5
|
|
149
|
-
corrections found in steps 4
|
|
242
|
+
Save only what came from the sources read in steps 5 to 7, not what the hub already had;
|
|
243
|
+
corrections found in steps 4 to 6 are already made by their `memory_update`. One `memory_save` per
|
|
150
244
|
durable point: a Fact for a decision or finding, a Skill for a how-to. Pass `supersedes` with the old
|
|
151
245
|
uid when it replaces an existing memory, and a `source` when it came from code.
|
|
152
246
|
|
|
@@ -157,7 +251,7 @@ source.
|
|
|
157
251
|
Decide the visibility by the guide's "What to share" section
|
|
158
252
|
(`memory_getSkillGuide section="What to share"`), and state the choice and the reason in the answer.
|
|
159
253
|
|
|
160
|
-
##
|
|
254
|
+
## 10. Close
|
|
161
255
|
|
|
162
256
|
End with the one line of what changed: each update and save by uid, with the visibility of each
|
|
163
257
|
save, or "Nothing changed."
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Answering as a consultant or BA
|
|
2
|
+
|
|
3
|
+
For business rules, scope, what the customer asked for or agreed, what not to build, and whether a
|
|
4
|
+
request is a bug or a change.
|
|
5
|
+
|
|
6
|
+
## Search first
|
|
7
|
+
|
|
8
|
+
- The project's Rules pages (rules with IDs and tiers), its Don't build page, and its Reference
|
|
9
|
+
pages (overview, glossary, workflows).
|
|
10
|
+
- Facts on decisions and on the customer's answers to questions.
|
|
11
|
+
- `<Project> › Sources`, for the documents behind each rule.
|
|
12
|
+
|
|
13
|
+
## Live sources
|
|
14
|
+
|
|
15
|
+
- The documents the rules cite (SOW, TDD, design pages), through step 5. Step 5's checks matter
|
|
16
|
+
most for this role: a changed SOW or TDD changes the scope.
|
|
17
|
+
- Tickets only for a decision recorded in their comments: at most five tickets' comments.
|
|
18
|
+
|
|
19
|
+
## Answer
|
|
20
|
+
|
|
21
|
+
- Answer with the rule IDs that decide it, and say what each means in your own words.
|
|
22
|
+
- In or out of scope: name the rule, the Don't build entry, or the document behind it. When nothing
|
|
23
|
+
covers it, say so: it is a new requirement, which needs a change request.
|
|
24
|
+
- Bug or change: a bug breaks an agreed rule or acceptance criterion; anything else the customer
|
|
25
|
+
now wants is a change. Name what it was measured against.
|
|
26
|
+
|
|
27
|
+
Never paste SOW text, and never name commercial terms (prices, rates, budgets).
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# Answering as a delivery lead
|
|
2
|
+
|
|
3
|
+
For progress, dates, milestones, risks, releases, and what is blocked or left. Step 6 always runs
|
|
4
|
+
for this role.
|
|
5
|
+
|
|
6
|
+
## Search first
|
|
7
|
+
|
|
8
|
+
- Facts and Scenarios on the project's repos: the latest "<Project> status snapshot", release
|
|
9
|
+
Facts, and plan Scenarios.
|
|
10
|
+
- The project's Reference pages only when the answer needs its scope.
|
|
11
|
+
|
|
12
|
+
## Live sources (in step 6)
|
|
13
|
+
|
|
14
|
+
Find the Linear project: the one the question links, else the project of the tickets the memories
|
|
15
|
+
cite (at most three projects, the most cited first).
|
|
16
|
+
|
|
17
|
+
1. Get the project with its milestones (name, target date, progress), its status, target date and
|
|
18
|
+
lead.
|
|
19
|
+
2. Read its latest project update: health, date and what it says. Never paste it.
|
|
20
|
+
3. List its issues: every open one whatever its last update, since stalled work is what a status
|
|
21
|
+
answer most needs, and those completed or canceled in step 6's window. They count toward step
|
|
22
|
+
6's 100 tickets.
|
|
23
|
+
4. Release and deploy tickets done in the window say what reached which environment.
|
|
24
|
+
|
|
25
|
+
Then check PRs as step 6 says.
|
|
26
|
+
|
|
27
|
+
## When Linear itself is behind
|
|
28
|
+
|
|
29
|
+
Project status, milestone progress and target dates are set by hand and are often left behind.
|
|
30
|
+
Flag these in the answer as "Linear may be behind", and never correct the hub from them:
|
|
31
|
+
|
|
32
|
+
- a milestone whose target date has passed with progress under 100%;
|
|
33
|
+
- a project status that does not match its issues, for example Backlog while stories are in UAT;
|
|
34
|
+
- a latest project update older than 14 days.
|
|
35
|
+
|
|
36
|
+
## Answer
|
|
37
|
+
|
|
38
|
+
1. One line on where the project stands against its next milestone date (on track, at risk or
|
|
39
|
+
behind) and why.
|
|
40
|
+
2. Milestones: the last one passed and the next two, each with its target date and progress.
|
|
41
|
+
3. Work by state: done or released (with the environment and version when the hub knows them), in
|
|
42
|
+
UAT or QA, in progress, waiting (and on whom: the customer, or another team's ticket), not
|
|
43
|
+
started.
|
|
44
|
+
4. Risks and decisions waiting, each naming its ticket.
|
|
45
|
+
5. What was not checked, and each "Linear may be behind" flag.
|
|
46
|
+
|
|
47
|
+
Ticket IDs are fine in the answer; tool names are not.
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Answering as a developer
|
|
2
|
+
|
|
3
|
+
For how the code works, where something lives, why it behaves as it does, and how to change or fix
|
|
4
|
+
it.
|
|
5
|
+
|
|
6
|
+
## Search first
|
|
7
|
+
|
|
8
|
+
- Skills (architecture maps and how-tos) and Facts with a `source`, on the project's repos.
|
|
9
|
+
- The project's Rules pages only when a rule constrains the change; cite the rule's ID.
|
|
10
|
+
|
|
11
|
+
## Live sources
|
|
12
|
+
|
|
13
|
+
- The code. With a checkout, confirm the answer in the files the items you rely on cite, read at
|
|
14
|
+
`origin/<default>` (`git show origin/<default>:<path>`), never the working tree. Read at most
|
|
15
|
+
five other files to fill a gap. Step 4's staleness check matters most for this role.
|
|
16
|
+
- Without a checkout, say the answer was not checked against the code, and give each item's
|
|
17
|
+
"verified <n> days ago".
|
|
18
|
+
- PRs only when the question is about a change in flight, through step 6.
|
|
19
|
+
|
|
20
|
+
## Answer
|
|
21
|
+
|
|
22
|
+
- Lead with the answer, then where it lives: `<owner/name>@<short commit>:<path>` for each place,
|
|
23
|
+
and the uid of each memory used.
|
|
24
|
+
- Name the gotchas the memories record, with their uids.
|
|
25
|
+
- File paths, function names, commands and tool names are fine for this role. Use no jargon the
|
|
26
|
+
code and the question do not use.
|
|
27
|
+
- When the code contradicts a memory, the code wins: say so, and fix the memory under step 4.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Answering as QA
|
|
2
|
+
|
|
3
|
+
For test cases, UAT, defects, regressions, and what to test or what is untested. Step 6 runs for
|
|
4
|
+
this role, for the stories the question is about.
|
|
5
|
+
|
|
6
|
+
## Search first
|
|
7
|
+
|
|
8
|
+
- The project's Rules pages for the feature: the expected behaviour, with rule IDs. These are what
|
|
9
|
+
a test checks.
|
|
10
|
+
- Facts and Scenarios on known issues, defects and UAT findings.
|
|
11
|
+
|
|
12
|
+
## Live sources (in step 6)
|
|
13
|
+
|
|
14
|
+
For each story the question is about (named by ID or title, or the feature's stories in its Linear
|
|
15
|
+
project), at most 15 stories:
|
|
16
|
+
|
|
17
|
+
- its status and its acceptance criteria (the ticket's description: read it, never paste it);
|
|
18
|
+
- its sub-tickets, above all its test-case tickets (titles like "Create test cases - …"), and their
|
|
19
|
+
state;
|
|
20
|
+
- defects: bug tickets linked to it, or in its project naming the feature, and their state.
|
|
21
|
+
|
|
22
|
+
Take these from one listing of the project's issues, which gives each sub-ticket's parent, rather
|
|
23
|
+
than a call per story. Read comments only on stories that failed QA or UAT or were sent back, within
|
|
24
|
+
step 6's five.
|
|
25
|
+
|
|
26
|
+
## Answer
|
|
27
|
+
|
|
28
|
+
- For each story: its state, its test cases (done, canceled or missing) and its open defects.
|
|
29
|
+
- Gaps: stories in QA or UAT with no done test-case ticket, rules no story or test covers, and
|
|
30
|
+
known issues the hub records that have no ticket.
|
|
31
|
+
- What to test next, riskiest first, each tied to a rule ID or an acceptance criterion.
|
|
32
|
+
|
|
33
|
+
Never paste test steps or ticket text: say what they mean and name the ticket.
|
package/dist/ask-prompt.js
CHANGED
|
@@ -26,7 +26,8 @@ function skillPaths(assetsDir) {
|
|
|
26
26
|
function readSkillBody(assetsDir) {
|
|
27
27
|
for (const path of skillPaths(assetsDir)) {
|
|
28
28
|
try {
|
|
29
|
-
|
|
29
|
+
const body = (0, fs_1.readFileSync)(path, 'utf-8').replace(/^---\r?\n[\s\S]*?\r?\n---\r?\n/, '').trim();
|
|
30
|
+
return [body, ...roleFiles((0, path_1.dirname)(path))].join('\n\n');
|
|
30
31
|
}
|
|
31
32
|
catch {
|
|
32
33
|
continue;
|
|
@@ -34,6 +35,18 @@ function readSkillBody(assetsDir) {
|
|
|
34
35
|
}
|
|
35
36
|
return undefined;
|
|
36
37
|
}
|
|
38
|
+
// A prompt has no skill folder to read from, so the role files ride along.
|
|
39
|
+
function roleFiles(skillDir) {
|
|
40
|
+
const folder = (0, path_1.join)(skillDir, 'references');
|
|
41
|
+
let names;
|
|
42
|
+
try {
|
|
43
|
+
names = (0, fs_1.readdirSync)(folder).filter((name) => name.endsWith('.md')).sort();
|
|
44
|
+
}
|
|
45
|
+
catch {
|
|
46
|
+
return [];
|
|
47
|
+
}
|
|
48
|
+
return names.map((name) => `## references/${name}\n\n${(0, fs_1.readFileSync)((0, path_1.join)(folder, name), 'utf-8').trim()}`);
|
|
49
|
+
}
|
|
37
50
|
function askPromptText(question, assetsDir) {
|
|
38
51
|
const body = readSkillBody(assetsDir) || FALLBACK;
|
|
39
52
|
return `${body}\n\n## The question\n\n${question.trim()}\n`;
|
package/package.json
CHANGED
package/skill-guide.md
CHANGED
|
@@ -95,10 +95,9 @@ list is prose, kept in sync by hand.
|
|
|
95
95
|
developer prefers to work emerged this session (a standing preference, a
|
|
96
96
|
recurring decision pattern). Pass only the field(s) that changed
|
|
97
97
|
(`preferences`, `decisions`, `patterns`) — **this replaces each field's
|
|
98
|
-
content entirely, it does not append.**
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
what's already there.
|
|
98
|
+
content entirely, it does not append.** To add to a field, read its
|
|
99
|
+
current text from `memory_sessionContext`'s `persona` and pass back the
|
|
100
|
+
whole text with your change.
|
|
102
101
|
- **`type: 'Wiki'`** — a standing reference, not a one-off decision:
|
|
103
102
|
"how the deploy pipeline works," "what each config variable does," "the
|
|
104
103
|
object model's relationships" — or a whole project document: an SOW, a
|
|
@@ -551,6 +550,10 @@ Before relying on a stale item, verify, then flag, then fix:
|
|
|
551
550
|
Rules:
|
|
552
551
|
|
|
553
552
|
- At most three fixes per task. Flag the rest to the developer.
|
|
553
|
+
- A status note is not a fix: one dated line added at the top of a memory that says where a ticket
|
|
554
|
+
or PR now stands and where that was seen (`UPDATE <date> (GitHub): PR #123 closed without
|
|
555
|
+
merging`), the rest left as it is. At most five status notes per task, under the same rules on
|
|
556
|
+
who may edit what. Flag the rest.
|
|
554
557
|
- `source.commit` only moves forward: only when `git merge-base --is-ancestor <old> <new>` passes,
|
|
555
558
|
and never onto an unmerged commit. When `target` is `HEAD` (no `origin/<default>` to compare
|
|
556
559
|
with), never move `source`; flag it instead.
|