@knowledgine/cli 0.2.1 → 0.3.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.
Files changed (213) hide show
  1. package/dist/commands/capture.d.ts.map +1 -1
  2. package/dist/commands/capture.js +11 -15
  3. package/dist/commands/capture.js.map +1 -1
  4. package/dist/commands/deprecation-check.d.ts +7 -0
  5. package/dist/commands/deprecation-check.d.ts.map +1 -0
  6. package/dist/commands/deprecation-check.js +75 -0
  7. package/dist/commands/deprecation-check.js.map +1 -0
  8. package/dist/commands/explain.d.ts +10 -0
  9. package/dist/commands/explain.d.ts.map +1 -0
  10. package/dist/commands/explain.js +252 -0
  11. package/dist/commands/explain.js.map +1 -0
  12. package/dist/commands/feedback-suggest.d.ts +8 -0
  13. package/dist/commands/feedback-suggest.d.ts.map +1 -0
  14. package/dist/commands/feedback-suggest.js +43 -0
  15. package/dist/commands/feedback-suggest.js.map +1 -0
  16. package/dist/commands/feedback.d.ts.map +1 -1
  17. package/dist/commands/feedback.js +1 -6
  18. package/dist/commands/feedback.js.map +1 -1
  19. package/dist/commands/ingest.d.ts.map +1 -1
  20. package/dist/commands/ingest.js +15 -2
  21. package/dist/commands/ingest.js.map +1 -1
  22. package/dist/commands/init.d.ts +2 -0
  23. package/dist/commands/init.d.ts.map +1 -1
  24. package/dist/commands/init.js +42 -5
  25. package/dist/commands/init.js.map +1 -1
  26. package/dist/commands/plugins.d.ts.map +1 -1
  27. package/dist/commands/plugins.js +1 -1
  28. package/dist/commands/plugins.js.map +1 -1
  29. package/dist/commands/recall.d.ts +10 -0
  30. package/dist/commands/recall.d.ts.map +1 -0
  31. package/dist/commands/recall.js +199 -0
  32. package/dist/commands/recall.js.map +1 -0
  33. package/dist/commands/search.d.ts +3 -0
  34. package/dist/commands/search.d.ts.map +1 -1
  35. package/dist/commands/search.js +22 -3
  36. package/dist/commands/search.js.map +1 -1
  37. package/dist/commands/serve.d.ts +8 -0
  38. package/dist/commands/serve.d.ts.map +1 -0
  39. package/dist/commands/serve.js +60 -0
  40. package/dist/commands/serve.js.map +1 -0
  41. package/dist/commands/setup-rules.d.ts +27 -0
  42. package/dist/commands/setup-rules.d.ts.map +1 -0
  43. package/dist/commands/setup-rules.js +309 -0
  44. package/dist/commands/setup-rules.js.map +1 -0
  45. package/dist/commands/setup-skills.d.ts +55 -0
  46. package/dist/commands/setup-skills.d.ts.map +1 -0
  47. package/dist/commands/setup-skills.js +356 -0
  48. package/dist/commands/setup-skills.js.map +1 -0
  49. package/dist/commands/setup.d.ts +14 -0
  50. package/dist/commands/setup.d.ts.map +1 -1
  51. package/dist/commands/setup.js +103 -13
  52. package/dist/commands/setup.js.map +1 -1
  53. package/dist/commands/start.d.ts.map +1 -1
  54. package/dist/commands/start.js.map +1 -1
  55. package/dist/commands/status.js +1 -1
  56. package/dist/commands/status.js.map +1 -1
  57. package/dist/commands/suggest.d.ts +11 -0
  58. package/dist/commands/suggest.d.ts.map +1 -0
  59. package/dist/commands/suggest.js +255 -0
  60. package/dist/commands/suggest.js.map +1 -0
  61. package/dist/commands/undeprecate.d.ts +5 -0
  62. package/dist/commands/undeprecate.d.ts.map +1 -0
  63. package/dist/commands/undeprecate.js +27 -0
  64. package/dist/commands/undeprecate.js.map +1 -0
  65. package/dist/commands/upgrade.d.ts.map +1 -1
  66. package/dist/commands/upgrade.js.map +1 -1
  67. package/dist/index.js +44 -6
  68. package/dist/index.js.map +1 -1
  69. package/dist/lib/content-extractor.d.ts +8 -0
  70. package/dist/lib/content-extractor.d.ts.map +1 -0
  71. package/dist/lib/content-extractor.js +50 -0
  72. package/dist/lib/content-extractor.js.map +1 -0
  73. package/dist/lib/diff-parser.d.ts +14 -0
  74. package/dist/lib/diff-parser.d.ts.map +1 -0
  75. package/dist/lib/diff-parser.js +108 -0
  76. package/dist/lib/diff-parser.js.map +1 -0
  77. package/dist/lib/entity-extractor.d.ts +2 -0
  78. package/dist/lib/entity-extractor.d.ts.map +1 -1
  79. package/dist/lib/entity-extractor.js +13 -76
  80. package/dist/lib/entity-extractor.js.map +1 -1
  81. package/dist/lib/formatter.d.ts.map +1 -1
  82. package/dist/lib/formatter.js +1 -5
  83. package/dist/lib/formatter.js.map +1 -1
  84. package/dist/lib/ingest-watcher.d.ts.map +1 -1
  85. package/dist/lib/ingest-watcher.js +1 -0
  86. package/dist/lib/ingest-watcher.js.map +1 -1
  87. package/dist/lib/plugin-loader.d.ts.map +1 -1
  88. package/dist/lib/plugin-loader.js +3 -1
  89. package/dist/lib/plugin-loader.js.map +1 -1
  90. package/dist/lib/progress.d.ts +2 -0
  91. package/dist/lib/progress.d.ts.map +1 -1
  92. package/dist/lib/progress.js +4 -2
  93. package/dist/lib/progress.js.map +1 -1
  94. package/dist/lib/ui/box.d.ts.map +1 -1
  95. package/dist/lib/ui/box.js.map +1 -1
  96. package/dist/lib/ui/error-formatter.d.ts.map +1 -1
  97. package/dist/lib/ui/error-formatter.js +1 -3
  98. package/dist/lib/ui/error-formatter.js.map +1 -1
  99. package/dist/lib/ui/table.js +1 -1
  100. package/dist/lib/ui/table.js.map +1 -1
  101. package/dist/templates/rules/antigravity.d.ts +6 -0
  102. package/dist/templates/rules/antigravity.d.ts.map +1 -0
  103. package/dist/templates/rules/antigravity.js +30 -0
  104. package/dist/templates/rules/antigravity.js.map +1 -0
  105. package/dist/templates/rules/claude-code.d.ts +6 -0
  106. package/dist/templates/rules/claude-code.d.ts.map +1 -0
  107. package/dist/templates/rules/claude-code.js +32 -0
  108. package/dist/templates/rules/claude-code.js.map +1 -0
  109. package/dist/templates/rules/cline.d.ts +6 -0
  110. package/dist/templates/rules/cline.d.ts.map +1 -0
  111. package/dist/templates/rules/cline.js +35 -0
  112. package/dist/templates/rules/cline.js.map +1 -0
  113. package/dist/templates/rules/codex.d.ts +6 -0
  114. package/dist/templates/rules/codex.d.ts.map +1 -0
  115. package/dist/templates/rules/codex.js +37 -0
  116. package/dist/templates/rules/codex.js.map +1 -0
  117. package/dist/templates/rules/continue.d.ts +6 -0
  118. package/dist/templates/rules/continue.d.ts.map +1 -0
  119. package/dist/templates/rules/continue.js +31 -0
  120. package/dist/templates/rules/continue.js.map +1 -0
  121. package/dist/templates/rules/core-rules.d.ts +6 -0
  122. package/dist/templates/rules/core-rules.d.ts.map +1 -0
  123. package/dist/templates/rules/core-rules.js +33 -0
  124. package/dist/templates/rules/core-rules.js.map +1 -0
  125. package/dist/templates/rules/cursor.d.ts +6 -0
  126. package/dist/templates/rules/cursor.d.ts.map +1 -0
  127. package/dist/templates/rules/cursor.js +29 -0
  128. package/dist/templates/rules/cursor.js.map +1 -0
  129. package/dist/templates/rules/gemini.d.ts +6 -0
  130. package/dist/templates/rules/gemini.d.ts.map +1 -0
  131. package/dist/templates/rules/gemini.js +30 -0
  132. package/dist/templates/rules/gemini.js.map +1 -0
  133. package/dist/templates/rules/github-copilot.d.ts +6 -0
  134. package/dist/templates/rules/github-copilot.d.ts.map +1 -0
  135. package/dist/templates/rules/github-copilot.js +42 -0
  136. package/dist/templates/rules/github-copilot.js.map +1 -0
  137. package/dist/templates/rules/index.d.ts +13 -0
  138. package/dist/templates/rules/index.d.ts.map +1 -0
  139. package/dist/templates/rules/index.js +13 -0
  140. package/dist/templates/rules/index.js.map +1 -0
  141. package/dist/templates/rules/opencode.d.ts +6 -0
  142. package/dist/templates/rules/opencode.d.ts.map +1 -0
  143. package/dist/templates/rules/opencode.js +30 -0
  144. package/dist/templates/rules/opencode.js.map +1 -0
  145. package/dist/templates/rules/windsurf.d.ts +6 -0
  146. package/dist/templates/rules/windsurf.d.ts.map +1 -0
  147. package/dist/templates/rules/windsurf.js +24 -0
  148. package/dist/templates/rules/windsurf.js.map +1 -0
  149. package/dist/templates/rules/zed.d.ts +6 -0
  150. package/dist/templates/rules/zed.d.ts.map +1 -0
  151. package/dist/templates/rules/zed.js +34 -0
  152. package/dist/templates/rules/zed.js.map +1 -0
  153. package/dist/templates/skills/index.d.ts +26 -0
  154. package/dist/templates/skills/index.d.ts.map +1 -0
  155. package/dist/templates/skills/index.js +75 -0
  156. package/dist/templates/skills/index.js.map +1 -0
  157. package/dist/templates/skills/knowledgine-capture/references.d.ts +2 -0
  158. package/dist/templates/skills/knowledgine-capture/references.d.ts.map +1 -0
  159. package/dist/templates/skills/knowledgine-capture/references.js +414 -0
  160. package/dist/templates/skills/knowledgine-capture/references.js.map +1 -0
  161. package/dist/templates/skills/knowledgine-capture/skill-md.d.ts +2 -0
  162. package/dist/templates/skills/knowledgine-capture/skill-md.d.ts.map +1 -0
  163. package/dist/templates/skills/knowledgine-capture/skill-md.js +97 -0
  164. package/dist/templates/skills/knowledgine-capture/skill-md.js.map +1 -0
  165. package/dist/templates/skills/knowledgine-debrief/references.d.ts +2 -0
  166. package/dist/templates/skills/knowledgine-debrief/references.d.ts.map +1 -0
  167. package/dist/templates/skills/knowledgine-debrief/references.js +140 -0
  168. package/dist/templates/skills/knowledgine-debrief/references.js.map +1 -0
  169. package/dist/templates/skills/knowledgine-debrief/skill-md.d.ts +2 -0
  170. package/dist/templates/skills/knowledgine-debrief/skill-md.d.ts.map +1 -0
  171. package/dist/templates/skills/knowledgine-debrief/skill-md.js +74 -0
  172. package/dist/templates/skills/knowledgine-debrief/skill-md.js.map +1 -0
  173. package/dist/templates/skills/knowledgine-explain/references.d.ts +2 -0
  174. package/dist/templates/skills/knowledgine-explain/references.d.ts.map +1 -0
  175. package/dist/templates/skills/knowledgine-explain/references.js +183 -0
  176. package/dist/templates/skills/knowledgine-explain/references.js.map +1 -0
  177. package/dist/templates/skills/knowledgine-explain/skill-md.d.ts +2 -0
  178. package/dist/templates/skills/knowledgine-explain/skill-md.d.ts.map +1 -0
  179. package/dist/templates/skills/knowledgine-explain/skill-md.js +89 -0
  180. package/dist/templates/skills/knowledgine-explain/skill-md.js.map +1 -0
  181. package/dist/templates/skills/knowledgine-feedback/references.d.ts +2 -0
  182. package/dist/templates/skills/knowledgine-feedback/references.d.ts.map +1 -0
  183. package/dist/templates/skills/knowledgine-feedback/references.js +214 -0
  184. package/dist/templates/skills/knowledgine-feedback/references.js.map +1 -0
  185. package/dist/templates/skills/knowledgine-feedback/skill-md.d.ts +2 -0
  186. package/dist/templates/skills/knowledgine-feedback/skill-md.d.ts.map +1 -0
  187. package/dist/templates/skills/knowledgine-feedback/skill-md.js +107 -0
  188. package/dist/templates/skills/knowledgine-feedback/skill-md.js.map +1 -0
  189. package/dist/templates/skills/knowledgine-ingest/references.d.ts +2 -0
  190. package/dist/templates/skills/knowledgine-ingest/references.d.ts.map +1 -0
  191. package/dist/templates/skills/knowledgine-ingest/references.js +243 -0
  192. package/dist/templates/skills/knowledgine-ingest/references.js.map +1 -0
  193. package/dist/templates/skills/knowledgine-ingest/skill-md.d.ts +2 -0
  194. package/dist/templates/skills/knowledgine-ingest/skill-md.d.ts.map +1 -0
  195. package/dist/templates/skills/knowledgine-ingest/skill-md.js +80 -0
  196. package/dist/templates/skills/knowledgine-ingest/skill-md.js.map +1 -0
  197. package/dist/templates/skills/knowledgine-recall/references.d.ts +2 -0
  198. package/dist/templates/skills/knowledgine-recall/references.d.ts.map +1 -0
  199. package/dist/templates/skills/knowledgine-recall/references.js +207 -0
  200. package/dist/templates/skills/knowledgine-recall/references.js.map +1 -0
  201. package/dist/templates/skills/knowledgine-recall/skill-md.d.ts +2 -0
  202. package/dist/templates/skills/knowledgine-recall/skill-md.d.ts.map +1 -0
  203. package/dist/templates/skills/knowledgine-recall/skill-md.js +86 -0
  204. package/dist/templates/skills/knowledgine-recall/skill-md.js.map +1 -0
  205. package/dist/templates/skills/knowledgine-suggest/references.d.ts +2 -0
  206. package/dist/templates/skills/knowledgine-suggest/references.d.ts.map +1 -0
  207. package/dist/templates/skills/knowledgine-suggest/references.js +121 -0
  208. package/dist/templates/skills/knowledgine-suggest/references.js.map +1 -0
  209. package/dist/templates/skills/knowledgine-suggest/skill-md.d.ts +2 -0
  210. package/dist/templates/skills/knowledgine-suggest/skill-md.d.ts.map +1 -0
  211. package/dist/templates/skills/knowledgine-suggest/skill-md.js +94 -0
  212. package/dist/templates/skills/knowledgine-suggest/skill-md.js.map +1 -0
  213. package/package.json +6 -4
