Predefined mesh configurations (dev-team, research, ops-incident, simulation, personal) let users bootstrap meshes with groups, roles, state keys, and system prompt hints. Templates are bundled at build time via Bun's JSON import support. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
31 lines
879 B
TypeScript
31 lines
879 B
TypeScript
import devTeam from "./dev-team.json" with { type: "json" };
|
|
import research from "./research.json" with { type: "json" };
|
|
import opsIncident from "./ops-incident.json" with { type: "json" };
|
|
import simulation from "./simulation.json" with { type: "json" };
|
|
import personal from "./personal.json" with { type: "json" };
|
|
|
|
export interface MeshTemplate {
|
|
name: string;
|
|
description: string;
|
|
groups: Array<{ name: string; roles: string[] }>;
|
|
stateKeys: Record<string, string>;
|
|
suggestedRoles: string[];
|
|
systemPromptHint: string;
|
|
}
|
|
|
|
export const TEMPLATES: Record<string, MeshTemplate> = {
|
|
"dev-team": devTeam,
|
|
research,
|
|
"ops-incident": opsIncident,
|
|
simulation,
|
|
personal,
|
|
};
|
|
|
|
export function listTemplates(): MeshTemplate[] {
|
|
return Object.values(TEMPLATES);
|
|
}
|
|
|
|
export function getTemplate(name: string): MeshTemplate | undefined {
|
|
return TEMPLATES[name];
|
|
}
|