@projitive/mcp 1.0.1 → 1.0.3
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/README.md +44 -20
- package/output/helpers/artifacts/artifacts.js +10 -0
- package/output/helpers/artifacts/artifacts.test.js +18 -0
- package/output/helpers/artifacts/index.js +1 -0
- package/output/helpers/index.js +3 -0
- package/output/helpers/linter/codes.js +25 -0
- package/output/helpers/linter/index.js +2 -0
- package/output/helpers/linter/linter.js +6 -0
- package/output/helpers/linter/linter.test.js +16 -0
- package/output/helpers/response/index.js +1 -0
- package/output/helpers/response/response.js +73 -0
- package/output/helpers/response/response.test.js +50 -0
- package/output/hooks.js +1 -14
- package/output/hooks.test.js +7 -18
- package/output/index.js +23 -5
- package/output/package.json +36 -0
- package/output/projitive.js +158 -124
- package/output/projitive.test.js +1 -0
- package/output/rendering-input-guard.test.js +20 -0
- package/output/roadmap.js +106 -80
- package/output/roadmap.test.js +11 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/projectContext.md +48 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/projectInit.md +40 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/projectLocate.md +22 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/projectNext.md +31 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/projectScan.md +28 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/roadmapContext.md +33 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/roadmapList.md +25 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/summary.json +90 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/summary.md +17 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/taskContext.md +47 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/taskList.md +27 -0
- package/output/smoke-reports/2026-02-18T13-18-19-740Z/taskNext.md +64 -0
- package/output/source/designs.js +38 -0
- package/output/source/helpers/artifacts/artifacts.js +10 -0
- package/output/source/helpers/artifacts/artifacts.test.js +18 -0
- package/output/source/helpers/artifacts/index.js +1 -0
- package/output/source/helpers/catch/catch.js +48 -0
- package/output/source/helpers/catch/catch.test.js +43 -0
- package/output/source/helpers/catch/index.js +1 -0
- package/output/source/helpers/files/files.js +62 -0
- package/output/source/helpers/files/files.test.js +32 -0
- package/output/source/helpers/files/index.js +1 -0
- package/output/source/helpers/index.js +6 -0
- package/output/source/helpers/linter/codes.js +25 -0
- package/output/source/helpers/linter/index.js +2 -0
- package/output/source/helpers/linter/linter.js +6 -0
- package/output/source/helpers/linter/linter.test.js +16 -0
- package/output/source/helpers/markdown/index.js +1 -0
- package/output/source/helpers/markdown/markdown.js +33 -0
- package/output/source/helpers/markdown/markdown.test.js +36 -0
- package/output/source/helpers/response/index.js +1 -0
- package/output/source/helpers/response/response.js +73 -0
- package/output/source/helpers/response/response.test.js +50 -0
- package/output/source/index.js +215 -0
- package/output/source/projitive.js +488 -0
- package/output/source/projitive.test.js +75 -0
- package/output/source/readme.js +26 -0
- package/output/source/reports.js +36 -0
- package/output/source/roadmap.js +165 -0
- package/output/source/roadmap.test.js +11 -0
- package/output/source/tasks.js +762 -0
- package/output/source/tasks.test.js +152 -0
- package/output/tasks.js +403 -204
- package/output/tasks.test.js +78 -4
- package/package.json +1 -1
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# projectContext
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"projectPath":"/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive"}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# projectContext
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- governanceDir: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
12
|
+
- tasksFile: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md
|
|
13
|
+
- roadmapIds: 1
|
|
14
|
+
|
|
15
|
+
## Evidence
|
|
16
|
+
### Task Summary
|
|
17
|
+
- total: 1
|
|
18
|
+
- TODO: 1
|
|
19
|
+
- IN_PROGRESS: 0
|
|
20
|
+
- BLOCKED: 0
|
|
21
|
+
- DONE: 0
|
|
22
|
+
|
|
23
|
+
### Artifacts
|
|
24
|
+
- ✅ README.md
|
|
25
|
+
path: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/README.md
|
|
26
|
+
lineCount: 8
|
|
27
|
+
- ✅ roadmap.md
|
|
28
|
+
path: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/roadmap.md
|
|
29
|
+
lineCount: 4
|
|
30
|
+
- ✅ tasks.md
|
|
31
|
+
path: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md
|
|
32
|
+
lineCount: 11
|
|
33
|
+
- ✅ designs/
|
|
34
|
+
path: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/designs
|
|
35
|
+
- ✅ reports/
|
|
36
|
+
path: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/reports
|
|
37
|
+
- ✅ hooks/
|
|
38
|
+
path: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/hooks
|
|
39
|
+
|
|
40
|
+
## Agent Guidance
|
|
41
|
+
- Start from `taskList` to choose a target task.
|
|
42
|
+
- Then call `taskContext` with a task ID to retrieve evidence locations and reading order.
|
|
43
|
+
|
|
44
|
+
## Lint Suggestions
|
|
45
|
+
- (none)
|
|
46
|
+
|
|
47
|
+
## Next Call
|
|
48
|
+
- taskList(projectPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive")
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# projectInit
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"rootPath":"/Users/yinxulai/Documents/Github/projitive-mcp-smoke","governanceDir":".projitive","force":true}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# projectInit
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- rootPath: /Users/yinxulai/Documents/Github/projitive-mcp-smoke
|
|
12
|
+
- governanceDir: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
13
|
+
- markerPath: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/.projitive
|
|
14
|
+
- force: true
|
|
15
|
+
|
|
16
|
+
## Evidence
|
|
17
|
+
- createdFiles: 4
|
|
18
|
+
- updatedFiles: 0
|
|
19
|
+
- skippedFiles: 0
|
|
20
|
+
- directories:
|
|
21
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
22
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/designs
|
|
23
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/reports
|
|
24
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/hooks
|
|
25
|
+
- files:
|
|
26
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/.projitive
|
|
27
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/README.md
|
|
28
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/roadmap.md
|
|
29
|
+
- created: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md
|
|
30
|
+
|
|
31
|
+
## Agent Guidance
|
|
32
|
+
- If files were skipped and you want to overwrite templates, rerun with force=true.
|
|
33
|
+
- Continue with projectContext and taskList for execution.
|
|
34
|
+
|
|
35
|
+
## Lint Suggestions
|
|
36
|
+
- After init, fill owner/roadmapRefs/links in tasks.md before marking DONE.
|
|
37
|
+
- Keep task source-of-truth inside marker block only.
|
|
38
|
+
|
|
39
|
+
## Next Call
|
|
40
|
+
- projectContext(projectPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive")
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# projectLocate
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"inputPath":"/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/designs"}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# projectLocate
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- resolvedFrom: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/designs
|
|
12
|
+
- governanceDir: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
13
|
+
- markerPath: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/.projitive
|
|
14
|
+
|
|
15
|
+
## Agent Guidance
|
|
16
|
+
- Call `projectContext` with this governanceDir to get task and roadmap summaries.
|
|
17
|
+
|
|
18
|
+
## Lint Suggestions
|
|
19
|
+
- Run `projectContext` to get governance/module lint suggestions for this project.
|
|
20
|
+
|
|
21
|
+
## Next Call
|
|
22
|
+
- projectContext(projectPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive")
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# projectNext
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"rootPath":"/Users/yinxulai/Documents/Github","maxDepth":2,"limit":5}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# projectNext
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- rootPath: /Users/yinxulai/Documents/Github
|
|
12
|
+
- maxDepth: 2
|
|
13
|
+
- matchedProjects: 2
|
|
14
|
+
- actionableProjects: 2
|
|
15
|
+
- limit: 5
|
|
16
|
+
|
|
17
|
+
## Evidence
|
|
18
|
+
- rankedProjects:
|
|
19
|
+
1. /Users/yinxulai/Documents/Github/projitive/.projitive | actionable=3 | in_progress=1 | todo=2 | blocked=0 | done=0 | latest=2026-02-17T23:50:00.000Z | tasksPath=/Users/yinxulai/Documents/Github/projitive/.projitive/tasks.md
|
|
20
|
+
2. /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive | actionable=1 | in_progress=0 | todo=1 | blocked=0 | done=0 | latest=2026-02-18T13:18:19.890Z | tasksPath=/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md
|
|
21
|
+
|
|
22
|
+
## Agent Guidance
|
|
23
|
+
- Pick top 1 project and call `projectContext` with its governanceDir.
|
|
24
|
+
- Then call `taskList` and `taskContext` to continue execution.
|
|
25
|
+
- If `tasksPath` is missing, create tasks.md using project convention before task-level operations.
|
|
26
|
+
|
|
27
|
+
## Lint Suggestions
|
|
28
|
+
- (none)
|
|
29
|
+
|
|
30
|
+
## Next Call
|
|
31
|
+
- projectContext(projectPath="/Users/yinxulai/Documents/Github/projitive/.projitive")
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# projectScan
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"rootPath":"/Users/yinxulai/Documents/Github","maxDepth":2}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# projectScan
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- rootPath: /Users/yinxulai/Documents/Github
|
|
12
|
+
- maxDepth: 2
|
|
13
|
+
- discoveredCount: 2
|
|
14
|
+
|
|
15
|
+
## Evidence
|
|
16
|
+
- projects:
|
|
17
|
+
1. /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
18
|
+
2. /Users/yinxulai/Documents/Github/projitive/.projitive
|
|
19
|
+
|
|
20
|
+
## Agent Guidance
|
|
21
|
+
- Use one discovered project path and call `projectLocate` to lock governance root.
|
|
22
|
+
- Then call `projectContext` to inspect current governance state.
|
|
23
|
+
|
|
24
|
+
## Lint Suggestions
|
|
25
|
+
- Run `projectContext` on a discovered project to receive module-level lint suggestions.
|
|
26
|
+
|
|
27
|
+
## Next Call
|
|
28
|
+
- projectLocate(inputPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive")
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# roadmapContext
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"projectPath":"/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive","roadmapId":"ROADMAP-0001"}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# roadmapContext
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- governanceDir: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
12
|
+
- roadmapId: ROADMAP-0001
|
|
13
|
+
- relatedTasks: 1
|
|
14
|
+
- references: 2
|
|
15
|
+
|
|
16
|
+
## Evidence
|
|
17
|
+
### Related Tasks
|
|
18
|
+
- TASK-0001 | TODO | Bootstrap governance workspace
|
|
19
|
+
|
|
20
|
+
### Reference Locations
|
|
21
|
+
- /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/roadmap.md#L4: - [ ] ROADMAP-0001: Bootstrap governance baseline (time: 2026-Q1)
|
|
22
|
+
- /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md#L9: - roadmapRefs: ROADMAP-0001
|
|
23
|
+
|
|
24
|
+
## Agent Guidance
|
|
25
|
+
- Read roadmap references first, then related tasks.
|
|
26
|
+
- Keep ROADMAP/TASK IDs unchanged while updating markdown files.
|
|
27
|
+
- Re-run `roadmapContext` after edits to confirm references remain consistent.
|
|
28
|
+
|
|
29
|
+
## Lint Suggestions
|
|
30
|
+
- (none)
|
|
31
|
+
|
|
32
|
+
## Next Call
|
|
33
|
+
- roadmapContext(projectPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive", roadmapId="ROADMAP-0001")
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# roadmapList
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"projectPath":"/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive","limit":5}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# roadmapList
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- governanceDir: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
12
|
+
- roadmapCount: 1
|
|
13
|
+
|
|
14
|
+
## Evidence
|
|
15
|
+
- roadmaps:
|
|
16
|
+
- ROADMAP-0001 | linkedTasks=1
|
|
17
|
+
|
|
18
|
+
## Agent Guidance
|
|
19
|
+
- Pick one roadmap ID and call `roadmapContext`.
|
|
20
|
+
|
|
21
|
+
## Lint Suggestions
|
|
22
|
+
- (none)
|
|
23
|
+
|
|
24
|
+
## Next Call
|
|
25
|
+
- roadmapContext(projectPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive", roadmapId="ROADMAP-0001")
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
{
|
|
2
|
+
"root": "/Users/yinxulai/Documents/Github",
|
|
3
|
+
"workspace": "/Users/yinxulai/Documents/Github/projitive",
|
|
4
|
+
"sandbox": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke",
|
|
5
|
+
"reportDir": "/Users/yinxulai/Documents/Github/projitive/packages/mcp/output/smoke-reports/2026-02-18T13-18-19-740Z",
|
|
6
|
+
"generatedAt": "2026-02-18T13:18:20.412Z",
|
|
7
|
+
"results": [
|
|
8
|
+
{
|
|
9
|
+
"methodName": "projectInit",
|
|
10
|
+
"passed": true,
|
|
11
|
+
"args": {
|
|
12
|
+
"rootPath": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke",
|
|
13
|
+
"governanceDir": ".projitive",
|
|
14
|
+
"force": true
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"methodName": "projectScan",
|
|
19
|
+
"passed": true,
|
|
20
|
+
"args": {
|
|
21
|
+
"rootPath": "/Users/yinxulai/Documents/Github",
|
|
22
|
+
"maxDepth": 2
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
"methodName": "projectNext",
|
|
27
|
+
"passed": true,
|
|
28
|
+
"args": {
|
|
29
|
+
"rootPath": "/Users/yinxulai/Documents/Github",
|
|
30
|
+
"maxDepth": 2,
|
|
31
|
+
"limit": 5
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"methodName": "projectLocate",
|
|
36
|
+
"passed": true,
|
|
37
|
+
"args": {
|
|
38
|
+
"inputPath": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/designs"
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
"methodName": "projectContext",
|
|
43
|
+
"passed": true,
|
|
44
|
+
"args": {
|
|
45
|
+
"projectPath": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive"
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"methodName": "taskList",
|
|
50
|
+
"passed": true,
|
|
51
|
+
"args": {
|
|
52
|
+
"projectPath": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive",
|
|
53
|
+
"limit": 5
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"methodName": "taskNext",
|
|
58
|
+
"passed": true,
|
|
59
|
+
"args": {
|
|
60
|
+
"rootPath": "/Users/yinxulai/Documents/Github",
|
|
61
|
+
"maxDepth": 2,
|
|
62
|
+
"topCandidates": 5
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"methodName": "taskContext",
|
|
67
|
+
"passed": true,
|
|
68
|
+
"args": {
|
|
69
|
+
"projectPath": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive",
|
|
70
|
+
"taskId": "TASK-0001"
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"methodName": "roadmapList",
|
|
75
|
+
"passed": true,
|
|
76
|
+
"args": {
|
|
77
|
+
"projectPath": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive",
|
|
78
|
+
"limit": 5
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"methodName": "roadmapContext",
|
|
83
|
+
"passed": true,
|
|
84
|
+
"args": {
|
|
85
|
+
"projectPath": "/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive",
|
|
86
|
+
"roadmapId": "ROADMAP-0001"
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
]
|
|
90
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# MCP Smoke Summary
|
|
2
|
+
|
|
3
|
+
- root: /Users/yinxulai/Documents/Github
|
|
4
|
+
- workspace: /Users/yinxulai/Documents/Github/projitive
|
|
5
|
+
- sandbox: /Users/yinxulai/Documents/Github/projitive-mcp-smoke
|
|
6
|
+
|
|
7
|
+
## Results
|
|
8
|
+
- PASS | projectInit
|
|
9
|
+
- PASS | projectScan
|
|
10
|
+
- PASS | projectNext
|
|
11
|
+
- PASS | projectLocate
|
|
12
|
+
- PASS | projectContext
|
|
13
|
+
- PASS | taskList
|
|
14
|
+
- PASS | taskNext
|
|
15
|
+
- PASS | taskContext
|
|
16
|
+
- PASS | roadmapList
|
|
17
|
+
- PASS | roadmapContext
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# taskContext
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"projectPath":"/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive","taskId":"TASK-0001"}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# taskContext
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- governanceDir: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
12
|
+
- taskId: TASK-0001
|
|
13
|
+
- title: Bootstrap governance workspace
|
|
14
|
+
- status: TODO
|
|
15
|
+
- owner: unassigned
|
|
16
|
+
- updatedAt: 2026-02-18T13:18:19.890Z
|
|
17
|
+
- roadmapRefs: ROADMAP-0001
|
|
18
|
+
- taskLocation: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md#L4
|
|
19
|
+
- hookStatus: head=missing, footer=missing
|
|
20
|
+
|
|
21
|
+
## Evidence
|
|
22
|
+
### Related Artifacts
|
|
23
|
+
- /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md
|
|
24
|
+
|
|
25
|
+
### Reference Locations
|
|
26
|
+
- /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md#L4: ## TASK-0001 | TODO | Bootstrap governance workspace
|
|
27
|
+
|
|
28
|
+
### Hook Paths
|
|
29
|
+
- (none)
|
|
30
|
+
|
|
31
|
+
### Suggested Read Order
|
|
32
|
+
1. /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md
|
|
33
|
+
|
|
34
|
+
## Agent Guidance
|
|
35
|
+
- Read the files in Suggested Read Order.
|
|
36
|
+
- Verify whether current status and evidence are consistent.
|
|
37
|
+
- This task is TODO: confirm scope and set execution plan before edits.
|
|
38
|
+
- Move to IN_PROGRESS only after owner and initial evidence are ready.
|
|
39
|
+
- If updates are needed, edit tasks/designs/reports markdown directly and keep TASK IDs unchanged.
|
|
40
|
+
- After editing, re-run `taskContext` to verify references and context consistency.
|
|
41
|
+
|
|
42
|
+
## Lint Suggestions
|
|
43
|
+
- [TASK_CONTEXT_HOOK_HEAD_MISSING] Missing /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/hooks/task_get_head.md. Add a task context head hook template if you need standardized preface.
|
|
44
|
+
- [TASK_CONTEXT_HOOK_FOOTER_MISSING] Missing /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/hooks/task_get_footer.md. Add a task context footer hook template for standardized close-out checks.
|
|
45
|
+
|
|
46
|
+
## Next Call
|
|
47
|
+
- taskContext(projectPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive", taskId="TASK-0001")
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# taskList
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"projectPath":"/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive","limit":5}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# taskList
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- governanceDir: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive
|
|
12
|
+
- tasksPath: /Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive/tasks.md
|
|
13
|
+
- filter.status: (none)
|
|
14
|
+
- returned: 1
|
|
15
|
+
|
|
16
|
+
## Evidence
|
|
17
|
+
- tasks:
|
|
18
|
+
- TASK-0001 | TODO | Bootstrap governance workspace | owner=unassigned | updatedAt=2026-02-18T13:18:19.890Z
|
|
19
|
+
|
|
20
|
+
## Agent Guidance
|
|
21
|
+
- Pick one task ID and call `taskContext`.
|
|
22
|
+
|
|
23
|
+
## Lint Suggestions
|
|
24
|
+
- (none)
|
|
25
|
+
|
|
26
|
+
## Next Call
|
|
27
|
+
- taskContext(projectPath="/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive", taskId="TASK-0001")
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# taskNext
|
|
2
|
+
|
|
3
|
+
- passed: true
|
|
4
|
+
- args: {"rootPath":"/Users/yinxulai/Documents/Github","maxDepth":2,"topCandidates":5}
|
|
5
|
+
|
|
6
|
+
## Output
|
|
7
|
+
|
|
8
|
+
# taskNext
|
|
9
|
+
|
|
10
|
+
## Summary
|
|
11
|
+
- rootPath: /Users/yinxulai/Documents/Github
|
|
12
|
+
- maxDepth: 2
|
|
13
|
+
- matchedProjects: 2
|
|
14
|
+
- actionableTasks: 4
|
|
15
|
+
- selectedProject: /Users/yinxulai/Documents/Github/projitive/.projitive
|
|
16
|
+
- selectedTaskId: TASK-0001
|
|
17
|
+
- selectedTaskStatus: IN_PROGRESS
|
|
18
|
+
|
|
19
|
+
## Evidence
|
|
20
|
+
### Selected Task
|
|
21
|
+
- id: TASK-0001
|
|
22
|
+
- title: Bootstrap repository self-management governance
|
|
23
|
+
- owner: ai-copilot
|
|
24
|
+
- updatedAt: 2026-02-17T23:50:00.000Z
|
|
25
|
+
- roadmapRefs: ROADMAP-0001
|
|
26
|
+
- taskLocation: /Users/yinxulai/Documents/Github/projitive/.projitive/tasks.md#L6
|
|
27
|
+
|
|
28
|
+
### Top Candidates
|
|
29
|
+
1. TASK-0001 | IN_PROGRESS | Bootstrap repository self-management governance | project=/Users/yinxulai/Documents/Github/projitive/.projitive | projectScore=4 | latest=2026-02-17T23:50:00.000Z
|
|
30
|
+
2. TASK-0002 | TODO | Stabilize default task.next workflow | project=/Users/yinxulai/Documents/Github/projitive/.projitive | projectScore=4 | latest=2026-02-17T23:50:00.000Z
|
|
31
|
+
3. TASK-0003 | TODO | Prepare spec v1.1 governance change proposal | project=/Users/yinxulai/Documents/Github/projitive/.projitive | projectScore=4 | latest=2026-02-17T23:50:00.000Z
|
|
32
|
+
4. TASK-0001 | TODO | Bootstrap governance workspace | project=/Users/yinxulai/Documents/Github/projitive-mcp-smoke/.projitive | projectScore=1 | latest=2026-02-18T13:18:19.890Z
|
|
33
|
+
|
|
34
|
+
### Selection Reason
|
|
35
|
+
- Rank rule: projectScore DESC -> taskPriority DESC -> taskUpdatedAt DESC.
|
|
36
|
+
- Selected candidate scores: projectScore=4, taskPriority=2, taskUpdatedAtMs=1771372200000.
|
|
37
|
+
|
|
38
|
+
### Related Artifacts
|
|
39
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/tasks.md
|
|
40
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/designs/self-management-bootstrap.md
|
|
41
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/reports/bootstrap-2026-02-17.md
|
|
42
|
+
|
|
43
|
+
### Reference Locations
|
|
44
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/tasks.md#L6: ## TASK-0001 | IN_PROGRESS | Bootstrap repository self-management governance
|
|
45
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/designs/self-management-bootstrap.md#L1: Task: TASK-0001
|
|
46
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/designs/self-management-bootstrap.md#L23: - Verify `task.next` can identify `TASK-0001` as actionable.
|
|
47
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/reports/bootstrap-2026-02-17.md#L1: Task: TASK-0001
|
|
48
|
+
- /Users/yinxulai/Documents/Github/projitive/.projitive/reports/bootstrap-2026-02-17.md#L17: - Continue TASK-0001 until first full `task.next` execution cycle is recorded.
|
|
49
|
+
|
|
50
|
+
### Suggested Read Order
|
|
51
|
+
1. /Users/yinxulai/Documents/Github/projitive/.projitive/tasks.md
|
|
52
|
+
2. /Users/yinxulai/Documents/Github/projitive/.projitive/designs/self-management-bootstrap.md
|
|
53
|
+
3. /Users/yinxulai/Documents/Github/projitive/.projitive/reports/bootstrap-2026-02-17.md
|
|
54
|
+
|
|
55
|
+
## Agent Guidance
|
|
56
|
+
- Start immediately with Suggested Read Order and execute the selected task.
|
|
57
|
+
- Update markdown artifacts directly while keeping TASK/ROADMAP IDs unchanged.
|
|
58
|
+
- Re-run `taskContext` for the selectedTaskId after edits to verify evidence consistency.
|
|
59
|
+
|
|
60
|
+
## Lint Suggestions
|
|
61
|
+
- (none)
|
|
62
|
+
|
|
63
|
+
## Next Call
|
|
64
|
+
- taskContext(projectPath="/Users/yinxulai/Documents/Github/projitive/.projitive", taskId="TASK-0001")
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { isValidRoadmapId } from "./roadmap.js";
|
|
2
|
+
import { isValidTaskId } from "./tasks.js";
|
|
3
|
+
export function parseDesignMetadata(markdown) {
|
|
4
|
+
const lines = markdown.split(/\r?\n/);
|
|
5
|
+
const metadata = {};
|
|
6
|
+
for (const line of lines) {
|
|
7
|
+
const [rawKey, ...rawValue] = line.split(":");
|
|
8
|
+
if (!rawKey || rawValue.length === 0) {
|
|
9
|
+
continue;
|
|
10
|
+
}
|
|
11
|
+
const key = rawKey.trim().toLowerCase();
|
|
12
|
+
const value = rawValue.join(":").trim();
|
|
13
|
+
if (key === "task")
|
|
14
|
+
metadata.task = value;
|
|
15
|
+
if (key === "roadmap")
|
|
16
|
+
metadata.roadmap = value;
|
|
17
|
+
if (key === "owner")
|
|
18
|
+
metadata.owner = value;
|
|
19
|
+
if (key === "status")
|
|
20
|
+
metadata.status = value;
|
|
21
|
+
if (key === "last updated")
|
|
22
|
+
metadata.lastUpdated = value;
|
|
23
|
+
}
|
|
24
|
+
return metadata;
|
|
25
|
+
}
|
|
26
|
+
export function validateDesignMetadata(metadata) {
|
|
27
|
+
const errors = [];
|
|
28
|
+
if (!metadata.task) {
|
|
29
|
+
errors.push("Missing Task metadata");
|
|
30
|
+
}
|
|
31
|
+
else if (!isValidTaskId(metadata.task)) {
|
|
32
|
+
errors.push(`Invalid Task metadata format: ${metadata.task}`);
|
|
33
|
+
}
|
|
34
|
+
if (metadata.roadmap && !isValidRoadmapId(metadata.roadmap)) {
|
|
35
|
+
errors.push(`Invalid Roadmap metadata format: ${metadata.roadmap}`);
|
|
36
|
+
}
|
|
37
|
+
return { ok: errors.length === 0, errors };
|
|
38
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export function candidateFilesFromArtifacts(artifacts) {
|
|
2
|
+
return artifacts
|
|
3
|
+
.filter((item) => item.exists)
|
|
4
|
+
.flatMap((item) => {
|
|
5
|
+
if (item.kind === "file") {
|
|
6
|
+
return [item.path];
|
|
7
|
+
}
|
|
8
|
+
return (item.markdownFiles ?? []).map((entry) => entry.path);
|
|
9
|
+
});
|
|
10
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { describe, expect, it } from "vitest";
|
|
2
|
+
import { candidateFilesFromArtifacts } from "./artifacts.js";
|
|
3
|
+
describe("candidateFilesFromArtifacts", () => {
|
|
4
|
+
it("collects existing file artifacts and markdown files from existing directories", () => {
|
|
5
|
+
const candidates = candidateFilesFromArtifacts([
|
|
6
|
+
{ name: "README.md", kind: "file", path: "/a/README.md", exists: true, lineCount: 3 },
|
|
7
|
+
{ name: "tasks.md", kind: "file", path: "/a/tasks.md", exists: false },
|
|
8
|
+
{
|
|
9
|
+
name: "designs",
|
|
10
|
+
kind: "directory",
|
|
11
|
+
path: "/a/designs",
|
|
12
|
+
exists: true,
|
|
13
|
+
markdownFiles: [{ path: "/a/designs/d1.md", lineCount: 10 }],
|
|
14
|
+
},
|
|
15
|
+
]);
|
|
16
|
+
expect(candidates).toEqual(["/a/README.md", "/a/designs/d1.md"]);
|
|
17
|
+
});
|
|
18
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./artifacts.js";
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
// 辅助函数:检查是否为 PromiseLike
|
|
2
|
+
function isPromiseLike(value) {
|
|
3
|
+
return value != null && typeof value === 'object' && 'then' in value && typeof value.then === 'function';
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* 构造成功结果对象
|
|
7
|
+
* isError 始终返回 false
|
|
8
|
+
*/
|
|
9
|
+
function createSuccess(value) {
|
|
10
|
+
return {
|
|
11
|
+
value,
|
|
12
|
+
error: undefined,
|
|
13
|
+
isError() { return false; }
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* 构造失败结果对象
|
|
18
|
+
* isError 始终返回 true
|
|
19
|
+
*/
|
|
20
|
+
function createFailure(error) {
|
|
21
|
+
return {
|
|
22
|
+
error,
|
|
23
|
+
value: undefined,
|
|
24
|
+
isError() { return true; }
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
export async function catchIt(input) {
|
|
28
|
+
try {
|
|
29
|
+
if (isPromiseLike(input)) {
|
|
30
|
+
const result = await Promise.resolve(input);
|
|
31
|
+
return createSuccess(result);
|
|
32
|
+
}
|
|
33
|
+
else if (typeof input === 'function') {
|
|
34
|
+
const result = input();
|
|
35
|
+
if (isPromiseLike(result)) {
|
|
36
|
+
return catchIt(result);
|
|
37
|
+
}
|
|
38
|
+
else {
|
|
39
|
+
return createSuccess(result);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
catch (error) {
|
|
44
|
+
return createFailure(error);
|
|
45
|
+
}
|
|
46
|
+
// 理论上不会到达这里,兜底类型安全
|
|
47
|
+
return createFailure(new Error('Unexpected input type'));
|
|
48
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { describe, it, expect } from 'vitest';
|
|
2
|
+
import { catchIt } from './catch.js';
|
|
3
|
+
describe('catchIt', () => {
|
|
4
|
+
it('同步函数返回值应为 value,error 为 undefined,isError 为 false', async () => {
|
|
5
|
+
const result = await catchIt(() => 123);
|
|
6
|
+
expect(result.value).toBe(123);
|
|
7
|
+
expect(result.error).toBeUndefined();
|
|
8
|
+
expect(result.isError()).toBe(false);
|
|
9
|
+
});
|
|
10
|
+
it('异步函数返回值应为 value,error 为 undefined,isError 为 false', async () => {
|
|
11
|
+
const result = await catchIt(async () => 456);
|
|
12
|
+
expect(result.value).toBe(456);
|
|
13
|
+
expect(result.error).toBeUndefined();
|
|
14
|
+
expect(result.isError()).toBe(false);
|
|
15
|
+
});
|
|
16
|
+
it('同步抛出异常时应返回 error,value 为 undefined,isError 为 true', async () => {
|
|
17
|
+
const error = new Error('fail');
|
|
18
|
+
const result = await catchIt(() => { throw error; });
|
|
19
|
+
expect(result.value).toBeUndefined();
|
|
20
|
+
expect(result.error).toBe(error);
|
|
21
|
+
expect(result.isError()).toBe(true);
|
|
22
|
+
});
|
|
23
|
+
it('异步抛出异常时应返回 error,value 为 undefined,isError 为 true', async () => {
|
|
24
|
+
const error = new Error('fail-async');
|
|
25
|
+
const result = await catchIt(() => Promise.reject(error));
|
|
26
|
+
expect(result.value).toBeUndefined();
|
|
27
|
+
expect(result.error).toBe(error);
|
|
28
|
+
expect(result.isError()).toBe(true);
|
|
29
|
+
});
|
|
30
|
+
it('PromiseLike resolve 时应返回 value,error 为 undefined,isError 为 false', async () => {
|
|
31
|
+
const result = await catchIt(Promise.resolve('ok'));
|
|
32
|
+
expect(result.value).toBe('ok');
|
|
33
|
+
expect(result.error).toBeUndefined();
|
|
34
|
+
expect(result.isError()).toBe(false);
|
|
35
|
+
});
|
|
36
|
+
it('PromiseLike reject 时应返回 error,value 为 undefined,isError 为 true', async () => {
|
|
37
|
+
const error = new Error('promise-fail');
|
|
38
|
+
const result = await catchIt(Promise.reject(error));
|
|
39
|
+
expect(result.value).toBeUndefined();
|
|
40
|
+
expect(result.error).toBe(error);
|
|
41
|
+
expect(result.isError()).toBe(true);
|
|
42
|
+
});
|
|
43
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './catch.js';
|