@christianmaf80/agentic-workflow 1.7.0-beta.1 → 1.8.0-beta.1
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/cli/commands/init.js +1 -0
- package/dist/core/context/manager.js +0 -33
- package/dist/workflows/init.md +11 -10
- package/package.json +1 -1
|
@@ -72,6 +72,7 @@ Global entry point for the agentic system. It uses absolute references to the co
|
|
|
72
72
|
agent:
|
|
73
73
|
core:
|
|
74
74
|
root: "${corePath}"
|
|
75
|
+
bootstrap: "${path.join(corePath, 'bootstrap.md')}"
|
|
75
76
|
artifacts: "${path.join(corePath, 'artifacts/index.md')}"
|
|
76
77
|
rules: "${path.join(corePath, 'rules/index.md')}"
|
|
77
78
|
workflows: "${path.join(corePath, 'workflows/index.md')}"
|
|
@@ -41,39 +41,6 @@ export class ContextManager {
|
|
|
41
41
|
}
|
|
42
42
|
return files;
|
|
43
43
|
}
|
|
44
|
-
/**
|
|
45
|
-
* Crea un bundle de inicialización (Bootstrap) siguiendo las Best Practices.
|
|
46
|
-
*/
|
|
47
|
-
async bootstrapContext() {
|
|
48
|
-
const files = [];
|
|
49
|
-
// 1. Índice Maestro Local
|
|
50
|
-
const localIndex = path.join(this.projectRoot, '.agent/index.md');
|
|
51
|
-
files.push(await this.readFile(localIndex, 'agent.index'));
|
|
52
|
-
// 2. Local Domain Indexes (client-defined)
|
|
53
|
-
const localRulesIndex = path.join(this.projectRoot, '.agent/rules/index.md');
|
|
54
|
-
const localRolesIndex = path.join(this.projectRoot, '.agent/rules/roles/index.md');
|
|
55
|
-
const localWorkflowsIndex = path.join(this.projectRoot, '.agent/workflows/index.md');
|
|
56
|
-
const localArtifactsIndex = path.join(this.projectRoot, '.agent/artifacts/index.md');
|
|
57
|
-
const localTemplatesIndex = path.join(this.projectRoot, '.agent/templates/index.md');
|
|
58
|
-
if (await this.exists(localRulesIndex))
|
|
59
|
-
files.push(await this.readFile(localRulesIndex, 'agent.local.rules'));
|
|
60
|
-
if (await this.exists(localRolesIndex))
|
|
61
|
-
files.push(await this.readFile(localRolesIndex, 'agent.local.roles'));
|
|
62
|
-
if (await this.exists(localWorkflowsIndex))
|
|
63
|
-
files.push(await this.readFile(localWorkflowsIndex, 'agent.local.workflows'));
|
|
64
|
-
if (await this.exists(localArtifactsIndex))
|
|
65
|
-
files.push(await this.readFile(localArtifactsIndex, 'agent.local.artifacts'));
|
|
66
|
-
if (await this.exists(localTemplatesIndex))
|
|
67
|
-
files.push(await this.readFile(localTemplatesIndex, 'agent.local.templates'));
|
|
68
|
-
const localBundle = this.formatBundle(files, true);
|
|
69
|
-
// Use prebuilt core bootstrap bundle only (no dynamic fallback).
|
|
70
|
-
const coreBootstrapPath = path.join(this.corePath, 'bootstrap.md');
|
|
71
|
-
if (!(await this.exists(coreBootstrapPath))) {
|
|
72
|
-
throw new Error('No se encontró bootstrap.md en el core. Ejecuta el build para generarlo.');
|
|
73
|
-
}
|
|
74
|
-
const coreBundle = await fs.readFile(coreBootstrapPath, 'utf-8');
|
|
75
|
-
return `${localBundle}\n\n---\n\n${coreBundle}`.trim();
|
|
76
|
-
}
|
|
77
44
|
async readFile(filePath, alias) {
|
|
78
45
|
const content = await fs.readFile(filePath, 'utf-8');
|
|
79
46
|
return { path: filePath, content, alias };
|
package/dist/workflows/init.md
CHANGED
|
@@ -19,24 +19,25 @@ blocking: true
|
|
|
19
19
|
|
|
20
20
|
## Objective (ONLY)
|
|
21
21
|
- Activate the **architect-agent** role.
|
|
22
|
-
- Load the prebuilt bootstrap bundle
|
|
23
|
-
- Capture developer language, name, strategy, and first task description.
|
|
22
|
+
- Load the prebuilt bootstrap bundle directly from the core path (no index traversal).
|
|
23
|
+
- Capture developer language, name, strategy, and first task description (one question at a time).
|
|
24
24
|
- Create the **task candidate** artifact `init.md`.
|
|
25
25
|
|
|
26
26
|
## Mandatory Steps
|
|
27
|
-
1.
|
|
28
|
-
2. Save the bundle
|
|
29
|
-
3. Ask the developer
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
27
|
+
1. Load the prebuilt bootstrap bundle from the core path: `${agent.core.root}/bootstrap.md`.
|
|
28
|
+
2. Save the bundle content to `.agent/artifacts/candidate/bootstrap.md`.
|
|
29
|
+
3. Ask the developer the **Gate questions** in order (one by one, do not continue until answered):
|
|
30
|
+
- Language confirmation (**YES**).
|
|
31
|
+
- Developer name (preferred form of address).
|
|
32
|
+
- Task strategy: **short (fast)** or **long**.
|
|
33
|
+
- Task description (1-3 sentences).
|
|
33
34
|
7. Create the `init.md` artifact using `templates.init`.
|
|
34
35
|
8. Evaluate Gate.
|
|
35
36
|
- The developer **MUST** explicitly confirm with a **YES**.
|
|
36
37
|
|
|
37
38
|
## Output (REQUIRED)
|
|
38
39
|
- Created artifact: `artifacts.candidate.init` (from `templates.init`).
|
|
39
|
-
- Created artifact: `artifacts.candidate.bootstrap` (bundle from `
|
|
40
|
+
- Created artifact: `artifacts.candidate.bootstrap` (bundle from `${agent.core.root}/bootstrap.md`).
|
|
40
41
|
|
|
41
42
|
## Pass
|
|
42
43
|
- `init.md` is created from `templates.init`.
|
|
@@ -50,7 +51,7 @@ Requirements (all mandatory):
|
|
|
50
51
|
3. In `init.md` YAML:
|
|
51
52
|
- `language.confirmed == true`
|
|
52
53
|
- `developer.name` is defined
|
|
53
|
-
- `strategy` is defined
|
|
54
|
+
- `strategy` is defined (short/fast or long)
|
|
54
55
|
- `task.description` is defined
|
|
55
56
|
4. The developer has explicitly approved with **YES**.
|
|
56
57
|
|
package/package.json
CHANGED