fraim 2.0.208 → 2.0.209
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.
|
@@ -56,17 +56,20 @@ function buildDeferredToolBootstrapSection(profile) {
|
|
|
56
56
|
function buildFraimInvocationBody(profile = 'none') {
|
|
57
57
|
return `Follow this process:
|
|
58
58
|
|
|
59
|
-
${buildDeferredToolBootstrapSection(profile)}1. **
|
|
59
|
+
${buildDeferredToolBootstrapSection(profile)}1. **Confirm FRAIM activation**:
|
|
60
|
+
Use this process only when the user explicitly invokes FRAIM, names a FRAIM job, asks what FRAIM job to run, or the active surface has already selected a FRAIM job. For ordinary requests, answer or work normally; do not scan FRAIM stubs first.
|
|
61
|
+
|
|
62
|
+
2. **If the user did not specify a FRAIM job or topic after activation**:
|
|
60
63
|
If local FRAIM job stubs are present in the workspace, inspect those first and match the request locally. Also inspect \`fraim/personalized-employee/jobs/\` for local overrides or repo-specific jobs. If local files are missing or you cannot inspect workspace files, call \`list_fraim_jobs()\` to view the full catalog, including any proxy-discoverable personalized jobs.
|
|
61
64
|
|
|
62
|
-
|
|
63
|
-
|
|
65
|
+
3. **Find the match**:
|
|
66
|
+
If the user names an exact FRAIM job, call \`get_fraim_job({ job: "<job-name>" })\` directly. Otherwise, match the user's request to a FRAIM job from the local stub catalog, \`fraim/personalized-employee/jobs/\`, or the full \`list_fraim_jobs()\` response. If no exact or high-confidence job match exists, say that no FRAIM job matches and continue with normal tools or ask one concise clarification. Do not pick the nearest catalog job.
|
|
64
67
|
|
|
65
|
-
|
|
68
|
+
4. **Load the full content**:
|
|
66
69
|
- For jobs, call \`get_fraim_job({ job: "<matched-job-name>" })\`.
|
|
67
70
|
- For skills, use the content returned by \`get_fraim_file(...)\`.
|
|
68
71
|
|
|
69
|
-
|
|
72
|
+
5. **Execute**:
|
|
70
73
|
- For jobs, follow the phased instructions and use \`seekMentoring\` when the job requires phase transitions.
|
|
71
74
|
- For skills, apply the skill steps directly to the user's current context.
|
|
72
75
|
`;
|
|
@@ -96,18 +99,18 @@ ${buildFraimInvocationBody('generic-tool-discovery')}
|
|
|
96
99
|
`;
|
|
97
100
|
}
|
|
98
101
|
function buildCodexSkillContent() {
|
|
99
|
-
return `# FRAIM
|
|
100
|
-
|
|
102
|
+
return `# FRAIM
|
|
103
|
+
|
|
101
104
|
${buildFraimInvocationBody('codex-tool-search')}`;
|
|
102
105
|
}
|
|
103
106
|
function buildGrokSkillContent() {
|
|
104
|
-
return `# FRAIM
|
|
105
|
-
|
|
107
|
+
return `# FRAIM
|
|
108
|
+
|
|
106
109
|
${buildFraimInvocationBody('generic-tool-discovery')}`;
|
|
107
110
|
}
|
|
108
111
|
function buildWindsurfCommandContent() {
|
|
109
|
-
return `# FRAIM
|
|
110
|
-
|
|
112
|
+
return `# FRAIM
|
|
113
|
+
|
|
111
114
|
${buildFraimInvocationBody('generic-tool-discovery')}`;
|
|
112
115
|
}
|
|
113
116
|
function buildKiroCommandContent() {
|
|
@@ -69,8 +69,12 @@ This repository uses FRAIM.
|
|
|
69
69
|
- Skills under \`${employeeSkillsPath}/\` are reusable capabilities that jobs compose.
|
|
70
70
|
- Rules under \`${employeeRulesPath}/\` are always-on constraints and conventions.
|
|
71
71
|
- Repo-specific overrides and learning artifacts live under \`${personalizedRootPath}/\` and take precedence over synced baseline content.
|
|
72
|
-
-
|
|
72
|
+
- Use FRAIM when the user explicitly invokes FRAIM, names a FRAIM job, asks what FRAIM job to run, or the active surface has already selected a FRAIM job.
|
|
73
|
+
- For ordinary requests, answer or work normally. Do not scan FRAIM stubs first.
|
|
74
|
+
- If the user names an exact FRAIM job, call \`get_fraim_job({ job: "<job-name>" })\` directly.
|
|
75
|
+
- When FRAIM routing is active but the job is not exact, scan the job stubs under \`${employeeJobsPath}/\` and \`${managerJobsPath}/\` to identify the most appropriate job. Read stub filenames and their Intent/Outcome sections before using catalog tools.
|
|
73
76
|
- Once you identify the relevant job, call \`get_fraim_job({ job: "<job-name>" })\` to get the full phased instructions.
|
|
77
|
+
- If no exact or high-confidence job match exists, say that no FRAIM job matches and continue with normal tools or ask one concise clarification.
|
|
74
78
|
- For deeper capability detail, call \`get_fraim_file({ path: "skills/<category>/<skill-name>.md" })\` or \`get_fraim_file({ path: "rules/<category>/<rule-name>.md" })\`.
|
|
75
79
|
- Read \`${projectRulesPath}\` if it exists before doing work.
|
|
76
80
|
- When users ask for next step recommendations, use recommend-next-job skill under \`${employeeSkillsPath}/\` to gather context before suggesting jobs.
|
|
@@ -91,7 +95,11 @@ ${(0, ide_invocation_surfaces_1.buildFraimInvocationBody)('generic-tool-discover
|
|
|
91
95
|
- FRAIM skills are reusable capabilities jobs compose.
|
|
92
96
|
- FRAIM rules are always-on constraints and conventions.
|
|
93
97
|
- Repo-specific overrides and learnings live under \`${personalizedRootPath}/\`.
|
|
94
|
-
- Use the
|
|
98
|
+
- Use FRAIM when the user explicitly invokes FRAIM, names a FRAIM job, asks what FRAIM job to run, or the active surface has already selected a FRAIM job.
|
|
99
|
+
- For ordinary requests, answer or work normally. Do not scan FRAIM stubs first.
|
|
100
|
+
- If the user names an exact FRAIM job, fetch that full job directly with FRAIM MCP tools.
|
|
101
|
+
- When FRAIM routing is active but the job is not exact, use local stubs to identify which job to invoke before fetching full content with FRAIM MCP tools.
|
|
102
|
+
- If no exact or high-confidence job match exists, say that no FRAIM job matches and continue with normal tools or ask one concise clarification.
|
|
95
103
|
- **Job stubs are for discovery only.** Never execute a job from stub content - always call \`get_fraim_job({ job: "<job-name>" })\` first.
|
|
96
104
|
`);
|
|
97
105
|
const fraimReadme = `# FRAIM Catalog
|
|
@@ -104,7 +112,7 @@ This directory is the repository-visible FRAIM surface.
|
|
|
104
112
|
- \`ai-employee/rules/\`: rule stubs
|
|
105
113
|
- \`personalized-employee/\`: repo-specific overrides and learnings
|
|
106
114
|
|
|
107
|
-
|
|
115
|
+
When FRAIM routing is active and no exact FRAIM job is named, use the stubs here to discover which FRAIM job, skill, or rule is relevant, then load the full content through FRAIM MCP tools. If an exact FRAIM job is named, load it directly. For ordinary requests, do not scan this catalog first.
|
|
108
116
|
`;
|
|
109
117
|
const vscodePrompt = `# FRAIM
|
|
110
118
|
|
|
@@ -50,15 +50,17 @@ const FRAIM_PROMPT_TEXT = `You are running in FRAIM mode. Follow this process:
|
|
|
50
50
|
|
|
51
51
|
0. **Preload deferred FRAIM tools when needed**: If FRAIM MCP tools are unavailable because this host lazily loads deferred tool schemas, call ToolSearch once to load fraim_connect, list_fraim_jobs, get_fraim_job, get_fraim_file, seekMentoring. Do the preload as one batched discovery step, not one search per tool.
|
|
52
52
|
|
|
53
|
-
1. **
|
|
53
|
+
1. **Confirm FRAIM activation**: Use FRAIM only when the user explicitly invokes FRAIM, names a FRAIM job, asks what FRAIM job to run, or the active surface has already selected a FRAIM job. For ordinary requests, answer or work normally; do not scan FRAIM stubs first.
|
|
54
54
|
|
|
55
|
-
2. **
|
|
55
|
+
2. **If the user did not specify a FRAIM job or topic after activation**: If local FRAIM job stubs are present in the workspace, inspect those first and match the request locally. Also inspect fraim/personalized-employee/jobs/ for local overrides or repo-specific jobs. If local files are missing, you cannot inspect workspace files, the user asks for available jobs, or recommendations require full catalog context, call list_fraim_jobs() to view the catalog.
|
|
56
56
|
|
|
57
|
-
3. **
|
|
57
|
+
3. **Find the match**: If the user names an exact FRAIM job, call get_fraim_job({ job: "<job-name>" }) directly. Otherwise, match the user's request to a FRAIM job from the local stub catalog, fraim/personalized-employee/jobs/, or the full list_fraim_jobs() response. If no exact or high-confidence job match exists, say that no FRAIM job matches and continue with normal tools or ask one concise clarification. Do not pick the nearest catalog job.
|
|
58
|
+
|
|
59
|
+
4. **Load the full content**:
|
|
58
60
|
- For jobs, call get_fraim_job({ job: "<matched-job-name>" }).
|
|
59
61
|
- For skills, use the content returned by get_fraim_file(...).
|
|
60
62
|
|
|
61
|
-
|
|
63
|
+
5. **Execute**:
|
|
62
64
|
- For jobs, follow the phased instructions and use seekMentoring when the job requires phase transitions.
|
|
63
65
|
- For skills, apply the skill steps directly to the user's current context.`;
|
|
64
66
|
exports.DEFAULT_LAUNCH_PHRASE_MAPPINGS = {
|
|
@@ -183,7 +185,7 @@ class McpService {
|
|
|
183
185
|
prompts: [
|
|
184
186
|
{
|
|
185
187
|
name: 'fraim',
|
|
186
|
-
description: 'Activate a FRAIM job or skill.
|
|
188
|
+
description: 'Activate a FRAIM job or skill. Use this prompt only for explicit FRAIM work, job recommendations, or known FRAIM job execution.',
|
|
187
189
|
arguments: [
|
|
188
190
|
{
|
|
189
191
|
name: 'task',
|
|
@@ -547,10 +549,13 @@ class McpService {
|
|
|
547
549
|
`FRAIM session active. Session ID: ${sessionId}`,
|
|
548
550
|
'',
|
|
549
551
|
'## Start Here',
|
|
550
|
-
'-
|
|
551
|
-
'-
|
|
552
|
-
'- If the user already named a job, call `get_fraim_job({ job: "<job-name>" })
|
|
553
|
-
'- If
|
|
552
|
+
'- Use FRAIM when the user explicitly invokes FRAIM, names a FRAIM job, asks what FRAIM job to run, or the active surface has already selected a FRAIM job.',
|
|
553
|
+
'- For ordinary requests, answer or work normally. Do not scan FRAIM stubs first.',
|
|
554
|
+
'- If the user already named a job, call `get_fraim_job({ job: "<job-name>" })` directly.',
|
|
555
|
+
'- If routing is active and local FRAIM job stubs are present under `fraim/ai-employee/jobs/` or `fraim/ai-manager/jobs/`, inspect those first to choose the best job.',
|
|
556
|
+
'- Also inspect `fraim/personalized-employee/jobs/` for local job overrides or repo-specific jobs when routing is active.',
|
|
557
|
+
'- If local stubs are missing, you cannot inspect workspace files, or the user asks for available jobs, call `list_fraim_jobs()` to view the full catalog.',
|
|
558
|
+
'- If no exact or high-confidence job match exists, say that no FRAIM job matches and continue with normal tools or ask one concise clarification.',
|
|
554
559
|
'- Use `get_fraim_file(...)` only for the specific skills or rules needed for the current task.',
|
|
555
560
|
'- Once a phased job starts, use `seekMentoring` for phase-specific instructions and transitions.'
|
|
556
561
|
];
|