rolexjs 1.4.0-dev-20260306081757 → 1.4.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/index.d.ts +17 -1
- package/dist/index.js +119 -7
- package/dist/index.js.map +1 -1
- package/package.json +6 -6
package/dist/index.d.ts
CHANGED
|
@@ -2,6 +2,22 @@ import { RoleX as RoleX$1, Platform, Renderer, Role } from '@rolexjs/core';
|
|
|
2
2
|
export * from '@rolexjs/core';
|
|
3
3
|
import { State } from '@rolexjs/system';
|
|
4
4
|
|
|
5
|
+
/**
|
|
6
|
+
* Product Render — format product state as readable text.
|
|
7
|
+
*
|
|
8
|
+
* Renders product operations into human-readable summaries.
|
|
9
|
+
* Ownership links show owner names only (not full individual trees).
|
|
10
|
+
* Specs show behavior contract titles for quick overview.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
type ProductAction = "create" | "strategy" | "spec" | "release" | "channel" | "own" | "disown" | "deprecate";
|
|
14
|
+
declare function renderProduct(state: State): string;
|
|
15
|
+
/**
|
|
16
|
+
* Render a product operation result as readable text.
|
|
17
|
+
* Returns status + hint + product overview.
|
|
18
|
+
*/
|
|
19
|
+
declare function renderProductResult(action: ProductAction, state: State): string;
|
|
20
|
+
|
|
5
21
|
/**
|
|
6
22
|
* Project Render — format project state as readable text.
|
|
7
23
|
*
|
|
@@ -53,4 +69,4 @@ declare class RoleX implements RoleX$1 {
|
|
|
53
69
|
/** Create a RoleX instance from a Platform. */
|
|
54
70
|
declare function createRoleX(platform: Platform, renderer?: Renderer): Promise<RoleX>;
|
|
55
71
|
|
|
56
|
-
export { type ProjectAction, RoleX, createRoleX, detail, renderProjectResult };
|
|
72
|
+
export { type ProductAction, type ProjectAction, RoleX, createRoleX, detail, renderProduct, renderProductResult, renderProjectResult };
|
package/dist/index.js
CHANGED
|
@@ -30,6 +30,15 @@ var descriptions = {
|
|
|
30
30
|
deliver: (n) => `Deliverable "${n}" added.`,
|
|
31
31
|
wiki: (n) => `Wiki entry "${n}" added.`,
|
|
32
32
|
archive: (n) => `Project "${n}" archived.`,
|
|
33
|
+
// Product
|
|
34
|
+
create: (n) => `Product "${n}" created.`,
|
|
35
|
+
strategy: (n) => `Strategy defined for "${n}".`,
|
|
36
|
+
spec: (n) => `Spec "${n}" added.`,
|
|
37
|
+
release: (n) => `Release "${n}" published.`,
|
|
38
|
+
channel: (n) => `Channel "${n}" added.`,
|
|
39
|
+
own: (n) => `Owner assigned to "${n}".`,
|
|
40
|
+
disown: (n) => `Owner removed from "${n}".`,
|
|
41
|
+
deprecate: (n) => `Product "${n}" deprecated.`,
|
|
33
42
|
// Role
|
|
34
43
|
activate: (n) => `Role "${n}" activated.`,
|
|
35
44
|
focus: (n) => `Focused on goal "${n}".`,
|
|
@@ -78,6 +87,15 @@ var hints = {
|
|
|
78
87
|
deliver: "deliverable recorded.",
|
|
79
88
|
wiki: "knowledge entry recorded.",
|
|
80
89
|
archive: "the project is archived.",
|
|
90
|
+
// Product
|
|
91
|
+
create: "define strategy, add specs, or assign an owner.",
|
|
92
|
+
strategy: "add behavior specs (BDD contracts) for the product.",
|
|
93
|
+
spec: "add more specs, or publish a release.",
|
|
94
|
+
release: "add distribution channels, or continue adding specs.",
|
|
95
|
+
channel: "distribution channel recorded.",
|
|
96
|
+
own: "the individual is now the product owner.",
|
|
97
|
+
disown: "the individual is no longer the product owner.",
|
|
98
|
+
deprecate: "the product is deprecated.",
|
|
81
99
|
// Role
|
|
82
100
|
activate: "want a goal, or check the current state.",
|
|
83
101
|
focus: "plan how to work toward it, or add tasks.",
|
|
@@ -169,7 +187,12 @@ var CONCEPT_ORDER = [
|
|
|
169
187
|
"scope",
|
|
170
188
|
"milestone",
|
|
171
189
|
"deliverable",
|
|
172
|
-
"wiki"
|
|
190
|
+
"wiki",
|
|
191
|
+
// Product
|
|
192
|
+
"strategy",
|
|
193
|
+
"spec",
|
|
194
|
+
"release",
|
|
195
|
+
"channel"
|
|
173
196
|
];
|
|
174
197
|
function goalProgress(goal) {
|
|
175
198
|
let plans = 0;
|
|
@@ -206,6 +229,85 @@ function sortByConceptOrder(children) {
|
|
|
206
229
|
});
|
|
207
230
|
}
|
|
208
231
|
|
|
232
|
+
// src/product-render.ts
|
|
233
|
+
function renderProduct(state) {
|
|
234
|
+
const lines = [];
|
|
235
|
+
const id = state.id ?? "(no id)";
|
|
236
|
+
const tag = state.tag ? ` #${state.tag}` : "";
|
|
237
|
+
lines.push(`# ${id}${tag}`);
|
|
238
|
+
if (state.information) {
|
|
239
|
+
lines.push("");
|
|
240
|
+
lines.push(state.information);
|
|
241
|
+
}
|
|
242
|
+
const owners = state.links?.filter((l) => l.relation === "ownership") ?? [];
|
|
243
|
+
if (owners.length > 0) {
|
|
244
|
+
lines.push("");
|
|
245
|
+
lines.push("## Owner");
|
|
246
|
+
for (const o of owners) {
|
|
247
|
+
const alias = o.target.alias?.length ? ` (${o.target.alias.join(", ")})` : "";
|
|
248
|
+
lines.push(`- ${o.target.id ?? "(no id)"}${alias}`);
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
const children = state.children ?? [];
|
|
252
|
+
const strategies = children.filter((c) => c.name === "strategy");
|
|
253
|
+
const specs = children.filter((c) => c.name === "spec");
|
|
254
|
+
const releases = children.filter((c) => c.name === "release");
|
|
255
|
+
const channels = children.filter((c) => c.name === "channel");
|
|
256
|
+
if (strategies.length > 0) {
|
|
257
|
+
lines.push("");
|
|
258
|
+
lines.push("## Strategy");
|
|
259
|
+
for (const s of strategies) {
|
|
260
|
+
if (s.information) lines.push(s.information);
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
if (specs.length > 0) {
|
|
264
|
+
lines.push("");
|
|
265
|
+
lines.push("## Specs");
|
|
266
|
+
for (const s of specs) {
|
|
267
|
+
const title = s.id ?? extractFeatureTitle(s.information);
|
|
268
|
+
lines.push(`- ${title}`);
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
if (releases.length > 0) {
|
|
272
|
+
lines.push("");
|
|
273
|
+
lines.push("## Releases");
|
|
274
|
+
for (const r of releases) {
|
|
275
|
+
const tag2 = r.tag ? ` #${r.tag}` : "";
|
|
276
|
+
const title = r.id ?? extractFeatureTitle(r.information);
|
|
277
|
+
lines.push(`- ${title}${tag2}`);
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
if (channels.length > 0) {
|
|
281
|
+
lines.push("");
|
|
282
|
+
lines.push("## Channels");
|
|
283
|
+
for (const c of channels) {
|
|
284
|
+
const title = c.id ?? extractFeatureTitle(c.information);
|
|
285
|
+
lines.push(`- ${title}`);
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
return lines.join("\n");
|
|
289
|
+
}
|
|
290
|
+
function renderProductResult(action, state) {
|
|
291
|
+
const name = state.id ?? state.name;
|
|
292
|
+
const lines = [];
|
|
293
|
+
lines.push(describe(action, name, state));
|
|
294
|
+
lines.push(hint(action));
|
|
295
|
+
const productState = isProductNode(state) ? state : null;
|
|
296
|
+
if (productState) {
|
|
297
|
+
lines.push("");
|
|
298
|
+
lines.push(renderProduct(productState));
|
|
299
|
+
}
|
|
300
|
+
return lines.join("\n");
|
|
301
|
+
}
|
|
302
|
+
function isProductNode(state) {
|
|
303
|
+
return state.name === "product";
|
|
304
|
+
}
|
|
305
|
+
function extractFeatureTitle(information) {
|
|
306
|
+
if (!information) return "(untitled)";
|
|
307
|
+
const match = information.match(/^Feature:\s*(.+)$/m);
|
|
308
|
+
return match?.[1]?.trim() ?? information.split("\n")[0].trim();
|
|
309
|
+
}
|
|
310
|
+
|
|
209
311
|
// src/project-render.ts
|
|
210
312
|
function renderProject(state) {
|
|
211
313
|
const lines = [];
|
|
@@ -243,10 +345,10 @@ function renderProject(state) {
|
|
|
243
345
|
for (const m of milestones) {
|
|
244
346
|
const tag2 = m.tag ? ` #${m.tag}` : "";
|
|
245
347
|
const marker = m.tag === "done" ? "[x]" : "[ ]";
|
|
246
|
-
const title =
|
|
348
|
+
const title = extractFeatureTitle2(m.information);
|
|
247
349
|
lines.push(`- ${marker} ${m.id ?? title}${tag2}`);
|
|
248
350
|
if (m.information && m.id) {
|
|
249
|
-
const desc =
|
|
351
|
+
const desc = extractFeatureTitle2(m.information);
|
|
250
352
|
if (desc && desc !== m.id) lines.push(` ${desc}`);
|
|
251
353
|
}
|
|
252
354
|
}
|
|
@@ -255,7 +357,7 @@ function renderProject(state) {
|
|
|
255
357
|
lines.push("");
|
|
256
358
|
lines.push("## Deliverables");
|
|
257
359
|
for (const d of deliverables) {
|
|
258
|
-
const title = d.id ??
|
|
360
|
+
const title = d.id ?? extractFeatureTitle2(d.information);
|
|
259
361
|
lines.push(`- ${title}`);
|
|
260
362
|
}
|
|
261
363
|
}
|
|
@@ -263,7 +365,7 @@ function renderProject(state) {
|
|
|
263
365
|
lines.push("");
|
|
264
366
|
lines.push("## Wiki");
|
|
265
367
|
for (const w of wikis) {
|
|
266
|
-
const title = w.id ??
|
|
368
|
+
const title = w.id ?? extractFeatureTitle2(w.information);
|
|
267
369
|
lines.push(`- ${title}`);
|
|
268
370
|
}
|
|
269
371
|
}
|
|
@@ -284,7 +386,7 @@ function renderProjectResult(action, state) {
|
|
|
284
386
|
function isProjectNode(state) {
|
|
285
387
|
return state.name === "project";
|
|
286
388
|
}
|
|
287
|
-
function
|
|
389
|
+
function extractFeatureTitle2(information) {
|
|
288
390
|
if (!information) return "(untitled)";
|
|
289
391
|
const match = information.match(/^Feature:\s*(.+)$/m);
|
|
290
392
|
return match?.[1]?.trim() ?? information.split("\n")[0].trim();
|
|
@@ -416,6 +518,14 @@ var PositionRenderer = class {
|
|
|
416
518
|
}
|
|
417
519
|
};
|
|
418
520
|
|
|
521
|
+
// src/renderers/product.ts
|
|
522
|
+
var ProductRenderer = class {
|
|
523
|
+
render(command, result) {
|
|
524
|
+
const action = command.startsWith("product.") ? command.slice("product.".length) : command;
|
|
525
|
+
return renderProductResult(action, result.state);
|
|
526
|
+
}
|
|
527
|
+
};
|
|
528
|
+
|
|
419
529
|
// src/renderers/project.ts
|
|
420
530
|
var ProjectRenderer = class {
|
|
421
531
|
render(command, result) {
|
|
@@ -440,7 +550,7 @@ var RoleRenderer = class {
|
|
|
440
550
|
|
|
441
551
|
// src/renderers/index.ts
|
|
442
552
|
function createRendererRouter() {
|
|
443
|
-
return new RendererRouter().register("role", new RoleRenderer()).register("individual", new IndividualRenderer()).register("org", new OrgRenderer()).register("position", new PositionRenderer()).register("project", new ProjectRenderer()).register("census", new CensusRenderer());
|
|
553
|
+
return new RendererRouter().register("role", new RoleRenderer()).register("individual", new IndividualRenderer()).register("org", new OrgRenderer()).register("position", new PositionRenderer()).register("product", new ProductRenderer()).register("project", new ProjectRenderer()).register("census", new CensusRenderer());
|
|
444
554
|
}
|
|
445
555
|
|
|
446
556
|
// src/rolex.ts
|
|
@@ -468,6 +578,8 @@ export {
|
|
|
468
578
|
RoleX,
|
|
469
579
|
createRoleX,
|
|
470
580
|
detail,
|
|
581
|
+
renderProduct,
|
|
582
|
+
renderProductResult,
|
|
471
583
|
renderProjectResult
|
|
472
584
|
};
|
|
473
585
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts","../src/render.ts","../src/project-render.ts","../src/rolex.ts","../src/renderers/index.ts","../src/renderers/census.ts","../src/renderers/individual.ts","../src/renderers/org.ts","../src/renderers/position.ts","../src/renderers/project.ts","../src/renderers/role.ts"],"sourcesContent":["/**\n * rolexjs — RoleX unified entry point.\n *\n * Usage:\n * import { createRoleX, Role } from \"rolexjs\";\n *\n * const rolex = await createRoleX(platform);\n * const role = await rolex.activate(\"sean\");\n * await role.want(\"Feature: Ship v1\", \"ship-v1\");\n */\n\n// Re-export core (structures, processes, Role, types)\nexport * from \"@rolexjs/core\";\n// Project Render\nexport type { ProjectAction } from \"./project-render.js\";\nexport { renderProjectResult } from \"./project-render.js\";\n// Render\nexport { detail } from \"./render.js\";\n// API\nexport { createRoleX, RoleX } from \"./rolex.js\";\n","/**\n * Render — 3-layer output for all Rolex operations.\n *\n * Layer 1: Status — what just happened (describe)\n * Layer 2: Hint — what to do next (hint + cognitive hint)\n * Layer 3: Projection — full state tree as markdown (renderState)\n *\n * render() composes the 3 layers. MCP and CLI are pure pass-through.\n */\nimport type { State } from \"@rolexjs/system\";\n\n// ================================================================\n// Description — what happened\n// ================================================================\n\nconst descriptions: Record<string, (name: string, state: State) => string> = {\n // Lifecycle\n born: (n) => `Individual \"${n}\" is born.`,\n found: (n) => `Organization \"${n}\" is founded.`,\n establish: (n) => `Position \"${n}\" is established.`,\n charter: (n) => `Charter defined for \"${n}\".`,\n charge: (n) => `Duty \"${n}\" assigned.`,\n retire: (n) => `\"${n}\" retired.`,\n die: (n) => `\"${n}\" is gone.`,\n dissolve: (n) => `Organization \"${n}\" dissolved.`,\n abolish: (n) => `Position \"${n}\" abolished.`,\n rehire: (n) => `\"${n}\" is back.`,\n\n // Organization\n hire: (n) => `\"${n}\" hired.`,\n fire: (n) => `\"${n}\" fired.`,\n appoint: (n) => `\"${n}\" appointed.`,\n dismiss: (n) => `\"${n}\" dismissed.`,\n\n // Project\n launch: (n) => `Project \"${n}\" launched.`,\n scope: (n) => `Scope defined for \"${n}\".`,\n milestone: (n) => `Milestone \"${n}\" added.`,\n achieve: (n) => `Milestone \"${n}\" achieved.`,\n enroll: (n) => `\"${n}\" enrolled.`,\n remove: (n) => `\"${n}\" removed.`,\n deliver: (n) => `Deliverable \"${n}\" added.`,\n wiki: (n) => `Wiki entry \"${n}\" added.`,\n archive: (n) => `Project \"${n}\" archived.`,\n\n // Role\n activate: (n) => `Role \"${n}\" activated.`,\n focus: (n) => `Focused on goal \"${n}\".`,\n\n // Execution\n want: (n) => `Goal \"${n}\" declared.`,\n plan: (n) => `Plan created for \"${n}\".`,\n todo: (n) => `Task \"${n}\" added.`,\n finish: (n) => `Task \"${n}\" finished → encounter recorded.`,\n complete: (n) => `Plan \"${n}\" completed → encounter recorded.`,\n abandon: (n) => `Plan \"${n}\" abandoned → encounter recorded.`,\n\n // Cognition\n reflect: (n) => `Reflected on \"${n}\" → experience gained.`,\n realize: (n) => `Realized principle from \"${n}\".`,\n master: (n) => `Mastered procedure from \"${n}\".`,\n\n // Knowledge management\n forget: (n) => `\"${n}\" forgotten.`,\n};\n\nexport function describe(process: string, name: string, state: State): string {\n const fn = descriptions[process];\n return fn ? fn(name, state) : `${process} completed.`;\n}\n\n// ================================================================\n// Hint — what to do next\n// ================================================================\n\nconst hints: Record<string, string> = {\n // Lifecycle\n born: \"hire into an organization, or activate to start working.\",\n found: \"define a charter for the organization.\",\n establish: \"charge with duties, then appoint members.\",\n charter: \"establish positions for the organization.\",\n charge: \"appoint someone to this position.\",\n retire: \"rehire if needed later.\",\n die: \"this individual is permanently gone.\",\n dissolve: \"the organization no longer exists.\",\n abolish: \"the position no longer exists.\",\n rehire: \"activate to resume working.\",\n\n // Organization\n hire: \"appoint to a position, or activate to start working.\",\n fire: \"the individual is no longer a member.\",\n appoint: \"the individual now holds this position.\",\n dismiss: \"the position is now vacant.\",\n\n // Project\n launch: \"define scope, add milestones, or enroll members.\",\n scope: \"add milestones to break down the project.\",\n milestone: \"enroll members and start working.\",\n achieve: \"continue with remaining milestones, or archive the project.\",\n enroll: \"assign milestones and start working.\",\n remove: \"the individual is no longer a participant.\",\n deliver: \"deliverable recorded.\",\n wiki: \"knowledge entry recorded.\",\n archive: \"the project is archived.\",\n\n // Role\n activate: \"want a goal, or check the current state.\",\n focus: \"plan how to work toward it, or add tasks.\",\n\n // Execution\n want: \"plan how to work toward it.\",\n plan: \"add tasks with todo.\",\n todo: \"start working, finish when done.\",\n finish: \"continue with remaining tasks, or complete the plan.\",\n complete: \"reflect on encounters to gain experience.\",\n abandon: \"reflect on encounters to learn from the experience.\",\n\n // Cognition\n reflect: \"realize principles or master procedures from experience.\",\n realize: \"principle added.\",\n master: \"procedure added.\",\n\n // Knowledge management\n forget: \"the node has been removed.\",\n};\n\nexport function hint(process: string): string {\n const h = hints[process];\n return h ? `Next: ${h}` : \"What would you like to do next?\";\n}\n\n// ================================================================\n// Detail — longer process descriptions (from .feature files)\n// ================================================================\n\nimport { directives, processes, world } from \"@rolexjs/core\";\n\n/** Full Gherkin feature content for a process — sourced from .feature files. */\nexport function detail(process: string): string {\n return processes[process] ?? \"\";\n}\n\n/** World feature descriptions — framework-level instructions. */\nexport { world };\n\n// ================================================================\n// Directive — system-level commands at decision points\n// ================================================================\n\n/** Get a directive by topic and scenario. Returns empty string if not found. */\nexport function directive(topic: string, scenario: string): string {\n return directives[topic]?.[scenario] ?? \"\";\n}\n\n// ================================================================\n// Generic State renderer — renders any State tree as markdown\n// ================================================================\n\n/**\n * renderState — markdown renderer for State trees.\n *\n * Rules:\n * - Heading: \"#\" repeated to depth + \" [name]\"\n * - Body: raw information field as-is (full Gherkin preserved)\n * - Links: \"> → relation [target.name]\" with target feature name\n * - Children: sorted by concept hierarchy, then rendered at depth+1\n * - Fold: when fold(node) returns true, render heading only (no body/links/children)\n *\n * Markdown heading depth caps at 6 (######).\n */\nexport interface RenderStateOptions {\n /** When returns true, render only the heading — skip body, links, and children. */\n fold?: (node: State) => boolean;\n}\n\nexport function renderState(state: State, depth = 1, options?: RenderStateOptions): string {\n const lines: string[] = [];\n const level = Math.min(depth, 6);\n const heading = \"#\".repeat(level);\n\n // Heading: [name] (id) {origin} #tag [progress]\n const idPart = state.id ? ` (${state.id})` : \"\";\n const originPart = state.origin ? ` {${state.origin}}` : \"\";\n const tagPart = state.tag ? ` #${state.tag}` : \"\";\n const progressPart = state.name === \"goal\" ? goalProgress(state) : \"\";\n lines.push(`${heading} [${state.name}]${idPart}${originPart}${tagPart}${progressPart}`);\n\n // Folded: heading only\n if (options?.fold?.(state)) {\n return lines.join(\"\\n\");\n }\n\n // Body: full information as-is\n if (state.information) {\n lines.push(\"\");\n lines.push(state.information);\n }\n\n // Links — plan references are compact, organizational links are expanded\n if (state.links && state.links.length > 0) {\n const compactRelations = new Set([\"after\", \"before\", \"fallback\", \"fallback-for\"]);\n const compact = state.links.filter((l) => compactRelations.has(l.relation));\n const expanded = state.links.filter((l) => !compactRelations.has(l.relation));\n for (const link of compact) {\n const targetId = link.target.id ? ` (${link.target.id})` : \"\";\n const targetTag = link.target.tag ? ` #${link.target.tag}` : \"\";\n lines.push(`> ${link.relation}: [${link.target.name}]${targetId}${targetTag}`);\n }\n if (expanded.length > 0) {\n const targets = sortByConceptOrder(expanded.map((l) => l.target));\n for (const target of targets) {\n lines.push(\"\");\n lines.push(renderState(target, depth + 1, options));\n }\n }\n }\n\n // Children — sorted by concept hierarchy, empty nodes filtered out\n if (state.children && state.children.length > 0) {\n const sorted = sortByConceptOrder(state.children.filter((c) => !isEmpty(c)));\n for (const child of sorted) {\n lines.push(\"\");\n lines.push(renderState(child, depth + 1, options));\n }\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Concept ordering — children sorted by structure hierarchy\n// ================================================================\n\n/** Concept tree order: identity → cognition → knowledge → execution → organization. */\nconst CONCEPT_ORDER: readonly string[] = [\n // Individual — Identity\n \"identity\",\n \"background\",\n \"tone\",\n \"mindset\",\n // Individual — Cognition\n \"encounter\",\n \"experience\",\n // Individual — Knowledge\n \"principle\",\n \"procedure\",\n // Individual — Execution\n \"goal\",\n \"plan\",\n \"task\",\n // Organization\n \"charter\",\n // Position\n \"position\",\n \"duty\",\n // Project\n \"scope\",\n \"milestone\",\n \"deliverable\",\n \"wiki\",\n];\n\n/** Summarize plan/task completion for a goal heading. */\nfunction goalProgress(goal: State): string {\n let plans = 0;\n let plansDone = 0;\n let tasks = 0;\n let tasksDone = 0;\n\n function walk(node: State): void {\n if (node.name === \"plan\") {\n plans++;\n if (node.tag === \"done\" || node.tag === \"abandoned\") plansDone++;\n } else if (node.name === \"task\") {\n tasks++;\n if (node.tag === \"done\") tasksDone++;\n }\n for (const child of node.children ?? []) walk(child);\n }\n\n for (const child of goal.children ?? []) walk(child);\n if (plans === 0 && tasks === 0) return \"\";\n const parts: string[] = [];\n if (plans > 0) parts.push(`${plansDone}/${plans} plans`);\n if (tasks > 0) parts.push(`${tasksDone}/${tasks} tasks`);\n return ` [${parts.join(\", \")}]`;\n}\n\n/** A node is empty when it has no id, no information, and no children. */\nfunction isEmpty(node: State): boolean {\n return !node.id && !node.information && (!node.children || node.children.length === 0);\n}\n\n/** Sort children by concept hierarchy order. Unknown names go to the end, preserving relative order. */\nfunction sortByConceptOrder(children: readonly State[]): readonly State[] {\n return [...children].sort((a, b) => {\n const ai = CONCEPT_ORDER.indexOf(a.name);\n const bi = CONCEPT_ORDER.indexOf(b.name);\n const aOrder = ai >= 0 ? ai : CONCEPT_ORDER.length;\n const bOrder = bi >= 0 ? bi : CONCEPT_ORDER.length;\n return aOrder - bOrder;\n });\n}\n\n// ================================================================\n// Render — 3-layer output for tool results\n// ================================================================\n\nexport interface RenderOptions {\n /** The process that was executed. */\n process: string;\n /** Display name for the primary node. */\n name: string;\n /** State projection of the affected node. */\n state: State;\n /** AI cognitive hint — first-person, state-aware self-direction cue. */\n cognitiveHint?: string | null;\n /** Fold predicate — folded nodes render heading only. */\n fold?: RenderStateOptions[\"fold\"];\n}\n\n/** Render a full 3-layer output string. */\nexport function render(opts: RenderOptions): string {\n const { process, name, state, cognitiveHint, fold } = opts;\n const lines: string[] = [];\n\n // Layer 1: Status\n lines.push(describe(process, name, state));\n\n // Layer 2: Hint (static) + Cognitive hint (state-aware)\n lines.push(hint(process));\n if (cognitiveHint) {\n lines.push(`I → ${cognitiveHint}`);\n }\n\n // Layer 3: Projection — generic markdown rendering of the full state tree\n lines.push(\"\");\n lines.push(renderState(state, 1, fold ? { fold } : undefined));\n\n return lines.join(\"\\n\");\n}\n","/**\n * Project Render — format project state as readable text.\n *\n * Renders project operations into human-readable summaries.\n * Participation links show member names only (not full individual trees).\n * Milestones show progress status (#done or pending).\n */\nimport type { State } from \"@rolexjs/system\";\nimport { describe, hint } from \"./render.js\";\n\n// ================================================================\n// Types\n// ================================================================\n\nexport type ProjectAction =\n | \"launch\"\n | \"scope\"\n | \"milestone\"\n | \"achieve\"\n | \"enroll\"\n | \"remove\"\n | \"deliver\"\n | \"wiki\"\n | \"archive\";\n\n// ================================================================\n// Project Overview\n// ================================================================\n\nexport function renderProject(state: State): string {\n const lines: string[] = [];\n const id = state.id ?? \"(no id)\";\n const tag = state.tag ? ` #${state.tag}` : \"\";\n\n // Title\n lines.push(`# ${id}${tag}`);\n\n // Feature body\n if (state.information) {\n lines.push(\"\");\n lines.push(state.information);\n }\n\n // Members (participation links — compact)\n const members = state.links?.filter((l) => l.relation === \"participation\") ?? [];\n if (members.length > 0) {\n lines.push(\"\");\n lines.push(\"## Members\");\n for (const m of members) {\n const alias = m.target.alias?.length ? ` (${m.target.alias.join(\", \")})` : \"\";\n lines.push(`- ${m.target.id ?? \"(no id)\"}${alias}`);\n }\n }\n\n // Children by type\n const children = state.children ?? [];\n\n const scopes = children.filter((c) => c.name === \"scope\");\n const milestones = children.filter((c) => c.name === \"milestone\");\n const deliverables = children.filter((c) => c.name === \"deliverable\");\n const wikis = children.filter((c) => c.name === \"wiki\");\n\n if (scopes.length > 0) {\n lines.push(\"\");\n lines.push(\"## Scope\");\n for (const s of scopes) {\n if (s.information) lines.push(s.information);\n }\n }\n\n if (milestones.length > 0) {\n lines.push(\"\");\n lines.push(\"## Milestones\");\n for (const m of milestones) {\n const tag = m.tag ? ` #${m.tag}` : \"\";\n const marker = m.tag === \"done\" ? \"[x]\" : \"[ ]\";\n const title = extractFeatureTitle(m.information);\n lines.push(`- ${marker} ${m.id ?? title}${tag}`);\n if (m.information && m.id) {\n const desc = extractFeatureTitle(m.information);\n if (desc && desc !== m.id) lines.push(` ${desc}`);\n }\n }\n }\n\n if (deliverables.length > 0) {\n lines.push(\"\");\n lines.push(\"## Deliverables\");\n for (const d of deliverables) {\n const title = d.id ?? extractFeatureTitle(d.information);\n lines.push(`- ${title}`);\n }\n }\n\n if (wikis.length > 0) {\n lines.push(\"\");\n lines.push(\"## Wiki\");\n for (const w of wikis) {\n const title = w.id ?? extractFeatureTitle(w.information);\n lines.push(`- ${title}`);\n }\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Compose — main entry point\n// ================================================================\n\n/**\n * Render a project operation result as readable text.\n * Returns status + hint + project overview.\n */\nexport function renderProjectResult(action: ProjectAction, state: State): string {\n const name = state.id ?? state.name;\n const lines: string[] = [];\n\n // Layer 1: Status\n lines.push(describe(action, name, state));\n\n // Layer 2: Hint\n lines.push(hint(action));\n\n // Layer 3: Project overview\n // For child operations (scope, milestone, etc.), find the project parent\n const projectState = isProjectNode(state) ? state : null;\n if (projectState) {\n lines.push(\"\");\n lines.push(renderProject(projectState));\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Helpers\n// ================================================================\n\nfunction isProjectNode(state: State): boolean {\n return state.name === \"project\";\n}\n\nfunction extractFeatureTitle(information?: string | null): string {\n if (!information) return \"(untitled)\";\n const match = information.match(/^Feature:\\s*(.+)$/m);\n return match?.[1]?.trim() ?? information.split(\"\\n\")[0].trim();\n}\n","/**\n * RoleX — thin entry point.\n *\n * Public API:\n * activate(id) — returns a stateful Role handle\n * direct(loc, args) — direct the world to execute an instruction\n *\n * Delegates to RoleXService (core) for all runtime logic.\n * rolexjs adds the concrete renderer and issue rendering transform.\n */\n\nimport {\n type RoleX as IRoleX,\n type Platform,\n type Renderer,\n type Role,\n RoleXService,\n} from \"@rolexjs/core\";\nimport { createRendererRouter } from \"./renderers/index.js\";\n\nexport class RoleX implements IRoleX {\n private service: RoleXService;\n\n private constructor(service: RoleXService) {\n this.service = service;\n }\n\n static async create(platform: Platform, renderer?: Renderer): Promise<RoleX> {\n const r = renderer ?? createRendererRouter();\n const service = await RoleXService.create(platform, r);\n return new RoleX(service);\n }\n\n async activate(individual: string): Promise<Role> {\n return this.service.activate(individual);\n }\n\n async direct<T = unknown>(\n locator: string,\n args?: Record<string, unknown>,\n options?: { raw?: boolean }\n ): Promise<T> {\n return this.service.direct<T>(locator, args, options);\n }\n}\n\n/** Create a RoleX instance from a Platform. */\nexport async function createRoleX(platform: Platform, renderer?: Renderer): Promise<RoleX> {\n return RoleX.create(platform, renderer);\n}\n","/**\n * Renderers — business-domain Markdown renderers for AI readability.\n *\n * Each renderer handles a command namespace and transforms\n * CommandResult into AI-readable Markdown.\n *\n * createRendererRouter() wires all renderers into a RendererRouter.\n */\n\nimport { RendererRouter } from \"@rolexjs/core\";\nimport { CensusRenderer } from \"./census.js\";\nimport { IndividualRenderer } from \"./individual.js\";\nimport { OrgRenderer } from \"./org.js\";\nimport { PositionRenderer } from \"./position.js\";\nimport { ProjectRenderer } from \"./project.js\";\nimport { RoleRenderer } from \"./role.js\";\n\nexport { CensusRenderer } from \"./census.js\";\nexport { IndividualRenderer } from \"./individual.js\";\nexport { OrgRenderer } from \"./org.js\";\nexport { PositionRenderer } from \"./position.js\";\nexport { ProjectRenderer } from \"./project.js\";\nexport type { Renderer } from \"./renderer.js\";\nexport { RoleRenderer } from \"./role.js\";\n\n/** Create a RendererRouter with all business renderers registered. */\nexport function createRendererRouter(): RendererRouter {\n return new RendererRouter()\n .register(\"role\", new RoleRenderer())\n .register(\"individual\", new IndividualRenderer())\n .register(\"org\", new OrgRenderer())\n .register(\"position\", new PositionRenderer())\n .register(\"project\", new ProjectRenderer())\n .register(\"census\", new CensusRenderer());\n}\n","/**\n * CensusRenderer — Markdown rendering for census.* commands.\n *\n * Renders the organization-centric tree view:\n * orgs → projects + members (with positions) → unaffiliated individuals.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport type { State } from \"@rolexjs/system\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class CensusRenderer implements Renderer {\n render(_command: string, result: CommandResult): string {\n const children = result.state.children ?? [];\n\n if (children.length === 0) {\n return \"Society is empty.\";\n }\n\n // Check if all children are the same type (filtered by type)\n const types = new Set(children.map((c) => c.name));\n if (types.size === 1 && !types.has(\"organization\")) {\n return this.renderFlat(children);\n }\n\n return this.renderTree(children);\n }\n\n private renderFlat(items: readonly State[]): string {\n const lines: string[] = [];\n for (const item of items) {\n const tag = item.tag ? ` #${item.tag}` : \"\";\n const alias = item.alias?.length ? ` (${item.alias.join(\", \")})` : \"\";\n lines.push(`${item.id ?? \"(no id)\"}${alias}${tag}`);\n }\n return lines.join(\"\\n\");\n }\n\n private renderTree(children: readonly State[]): string {\n const orgs = children.filter((c) => c.name === \"organization\");\n const individuals = children.filter((c) => c.name === \"individual\");\n\n // Build a map: individual id → positions they serve\n const individualPositions = new Map<string, string[]>();\n for (const ind of individuals) {\n const serves = ind.links?.filter((l) => l.relation === \"serve\") ?? [];\n if (serves.length > 0) {\n individualPositions.set(\n ind.id ?? \"\",\n serves.map((l) => l.target.id ?? \"(no id)\")\n );\n }\n }\n\n const affiliatedIndividuals = new Set<string>();\n const lines: string[] = [];\n\n for (const org of orgs) {\n const alias = org.alias?.length ? ` (${org.alias.join(\", \")})` : \"\";\n const tag = org.tag ? ` #${org.tag}` : \"\";\n lines.push(`${org.id}${alias}${tag}`);\n\n // Projects owned by this org\n const projects = org.links?.filter((l) => l.relation === \"project\") ?? [];\n for (const p of projects) {\n const pAlias = p.target.alias?.length ? ` (${p.target.alias.join(\", \")})` : \"\";\n const pTag = p.target.tag ? ` #${p.target.tag}` : \"\";\n lines.push(` 📦 ${p.target.id ?? \"(no id)\"}${pAlias}${pTag}`);\n }\n\n // Members of this org\n const members = org.links?.filter((l) => l.relation === \"membership\") ?? [];\n if (members.length === 0 && projects.length === 0) {\n lines.push(\" (empty)\");\n }\n for (const m of members) {\n affiliatedIndividuals.add(m.target.id ?? \"\");\n const mAlias = m.target.alias?.length ? ` (${m.target.alias.join(\", \")})` : \"\";\n const mTag = m.target.tag ? ` #${m.target.tag}` : \"\";\n const posLabels = individualPositions.get(m.target.id ?? \"\");\n const posStr = posLabels?.length ? ` — ${posLabels.join(\", \")}` : \"\";\n lines.push(` ${m.target.id}${mAlias}${mTag}${posStr}`);\n }\n lines.push(\"\");\n }\n\n // Unaffiliated individuals\n const unaffiliated = individuals.filter((ind) => !affiliatedIndividuals.has(ind.id ?? \"\"));\n if (unaffiliated.length > 0) {\n lines.push(\"─── unaffiliated ───\");\n for (const ind of unaffiliated) {\n const alias = ind.alias?.length ? ` (${ind.alias.join(\", \")})` : \"\";\n const tag = ind.tag ? ` #${ind.tag}` : \"\";\n const posLabels = individualPositions.get(ind.id ?? \"\");\n const posStr = posLabels?.length ? ` — ${posLabels.join(\", \")}` : \"\";\n lines.push(` ${ind.id}${alias}${tag}${posStr}`);\n }\n }\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * IndividualRenderer — Markdown rendering for individual.* commands.\n *\n * Covers: born, retire, die, rehire, teach, train.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class IndividualRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"individual.\")\n ? command.slice(\"individual.\".length)\n : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(renderState(result.state));\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * OrgRenderer — Markdown rendering for org.* commands.\n *\n * Covers: found, charter, dissolve, hire, fire.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class OrgRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"org.\") ? command.slice(\"org.\".length) : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(renderState(result.state));\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * PositionRenderer — Markdown rendering for position.* commands.\n *\n * Covers: establish, charge, require, abolish, appoint, dismiss.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class PositionRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"position.\") ? command.slice(\"position.\".length) : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(renderState(result.state));\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * ProjectRenderer — Markdown rendering for project.* commands.\n *\n * Covers: launch, scope, milestone, achieve, enroll, remove, deliver, wiki, archive.\n * Uses specialized project layout (members, milestones, deliverables, wiki sections).\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { type ProjectAction, renderProjectResult } from \"../project-render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class ProjectRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const action = (\n command.startsWith(\"project.\") ? command.slice(\"project.\".length) : command\n ) as ProjectAction;\n return renderProjectResult(action, result.state);\n }\n}\n","/**\n * RoleRenderer — Markdown rendering for role.* commands.\n *\n * Covers: focus, want, plan, todo, finish, complete, abandon,\n * reflect, realize, master, forget, skill.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class RoleRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"role.\") ? command.slice(\"role.\".length) : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(renderState(result.state));\n\n return lines.join(\"\\n\");\n }\n}\n"],"mappings":";AAYA,cAAc;;;AC2Hd,SAAS,YAAY,WAAW,aAAa;AAxH7C,IAAM,eAAuE;AAAA;AAAA,EAE3E,MAAM,CAAC,MAAM,eAAe,CAAC;AAAA,EAC7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ACzC,SAAK,UAAU;AAAA,EACjB;AAAA,EAEA,aAAa,OAAO,UAAoB,UAAqC;AAC3E,UAAM,IAAI,YAAY,qBAAqB;AAC3C,UAAM,UAAU,MAAM,aAAa,OAAO,UAAU,CAAC;AACrD,WAAO,IAAI,OAAM,OAAO;AAAA,EAC1B;AAAA,EAEA,MAAM,SAAS,YAAmC;AAChD,WAAO,KAAK,QAAQ,SAAS,UAAU;AAAA,EACzC;AAAA,EAEA,MAAM,OACJ,SACA,MACA,SACY;AACZ,WAAO,KAAK,QAAQ,OAAU,SAAS,MAAM,OAAO;AAAA,EACtD;AACF;AAGA,eAAsB,YAAY,UAAoB,UAAqC;AACzF,SAAO,MAAM,OAAO,UAAU,QAAQ;AACxC;","names":["tag"]}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts","../src/render.ts","../src/product-render.ts","../src/project-render.ts","../src/rolex.ts","../src/renderers/index.ts","../src/renderers/census.ts","../src/renderers/individual.ts","../src/renderers/org.ts","../src/renderers/position.ts","../src/renderers/product.ts","../src/renderers/project.ts","../src/renderers/role.ts"],"sourcesContent":["/**\n * rolexjs — RoleX unified entry point.\n *\n * Usage:\n * import { createRoleX, Role } from \"rolexjs\";\n *\n * const rolex = await createRoleX(platform);\n * const role = await rolex.activate(\"sean\");\n * await role.want(\"Feature: Ship v1\", \"ship-v1\");\n */\n\n// Re-export core (structures, processes, Role, types)\nexport * from \"@rolexjs/core\";\n// Product Render\nexport type { ProductAction } from \"./product-render.js\";\nexport { renderProduct, renderProductResult } from \"./product-render.js\";\n// Project Render\nexport type { ProjectAction } from \"./project-render.js\";\nexport { renderProjectResult } from \"./project-render.js\";\n// Render\nexport { detail } from \"./render.js\";\n// API\nexport { createRoleX, RoleX } from \"./rolex.js\";\n","/**\n * Render — 3-layer output for all Rolex operations.\n *\n * Layer 1: Status — what just happened (describe)\n * Layer 2: Hint — what to do next (hint + cognitive hint)\n * Layer 3: Projection — full state tree as markdown (renderState)\n *\n * render() composes the 3 layers. MCP and CLI are pure pass-through.\n */\nimport type { State } from \"@rolexjs/system\";\n\n// ================================================================\n// Description — what happened\n// ================================================================\n\nconst descriptions: Record<string, (name: string, state: State) => string> = {\n // Lifecycle\n born: (n) => `Individual \"${n}\" is born.`,\n found: (n) => `Organization \"${n}\" is founded.`,\n establish: (n) => `Position \"${n}\" is established.`,\n charter: (n) => `Charter defined for \"${n}\".`,\n charge: (n) => `Duty \"${n}\" assigned.`,\n retire: (n) => `\"${n}\" retired.`,\n die: (n) => `\"${n}\" is gone.`,\n dissolve: (n) => `Organization \"${n}\" dissolved.`,\n abolish: (n) => `Position \"${n}\" abolished.`,\n rehire: (n) => `\"${n}\" is back.`,\n\n // Organization\n hire: (n) => `\"${n}\" hired.`,\n fire: (n) => `\"${n}\" fired.`,\n appoint: (n) => `\"${n}\" appointed.`,\n dismiss: (n) => `\"${n}\" dismissed.`,\n\n // Project\n launch: (n) => `Project \"${n}\" launched.`,\n scope: (n) => `Scope defined for \"${n}\".`,\n milestone: (n) => `Milestone \"${n}\" added.`,\n achieve: (n) => `Milestone \"${n}\" achieved.`,\n enroll: (n) => `\"${n}\" enrolled.`,\n remove: (n) => `\"${n}\" removed.`,\n deliver: (n) => `Deliverable \"${n}\" added.`,\n wiki: (n) => `Wiki entry \"${n}\" added.`,\n archive: (n) => `Project \"${n}\" archived.`,\n\n // Product\n create: (n) => `Product \"${n}\" created.`,\n strategy: (n) => `Strategy defined for \"${n}\".`,\n spec: (n) => `Spec \"${n}\" added.`,\n release: (n) => `Release \"${n}\" published.`,\n channel: (n) => `Channel \"${n}\" added.`,\n own: (n) => `Owner assigned to \"${n}\".`,\n disown: (n) => `Owner removed from \"${n}\".`,\n deprecate: (n) => `Product \"${n}\" deprecated.`,\n\n // Role\n activate: (n) => `Role \"${n}\" activated.`,\n focus: (n) => `Focused on goal \"${n}\".`,\n\n // Execution\n want: (n) => `Goal \"${n}\" declared.`,\n plan: (n) => `Plan created for \"${n}\".`,\n todo: (n) => `Task \"${n}\" added.`,\n finish: (n) => `Task \"${n}\" finished → encounter recorded.`,\n complete: (n) => `Plan \"${n}\" completed → encounter recorded.`,\n abandon: (n) => `Plan \"${n}\" abandoned → encounter recorded.`,\n\n // Cognition\n reflect: (n) => `Reflected on \"${n}\" → experience gained.`,\n realize: (n) => `Realized principle from \"${n}\".`,\n master: (n) => `Mastered procedure from \"${n}\".`,\n\n // Knowledge management\n forget: (n) => `\"${n}\" forgotten.`,\n};\n\nexport function describe(process: string, name: string, state: State): string {\n const fn = descriptions[process];\n return fn ? fn(name, state) : `${process} completed.`;\n}\n\n// ================================================================\n// Hint — what to do next\n// ================================================================\n\nconst hints: Record<string, string> = {\n // Lifecycle\n born: \"hire into an organization, or activate to start working.\",\n found: \"define a charter for the organization.\",\n establish: \"charge with duties, then appoint members.\",\n charter: \"establish positions for the organization.\",\n charge: \"appoint someone to this position.\",\n retire: \"rehire if needed later.\",\n die: \"this individual is permanently gone.\",\n dissolve: \"the organization no longer exists.\",\n abolish: \"the position no longer exists.\",\n rehire: \"activate to resume working.\",\n\n // Organization\n hire: \"appoint to a position, or activate to start working.\",\n fire: \"the individual is no longer a member.\",\n appoint: \"the individual now holds this position.\",\n dismiss: \"the position is now vacant.\",\n\n // Project\n launch: \"define scope, add milestones, or enroll members.\",\n scope: \"add milestones to break down the project.\",\n milestone: \"enroll members and start working.\",\n achieve: \"continue with remaining milestones, or archive the project.\",\n enroll: \"assign milestones and start working.\",\n remove: \"the individual is no longer a participant.\",\n deliver: \"deliverable recorded.\",\n wiki: \"knowledge entry recorded.\",\n archive: \"the project is archived.\",\n\n // Product\n create: \"define strategy, add specs, or assign an owner.\",\n strategy: \"add behavior specs (BDD contracts) for the product.\",\n spec: \"add more specs, or publish a release.\",\n release: \"add distribution channels, or continue adding specs.\",\n channel: \"distribution channel recorded.\",\n own: \"the individual is now the product owner.\",\n disown: \"the individual is no longer the product owner.\",\n deprecate: \"the product is deprecated.\",\n\n // Role\n activate: \"want a goal, or check the current state.\",\n focus: \"plan how to work toward it, or add tasks.\",\n\n // Execution\n want: \"plan how to work toward it.\",\n plan: \"add tasks with todo.\",\n todo: \"start working, finish when done.\",\n finish: \"continue with remaining tasks, or complete the plan.\",\n complete: \"reflect on encounters to gain experience.\",\n abandon: \"reflect on encounters to learn from the experience.\",\n\n // Cognition\n reflect: \"realize principles or master procedures from experience.\",\n realize: \"principle added.\",\n master: \"procedure added.\",\n\n // Knowledge management\n forget: \"the node has been removed.\",\n};\n\nexport function hint(process: string): string {\n const h = hints[process];\n return h ? `Next: ${h}` : \"What would you like to do next?\";\n}\n\n// ================================================================\n// Detail — longer process descriptions (from .feature files)\n// ================================================================\n\nimport { directives, processes, world } from \"@rolexjs/core\";\n\n/** Full Gherkin feature content for a process — sourced from .feature files. */\nexport function detail(process: string): string {\n return processes[process] ?? \"\";\n}\n\n/** World feature descriptions — framework-level instructions. */\nexport { world };\n\n// ================================================================\n// Directive — system-level commands at decision points\n// ================================================================\n\n/** Get a directive by topic and scenario. Returns empty string if not found. */\nexport function directive(topic: string, scenario: string): string {\n return directives[topic]?.[scenario] ?? \"\";\n}\n\n// ================================================================\n// Generic State renderer — renders any State tree as markdown\n// ================================================================\n\n/**\n * renderState — markdown renderer for State trees.\n *\n * Rules:\n * - Heading: \"#\" repeated to depth + \" [name]\"\n * - Body: raw information field as-is (full Gherkin preserved)\n * - Links: \"> → relation [target.name]\" with target feature name\n * - Children: sorted by concept hierarchy, then rendered at depth+1\n * - Fold: when fold(node) returns true, render heading only (no body/links/children)\n *\n * Markdown heading depth caps at 6 (######).\n */\nexport interface RenderStateOptions {\n /** When returns true, render only the heading — skip body, links, and children. */\n fold?: (node: State) => boolean;\n}\n\nexport function renderState(state: State, depth = 1, options?: RenderStateOptions): string {\n const lines: string[] = [];\n const level = Math.min(depth, 6);\n const heading = \"#\".repeat(level);\n\n // Heading: [name] (id) {origin} #tag [progress]\n const idPart = state.id ? ` (${state.id})` : \"\";\n const originPart = state.origin ? ` {${state.origin}}` : \"\";\n const tagPart = state.tag ? ` #${state.tag}` : \"\";\n const progressPart = state.name === \"goal\" ? goalProgress(state) : \"\";\n lines.push(`${heading} [${state.name}]${idPart}${originPart}${tagPart}${progressPart}`);\n\n // Folded: heading only\n if (options?.fold?.(state)) {\n return lines.join(\"\\n\");\n }\n\n // Body: full information as-is\n if (state.information) {\n lines.push(\"\");\n lines.push(state.information);\n }\n\n // Links — plan references are compact, organizational links are expanded\n if (state.links && state.links.length > 0) {\n const compactRelations = new Set([\"after\", \"before\", \"fallback\", \"fallback-for\"]);\n const compact = state.links.filter((l) => compactRelations.has(l.relation));\n const expanded = state.links.filter((l) => !compactRelations.has(l.relation));\n for (const link of compact) {\n const targetId = link.target.id ? ` (${link.target.id})` : \"\";\n const targetTag = link.target.tag ? ` #${link.target.tag}` : \"\";\n lines.push(`> ${link.relation}: [${link.target.name}]${targetId}${targetTag}`);\n }\n if (expanded.length > 0) {\n const targets = sortByConceptOrder(expanded.map((l) => l.target));\n for (const target of targets) {\n lines.push(\"\");\n lines.push(renderState(target, depth + 1, options));\n }\n }\n }\n\n // Children — sorted by concept hierarchy, empty nodes filtered out\n if (state.children && state.children.length > 0) {\n const sorted = sortByConceptOrder(state.children.filter((c) => !isEmpty(c)));\n for (const child of sorted) {\n lines.push(\"\");\n lines.push(renderState(child, depth + 1, options));\n }\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Concept ordering — children sorted by structure hierarchy\n// ================================================================\n\n/** Concept tree order: identity → cognition → knowledge → execution → organization. */\nconst CONCEPT_ORDER: readonly string[] = [\n // Individual — Identity\n \"identity\",\n \"background\",\n \"tone\",\n \"mindset\",\n // Individual — Cognition\n \"encounter\",\n \"experience\",\n // Individual — Knowledge\n \"principle\",\n \"procedure\",\n // Individual — Execution\n \"goal\",\n \"plan\",\n \"task\",\n // Organization\n \"charter\",\n // Position\n \"position\",\n \"duty\",\n // Project\n \"scope\",\n \"milestone\",\n \"deliverable\",\n \"wiki\",\n // Product\n \"strategy\",\n \"spec\",\n \"release\",\n \"channel\",\n];\n\n/** Summarize plan/task completion for a goal heading. */\nfunction goalProgress(goal: State): string {\n let plans = 0;\n let plansDone = 0;\n let tasks = 0;\n let tasksDone = 0;\n\n function walk(node: State): void {\n if (node.name === \"plan\") {\n plans++;\n if (node.tag === \"done\" || node.tag === \"abandoned\") plansDone++;\n } else if (node.name === \"task\") {\n tasks++;\n if (node.tag === \"done\") tasksDone++;\n }\n for (const child of node.children ?? []) walk(child);\n }\n\n for (const child of goal.children ?? []) walk(child);\n if (plans === 0 && tasks === 0) return \"\";\n const parts: string[] = [];\n if (plans > 0) parts.push(`${plansDone}/${plans} plans`);\n if (tasks > 0) parts.push(`${tasksDone}/${tasks} tasks`);\n return ` [${parts.join(\", \")}]`;\n}\n\n/** A node is empty when it has no id, no information, and no children. */\nfunction isEmpty(node: State): boolean {\n return !node.id && !node.information && (!node.children || node.children.length === 0);\n}\n\n/** Sort children by concept hierarchy order. Unknown names go to the end, preserving relative order. */\nfunction sortByConceptOrder(children: readonly State[]): readonly State[] {\n return [...children].sort((a, b) => {\n const ai = CONCEPT_ORDER.indexOf(a.name);\n const bi = CONCEPT_ORDER.indexOf(b.name);\n const aOrder = ai >= 0 ? ai : CONCEPT_ORDER.length;\n const bOrder = bi >= 0 ? bi : CONCEPT_ORDER.length;\n return aOrder - bOrder;\n });\n}\n\n// ================================================================\n// Render — 3-layer output for tool results\n// ================================================================\n\nexport interface RenderOptions {\n /** The process that was executed. */\n process: string;\n /** Display name for the primary node. */\n name: string;\n /** State projection of the affected node. */\n state: State;\n /** AI cognitive hint — first-person, state-aware self-direction cue. */\n cognitiveHint?: string | null;\n /** Fold predicate — folded nodes render heading only. */\n fold?: RenderStateOptions[\"fold\"];\n}\n\n/** Render a full 3-layer output string. */\nexport function render(opts: RenderOptions): string {\n const { process, name, state, cognitiveHint, fold } = opts;\n const lines: string[] = [];\n\n // Layer 1: Status\n lines.push(describe(process, name, state));\n\n // Layer 2: Hint (static) + Cognitive hint (state-aware)\n lines.push(hint(process));\n if (cognitiveHint) {\n lines.push(`I → ${cognitiveHint}`);\n }\n\n // Layer 3: Projection — generic markdown rendering of the full state tree\n lines.push(\"\");\n lines.push(renderState(state, 1, fold ? { fold } : undefined));\n\n return lines.join(\"\\n\");\n}\n","/**\n * Product Render — format product state as readable text.\n *\n * Renders product operations into human-readable summaries.\n * Ownership links show owner names only (not full individual trees).\n * Specs show behavior contract titles for quick overview.\n */\nimport type { State } from \"@rolexjs/system\";\nimport { describe, hint } from \"./render.js\";\n\n// ================================================================\n// Types\n// ================================================================\n\nexport type ProductAction =\n | \"create\"\n | \"strategy\"\n | \"spec\"\n | \"release\"\n | \"channel\"\n | \"own\"\n | \"disown\"\n | \"deprecate\";\n\n// ================================================================\n// Product Overview\n// ================================================================\n\nexport function renderProduct(state: State): string {\n const lines: string[] = [];\n const id = state.id ?? \"(no id)\";\n const tag = state.tag ? ` #${state.tag}` : \"\";\n\n // Title\n lines.push(`# ${id}${tag}`);\n\n // Feature body (vision)\n if (state.information) {\n lines.push(\"\");\n lines.push(state.information);\n }\n\n // Owners (ownership links — compact)\n const owners = state.links?.filter((l) => l.relation === \"ownership\") ?? [];\n if (owners.length > 0) {\n lines.push(\"\");\n lines.push(\"## Owner\");\n for (const o of owners) {\n const alias = o.target.alias?.length ? ` (${o.target.alias.join(\", \")})` : \"\";\n lines.push(`- ${o.target.id ?? \"(no id)\"}${alias}`);\n }\n }\n\n // Children by type\n const children = state.children ?? [];\n\n const strategies = children.filter((c) => c.name === \"strategy\");\n const specs = children.filter((c) => c.name === \"spec\");\n const releases = children.filter((c) => c.name === \"release\");\n const channels = children.filter((c) => c.name === \"channel\");\n\n if (strategies.length > 0) {\n lines.push(\"\");\n lines.push(\"## Strategy\");\n for (const s of strategies) {\n if (s.information) lines.push(s.information);\n }\n }\n\n if (specs.length > 0) {\n lines.push(\"\");\n lines.push(\"## Specs\");\n for (const s of specs) {\n const title = s.id ?? extractFeatureTitle(s.information);\n lines.push(`- ${title}`);\n }\n }\n\n if (releases.length > 0) {\n lines.push(\"\");\n lines.push(\"## Releases\");\n for (const r of releases) {\n const tag = r.tag ? ` #${r.tag}` : \"\";\n const title = r.id ?? extractFeatureTitle(r.information);\n lines.push(`- ${title}${tag}`);\n }\n }\n\n if (channels.length > 0) {\n lines.push(\"\");\n lines.push(\"## Channels\");\n for (const c of channels) {\n const title = c.id ?? extractFeatureTitle(c.information);\n lines.push(`- ${title}`);\n }\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Compose — main entry point\n// ================================================================\n\n/**\n * Render a product operation result as readable text.\n * Returns status + hint + product overview.\n */\nexport function renderProductResult(action: ProductAction, state: State): string {\n const name = state.id ?? state.name;\n const lines: string[] = [];\n\n // Layer 1: Status\n lines.push(describe(action, name, state));\n\n // Layer 2: Hint\n lines.push(hint(action));\n\n // Layer 3: Product overview\n const productState = isProductNode(state) ? state : null;\n if (productState) {\n lines.push(\"\");\n lines.push(renderProduct(productState));\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Helpers\n// ================================================================\n\nfunction isProductNode(state: State): boolean {\n return state.name === \"product\";\n}\n\nfunction extractFeatureTitle(information?: string | null): string {\n if (!information) return \"(untitled)\";\n const match = information.match(/^Feature:\\s*(.+)$/m);\n return match?.[1]?.trim() ?? information.split(\"\\n\")[0].trim();\n}\n","/**\n * Project Render — format project state as readable text.\n *\n * Renders project operations into human-readable summaries.\n * Participation links show member names only (not full individual trees).\n * Milestones show progress status (#done or pending).\n */\nimport type { State } from \"@rolexjs/system\";\nimport { describe, hint } from \"./render.js\";\n\n// ================================================================\n// Types\n// ================================================================\n\nexport type ProjectAction =\n | \"launch\"\n | \"scope\"\n | \"milestone\"\n | \"achieve\"\n | \"enroll\"\n | \"remove\"\n | \"deliver\"\n | \"wiki\"\n | \"archive\";\n\n// ================================================================\n// Project Overview\n// ================================================================\n\nexport function renderProject(state: State): string {\n const lines: string[] = [];\n const id = state.id ?? \"(no id)\";\n const tag = state.tag ? ` #${state.tag}` : \"\";\n\n // Title\n lines.push(`# ${id}${tag}`);\n\n // Feature body\n if (state.information) {\n lines.push(\"\");\n lines.push(state.information);\n }\n\n // Members (participation links — compact)\n const members = state.links?.filter((l) => l.relation === \"participation\") ?? [];\n if (members.length > 0) {\n lines.push(\"\");\n lines.push(\"## Members\");\n for (const m of members) {\n const alias = m.target.alias?.length ? ` (${m.target.alias.join(\", \")})` : \"\";\n lines.push(`- ${m.target.id ?? \"(no id)\"}${alias}`);\n }\n }\n\n // Children by type\n const children = state.children ?? [];\n\n const scopes = children.filter((c) => c.name === \"scope\");\n const milestones = children.filter((c) => c.name === \"milestone\");\n const deliverables = children.filter((c) => c.name === \"deliverable\");\n const wikis = children.filter((c) => c.name === \"wiki\");\n\n if (scopes.length > 0) {\n lines.push(\"\");\n lines.push(\"## Scope\");\n for (const s of scopes) {\n if (s.information) lines.push(s.information);\n }\n }\n\n if (milestones.length > 0) {\n lines.push(\"\");\n lines.push(\"## Milestones\");\n for (const m of milestones) {\n const tag = m.tag ? ` #${m.tag}` : \"\";\n const marker = m.tag === \"done\" ? \"[x]\" : \"[ ]\";\n const title = extractFeatureTitle(m.information);\n lines.push(`- ${marker} ${m.id ?? title}${tag}`);\n if (m.information && m.id) {\n const desc = extractFeatureTitle(m.information);\n if (desc && desc !== m.id) lines.push(` ${desc}`);\n }\n }\n }\n\n if (deliverables.length > 0) {\n lines.push(\"\");\n lines.push(\"## Deliverables\");\n for (const d of deliverables) {\n const title = d.id ?? extractFeatureTitle(d.information);\n lines.push(`- ${title}`);\n }\n }\n\n if (wikis.length > 0) {\n lines.push(\"\");\n lines.push(\"## Wiki\");\n for (const w of wikis) {\n const title = w.id ?? extractFeatureTitle(w.information);\n lines.push(`- ${title}`);\n }\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Compose — main entry point\n// ================================================================\n\n/**\n * Render a project operation result as readable text.\n * Returns status + hint + project overview.\n */\nexport function renderProjectResult(action: ProjectAction, state: State): string {\n const name = state.id ?? state.name;\n const lines: string[] = [];\n\n // Layer 1: Status\n lines.push(describe(action, name, state));\n\n // Layer 2: Hint\n lines.push(hint(action));\n\n // Layer 3: Project overview\n // For child operations (scope, milestone, etc.), find the project parent\n const projectState = isProjectNode(state) ? state : null;\n if (projectState) {\n lines.push(\"\");\n lines.push(renderProject(projectState));\n }\n\n return lines.join(\"\\n\");\n}\n\n// ================================================================\n// Helpers\n// ================================================================\n\nfunction isProjectNode(state: State): boolean {\n return state.name === \"project\";\n}\n\nfunction extractFeatureTitle(information?: string | null): string {\n if (!information) return \"(untitled)\";\n const match = information.match(/^Feature:\\s*(.+)$/m);\n return match?.[1]?.trim() ?? information.split(\"\\n\")[0].trim();\n}\n","/**\n * RoleX — thin entry point.\n *\n * Public API:\n * activate(id) — returns a stateful Role handle\n * direct(loc, args) — direct the world to execute an instruction\n *\n * Delegates to RoleXService (core) for all runtime logic.\n * rolexjs adds the concrete renderer and issue rendering transform.\n */\n\nimport {\n type RoleX as IRoleX,\n type Platform,\n type Renderer,\n type Role,\n RoleXService,\n} from \"@rolexjs/core\";\nimport { createRendererRouter } from \"./renderers/index.js\";\n\nexport class RoleX implements IRoleX {\n private service: RoleXService;\n\n private constructor(service: RoleXService) {\n this.service = service;\n }\n\n static async create(platform: Platform, renderer?: Renderer): Promise<RoleX> {\n const r = renderer ?? createRendererRouter();\n const service = await RoleXService.create(platform, r);\n return new RoleX(service);\n }\n\n async activate(individual: string): Promise<Role> {\n return this.service.activate(individual);\n }\n\n async direct<T = unknown>(\n locator: string,\n args?: Record<string, unknown>,\n options?: { raw?: boolean }\n ): Promise<T> {\n return this.service.direct<T>(locator, args, options);\n }\n}\n\n/** Create a RoleX instance from a Platform. */\nexport async function createRoleX(platform: Platform, renderer?: Renderer): Promise<RoleX> {\n return RoleX.create(platform, renderer);\n}\n","/**\n * Renderers — business-domain Markdown renderers for AI readability.\n *\n * Each renderer handles a command namespace and transforms\n * CommandResult into AI-readable Markdown.\n *\n * createRendererRouter() wires all renderers into a RendererRouter.\n */\n\nimport { RendererRouter } from \"@rolexjs/core\";\nimport { CensusRenderer } from \"./census.js\";\nimport { IndividualRenderer } from \"./individual.js\";\nimport { OrgRenderer } from \"./org.js\";\nimport { PositionRenderer } from \"./position.js\";\nimport { ProductRenderer } from \"./product.js\";\nimport { ProjectRenderer } from \"./project.js\";\nimport { RoleRenderer } from \"./role.js\";\n\nexport { CensusRenderer } from \"./census.js\";\nexport { IndividualRenderer } from \"./individual.js\";\nexport { OrgRenderer } from \"./org.js\";\nexport { PositionRenderer } from \"./position.js\";\nexport { ProductRenderer } from \"./product.js\";\nexport { ProjectRenderer } from \"./project.js\";\nexport type { Renderer } from \"./renderer.js\";\nexport { RoleRenderer } from \"./role.js\";\n\n/** Create a RendererRouter with all business renderers registered. */\nexport function createRendererRouter(): RendererRouter {\n return new RendererRouter()\n .register(\"role\", new RoleRenderer())\n .register(\"individual\", new IndividualRenderer())\n .register(\"org\", new OrgRenderer())\n .register(\"position\", new PositionRenderer())\n .register(\"product\", new ProductRenderer())\n .register(\"project\", new ProjectRenderer())\n .register(\"census\", new CensusRenderer());\n}\n","/**\n * CensusRenderer — Markdown rendering for census.* commands.\n *\n * Renders the organization-centric tree view:\n * orgs → projects + members (with positions) → unaffiliated individuals.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport type { State } from \"@rolexjs/system\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class CensusRenderer implements Renderer {\n render(_command: string, result: CommandResult): string {\n const children = result.state.children ?? [];\n\n if (children.length === 0) {\n return \"Society is empty.\";\n }\n\n // Check if all children are the same type (filtered by type)\n const types = new Set(children.map((c) => c.name));\n if (types.size === 1 && !types.has(\"organization\")) {\n return this.renderFlat(children);\n }\n\n return this.renderTree(children);\n }\n\n private renderFlat(items: readonly State[]): string {\n const lines: string[] = [];\n for (const item of items) {\n const tag = item.tag ? ` #${item.tag}` : \"\";\n const alias = item.alias?.length ? ` (${item.alias.join(\", \")})` : \"\";\n lines.push(`${item.id ?? \"(no id)\"}${alias}${tag}`);\n }\n return lines.join(\"\\n\");\n }\n\n private renderTree(children: readonly State[]): string {\n const orgs = children.filter((c) => c.name === \"organization\");\n const individuals = children.filter((c) => c.name === \"individual\");\n\n // Build a map: individual id → positions they serve\n const individualPositions = new Map<string, string[]>();\n for (const ind of individuals) {\n const serves = ind.links?.filter((l) => l.relation === \"serve\") ?? [];\n if (serves.length > 0) {\n individualPositions.set(\n ind.id ?? \"\",\n serves.map((l) => l.target.id ?? \"(no id)\")\n );\n }\n }\n\n const affiliatedIndividuals = new Set<string>();\n const lines: string[] = [];\n\n for (const org of orgs) {\n const alias = org.alias?.length ? ` (${org.alias.join(\", \")})` : \"\";\n const tag = org.tag ? ` #${org.tag}` : \"\";\n lines.push(`${org.id}${alias}${tag}`);\n\n // Projects owned by this org\n const projects = org.links?.filter((l) => l.relation === \"project\") ?? [];\n for (const p of projects) {\n const pAlias = p.target.alias?.length ? ` (${p.target.alias.join(\", \")})` : \"\";\n const pTag = p.target.tag ? ` #${p.target.tag}` : \"\";\n lines.push(` 📦 ${p.target.id ?? \"(no id)\"}${pAlias}${pTag}`);\n }\n\n // Members of this org\n const members = org.links?.filter((l) => l.relation === \"membership\") ?? [];\n if (members.length === 0 && projects.length === 0) {\n lines.push(\" (empty)\");\n }\n for (const m of members) {\n affiliatedIndividuals.add(m.target.id ?? \"\");\n const mAlias = m.target.alias?.length ? ` (${m.target.alias.join(\", \")})` : \"\";\n const mTag = m.target.tag ? ` #${m.target.tag}` : \"\";\n const posLabels = individualPositions.get(m.target.id ?? \"\");\n const posStr = posLabels?.length ? ` — ${posLabels.join(\", \")}` : \"\";\n lines.push(` ${m.target.id}${mAlias}${mTag}${posStr}`);\n }\n lines.push(\"\");\n }\n\n // Unaffiliated individuals\n const unaffiliated = individuals.filter((ind) => !affiliatedIndividuals.has(ind.id ?? \"\"));\n if (unaffiliated.length > 0) {\n lines.push(\"─── unaffiliated ───\");\n for (const ind of unaffiliated) {\n const alias = ind.alias?.length ? ` (${ind.alias.join(\", \")})` : \"\";\n const tag = ind.tag ? ` #${ind.tag}` : \"\";\n const posLabels = individualPositions.get(ind.id ?? \"\");\n const posStr = posLabels?.length ? ` — ${posLabels.join(\", \")}` : \"\";\n lines.push(` ${ind.id}${alias}${tag}${posStr}`);\n }\n }\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * IndividualRenderer — Markdown rendering for individual.* commands.\n *\n * Covers: born, retire, die, rehire, teach, train.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class IndividualRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"individual.\")\n ? command.slice(\"individual.\".length)\n : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(renderState(result.state));\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * OrgRenderer — Markdown rendering for org.* commands.\n *\n * Covers: found, charter, dissolve, hire, fire.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class OrgRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"org.\") ? command.slice(\"org.\".length) : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(renderState(result.state));\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * PositionRenderer — Markdown rendering for position.* commands.\n *\n * Covers: establish, charge, require, abolish, appoint, dismiss.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class PositionRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"position.\") ? command.slice(\"position.\".length) : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(renderState(result.state));\n\n return lines.join(\"\\n\");\n }\n}\n","/**\n * ProductRenderer — Markdown rendering for product.* commands.\n *\n * Covers: create, strategy, spec, release, channel, own, disown, deprecate.\n * Uses specialized product layout (owner, strategy, specs, releases, channels).\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { type ProductAction, renderProductResult } from \"../product-render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class ProductRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const action = (\n command.startsWith(\"product.\") ? command.slice(\"product.\".length) : command\n ) as ProductAction;\n return renderProductResult(action, result.state);\n }\n}\n","/**\n * ProjectRenderer — Markdown rendering for project.* commands.\n *\n * Covers: launch, scope, milestone, achieve, enroll, remove, deliver, wiki, archive.\n * Uses specialized project layout (members, milestones, deliverables, wiki sections).\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { type ProjectAction, renderProjectResult } from \"../project-render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class ProjectRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const action = (\n command.startsWith(\"project.\") ? command.slice(\"project.\".length) : command\n ) as ProjectAction;\n return renderProjectResult(action, result.state);\n }\n}\n","/**\n * RoleRenderer — Markdown rendering for role.* commands.\n *\n * Covers: focus, want, plan, todo, finish, complete, abandon,\n * reflect, realize, master, forget, skill.\n */\n\nimport type { CommandResult } from \"@rolexjs/core\";\nimport { describe, hint, renderState } from \"../render.js\";\nimport type { Renderer } from \"./renderer.js\";\n\nexport class RoleRenderer implements Renderer {\n render(command: string, result: CommandResult): string {\n const process = command.startsWith(\"role.\") ? command.slice(\"role.\".length) : command;\n const name = result.state.id ?? result.state.name;\n const lines: string[] = [];\n\n lines.push(describe(process, name, result.state));\n lines.push(hint(process));\n lines.push(\"\");\n lines.push(render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AAM,OACJ,SACA,MACA,SACY;AACZ,WAAO,KAAK,QAAQ,OAAU,SAAS,MAAM,OAAO;AAAA,EACtD;AACF;AAGA,eAAsB,YAAY,UAAoB,UAAqC;AACzF,SAAO,MAAM,OAAO,UAAU,QAAQ;AACxC;","names":["tag","tag","extractFeatureTitle"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rolexjs",
|
|
3
|
-
"version": "1.4.0
|
|
3
|
+
"version": "1.4.0",
|
|
4
4
|
"description": "RoleX - AI Agent Role Management Framework",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"rolex",
|
|
@@ -38,15 +38,15 @@
|
|
|
38
38
|
"clean": "rm -rf dist"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@rolexjs/core": "1.4.0
|
|
42
|
-
"@rolexjs/genesis": "1.4.0
|
|
43
|
-
"@rolexjs/system": "1.4.0
|
|
44
|
-
"@rolexjs/parser": "1.4.0
|
|
41
|
+
"@rolexjs/core": "^1.4.0",
|
|
42
|
+
"@rolexjs/genesis": "^1.4.0",
|
|
43
|
+
"@rolexjs/system": "^1.4.0",
|
|
44
|
+
"@rolexjs/parser": "^1.4.0",
|
|
45
45
|
"issuexjs": "^0.2.0",
|
|
46
46
|
"resourcexjs": "^2.14.0"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
|
-
"@rolexjs/local-platform": "1.4.0
|
|
49
|
+
"@rolexjs/local-platform": "^1.4.0"
|
|
50
50
|
},
|
|
51
51
|
"publishConfig": {
|
|
52
52
|
"access": "public"
|