pikakit 1.0.16 → 1.0.17
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.
|
@@ -40,6 +40,28 @@ function findProjectRoot() {
|
|
|
40
40
|
|
|
41
41
|
const projectRoot = findProjectRoot();
|
|
42
42
|
const dashboardPath = path.join(__dirname, '..', 'dashboard');
|
|
43
|
+
const knowledgeDir = path.join(projectRoot, '.agent', 'knowledge');
|
|
44
|
+
|
|
45
|
+
// Read lessons count from YAML files (same source as CLI)
|
|
46
|
+
function getLessonsCount() {
|
|
47
|
+
let count = 0;
|
|
48
|
+
const files = ['lessons-learned.yaml', 'mistakes.yaml', 'improvements.yaml'];
|
|
49
|
+
|
|
50
|
+
for (const file of files) {
|
|
51
|
+
const filePath = path.join(knowledgeDir, file);
|
|
52
|
+
if (fs.existsSync(filePath)) {
|
|
53
|
+
try {
|
|
54
|
+
const content = fs.readFileSync(filePath, 'utf-8');
|
|
55
|
+
// Simple YAML parsing - count items in lessons/mistakes/improvements arrays
|
|
56
|
+
const matches = content.match(/^\s*-\s+id:/gm);
|
|
57
|
+
if (matches) count += matches.length;
|
|
58
|
+
} catch (e) {
|
|
59
|
+
// Ignore read errors
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
return count;
|
|
64
|
+
}
|
|
43
65
|
|
|
44
66
|
// ============================================================================
|
|
45
67
|
// DATA PROVIDERS
|
|
@@ -84,11 +106,11 @@ const api = {
|
|
|
84
106
|
const kpis = hasRealData ? realKpis.kpis : {};
|
|
85
107
|
|
|
86
108
|
const totalTasks = metricsCollector?.getMetricValue?.('total_tasks') || 0;
|
|
87
|
-
const patternsLearned =
|
|
109
|
+
const patternsLearned = getLessonsCount(); // Read directly from YAML files
|
|
88
110
|
const skillsGenerated = skillGenerator?.getSkillCount?.() || 0;
|
|
89
111
|
|
|
90
|
-
// Determine if this is a new user (no
|
|
91
|
-
const isNewUser =
|
|
112
|
+
// Determine if this is a new user (no lessons yet)
|
|
113
|
+
const isNewUser = patternsLearned === 0;
|
|
92
114
|
|
|
93
115
|
const summary = {
|
|
94
116
|
totalTasks,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pikakit",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.17",
|
|
4
4
|
"description": "Enterprise-grade Agent Skill Manager with Antigravity Skills support, Progressive Disclosure detection, and semantic routing validation",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "pikakit <pikakit@gmail.com>",
|