@@ -0,0 +1,214 @@
1
+ export const REFERENCES = {
2
+ "error-types.md": `# Error Types
3
+
4
+ Descriptions and examples of the three entity extraction error types.
5
+
6
+ ---
7
+
8
+ ## false_positive
9
+
10
+ **Definition**: An entity was extracted that is not actually a meaningful named entity.
11
+ The extraction system incorrectly identified a word or phrase as a significant entity.
12
+
13
+ **Common causes**:
14
+ - Common English words extracted as entity types (e.g., "Map" as technology)
15
+ - Context-specific jargon that is not a real entity (e.g., "Result" as a concept)
16
+ - Partial matches of entity names (e.g., "Type" extracted from "TypeScript")
17
+
18
+ **Examples**:
19
+
20
+ | Entity | Extracted Type | Why it's wrong |
21
+ |--------|---------------|----------------|
22
+ | "the" | concept | Common article, not an entity |
23
+ | "Manager" | technology | Generic class name suffix, not a product |
24
+ | "Error" | technology | Common programming term, not a specific tool |
25
+ | "Result" | concept | Generic programming term, used everywhere |
26
+
27
+ **When to report**:
28
+ Report when the false entity appears frequently in search results and reduces result
29
+ quality. A single occurrence in one obscure note may not be worth reporting.
30
+
31
+ **How to report**:
32
+ \`\`\`
33
+ report_extraction_error(
34
+ entityName: "Manager",
35
+ errorType: "false_positive",
36
+ entityType: "technology",
37
+ details: "Generic class name suffix, not a specific technology product"
38
+ )
39
+ \`\`\`
40
+
41
+ ---
42
+
43
+ ## wrong_type
44
+
45
+ **Definition**: A real, meaningful entity was extracted but assigned to the wrong type.
46
+ The entity exists and is valid, but it is categorized incorrectly.
47
+
48
+ **Common causes**:
49
+ - Technologies named like people (e.g., "Rust" could be confused with a surname)
50
+ - Concepts with technical names
51
+ - Projects or tools that share names with common words
52
+
53
+ **Examples**:
54
+
55
+ | Entity | Wrong Type | Correct Type | Reason |
56
+ |--------|-----------|--------------|--------|
57
+ | "TypeScript" | person | technology | A programming language, not a person |
58
+ | "Rust" | concept | technology | A programming language |
59
+ | "knowledgine" | concept | project | The name of this project |
60
+ | "Jest" | person | technology | A JavaScript testing framework |
61
+
62
+ **When to report**:
63
+ Report when wrong type classification causes the entity to appear in irrelevant searches
64
+ or prevents it from appearing in the correct entity type queries.
65
+
66
+ **How to report**:
67
+ \`\`\`
68
+ report_extraction_error(
69
+ entityName: "TypeScript",
70
+ errorType: "wrong_type",
71
+ entityType: "person",
72
+ correctType: "technology",
73
+ details: "TypeScript is a programming language, not a person's name"
74
+ )
75
+ \`\`\`
76
+
77
+ ---
78
+
79
+ ## missed_entity
80
+
81
+ **Definition**: A significant entity was not extracted at all. The entity appears
82
+ in knowledge base notes but has no entity record in the graph.
83
+
84
+ **Common causes**:
85
+ - Entity extraction confidence threshold was too high for this entity
86
+ - Entity name was mentioned in an unusual format or context
87
+ - Entity is new and the extractor's model was not trained on it
88
+ - Entity appears in code blocks rather than prose
89
+
90
+ **Examples**:
91
+ - "Zod" mentioned throughout validation code but no entity extracted
92
+ - A team member's name that appears in commit messages but not in entity graph
93
+ - A specific error code (e.g., "SQLITE_CONSTRAINT_UNIQUE") that is referenced often
94
+ - A library name that only appears in import statements
95
+
96
+ **When to report**:
97
+ Report when an entity is important enough that you would use \`search_entities\` or
98
+ \`get_entity_graph\` to find it. Minor entities with low frequency may not be worth adding.
99
+
100
+ **How to report**:
101
+ \`\`\`
102
+ report_extraction_error(
103
+ entityName: "Zod",
104
+ errorType: "missed_entity",
105
+ details: "Validation library used throughout packages/core for schema validation. \
106
+ Appears in imports and error messages but no entity was extracted."
107
+ )
108
+ \`\`\`
109
+ `,
110
+ "feedback-guide.md": `# Feedback Guide
111
+
112
+ How to write effective feedback reports that lead to extraction improvements.
113
+
114
+ ---
115
+
116
+ ## What Makes Feedback Effective
117
+
118
+ Good feedback:
119
+ 1. **Identifies the specific entity** — Exact name, not a description
120
+ 2. **States the correct classification** — What type it should or should not be
121
+ 3. **Explains why** — A brief rationale makes the feedback actionable
122
+ 4. **References a note** — Links to where the issue was observed (when possible)
123
+
124
+ ---
125
+
126
+ ## Workflow for Reporting Feedback
127
+
128
+ ### Step 1: Identify the issue
129
+
130
+ Use \`search_entities\` to find the entity in question:
131
+ \`\`\`
132
+ search_entities(query: "TypeScript", limit: 5)
133
+ \`\`\`
134
+
135
+ Check the returned type against what you expect.
136
+
137
+ ### Step 2: Find a relevant note (optional but helpful)
138
+
139
+ If you saw the entity misclassified in a specific note, note its ID.
140
+ You can find note IDs in search_knowledge results.
141
+
142
+ ### Step 3: Report
143
+
144
+ Call \`report_extraction_error\` with all available information:
145
+ \`\`\`
146
+ report_extraction_error(
147
+ entityName: "<exact name>",
148
+ errorType: "<false_positive|wrong_type|missed_entity>",
149
+ entityType: "<current type if known>",
150
+ correctType: "<correct type for wrong_type errors>",
151
+ noteId: "<note id if available>",
152
+ details: "<1–2 sentence explanation>"
153
+ )
154
+ \`\`\`
155
+
156
+ ### Step 4: Verify submission
157
+
158
+ Confirm the tool returned a success response with a feedback ID.
159
+ Note the ID if you want to track the feedback status later.
160
+
161
+ ---
162
+
163
+ ## Writing the Details Field
164
+
165
+ The \`details\` field is the most important part of effective feedback. Include:
166
+
167
+ - What the entity actually is (if not obvious from its name)
168
+ - Why the extracted type is wrong
169
+ - How frequently the entity appears (if it is a missed entity)
170
+ - Any context that might help the extractor improve
171
+
172
+ **Weak details**:
173
+ \`\`\`
174
+ details: "wrong"
175
+ details: "this is not right"
176
+ \`\`\`
177
+
178
+ **Strong details**:
179
+ \`\`\`
180
+ details: "Zod is a TypeScript-first schema validation library. It appears in ~20 notes
181
+ under packages/core/src as imports and in error messages but was not extracted. It
182
+ should be classified as 'technology'."
183
+ \`\`\`
184
+
185
+ ---
186
+
187
+ ## Prioritizing What to Report
188
+
189
+ | Priority | Criteria |
190
+ |----------|----------|
191
+ | High | Entity appears in many notes; wrong type pollutes search results |
192
+ | High | Missed entity is central to the project domain |
193
+ | Medium | False positive appears often but does not cause significant harm |
194
+ | Low | Single-occurrence issue with minimal impact on search quality |
195
+
196
+ ---
197
+
198
+ ## After Reporting
199
+
200
+ Check feedback status and apply improvements:
201
+
202
+ \`\`\`bash
203
+ # List pending feedback
204
+ knowledgine feedback list --status pending
205
+
206
+ # View statistics on feedback quality
207
+ knowledgine feedback stats
208
+ \`\`\`
209
+
210
+ Applied feedback updates the extraction configuration so future ingests produce
211
+ better results. Dismissed feedback is recorded but no change is made.
212
+ `,
213
+ };
214
+ //# sourceMappingURL=references.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"references.js","sourceRoot":"","sources":["../../../../src/templates/skills/knowledgine-feedback/references.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,UAAU,GAA2B;IAChD,gBAAgB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2GnB;IAEC,mBAAmB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsGtB;CACA,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const SKILL_MD = "---\nname: knowledgine-feedback\ndescription: >\n Report incorrect, missing, or misclassified entity extractions to improve knowledge\n base quality. Invoke when you notice an entity that should not exist (false positive),\n an entity assigned to the wrong type (wrong_type), or a real entity that was not\n extracted at all (missed_entity).\n---\n# knowledgine-feedback\n\n## Purpose\n\nImprove the quality of automatic entity extraction by reporting errors. Feedback is\nstored and can be applied to update extraction rules, preventing the same errors from\nrecurring in future ingests.\n\n## When to Use\n\n- **False positive detected** \u2014 An entity was extracted that is not actually a named entity\n (e.g., a common English word extracted as a \"technology\" entity)\n- **Wrong type detected** \u2014 An entity exists but is classified incorrectly\n (e.g., \"TypeScript\" classified as \"person\" instead of \"technology\")\n- **Missed entity detected** \u2014 An important entity was not extracted at all\n (e.g., a library name that appears frequently but has no entity record)\n\n## When NOT to Use\n\n- When entity extraction quality is acceptable \u2014 minor imprecision is normal\n- For subjective disagreements about entity importance (not extracting an entity\n does not always mean it was missed \u2014 the extractor uses confidence thresholds)\n\n## How to Report (MCP Tool)\n\nUse the `report_extraction_error` MCP tool:\n\n```\nreport_extraction_error(\n entityName: string, // The entity name as it appears in the note\n errorType: string, // \"false_positive\" | \"wrong_type\" | \"missed_entity\"\n entityType?: string, // Current entity type (for wrong_type and false_positive)\n correctType?: string, // What the type should be (for wrong_type)\n noteId?: string, // ID of the note where the issue was observed\n details?: string // Additional context about the error\n)\n```\n\n## How to Report (CLI Alternative)\n\n```bash\n# Report a false positive\nknowledgine feedback report --entity \"the\" --type false_positive --entity-type concept --details \"Common English article incorrectly extracted as entity\"\n\n# Report wrong type\nknowledgine feedback report --entity \"TypeScript\" --type wrong_type --entity-type person --correct-type technology\n\n# Report missed entity\nknowledgine feedback report --entity \"Zod\" --type missed_entity --details \"Validation library used throughout packages/core but not extracted\"\n```\n\n## Step-by-Step Instructions\n\n1. **Identify the error type** \u2014 Is it a false positive, wrong type, or missed entity?\n2. **Find the entity name** \u2014 Use `search_entities` to find the exact stored name if it exists\n3. **Note the note ID** \u2014 If you observed the error in a specific note, record its ID\n4. **Call report_extraction_error** \u2014 Include all applicable parameters\n5. **Verify submission** \u2014 Confirm the tool returned a success response\n\n## Managing Feedback\n\n```bash\n# View pending feedback\nknowledgine feedback list --status pending\n\n# Apply a specific feedback report (admin operation)\nknowledgine feedback apply <id>\n\n# Dismiss feedback without applying\nknowledgine feedback dismiss <id>\n\n# View feedback statistics\nknowledgine feedback stats\n```\n\n## Best Practices\n\n- Report high-frequency errors first \u2014 they have the most impact\n- Include specific details about what makes the extraction incorrect\n- Reference a note ID when possible so the error can be verified in context\n- Do not report minor cases that have no practical impact on search quality\n\n## Reference Files\n\n- See `error-types.md` for detailed descriptions and examples of each error type\n- See `feedback-guide.md` for how to write effective feedback reports\n";
2
+ //# sourceMappingURL=skill-md.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skill-md.d.ts","sourceRoot":"","sources":["../../../../src/templates/skills/knowledgine-feedback/skill-md.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,QAAQ,2vHAyGpB,CAAC"}
@@ -0,0 +1,107 @@
1
+ export const SKILL_MD = `---
2
+ name: knowledgine-feedback
3
+ description: >
4
+ Report incorrect, missing, or misclassified entity extractions to improve knowledge
5
+ base quality. Invoke when you notice an entity that should not exist (false positive),
6
+ an entity assigned to the wrong type (wrong_type), or a real entity that was not
7
+ extracted at all (missed_entity).
8
+ ---
9
+ # knowledgine-feedback
10
+
11
+ ## Purpose
12
+
13
+ Improve the quality of automatic entity extraction by reporting errors. Feedback is
14
+ stored and can be applied to update extraction rules, preventing the same errors from
15
+ recurring in future ingests.
16
+
17
+ ## When to Use
18
+
19
+ - **False positive detected** — An entity was extracted that is not actually a named entity
20
+ (e.g., a common English word extracted as a "technology" entity)
21
+ - **Wrong type detected** — An entity exists but is classified incorrectly
22
+ (e.g., "TypeScript" classified as "person" instead of "technology")
23
+ - **Missed entity detected** — An important entity was not extracted at all
24
+ (e.g., a library name that appears frequently but has no entity record)
25
+
26
+ ## When NOT to Use
27
+
28
+ - When entity extraction quality is acceptable — minor imprecision is normal
29
+ - For subjective disagreements about entity importance (not extracting an entity
30
+ does not always mean it was missed — the extractor uses confidence thresholds)
31
+
32
+ ## How to Report (MCP Tool)
33
+
34
+ Use the \`report_extraction_error\` MCP tool:
35
+
36
+ \`\`\`
37
+ report_extraction_error(
38
+ entityName: string, // The entity name as it appears in the note
39
+ errorType: string, // "false_positive" | "wrong_type" | "missed_entity"
40
+ entityType?: string, // Current entity type (for wrong_type and false_positive)
41
+ correctType?: string, // What the type should be (for wrong_type)
42
+ noteId?: string, // ID of the note where the issue was observed
43
+ details?: string // Additional context about the error
44
+ )
45
+ \`\`\`
46
+
47
+ ## How to Report (CLI Alternative)
48
+
49
+ \`\`\`bash
50
+ # Report a false positive
51
+ knowledgine feedback report \
52
+ --entity "the" \
53
+ --type false_positive \
54
+ --entity-type concept \
55
+ --details "Common English article incorrectly extracted as entity"
56
+
57
+ # Report wrong type
58
+ knowledgine feedback report \
59
+ --entity "TypeScript" \
60
+ --type wrong_type \
61
+ --entity-type person \
62
+ --correct-type technology
63
+
64
+ # Report missed entity
65
+ knowledgine feedback report \
66
+ --entity "Zod" \
67
+ --type missed_entity \
68
+ --details "Validation library used throughout packages/core but not extracted"
69
+ \`\`\`
70
+
71
+ ## Step-by-Step Instructions
72
+
73
+ 1. **Identify the error type** — Is it a false positive, wrong type, or missed entity?
74
+ 2. **Find the entity name** — Use \`search_entities\` to find the exact stored name if it exists
75
+ 3. **Note the note ID** — If you observed the error in a specific note, record its ID
76
+ 4. **Call report_extraction_error** — Include all applicable parameters
77
+ 5. **Verify submission** — Confirm the tool returned a success response
78
+
79
+ ## Managing Feedback
80
+
81
+ \`\`\`bash
82
+ # View pending feedback
83
+ knowledgine feedback list --status pending
84
+
85
+ # Apply a specific feedback report (admin operation)
86
+ knowledgine feedback apply <id>
87
+
88
+ # Dismiss feedback without applying
89
+ knowledgine feedback dismiss <id>
90
+
91
+ # View feedback statistics
92
+ knowledgine feedback stats
93
+ \`\`\`
94
+
95
+ ## Best Practices
96
+
97
+ - Report high-frequency errors first — they have the most impact
98
+ - Include specific details about what makes the extraction incorrect
99
+ - Reference a note ID when possible so the error can be verified in context
100
+ - Do not report minor cases that have no practical impact on search quality
101
+
102
+ ## Reference Files
103
+
104
+ - See \`error-types.md\` for detailed descriptions and examples of each error type
105
+ - See \`feedback-guide.md\` for how to write effective feedback reports
106
+ `;
107
+ //# sourceMappingURL=skill-md.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skill-md.js","sourceRoot":"","sources":["../../../../src/templates/skills/knowledgine-feedback/skill-md.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,QAAQ,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyGvB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const REFERENCES: Record<string, string>;
2
+ //# sourceMappingURL=references.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"references.d.ts","sourceRoot":"","sources":["../../../../src/templates/skills/knowledgine-ingest/references.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAkP7C,CAAC"}
@@ -0,0 +1,243 @@
1
+ export const REFERENCES = {
2
+ "plugin-guide.md": `# Plugin Guide
3
+
4
+ Detailed documentation for each knowledgine ingest plugin.
5
+
6
+ ---
7
+
8
+ ## markdown
9
+
10
+ **Plugin ID**: \`markdown\`
11
+ **Source**: Local markdown files in the knowledge base directory
12
+
13
+ The default plugin used by \`knowledgine init\`. Scans the configured root directory
14
+ for \`.md\` files and indexes them.
15
+
16
+ \`\`\`bash
17
+ knowledgine ingest --source markdown --path ~/notes
18
+ \`\`\`
19
+
20
+ **What it captures**: Full text of markdown files, front matter metadata, headings,
21
+ code blocks.
22
+
23
+ **Incremental**: Yes. Tracks file modification times; re-ingests changed files only.
24
+
25
+ ---
26
+
27
+ ## git-history
28
+
29
+ **Plugin ID**: \`git-history\`
30
+ **Source**: Git repository commit history
31
+
32
+ Extracts knowledge from Git commit messages and associated diffs. Particularly useful
33
+ for understanding past design decisions and the evolution of specific files.
34
+
35
+ \`\`\`bash
36
+ knowledgine ingest --source git-history --path ~/project
37
+ \`\`\`
38
+
39
+ **What it captures**: Commit messages (especially conventional commit prefixes like
40
+ \`feat:\`, \`fix:\`, \`refactor:\`), file paths changed, commit metadata.
41
+
42
+ **Prerequisites**: Must be run inside a Git repository (or with \`--path\` pointing to one).
43
+
44
+ **Incremental**: Yes. Tracks the last processed commit hash.
45
+
46
+ **Tips**:
47
+ - Run with \`--full\` when first setting up to get the complete history
48
+ - Commit messages following Conventional Commits format produce higher-quality captures
49
+
50
+ ---
51
+
52
+ ## github
53
+
54
+ **Plugin ID**: \`github\`
55
+ **Source**: GitHub Pull Requests and Issues
56
+
57
+ Fetches PR descriptions, issue bodies, and comments from a GitHub repository.
58
+ Captures design discussions, bug reports, and decision rationale.
59
+
60
+ \`\`\`bash
61
+ GITHUB_TOKEN=<token> knowledgine ingest --source github --repo owner/repo --path ~/project
62
+ \`\`\`
63
+
64
+ **Prerequisites**:
65
+ - \`GITHUB_TOKEN\` environment variable with \`repo\` scope (or \`public_repo\` for public repos)
66
+ - \`--repo\` flag specifying the repository (format: \`owner/repo\`)
67
+
68
+ **What it captures**: PR titles and bodies, issue titles and bodies, labels.
69
+
70
+ **Rate limiting**: Uses authenticated requests; limit is 5000 requests/hour with a token.
71
+
72
+ **Incremental**: Yes. Tracks the last fetched item number.
73
+
74
+ ---
75
+
76
+ ## obsidian
77
+
78
+ **Plugin ID**: \`obsidian\`
79
+ **Source**: Obsidian vault markdown notes
80
+
81
+ Imports notes from an Obsidian vault, preserving internal links and tags.
82
+
83
+ \`\`\`bash
84
+ knowledgine ingest --source obsidian --path ~/vault
85
+ \`\`\`
86
+
87
+ **What it captures**: Note content, Obsidian tags (converted to knowledgine tags),
88
+ wikilinks, front matter.
89
+
90
+ **Prerequisites**: The Obsidian vault directory must be accessible. No special
91
+ configuration required — Obsidian stores notes as plain markdown.
92
+
93
+ **Tips**:
94
+ - Use \`--full\` after reorganizing your vault
95
+ - Notes with \`#private\` or \`#ignore\` tags can be excluded via plugin configuration
96
+
97
+ ---
98
+
99
+ ## claude-sessions
100
+
101
+ **Plugin ID**: \`claude-sessions\`
102
+ **Source**: Claude Code session history
103
+
104
+ Imports context from past Claude Code sessions stored in the session history.
105
+
106
+ \`\`\`bash
107
+ knowledgine ingest --source claude-sessions --path ~/project
108
+ \`\`\`
109
+
110
+ **What it captures**: Session summaries, key decisions and discoveries logged during
111
+ past Claude Code sessions.
112
+
113
+ **Storage location**: Claude Code stores session history in
114
+ \`~/.claude/projects/<project-hash>/\`.
115
+
116
+ ---
117
+
118
+ ## cursor-sessions
119
+
120
+ **Plugin ID**: \`cursor-sessions\`
121
+ **Source**: Cursor IDE session history
122
+
123
+ Imports knowledge from Cursor IDE's AI conversation history.
124
+
125
+ \`\`\`bash
126
+ knowledgine ingest --source cursor-sessions --path ~/project
127
+ \`\`\`
128
+
129
+ **What it captures**: Cursor AI conversation content that includes code decisions,
130
+ bug fixes, and architectural discussions.
131
+
132
+ **Storage location**: Cursor stores session data in its SQLite workspace database.
133
+
134
+ ---
135
+
136
+ ## cicd
137
+
138
+ **Plugin ID**: \`cicd\`
139
+ **Source**: CI/CD pipeline results (GitHub Actions)
140
+
141
+ Imports CI/CD pipeline outcomes, failed test results, and deployment records.
142
+
143
+ \`\`\`bash
144
+ GITHUB_TOKEN=<token> knowledgine ingest --source cicd --repo owner/repo --path ~/project
145
+ \`\`\`
146
+
147
+ **What it captures**: Workflow run summaries, failed job details, deployment events.
148
+
149
+ **Prerequisites**: \`GITHUB_TOKEN\` and \`--repo\` flag (same as github plugin).
150
+
151
+ **Use case**: Building knowledge about flaky tests, infrastructure issues, and
152
+ deployment patterns from CI history.
153
+ `,
154
+ "source-types.md": `# Source Types and Configuration
155
+
156
+ Configuration requirements and environment variables for each ingest source.
157
+
158
+ ---
159
+
160
+ ## Configuration Summary
161
+
162
+ | Source | Required Config | Optional Config |
163
+ |--------|----------------|-----------------|
164
+ | \`markdown\` | \`--path\` (knowledge base dir) | — |
165
+ | \`git-history\` | \`--path\` (git repo dir) | \`--full\` to reset cursor |
166
+ | \`github\` | \`GITHUB_TOKEN\`, \`--repo\` | \`--full\` |
167
+ | \`obsidian\` | \`--path\` (vault dir) | \`--full\` |
168
+ | \`claude-sessions\` | \`--path\` | — |
169
+ | \`cursor-sessions\` | \`--path\` | — |
170
+ | \`cicd\` | \`GITHUB_TOKEN\`, \`--repo\` | \`--full\` |
171
+
172
+ ---
173
+
174
+ ## Environment Variables
175
+
176
+ ### GITHUB_TOKEN
177
+
178
+ Required for \`github\` and \`cicd\` plugins.
179
+
180
+ \`\`\`bash
181
+ # Set in shell
182
+ export GITHUB_TOKEN=ghp_xxxxxxxxxxxxxxxxxxxx
183
+
184
+ # Or prefix the command
185
+ GITHUB_TOKEN=ghp_xxx knowledgine ingest --source github --repo owner/repo
186
+ \`\`\`
187
+
188
+ **Required scopes**:
189
+ - Public repos: \`public_repo\`
190
+ - Private repos: \`repo\`
191
+ - For CI/CD: add \`workflow\` scope
192
+
193
+ **Creating a token**:
194
+ GitHub → Settings → Developer settings → Personal access tokens → Tokens (classic)
195
+
196
+ ---
197
+
198
+ ## Cursor State Management
199
+
200
+ Each plugin tracks a "cursor" — the last processed position — to enable incremental
201
+ ingestion. You can inspect cursor state and reset it:
202
+
203
+ \`\`\`bash
204
+ # View cursor state for all plugins
205
+ knowledgine plugins status --path ~/project
206
+
207
+ # Reset cursor to force full re-ingest
208
+ knowledgine ingest --source <plugin> --full --path ~/project
209
+ \`\`\`
210
+
211
+ ---
212
+
213
+ ## Running Multiple Plugins
214
+
215
+ \`\`\`bash
216
+ # Run all registered plugins sequentially
217
+ knowledgine ingest --all --path ~/project
218
+
219
+ # Check which plugins are registered
220
+ knowledgine plugins list
221
+ \`\`\`
222
+
223
+ ---
224
+
225
+ ## Troubleshooting
226
+
227
+ ### "No plugin registered with ID: xxx"
228
+ The plugin is not registered. Check the plugin ID spelling against \`knowledgine plugins list\`.
229
+
230
+ ### "GITHUB_TOKEN not set"
231
+ Set the \`GITHUB_TOKEN\` environment variable before running the github or cicd plugin.
232
+
233
+ ### "Repository not found"
234
+ Verify the \`--repo\` flag uses \`owner/repo\` format and that your token has access to the repo.
235
+
236
+ ### Ingest produced 0 notes
237
+ - Confirm the \`--path\` points to the correct directory
238
+ - For git-history: ensure the path contains a .git directory
239
+ - For obsidian: ensure the path contains .md files
240
+ - Try \`--full\` to reset the cursor and reprocess all content
241
+ `,
242
+ };
243
+ //# sourceMappingURL=references.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"references.js","sourceRoot":"","sources":["../../../../src/templates/skills/knowledgine-ingest/references.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,UAAU,GAA2B;IAChD,iBAAiB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuJpB;IAEC,iBAAiB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuFpB;CACA,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const SKILL_MD = "---\nname: knowledgine-ingest\ndescription: >\n Import knowledge from external sources into the local knowledge base. Invoke when\n the user wants to import from Git commit history, GitHub PRs and issues, Obsidian\n vaults, Claude or Cursor session histories, or CI/CD pipelines. Each source requires\n a specific plugin and configuration.\n---\n# knowledgine-ingest\n\n## Purpose\n\nPopulate the knowledge base from external knowledge repositories \u2014 version control\nhistory, issue trackers, personal note systems, AI session logs \u2014 without manual\ncapture. Ingestion enriches the knowledge base with historical context that predates\nthe current session.\n\n## When to Use\n\n- **Onboarding to a codebase** \u2014 Ingest Git history to capture past decisions\n- **Integrating GitHub knowledge** \u2014 Import PRs and issues for context\n- **Importing Obsidian notes** \u2014 Bring personal or team notes into the knowledge base\n- **Capturing AI session history** \u2014 Import Claude or Cursor session logs\n- **Building CI knowledge** \u2014 Import CI/CD pipeline outcomes and patterns\n- **User explicitly requests import** \u2014 \"Load my notes from Obsidian\"\n\n## When NOT to Use\n\n- When the source has already been fully ingested in this session (check cursor state)\n- When the user has not configured the required credentials (e.g., GITHUB_TOKEN)\n\n## How to Ingest (CLI)\n\n```bash\n# Run a specific plugin\nknowledgine ingest --source <plugin-id> --path <knowledge-base-path>\n\n# Run all registered plugins\nknowledgine ingest --all --path <knowledge-base-path>\n\n# Force full re-ingest (ignore stored cursor)\nknowledgine ingest --source <plugin-id> --full --path <knowledge-base-path>\n\n# GitHub-specific (requires GITHUB_TOKEN env var)\nknowledgine ingest --source github --repo owner/repo --path <path>\n```\n\n## Available Source Plugins\n\n| Plugin ID | Source | Notes |\n|-----------|--------|-------|\n| `markdown` | Local markdown files | Default; used by `knowledgine init` |\n| `git-history` | Git commit messages and diffs | Extracts decisions from commit history |\n| `github` | GitHub PRs and issues | Requires `GITHUB_TOKEN` env var |\n| `obsidian` | Obsidian vault notes | Reads from configured vault path |\n| `claude-sessions` | Claude Code session logs | Imports past AI session context |\n| `cursor-sessions` | Cursor IDE session history | Imports Cursor session context |\n| `cicd` | CI/CD pipeline results | GitHub Actions, build outcomes |\n\n## Step-by-Step Instructions\n\n1. **Identify the source** \u2014 Which external system contains the knowledge to import?\n2. **Check prerequisites** \u2014 Does the plugin need credentials or configuration? (see plugin-guide.md)\n3. **Run the ingest command** \u2014 Use the appropriate plugin ID and options\n4. **Verify results** \u2014 Run `knowledgine status` or search to confirm notes were imported\n5. **Re-ingest if needed** \u2014 Use `--full` flag to re-process already-seen content\n\n## Best Practices\n\n- Run `git-history` ingest when starting work on a new repository\n- Set `GITHUB_TOKEN` before ingesting GitHub content to avoid rate limiting\n- Use `--full` flag after changing ingest configuration\n- Check `knowledgine plugins status` to see the last ingest cursor for each plugin\n\n## Reference Files\n\n- See `plugin-guide.md` for detailed documentation on each plugin\n- See `source-types.md` for configuration requirements for each source type\n";
2
+ //# sourceMappingURL=skill-md.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skill-md.d.ts","sourceRoot":"","sources":["../../../../src/templates/skills/knowledgine-ingest/skill-md.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,QAAQ,q5GA8EpB,CAAC"}