@compilr-dev/sdk 0.26.0 → 0.28.0
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/dist/actions/registry.d.ts +1 -1
- package/dist/actions/registry.js +1 -1
- package/dist/guide/shared-content.js +42 -9
- package/dist/index.d.ts +12 -8
- package/dist/index.js +7 -5
- package/dist/platform/tools/canvas-tools.js +11 -11
- package/dist/project-types/action-meta.d.ts +21 -7
- package/dist/project-types/action-meta.js +44 -213
- package/dist/project-types/index.d.ts +5 -3
- package/dist/project-types/index.js +3 -2
- package/dist/project-types/macro-meta.d.ts +39 -0
- package/dist/project-types/{skill-meta.js → macro-meta.js} +203 -12
- package/dist/project-types/macro-relevance.d.ts +47 -0
- package/dist/project-types/macro-relevance.js +58 -0
- package/dist/project-types/types.d.ts +23 -4
- package/dist/skills/book-macros.d.ts +10 -0
- package/dist/skills/{book-skills.js → book-macros.js} +6 -6
- package/dist/skills/business-macros.d.ts +11 -0
- package/dist/skills/{business-skills.js → business-macros.js} +7 -7
- package/dist/skills/canvas-exemplars.d.ts +2 -2
- package/dist/skills/canvas-exemplars.js +4 -4
- package/dist/skills/canvas-icons.d.ts +1 -1
- package/dist/skills/canvas-icons.js +2 -2
- package/dist/skills/canvas-macros.d.ts +11 -0
- package/dist/skills/{canvas-skills.js → canvas-macros.js} +11 -11
- package/dist/skills/content-macros.d.ts +10 -0
- package/dist/skills/{content-skills.js → content-macros.js} +6 -6
- package/dist/skills/course-macros.d.ts +9 -0
- package/dist/skills/{course-skills.js → course-macros.js} +5 -5
- package/dist/skills/index.d.ts +6 -2
- package/dist/skills/index.js +4 -2
- package/dist/skills/macro-invocation.d.ts +78 -0
- package/dist/skills/macro-invocation.js +286 -0
- package/dist/skills/macro-list.d.ts +54 -0
- package/dist/skills/macro-list.js +84 -0
- package/dist/skills/operations.js +4 -4
- package/dist/skills/platform-macros.d.ts +27 -0
- package/dist/skills/platform-macros.js +94 -0
- package/dist/skills/prompt-resolver.d.ts +8 -2
- package/dist/skills/prompt-resolver.js +14 -8
- package/dist/skills/research-macros.d.ts +10 -0
- package/dist/skills/{research-skills.js → research-macros.js} +6 -6
- package/dist/skills/resolver.d.ts +15 -9
- package/dist/skills/resolver.js +13 -13
- package/dist/skills/software-macros.d.ts +14 -0
- package/dist/skills/{software-skills.js → software-macros.js} +37 -37
- package/dist/skills/types.d.ts +2 -2
- package/dist/skills/types.js +4 -4
- package/dist/team/agent-templates.d.ts +0 -1
- package/dist/team/agent-templates.js +0 -2
- package/dist/team/custom-agents.d.ts +1 -2
- package/dist/team/custom-agents.js +1 -2
- package/dist/team/index.d.ts +3 -3
- package/dist/team/index.js +1 -1
- package/dist/team/{skill-requirements.d.ts → macro-requirements.d.ts} +20 -14
- package/dist/team/{skill-requirements.js → macro-requirements.js} +28 -22
- package/dist/team/macro-tool-gap.d.ts +3 -3
- package/dist/team/macro-tool-gap.js +6 -6
- package/dist/team/team-agent.d.ts +6 -7
- package/dist/team/team-agent.js +6 -14
- package/dist/team/types.d.ts +8 -7
- package/dist/team/workshop-data.d.ts +17 -5
- package/dist/team/workshop-data.js +13 -13
- package/package.json +1 -1
- package/dist/project-types/skill-meta.d.ts +0 -17
- package/dist/skills/book-skills.d.ts +0 -10
- package/dist/skills/business-skills.d.ts +0 -11
- package/dist/skills/canvas-skills.d.ts +0 -11
- package/dist/skills/content-skills.d.ts +0 -10
- package/dist/skills/course-skills.d.ts +0 -9
- package/dist/skills/platform-skills.d.ts +0 -20
- package/dist/skills/platform-skills.js +0 -87
- package/dist/skills/research-skills.d.ts +0 -10
- package/dist/skills/software-skills.d.ts +0 -14
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Action Registry — Defines which actions are available and where.
|
|
3
3
|
*
|
|
4
|
-
* Each action maps to a skill (from
|
|
4
|
+
* Each action maps to a skill (from platformMacros/builtinSkills)
|
|
5
5
|
* but adds UI metadata: icon, label, category, applicable contexts,
|
|
6
6
|
* and suggested agent role.
|
|
7
7
|
*/
|
package/dist/actions/registry.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Action Registry — Defines which actions are available and where.
|
|
3
3
|
*
|
|
4
|
-
* Each action maps to a skill (from
|
|
4
|
+
* Each action maps to a skill (from platformMacros/builtinSkills)
|
|
5
5
|
* but adds UI metadata: icon, label, category, applicable contexts,
|
|
6
6
|
* and suggested agent role.
|
|
7
7
|
*/
|
|
@@ -115,20 +115,53 @@ The delegated agent runs independently and returns results to the coordinator.`,
|
|
|
115
115
|
},
|
|
116
116
|
// ── Skills ──────────────────────────────────────────────────────────────
|
|
117
117
|
{
|
|
118
|
-
id: '
|
|
119
|
-
title: '
|
|
120
|
-
keywords: ['skills', 'slash', 'command', '/'],
|
|
121
|
-
content: `
|
|
118
|
+
id: 'macros-overview',
|
|
119
|
+
title: 'Macros Overview',
|
|
120
|
+
keywords: ['macros', 'macro', 'skills', 'slash', 'command', '/'],
|
|
121
|
+
content: `Macros are pre-built prompts that guide the agent through specific workflows. You
|
|
122
|
+
invoke one; it expands into a message.
|
|
122
123
|
|
|
123
|
-
Use them by typing / followed by the
|
|
124
|
+
Use them by typing / followed by the macro name (e.g., /design, /build).
|
|
124
125
|
|
|
125
|
-
|
|
126
|
+
Macros vary by project type. Software projects have: /design, /sketch, /prd, /architecture, /scaffold, /build, /refine, /session-notes.
|
|
126
127
|
|
|
127
128
|
Research projects have: /research-scaffold, /outline, /literature-review, /draft-section, /peer-review.
|
|
128
129
|
|
|
129
130
|
Business projects have: /business-vision, /market-analysis, /competitor-analysis, /financial-model, /pitch-outline, /business-review.
|
|
130
131
|
|
|
131
|
-
|
|
132
|
+
Macros can be combined with your own instructions: type /design then add context.
|
|
133
|
+
|
|
134
|
+
**Macros are not Skills.** A macro is text YOU trigger. A Skill is a capability the MODEL
|
|
135
|
+
chooses from a catalogue and loads when it decides it is relevant — see "Skills". They were
|
|
136
|
+
called the same thing until recently, which is why older notes use "skill" for both.`,
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
id: 'skills',
|
|
140
|
+
title: 'Skills — Capabilities the Model Chooses',
|
|
141
|
+
keywords: ['skill', 'skills', 'SKILL.md', 'anthropic', 'agent skills', 'catalogue', 'grant'],
|
|
142
|
+
content: `A Skill is a capability the MODEL picks up when it decides the work calls for it —
|
|
143
|
+
not something you type.
|
|
144
|
+
|
|
145
|
+
Each agent is shown a CATALOGUE: one line per skill, name and description only. When the agent
|
|
146
|
+
judges a skill relevant it loads the body then, and not before, so an unused skill costs a line
|
|
147
|
+
of context rather than a document.
|
|
148
|
+
|
|
149
|
+
**Where they live**
|
|
150
|
+
- User scope: ~/.compilr-dev/skills/<name>/SKILL.md — personal, every project
|
|
151
|
+
- Project scope: <project>/.compilr/skills/<name>/SKILL.md — shared via version control
|
|
152
|
+
|
|
153
|
+
The format is Anthropic's Agent Skills format: YAML frontmatter (name, description) and a
|
|
154
|
+
markdown body. We read the frontmatter and the body; bundled references/, scripts/, templates/
|
|
155
|
+
and assets/ are not read yet.
|
|
156
|
+
|
|
157
|
+
**Granting them per agent**
|
|
158
|
+
In the agent editor's Skills section, tick the skills an agent may choose from. An agent you have
|
|
159
|
+
never restricted may choose any installed skill; once you save a selection it is limited to
|
|
160
|
+
exactly what is ticked, and an empty selection grants none.
|
|
161
|
+
|
|
162
|
+
**Skills are not macros.** A macro (/design, /build) is text YOU trigger. A skill is something
|
|
163
|
+
the model reaches for on its own. A skill you install is also typeable as a slash command, so one
|
|
164
|
+
folder can serve both purposes — see "Custom Skills".`,
|
|
132
165
|
},
|
|
133
166
|
{
|
|
134
167
|
id: 'custom-skills',
|
|
@@ -157,8 +190,8 @@ A folder with a SKILL.md file containing YAML frontmatter (name, description) an
|
|
|
157
190
|
|
|
158
191
|
**Desktop:** The Agents panel has a Skills section showing custom skills. Click the maximize button to open the SkillsView tab with full management (create, fork, bind/unbind, enable/disable, delete). Click a skill name to view/edit in the code editor.
|
|
159
192
|
|
|
160
|
-
**Forking
|
|
161
|
-
You cannot override
|
|
193
|
+
**Forking shipped macros:**
|
|
194
|
+
You cannot override a shipped macro directly — its name is reserved, so creating one is refused. Fork it instead: that copies it, and you edit the copy. Then bind a slash command to your fork (e.g., /design → design-acme).
|
|
162
195
|
|
|
163
196
|
**Bindings:**
|
|
164
197
|
Bindings remap slash commands to custom skills. Example: bind /design to your forked design-acme skill. When you type /design, it uses your custom prompt instead of the SDK version. Use the Bindings tab/section to manage them.
|
package/dist/index.d.ts
CHANGED
|
@@ -36,10 +36,10 @@
|
|
|
36
36
|
export { createCompilrAgent } from './agent.js';
|
|
37
37
|
export type { CompilrAgentConfig, CompilrAgent, RunOptions, RunResult, ToolCallRecord, ToolConfig, UsageInfo, ProviderType, PermissionCallback, GuardrailConfig, ContextConfig, CapabilitiesConfig, } from './config.js';
|
|
38
38
|
export { AgentTeam, TeamAgent, SharedContextManager, ArtifactStore, DelegationTracker, ContextResolver, createDelegationStatusTool, createHandoffTool, createDelegateTool, createDelegateBackgroundTool, buildHandoffTaskMessage, validateHandoffIntent, HandoffStash, createConsultTool, buildConsultQuestionMessage, ROLE_NAME_ALIASES, normalizeRoleName, isNarrowing, lostWriteAccess, } from './team/index.js';
|
|
39
|
-
export type { AgentTeamConfig, TeamAgentConfig, TeamAgentUpdate, AgentUpdateResult, ITeamPersistence, IArtifactStorage, ISessionRegistry, CustomAgentDefinition, AgentTemplate, AgentWorkshopData, WorkshopRoleDef, WorkshopToolProfile, WorkshopModelTier,
|
|
40
|
-
export type { AgentRole, RoleMetadata, ToolProfile, MascotExpression, BackgroundSessionInfo, SerializedTeam, SerializedTeamAgent, TeamMetadata, TeamEvent, TeamEventType, TeamEventHandler, Artifact, ArtifactType as TeamArtifactType, ArtifactSummary as TeamArtifactSummary, CreateArtifactOptions, UpdateArtifactOptions, SerializedArtifact, SharedContext, SharedProjectInfo, SharedTeamInfo, TeamRosterEntry, TeamActivity, TeamActivityType, SharedDecision, TokenBudget, SerializedSharedContext, ParsedMention, ParsedInput, ResolvedMention, ResolveOptions, ResolutionSource, Delegation, DelegationStatus, DelegationResult, CompletionEvent, CreateDelegationOptions, DelegationStats, DelegationTrackerEvents, HandoffResult, HandoffToolConfig, HandoffIntent, HandoffValidationResult, DelegateResult, DelegateToolConfig, DelegateBackgroundResult, DelegateBackgroundToolConfig, ConsultInput, ConsultResult, ConsultToolConfig, NormalizedRole,
|
|
41
|
-
export { ROLE_METADATA, ROLE_EXPERTISE, ROLE_GROUPS, PREDEFINED_ROLE_IDS, TOOL_GROUPS, TOOL_PROFILES, PROFILE_INFO,
|
|
42
|
-
export { getToolsForProfile, detectProfileFromTools, isProfileReadOnly, generateToolAwarenessPrompt, generateCoordinatorGuidance, generateSpecialistGuidance, createDefaultToolConfig, validateToolConfig, getAllGroupIds, getGroupInfo, getGroupsByTier, getGroupsForProfile, assignMascot, generateCustomAgentSystemPrompt, mcpServerOf, filterMcpToolsByGrant, MCP_TOOL_PREFIX, getCustomAgentToolFilter, getCustomAgentProfileLabel, validateAgentId, isAgentIdTaken, createCustomAgentDefinition, listTemplates, getTemplate, saveTemplate, updateTemplate, deleteTemplate, createAgentFromTemplate, parseInputForMentions, getReferencedAgents, hasReferences, buildMessageWithContext, buildContextMap, findAgentForRole, findAgentById, getAvailableSpecialists, getSpecialistsSummary, hasSpecialists, suggestOwner, suggestOwners, matchesAgentExpertise, wouldCreateLoop, recordAssignment, getAssignmentHistory, clearAssignmentHistory, clearAllAssignmentHistory, canReassign, resolveAgentIdCollision, setActiveSharedContext, getActiveSharedContext, recordTeamActivity,
|
|
39
|
+
export type { AgentTeamConfig, TeamAgentConfig, TeamAgentUpdate, AgentUpdateResult, ITeamPersistence, IArtifactStorage, ISessionRegistry, CustomAgentDefinition, AgentTemplate, AgentWorkshopData, WorkshopRoleDef, WorkshopToolProfile, WorkshopModelTier, WorkshopMacroDef, PlanSubmitInfo, PlanSubmitResult, PlanModeExitInfo, PlanModeCallbacks, ToolConfig as TeamToolConfig, ToolTier, ToolGroup, ProfileInfo, } from './team/index.js';
|
|
40
|
+
export type { AgentRole, RoleMetadata, ToolProfile, MascotExpression, BackgroundSessionInfo, SerializedTeam, SerializedTeamAgent, TeamMetadata, TeamEvent, TeamEventType, TeamEventHandler, Artifact, ArtifactType as TeamArtifactType, ArtifactSummary as TeamArtifactSummary, CreateArtifactOptions, UpdateArtifactOptions, SerializedArtifact, SharedContext, SharedProjectInfo, SharedTeamInfo, TeamRosterEntry, TeamActivity, TeamActivityType, SharedDecision, TokenBudget, SerializedSharedContext, ParsedMention, ParsedInput, ResolvedMention, ResolveOptions, ResolutionSource, Delegation, DelegationStatus, DelegationResult, CompletionEvent, CreateDelegationOptions, DelegationStats, DelegationTrackerEvents, HandoffResult, HandoffToolConfig, HandoffIntent, HandoffValidationResult, DelegateResult, DelegateToolConfig, DelegateBackgroundResult, DelegateBackgroundToolConfig, ConsultInput, ConsultResult, ConsultToolConfig, NormalizedRole, } from './team/index.js';
|
|
41
|
+
export { ROLE_METADATA, ROLE_EXPERTISE, ROLE_GROUPS, PREDEFINED_ROLE_IDS, TOOL_GROUPS, TOOL_PROFILES, PROFILE_INFO, MACRO_REQUIREMENTS, getDefinedMacroNames, getMacroRequirements, getCompatibleMacros, getMacrosByCategory, CUSTOM_MASCOTS, buildAgentWorkshopData, buildSuggestedRolesMap, PLAN_MODE_BLOCKED_TOOLS, PLAN_MODE_DENIAL_MESSAGE, PLAN_MODE_PROMPT, isToolAllowedInPlanMode, getPlanModePrompt, } from './team/index.js';
|
|
42
|
+
export { getToolsForProfile, detectProfileFromTools, isProfileReadOnly, generateToolAwarenessPrompt, generateCoordinatorGuidance, generateSpecialistGuidance, createDefaultToolConfig, validateToolConfig, getAllGroupIds, getGroupInfo, getGroupsByTier, getGroupsForProfile, assignMascot, generateCustomAgentSystemPrompt, mcpServerOf, filterMcpToolsByGrant, MCP_TOOL_PREFIX, getCustomAgentToolFilter, getCustomAgentProfileLabel, validateAgentId, isAgentIdTaken, createCustomAgentDefinition, listTemplates, getTemplate, saveTemplate, updateTemplate, deleteTemplate, createAgentFromTemplate, parseInputForMentions, getReferencedAgents, hasReferences, buildMessageWithContext, buildContextMap, findAgentForRole, findAgentById, getAvailableSpecialists, getSpecialistsSummary, hasSpecialists, suggestOwner, suggestOwners, matchesAgentExpertise, wouldCreateLoop, recordAssignment, getAssignmentHistory, clearAssignmentHistory, clearAllAssignmentHistory, canReassign, resolveAgentIdCollision, setActiveSharedContext, getActiveSharedContext, recordTeamActivity, checkMacroCompatibility, macroToolGap, macroToolGapPreamble, getAllRequiredTools, } from './team/index.js';
|
|
43
43
|
export { codingPreset, readOnlyPreset, resolvePreset } from './presets/index.js';
|
|
44
44
|
export type { Preset } from './presets/index.js';
|
|
45
45
|
export type { AnyTool } from './presets/types.js';
|
|
@@ -68,16 +68,20 @@ export { createPlatformTools, createProjectTools, createWorkItemTools, createDoc
|
|
|
68
68
|
export type { ProjectAnchorStoreConfig, FileArtifactServiceConfig, ImageToolsConfig, ImageResizer, } from './platform/index.js';
|
|
69
69
|
export { STEP_ORDER, GUIDED_STEP_CRITERIA, getNextStep, isValidTransition, getStepCriteria, formatStepDisplay, getStepNumber, } from './platform/index.js';
|
|
70
70
|
export type { CustomSkill, CompilrSkillExtension, ForkedFromMarker, SkillEligibilityContext, SkillCollision, SkillDiffLine, SkillValidationIssue, ScopeConfig, SkillResolution, } from './skills/index.js';
|
|
71
|
-
export {
|
|
71
|
+
export { RESERVED_MACRO_NAMES, isReservedMacroName, parseSkillMarkdown, loadSkillsFromDir, loadInstalledSkills, resolveLayeredSkills, resolveSkillsForAgent, resolveSkillsForTeamAgent, detectCollisions, formatCollisionWarnings, diffForkVsUpstream, buildForkContent, buildNewSkillContent, validateSkill as validateSkillQuality, getSkillsDir, getSkillFolder, getSkillFile, ensureSkillsDir, isValidSkillName, getScopeConfigPath, readSkillScopeConfig, readSkillScopeConfigSync, writeSkillScopeConfig, getSkillBindings, resolveSkillBinding, } from './skills/index.js';
|
|
72
72
|
export type { SkillScope, SkillPromptResolution, AvailableSkillEntry, SkillSources, } from './skills/index.js';
|
|
73
73
|
export { resolveSkillPrompt, getAllAvailableSkills } from './skills/index.js';
|
|
74
|
+
export { buildMacroList } from './skills/index.js';
|
|
75
|
+
export { buildMacroInvocation } from './skills/index.js';
|
|
76
|
+
export type { MacroInvocation, MacroInvocationContext, MacroProjectContext, } from './skills/index.js';
|
|
77
|
+
export type { MacroListEntry, BuildMacroListOptions } from './skills/index.js';
|
|
74
78
|
export { generateSkillCatalog, toCatalogEntry, createLoadSkillTool } from './skills/index.js';
|
|
75
79
|
export type { SkillCatalogEntry, SkillSource } from './skills/index.js';
|
|
76
|
-
export {
|
|
80
|
+
export { platformMacros, designMacro, sketchMacro, prdMacro, refineMacro, refineItemMacro, architectureMacro, sessionNotesMacro, buildMacro, scaffoldMacro, outlineMacro, literatureReviewMacro, draftSectionMacro, peerReviewMacro, researchScaffoldMacro, businessVisionMacro, marketAnalysisMacro, competitorAnalysisMacro, financialModelMacro, pitchOutlineMacro, businessReviewMacro, brandSetupMacro, contentStrategyMacro, contentCalendarMacro, createContentMacro, contentReviewMacro, curriculumDesignMacro, lessonPlanMacro, assessmentDesignMacro, courseReviewMacro, bookOutlineMacro, characterDesignMacro, plotThreadsMacro, sceneBreakdownMacro, bookReviewMacro, } from './skills/index.js';
|
|
77
81
|
export { ACTION_REGISTRY, getActionsForContext, getActionById, resolveActionPrompt, buildContextSummary, getSuggestedRole, } from './actions/index.js';
|
|
78
82
|
export type { ActionContext, ActionDefinition } from './actions/index.js';
|
|
79
|
-
export { PROJECT_TYPES, getProjectTypeConfig, getEnrichedProjectTypeConfig, getProjectTypesByCategory, generalConfig, softwareConfig, researchConfig, businessPlanConfig, contentConfig, techDocsConfig, courseConfig,
|
|
80
|
-
export type { ActionMeta,
|
|
83
|
+
export { PROJECT_TYPES, getProjectTypeConfig, getEnrichedProjectTypeConfig, getProjectTypesByCategory, generalConfig, softwareConfig, researchConfig, businessPlanConfig, contentConfig, techDocsConfig, courseConfig, MACRO_META_REGISTRY, resolveActionMeta, getRelevantMacros, getMacroMeta, getAllMacroMeta, } from './project-types/index.js';
|
|
84
|
+
export type { ActionMeta, MacroMeta, MacroCategory, MacroCapabilities, } from './project-types/index.js';
|
|
81
85
|
export type { ProjectTypeConfig, ProjectPhase, SuggestedAgent, DocumentTemplate, } from './project-types/index.js';
|
|
82
86
|
export { defineTool, createSuccessResult, createErrorResult, mergeHooks, createLoggingHooks, createClaudeProvider, createOpenAIProvider, createGeminiNativeProvider, createOllamaProvider, createTogetherProvider, createGroqProvider, createFireworksProvider, createPerplexityProvider, createOpenRouterProvider, createMockProvider, MockProvider, Agent, ContextManager, DEFAULT_CONTEXT_CONFIG, createTaskTool, createSuggestTool, defaultAgentTypes, TOOL_SETS, BUILTIN_GUARDRAILS, TOOL_NAMES, getDefaultShellManager, builtinSkills, AnchorManager, MCPManager, AgentError, ProviderError, ToolError, ToolTimeoutError, MaxIterationsError, AbortError, } from '@compilr-dev/agents';
|
|
83
87
|
export { classifyAgentError, isApiKeyError } from './errors/classify.js';
|
package/dist/index.js
CHANGED
|
@@ -43,7 +43,7 @@ export { createCompilrAgent } from './agent.js';
|
|
|
43
43
|
// Core classes
|
|
44
44
|
export { AgentTeam, TeamAgent, SharedContextManager, ArtifactStore, DelegationTracker, ContextResolver, createDelegationStatusTool, createHandoffTool, createDelegateTool, createDelegateBackgroundTool, buildHandoffTaskMessage, validateHandoffIntent, HandoffStash, createConsultTool, buildConsultQuestionMessage, ROLE_NAME_ALIASES, normalizeRoleName, isNarrowing, lostWriteAccess, } from './team/index.js';
|
|
45
45
|
// Constants
|
|
46
|
-
export { ROLE_METADATA, ROLE_EXPERTISE, ROLE_GROUPS, PREDEFINED_ROLE_IDS, TOOL_GROUPS, TOOL_PROFILES, PROFILE_INFO,
|
|
46
|
+
export { ROLE_METADATA, ROLE_EXPERTISE, ROLE_GROUPS, PREDEFINED_ROLE_IDS, TOOL_GROUPS, TOOL_PROFILES, PROFILE_INFO, MACRO_REQUIREMENTS, getDefinedMacroNames, getMacroRequirements, getCompatibleMacros, getMacrosByCategory, CUSTOM_MASCOTS, buildAgentWorkshopData, buildSuggestedRolesMap,
|
|
47
47
|
// Plan mode
|
|
48
48
|
PLAN_MODE_BLOCKED_TOOLS, PLAN_MODE_DENIAL_MESSAGE, PLAN_MODE_PROMPT, isToolAllowedInPlanMode, getPlanModePrompt, } from './team/index.js';
|
|
49
49
|
// Utility functions
|
|
@@ -67,7 +67,7 @@ resolveAgentIdCollision,
|
|
|
67
67
|
// Activity
|
|
68
68
|
setActiveSharedContext, getActiveSharedContext, recordTeamActivity,
|
|
69
69
|
// Skills
|
|
70
|
-
|
|
70
|
+
checkMacroCompatibility, macroToolGap, macroToolGapPreamble, getAllRequiredTools, } from './team/index.js';
|
|
71
71
|
// =============================================================================
|
|
72
72
|
// Presets
|
|
73
73
|
// =============================================================================
|
|
@@ -152,10 +152,12 @@ export { createPlatformTools, createProjectTools, createWorkItemTools, createDoc
|
|
|
152
152
|
// Platform Workflow (pure step-criteria logic)
|
|
153
153
|
// =============================================================================
|
|
154
154
|
export { STEP_ORDER, GUIDED_STEP_CRITERIA, getNextStep, isValidTransition, getStepCriteria, formatStepDisplay, getStepNumber, } from './platform/index.js';
|
|
155
|
-
export {
|
|
155
|
+
export { RESERVED_MACRO_NAMES, isReservedMacroName, parseSkillMarkdown, loadSkillsFromDir, loadInstalledSkills, resolveLayeredSkills, resolveSkillsForAgent, resolveSkillsForTeamAgent, detectCollisions, formatCollisionWarnings, diffForkVsUpstream, buildForkContent, buildNewSkillContent, validateSkill as validateSkillQuality, getSkillsDir, getSkillFolder, getSkillFile, ensureSkillsDir, isValidSkillName, getScopeConfigPath, readSkillScopeConfig, readSkillScopeConfigSync, writeSkillScopeConfig, getSkillBindings, resolveSkillBinding, } from './skills/index.js';
|
|
156
156
|
export { resolveSkillPrompt, getAllAvailableSkills } from './skills/index.js';
|
|
157
|
+
export { buildMacroList } from './skills/index.js';
|
|
158
|
+
export { buildMacroInvocation } from './skills/index.js';
|
|
157
159
|
export { generateSkillCatalog, toCatalogEntry, createLoadSkillTool } from './skills/index.js';
|
|
158
|
-
export {
|
|
160
|
+
export { platformMacros, designMacro, sketchMacro, prdMacro, refineMacro, refineItemMacro, architectureMacro, sessionNotesMacro, buildMacro, scaffoldMacro, outlineMacro, literatureReviewMacro, draftSectionMacro, peerReviewMacro, researchScaffoldMacro, businessVisionMacro, marketAnalysisMacro, competitorAnalysisMacro, financialModelMacro, pitchOutlineMacro, businessReviewMacro, brandSetupMacro, contentStrategyMacro, contentCalendarMacro, createContentMacro, contentReviewMacro, curriculumDesignMacro, lessonPlanMacro, assessmentDesignMacro, courseReviewMacro, bookOutlineMacro, characterDesignMacro, plotThreadsMacro, sceneBreakdownMacro, bookReviewMacro, } from './skills/index.js';
|
|
159
161
|
// =============================================================================
|
|
160
162
|
// Contextual Actions (skill invocations with context)
|
|
161
163
|
// =============================================================================
|
|
@@ -165,7 +167,7 @@ export { ACTION_REGISTRY, getActionsForContext, getActionById, resolveActionProm
|
|
|
165
167
|
// =============================================================================
|
|
166
168
|
export { PROJECT_TYPES, getProjectTypeConfig, getEnrichedProjectTypeConfig, getProjectTypesByCategory, generalConfig, softwareConfig, researchConfig, businessPlanConfig, contentConfig, techDocsConfig, courseConfig,
|
|
167
169
|
// Action & skill metadata
|
|
168
|
-
|
|
170
|
+
MACRO_META_REGISTRY, resolveActionMeta, getRelevantMacros, getMacroMeta, getAllMacroMeta, } from './project-types/index.js';
|
|
169
171
|
// =============================================================================
|
|
170
172
|
// Re-exports from @compilr-dev/agents (convenience — no need to install separately)
|
|
171
173
|
// =============================================================================
|
|
@@ -20,9 +20,9 @@ import * as pathNode from 'node:path';
|
|
|
20
20
|
const PAGE_SIZES = ['16:9', '4:3', '1:1', '4:5', '9:16'];
|
|
21
21
|
import { seedValues } from '../../canvas/types.js';
|
|
22
22
|
import { validateControlManifest } from '../../canvas/validate.js';
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
23
|
+
import { canvasMacro, infographicMacro, carouselMacro, boardMacro, canvasStylesMacro, } from '../../skills/canvas-macros.js';
|
|
24
|
+
import { canvasExemplarInfographicMacro, canvasExemplarAppScreenMacro, } from '../../skills/canvas-exemplars.js';
|
|
25
|
+
import { canvasIconsMacro } from '../../skills/canvas-icons.js';
|
|
26
26
|
const CANVAS_TYPES = ['infographic', 'carousel', 'board'];
|
|
27
27
|
/** Render content as numbered lines (1-based), optionally a slice. */
|
|
28
28
|
function numberedLines(content, startLine, maxLines) {
|
|
@@ -743,14 +743,14 @@ export function createCanvasTools(config, imageConfig) {
|
|
|
743
743
|
tests). The type was lying, not the guard.
|
|
744
744
|
*/
|
|
745
745
|
const guides = {
|
|
746
|
-
canvas:
|
|
747
|
-
infographic:
|
|
748
|
-
carousel:
|
|
749
|
-
board:
|
|
750
|
-
styles:
|
|
751
|
-
'exemplar-infographic':
|
|
752
|
-
'exemplar-app-screen':
|
|
753
|
-
icons:
|
|
746
|
+
canvas: canvasMacro,
|
|
747
|
+
infographic: infographicMacro,
|
|
748
|
+
carousel: carouselMacro,
|
|
749
|
+
board: boardMacro,
|
|
750
|
+
styles: canvasStylesMacro,
|
|
751
|
+
'exemplar-infographic': canvasExemplarInfographicMacro,
|
|
752
|
+
'exemplar-app-screen': canvasExemplarAppScreenMacro,
|
|
753
|
+
icons: canvasIconsMacro,
|
|
754
754
|
};
|
|
755
755
|
const guide = guides[input.topic];
|
|
756
756
|
if (!guide) {
|
|
@@ -1,14 +1,28 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Action
|
|
2
|
+
* Action metadata — the action-button VIEW of a macro.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
4
|
+
* ⚠️ THIS FILE USED TO HOLD A SECOND REGISTRY. `ACTION_META_REGISTRY` keyed the same 35 macro
|
|
5
|
+
* ids as MACRO_META_REGISTRY with its own labels, descriptions and icons, and the two drifted
|
|
6
|
+
* apart in both directions. It is gone; this now derives from the one registry.
|
|
7
|
+
*
|
|
8
|
+
* What it does NOT do is flatten the difference. The action view was deliberately terser —
|
|
9
|
+
* 26 of 35 labels and 33 of 35 descriptions were shorter, because a button in a row of six
|
|
10
|
+
* cannot say "Competitor Analysis" and a work-item action says "Implement this item" rather
|
|
11
|
+
* than "Implement a feature". Those live on MacroMeta as `shortLabel` / `shortDescription`
|
|
12
|
+
* and are preferred here, so every label and description this function returns is byte-for-byte
|
|
13
|
+
* what the old registry returned. That is asserted in tests/project-types/action-meta.test.ts,
|
|
14
|
+
* against a snapshot taken before the merge.
|
|
15
|
+
*
|
|
16
|
+
* Spec: project-docs/00-requirements/compilr-dev-sdk/macro-metadata-consolidation.md
|
|
6
17
|
*/
|
|
7
18
|
import type { ActionMeta } from './types.js';
|
|
8
|
-
/** All known action metadata, keyed by action/skill ID */
|
|
9
|
-
export declare const ACTION_META_REGISTRY: Record<string, ActionMeta>;
|
|
10
19
|
/**
|
|
11
|
-
* Resolve action
|
|
12
|
-
*
|
|
20
|
+
* Resolve action ids to their button metadata.
|
|
21
|
+
*
|
|
22
|
+
* An unknown id still yields a usable entry rather than throwing — but it is a hole, not a
|
|
23
|
+
* feature: it renders as the raw id with a generic icon, which is exactly how twenty macros
|
|
24
|
+
* came to be displayed as `business-vision`, `market-analysis`, … The coverage guard in
|
|
25
|
+
* tests/skills/macro-meta-coverage.test.ts is what keeps this branch unreachable for anything
|
|
26
|
+
* we ship.
|
|
13
27
|
*/
|
|
14
28
|
export declare function resolveActionMeta(actionIds: readonly string[]): ActionMeta[];
|
|
@@ -1,220 +1,51 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Action
|
|
2
|
+
* Action metadata — the action-button VIEW of a macro.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
4
|
+
* ⚠️ THIS FILE USED TO HOLD A SECOND REGISTRY. `ACTION_META_REGISTRY` keyed the same 35 macro
|
|
5
|
+
* ids as MACRO_META_REGISTRY with its own labels, descriptions and icons, and the two drifted
|
|
6
|
+
* apart in both directions. It is gone; this now derives from the one registry.
|
|
7
|
+
*
|
|
8
|
+
* What it does NOT do is flatten the difference. The action view was deliberately terser —
|
|
9
|
+
* 26 of 35 labels and 33 of 35 descriptions were shorter, because a button in a row of six
|
|
10
|
+
* cannot say "Competitor Analysis" and a work-item action says "Implement this item" rather
|
|
11
|
+
* than "Implement a feature". Those live on MacroMeta as `shortLabel` / `shortDescription`
|
|
12
|
+
* and are preferred here, so every label and description this function returns is byte-for-byte
|
|
13
|
+
* what the old registry returned. That is asserted in tests/project-types/action-meta.test.ts,
|
|
14
|
+
* against a snapshot taken before the merge.
|
|
15
|
+
*
|
|
16
|
+
* Spec: project-docs/00-requirements/compilr-dev-sdk/macro-metadata-consolidation.md
|
|
6
17
|
*/
|
|
7
|
-
|
|
8
|
-
export const ACTION_META_REGISTRY = {
|
|
9
|
-
// ── Software project actions ─────────────────────────────────────────────
|
|
10
|
-
design: { id: 'design', label: 'Design', icon: 'Wand2', description: 'Design the app' },
|
|
11
|
-
prd: { id: 'prd', label: 'PRD', icon: 'FileText', description: 'Write requirements' },
|
|
12
|
-
architecture: {
|
|
13
|
-
id: 'architecture',
|
|
14
|
-
label: 'Architecture',
|
|
15
|
-
icon: 'Network',
|
|
16
|
-
description: 'System architecture',
|
|
17
|
-
},
|
|
18
|
-
refine: { id: 'refine', label: 'Refine', icon: 'RefreshCw', description: 'Refine backlog' },
|
|
19
|
-
scaffold: { id: 'scaffold', label: 'Scaffold', icon: 'Layers', description: 'Generate code' },
|
|
20
|
-
'session-notes': {
|
|
21
|
-
id: 'session-notes',
|
|
22
|
-
label: 'Notes',
|
|
23
|
-
icon: 'StickyNote',
|
|
24
|
-
description: 'Session summary',
|
|
25
|
-
},
|
|
26
|
-
// ── Research project actions ─────────────────────────────────────────────
|
|
27
|
-
'research-scaffold': {
|
|
28
|
-
id: 'research-scaffold',
|
|
29
|
-
label: 'New Paper',
|
|
30
|
-
icon: 'Layers',
|
|
31
|
-
description: 'Set up from a template',
|
|
32
|
-
},
|
|
33
|
-
outline: {
|
|
34
|
-
id: 'outline',
|
|
35
|
-
label: 'Outline',
|
|
36
|
-
icon: 'BookOpen',
|
|
37
|
-
description: 'Build paper outline',
|
|
38
|
-
},
|
|
39
|
-
'literature-review': {
|
|
40
|
-
id: 'literature-review',
|
|
41
|
-
label: 'Lit Review',
|
|
42
|
-
icon: 'Search',
|
|
43
|
-
description: 'Analyze sources',
|
|
44
|
-
},
|
|
45
|
-
'draft-section': {
|
|
46
|
-
id: 'draft-section',
|
|
47
|
-
label: 'Draft',
|
|
48
|
-
icon: 'PenTool',
|
|
49
|
-
description: 'Write a section',
|
|
50
|
-
},
|
|
51
|
-
'peer-review': {
|
|
52
|
-
id: 'peer-review',
|
|
53
|
-
label: 'Review',
|
|
54
|
-
icon: 'ShieldCheck',
|
|
55
|
-
description: 'Review the paper',
|
|
56
|
-
},
|
|
57
|
-
// ── Business Plan project actions ──────────────────────────────────────────
|
|
58
|
-
'business-vision': {
|
|
59
|
-
id: 'business-vision',
|
|
60
|
-
label: 'Vision',
|
|
61
|
-
icon: 'Target',
|
|
62
|
-
description: 'Define your business',
|
|
63
|
-
},
|
|
64
|
-
'market-analysis': {
|
|
65
|
-
id: 'market-analysis',
|
|
66
|
-
label: 'Market',
|
|
67
|
-
icon: 'TrendingUp',
|
|
68
|
-
description: 'Analyze the market',
|
|
69
|
-
},
|
|
70
|
-
'competitor-analysis': {
|
|
71
|
-
id: 'competitor-analysis',
|
|
72
|
-
label: 'Competitors',
|
|
73
|
-
icon: 'Swords',
|
|
74
|
-
description: 'Map competition',
|
|
75
|
-
},
|
|
76
|
-
// ── Content & Marketing actions ───────────────────────────────────────────
|
|
77
|
-
'brand-setup': {
|
|
78
|
-
id: 'brand-setup',
|
|
79
|
-
label: 'Brand',
|
|
80
|
-
icon: 'Palette',
|
|
81
|
-
description: 'Set up brand identity',
|
|
82
|
-
},
|
|
83
|
-
'content-strategy': {
|
|
84
|
-
id: 'content-strategy',
|
|
85
|
-
label: 'Strategy',
|
|
86
|
-
icon: 'Target',
|
|
87
|
-
description: 'Define pillars',
|
|
88
|
-
},
|
|
89
|
-
'content-calendar': {
|
|
90
|
-
id: 'content-calendar',
|
|
91
|
-
label: 'Calendar',
|
|
92
|
-
icon: 'Calendar',
|
|
93
|
-
description: 'Plan content',
|
|
94
|
-
},
|
|
95
|
-
'create-content': {
|
|
96
|
-
id: 'create-content',
|
|
97
|
-
label: 'Create',
|
|
98
|
-
icon: 'PenTool',
|
|
99
|
-
description: 'Write content',
|
|
100
|
-
},
|
|
101
|
-
'content-review': {
|
|
102
|
-
id: 'content-review',
|
|
103
|
-
label: 'Review',
|
|
104
|
-
icon: 'CheckCircle',
|
|
105
|
-
description: 'Check quality',
|
|
106
|
-
},
|
|
107
|
-
// ── Book actions ─────────────────────────────────────────────────────────
|
|
108
|
-
'book-outline': {
|
|
109
|
-
id: 'book-outline',
|
|
110
|
-
label: 'Outline',
|
|
111
|
-
icon: 'BookOpen',
|
|
112
|
-
description: 'Plan structure',
|
|
113
|
-
},
|
|
114
|
-
'character-design': {
|
|
115
|
-
id: 'character-design',
|
|
116
|
-
label: 'Characters',
|
|
117
|
-
icon: 'Users',
|
|
118
|
-
description: 'Build cast',
|
|
119
|
-
},
|
|
120
|
-
'plot-threads': {
|
|
121
|
-
id: 'plot-threads',
|
|
122
|
-
label: 'Threads',
|
|
123
|
-
icon: 'GitBranch',
|
|
124
|
-
description: 'Map plot lines',
|
|
125
|
-
},
|
|
126
|
-
'scene-breakdown': {
|
|
127
|
-
id: 'scene-breakdown',
|
|
128
|
-
label: 'Scenes',
|
|
129
|
-
icon: 'Layers',
|
|
130
|
-
description: 'Detail scenes',
|
|
131
|
-
},
|
|
132
|
-
'book-review': {
|
|
133
|
-
id: 'book-review',
|
|
134
|
-
label: 'Review',
|
|
135
|
-
icon: 'CheckCircle',
|
|
136
|
-
description: 'Structure check',
|
|
137
|
-
},
|
|
138
|
-
// ── Course / Training actions ─────────────────────────────────────────────
|
|
139
|
-
'curriculum-design': {
|
|
140
|
-
id: 'curriculum-design',
|
|
141
|
-
label: 'Curriculum',
|
|
142
|
-
icon: 'School',
|
|
143
|
-
description: 'Define structure',
|
|
144
|
-
},
|
|
145
|
-
'lesson-plan': {
|
|
146
|
-
id: 'lesson-plan',
|
|
147
|
-
label: 'Lessons',
|
|
148
|
-
icon: 'BookOpen',
|
|
149
|
-
description: 'Plan lessons',
|
|
150
|
-
},
|
|
151
|
-
'assessment-design': {
|
|
152
|
-
id: 'assessment-design',
|
|
153
|
-
label: 'Assess',
|
|
154
|
-
icon: 'ClipboardCheck',
|
|
155
|
-
description: 'Create assessments',
|
|
156
|
-
},
|
|
157
|
-
'course-review': {
|
|
158
|
-
id: 'course-review',
|
|
159
|
-
label: 'Review',
|
|
160
|
-
icon: 'CheckCircle',
|
|
161
|
-
description: 'Quality check',
|
|
162
|
-
},
|
|
163
|
-
'financial-model': {
|
|
164
|
-
id: 'financial-model',
|
|
165
|
-
label: 'Financials',
|
|
166
|
-
icon: 'DollarSign',
|
|
167
|
-
description: 'Build projections',
|
|
168
|
-
},
|
|
169
|
-
'pitch-outline': {
|
|
170
|
-
id: 'pitch-outline',
|
|
171
|
-
label: 'Pitch',
|
|
172
|
-
icon: 'Rocket',
|
|
173
|
-
description: 'Structure a pitch',
|
|
174
|
-
},
|
|
175
|
-
'business-review': {
|
|
176
|
-
id: 'business-review',
|
|
177
|
-
label: 'Review',
|
|
178
|
-
icon: 'ShieldCheck',
|
|
179
|
-
description: 'Validate the plan',
|
|
180
|
-
},
|
|
181
|
-
// ── Work item actions ────────────────────────────────────────────────────
|
|
182
|
-
build: {
|
|
183
|
-
id: 'build',
|
|
184
|
-
label: 'Build',
|
|
185
|
-
icon: 'Hammer',
|
|
186
|
-
description: 'Implement this item',
|
|
187
|
-
category: 'development',
|
|
188
|
-
suggestedRole: 'developer',
|
|
189
|
-
},
|
|
190
|
-
'refine-item': {
|
|
191
|
-
id: 'refine-item',
|
|
192
|
-
label: 'Refine',
|
|
193
|
-
icon: 'RefreshCw',
|
|
194
|
-
description: 'Add detail to this item',
|
|
195
|
-
category: 'planning',
|
|
196
|
-
suggestedRole: 'pm',
|
|
197
|
-
},
|
|
198
|
-
'code-review': {
|
|
199
|
-
id: 'code-review',
|
|
200
|
-
label: 'Review',
|
|
201
|
-
icon: 'Search',
|
|
202
|
-
description: 'Review code for this item',
|
|
203
|
-
category: 'development',
|
|
204
|
-
suggestedRole: 'qa',
|
|
205
|
-
},
|
|
206
|
-
explain: {
|
|
207
|
-
id: 'explain',
|
|
208
|
-
label: 'Explain',
|
|
209
|
-
icon: 'BookOpen',
|
|
210
|
-
description: 'Explain this item',
|
|
211
|
-
category: 'documentation',
|
|
212
|
-
},
|
|
213
|
-
};
|
|
18
|
+
import { MACRO_META_REGISTRY } from './macro-meta.js';
|
|
214
19
|
/**
|
|
215
|
-
* Resolve action
|
|
216
|
-
*
|
|
20
|
+
* Resolve action ids to their button metadata.
|
|
21
|
+
*
|
|
22
|
+
* An unknown id still yields a usable entry rather than throwing — but it is a hole, not a
|
|
23
|
+
* feature: it renders as the raw id with a generic icon, which is exactly how twenty macros
|
|
24
|
+
* came to be displayed as `business-vision`, `market-analysis`, … The coverage guard in
|
|
25
|
+
* tests/skills/macro-meta-coverage.test.ts is what keeps this branch unreachable for anything
|
|
26
|
+
* we ship.
|
|
217
27
|
*/
|
|
218
28
|
export function resolveActionMeta(actionIds) {
|
|
219
|
-
return actionIds.map((id) =>
|
|
29
|
+
return actionIds.map((id) => {
|
|
30
|
+
// `in`, not a falsy check on the lookup. `Record<string, MacroMeta>` claims every key
|
|
31
|
+
// resolves, so `if (!meta)` reads as dead code to eslint and it asks for the guard to be
|
|
32
|
+
// deleted — but `id` comes from a project type's data, not from the type, and an unknown id
|
|
33
|
+
// is exactly what this branch is for. `checkMacroCompatibility` guards the same way.
|
|
34
|
+
if (!(id in MACRO_META_REGISTRY))
|
|
35
|
+
return { id, label: id, icon: 'Zap', description: id };
|
|
36
|
+
const meta = MACRO_META_REGISTRY[id];
|
|
37
|
+
const action = {
|
|
38
|
+
id: meta.id,
|
|
39
|
+
label: meta.shortLabel ?? meta.label,
|
|
40
|
+
icon: meta.icon,
|
|
41
|
+
description: meta.shortDescription ?? meta.description,
|
|
42
|
+
// Populated for every action now. The old registry carried it on 4 of 35 entries, which
|
|
43
|
+
// was an artifact of who edited it last rather than a distinction — nothing reads it, and
|
|
44
|
+
// ActionBar already groups by category elsewhere.
|
|
45
|
+
category: meta.category,
|
|
46
|
+
};
|
|
47
|
+
if (meta.suggestedRole !== undefined)
|
|
48
|
+
action.suggestedRole = meta.suggestedRole;
|
|
49
|
+
return action;
|
|
50
|
+
});
|
|
220
51
|
}
|
|
@@ -5,10 +5,12 @@
|
|
|
5
5
|
* document templates, and skills. The underlying platform is the same
|
|
6
6
|
* for all types.
|
|
7
7
|
*/
|
|
8
|
-
export type { ProjectTypeConfig, ProjectPhase, SuggestedAgent, DocumentTemplate, ActionMeta,
|
|
8
|
+
export type { ProjectTypeConfig, ProjectPhase, SuggestedAgent, DocumentTemplate, ActionMeta, MacroMeta, MacroCategory, } from './types.js';
|
|
9
9
|
export { generalConfig, softwareConfig, researchConfig, businessPlanConfig, contentConfig, techDocsConfig, courseConfig, bookConfig, } from './configs.js';
|
|
10
|
-
export {
|
|
11
|
-
export {
|
|
10
|
+
export { MACRO_META_REGISTRY, getMacroMeta, getAllMacroMeta } from './macro-meta.js';
|
|
11
|
+
export { resolveActionMeta } from './action-meta.js';
|
|
12
|
+
export { getRelevantMacros } from './macro-relevance.js';
|
|
13
|
+
export type { MacroCapabilities } from './macro-relevance.js';
|
|
12
14
|
import type { ProjectTypeConfig } from './types.js';
|
|
13
15
|
/** All registered project types */
|
|
14
16
|
export declare const PROJECT_TYPES: ProjectTypeConfig[];
|
|
@@ -8,8 +8,9 @@
|
|
|
8
8
|
// Configs
|
|
9
9
|
export { generalConfig, softwareConfig, researchConfig, businessPlanConfig, contentConfig, techDocsConfig, courseConfig, bookConfig, } from './configs.js';
|
|
10
10
|
// Action & Skill metadata
|
|
11
|
-
export {
|
|
12
|
-
export {
|
|
11
|
+
export { MACRO_META_REGISTRY, getMacroMeta, getAllMacroMeta } from './macro-meta.js';
|
|
12
|
+
export { resolveActionMeta } from './action-meta.js';
|
|
13
|
+
export { getRelevantMacros } from './macro-relevance.js';
|
|
13
14
|
import { resolveActionMeta } from './action-meta.js';
|
|
14
15
|
import { generalConfig, softwareConfig, researchConfig, businessPlanConfig, contentConfig, techDocsConfig, courseConfig, bookConfig, } from './configs.js';
|
|
15
16
|
/** All registered project types */
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Macro Metadata Registry — the single registry for every macro we ship.
|
|
3
|
+
*
|
|
4
|
+
* 55 entries: 42 platform macros, the 6 agents-library builtins they do not shadow, and the 7
|
|
5
|
+
* from agents-coding. Every id here is a MACRO — a named prompt the user invokes — never an
|
|
6
|
+
* installed Skill, which carries its own description in its SKILL.md.
|
|
7
|
+
*
|
|
8
|
+
* ⚠️ THERE USED TO BE THREE OF THESE. This one (unread, reachable only through an IPC channel
|
|
9
|
+
* nothing called), ACTION_META_REGISTRY (live, shorter labels), and a third inside Desktop
|
|
10
|
+
* (live, the slash menu). Each was missing what the others had: this one lacked all 8 canvas
|
|
11
|
+
* and 7 agents-coding macros, Desktop's lacked all 20 business/content/course/book ones. The
|
|
12
|
+
* failure mode was never an error — a macro with no entry renders as its raw id with a generic
|
|
13
|
+
* icon, so a business-plan project listed `business-vision`, `market-analysis`, … verbatim.
|
|
14
|
+
*
|
|
15
|
+
* `shortLabel` is why the merge is not lossy: ACTION_META's labels were shorter ON PURPOSE
|
|
16
|
+
* (a button in a row of six cannot say "Competitor Analysis"), so both survive here. Every one
|
|
17
|
+
* of its 35 labels is reproducible as `shortLabel ?? label`, asserted before it was deleted.
|
|
18
|
+
*
|
|
19
|
+
* Coverage is enforced, in both directions, by tests/skills/macro-meta-coverage.test.ts —
|
|
20
|
+
* derived from the macro sources themselves, never a hand-written list, because a hand-written
|
|
21
|
+
* list is precisely what produced three maps.
|
|
22
|
+
*
|
|
23
|
+
* Spec: project-docs/00-requirements/compilr-dev-sdk/macro-metadata-consolidation.md
|
|
24
|
+
*/
|
|
25
|
+
import type { MacroMeta } from './types.js';
|
|
26
|
+
/** All macro UI metadata — platform macros + the agents library's builtins. */
|
|
27
|
+
export declare const MACRO_META_REGISTRY: Record<string, MacroMeta>;
|
|
28
|
+
/**
|
|
29
|
+
* Get macro metadata by ID.
|
|
30
|
+
*
|
|
31
|
+
* No internal caller: `buildMacroList` and `resolveActionMeta` read the registry directly.
|
|
32
|
+
* Kept as public API of a published package — but do not read its existence as evidence that
|
|
33
|
+
* something depends on it. The IPC channel that used to was deleted for being dead.
|
|
34
|
+
*/
|
|
35
|
+
export declare function getMacroMeta(macroId: string): MacroMeta | undefined;
|
|
36
|
+
/**
|
|
37
|
+
* Get all macro metadata entries.
|
|
38
|
+
*/
|
|
39
|
+
export declare function getAllMacroMeta(): MacroMeta[];
|