@kentwynn/kgraph 0.1.9 → 0.1.11

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.
@@ -14,10 +14,27 @@ Before exploring the repository, run \`kgraph context "<topic>"\` to load existi
14
14
  1. Infer the topic from the user's request.
15
15
  2. Run \`kgraph context "<topic>"\`.
16
16
  3. Use the returned files, symbols, relationships, and cognition before broad exploration.
17
- 4. Save durable discoveries to \`.kgraph/inbox/\` and immediately run \`kgraph update\`.
17
+ 4. **After completing the work**, always write a Markdown note to \`.kgraph/inbox/<slug>.md\` capturing what was built or changed, which files and symbols were touched, and any decisions made. Then immediately run \`kgraph update\`.
18
18
  5. If you created, moved, deleted, or renamed files or symbols during this session, run \`kgraph scan\` and report the summary. Skip it otherwise.
19
19
  6. Run \`kgraph visualize\` when the user wants to inspect the dependency graph — opens an interactive graph at http://localhost:4242 with PNG export.
20
20
  7. Run \`kgraph history\` to review the timeline of past cognition sessions with git author attribution.
21
+
22
+ The inbox note must use this structure:
23
+ \`\`\`markdown
24
+ # <Short Title>
25
+
26
+ ## Summary
27
+ One or two sentences describing what was done.
28
+
29
+ ## Key Files
30
+ - \`path/to/file.ts\` — what it does
31
+
32
+ ## Key Symbols
33
+ - \`FunctionName\` — what it does
34
+
35
+ ## Decisions
36
+ Any architectural or implementation decisions made.
37
+ \`\`\`
21
38
  `,
22
39
  },
23
40
  {
@@ -21,10 +21,27 @@ Workflow:
21
21
  1. Infer the current topic from the user request.
22
22
  2. Run \`kgraph context "<topic>"\` before broad repo exploration.
23
23
  3. Use KGraph's returned files, symbols, relationships, and cognition as navigation hints.
24
- 4. After durable discoveries, write a concise Markdown note to \`.kgraph/inbox/\` and immediately run \`kgraph update\`.
24
+ 4. **After completing the work**, always write a Markdown note to \`.kgraph/inbox/<slug>.md\` capturing what was built or changed, which files and symbols were touched, and any decisions made. Then immediately run \`kgraph update\`.
25
25
  5. If you created, moved, deleted, or renamed files or symbols during this session, run \`kgraph scan\`. Skip it otherwise.
26
26
  6. Run \`kgraph visualize\` when the user wants to inspect the dependency graph — opens an interactive graph at http://localhost:4242 with PNG export.
27
27
  7. Run \`kgraph history\` to review the timeline of past cognition sessions with git author attribution.
28
+
29
+ The inbox note must use this structure:
30
+ \`\`\`markdown
31
+ # <Short Title>
32
+
33
+ ## Summary
34
+ One or two sentences describing what was done.
35
+
36
+ ## Key Files
37
+ - \`path/to/file.ts\` — what it does
38
+
39
+ ## Key Symbols
40
+ - \`FunctionName\` — what it does
41
+
42
+ ## Decisions
43
+ Any architectural or implementation decisions made.
44
+ \`\`\`
28
45
  `,
29
46
  },
30
47
  ],
@@ -4,30 +4,28 @@ export const copilotAdapter = {
4
4
  targetPath: '.github/copilot-instructions.md',
5
5
  instructions: `## KGraph Workflow
6
6
 
7
- Before exploring the repository, run \`kgraph context "<topic>"\` to load existing repo intelligence.
8
- After durable discoveries (architecture decisions, debugging insights, structural findings), write a concise Markdown note to \`.kgraph/inbox/\` and immediately run \`kgraph update\`.
9
- If you created, moved, deleted, or renamed files or symbols, run \`kgraph scan\`.
10
- Use /kgraph for the full automated workflow. Use /kgraph-scan, /kgraph-update, /kgraph-visualize, and /kgraph-history for manual steps.
11
- `,
12
- commandFiles: [
13
- {
14
- path: '.github/prompts/kgraph.prompt.md',
15
- content: `---
16
- description: Use KGraph persistent repo intelligence for the current coding task
17
- agent: agent
18
- ---
7
+ 1. **Before exploring the repository**, run \`kgraph context "<topic>"\` to load existing repo intelligence. Use the returned files, symbols, and cognition before any broad exploration.
8
+ 2. **After every meaningful implementation or discovery session**, write a Markdown note to \`.kgraph/inbox/<slug>.md\` capturing what was built, which files were touched, which symbols matter, and any decisions made. Then immediately run \`kgraph update\`.
9
+ 3. If you created, moved, deleted, or renamed files or symbols, run \`kgraph scan\`.
19
10
 
20
- Use KGraph persistent repo intelligence for the current request.
11
+ The inbox note must use this structure:
12
+ \`\`\`markdown
13
+ # <Short Title>
21
14
 
22
- 1. Infer the topic from the user's request.
23
- 2. Run \`kgraph context "<topic>"\`.
24
- 3. Use the returned files, symbols, relationships, and cognition before broad exploration.
25
- 4. After durable discoveries, write a concise Markdown note to \`.kgraph/inbox/\` and immediately run \`kgraph update\`.
26
- 5. If you created, moved, deleted, or renamed files or symbols during this session, run \`kgraph scan\`. Skip it otherwise.
27
- 6. Run \`kgraph visualize\` when the user wants to inspect the dependency graph — opens an interactive graph at http://localhost:4242 with PNG export.
28
- 7. Run \`kgraph history\` to review the timeline of past cognition sessions with git author attribution.
15
+ ## Summary
16
+ One or two sentences describing what was done.
17
+
18
+ ## Key Files
19
+ - \`path/to/file.ts\` what it does
20
+
21
+ ## Key Symbols
22
+ - \`FunctionName\` — what it does
23
+
24
+ ## Decisions
25
+ Any architectural or implementation decisions made.
26
+ \`\`\`
29
27
  `,
30
- },
28
+ commandFiles: [
31
29
  {
32
30
  path: '.github/prompts/kgraph-scan.prompt.md',
33
31
  content: `---
@@ -56,6 +54,38 @@ agent: agent
56
54
  ---
57
55
 
58
56
  Run \`kgraph visualize\` to start the interactive dependency graph at http://localhost:4242, then summarize what nodes and connections are visible.
57
+ `,
58
+ },
59
+ {
60
+ path: '.github/prompts/kgraph-capture.prompt.md',
61
+ content: `---
62
+ description: Save what was just built or changed into KGraph cognition
63
+ agent: agent
64
+ argument-hint: "Brief description of what was done"
65
+ ---
66
+
67
+ Capture this session into KGraph cognition.
68
+
69
+ 1. Write a Markdown note to \`.kgraph/inbox/<slug>.md\` using the structure below. Use the user's message as the summary if provided.
70
+ 2. Immediately run \`kgraph update\`.
71
+ 3. If files or symbols were created, moved, deleted, or renamed, also run \`kgraph scan\`.
72
+
73
+ Note structure:
74
+ \`\`\`markdown
75
+ # <Short Title>
76
+
77
+ ## Summary
78
+ One or two sentences describing what was done.
79
+
80
+ ## Key Files
81
+ - \`path/to/file.ts\` — what it does
82
+
83
+ ## Key Symbols
84
+ - \`FunctionName\` — what it does
85
+
86
+ ## Decisions
87
+ Any architectural or implementation decisions made.
88
+ \`\`\`
59
89
  `,
60
90
  },
61
91
  {
@@ -69,5 +99,5 @@ Run \`kgraph history\` to display the timeline of all processed cognition sessio
69
99
  `,
70
100
  },
71
101
  ],
72
- obsoleteCommandFiles: [],
102
+ obsoleteCommandFiles: ['.github/prompts/kgraph.prompt.md'],
73
103
  };
@@ -9,8 +9,8 @@ alwaysApply: true
9
9
 
10
10
  ## KGraph Workflow
11
11
 
12
- - Before exploring the repository, run \`kgraph context "<topic>"\` to load existing repo intelligence.
13
- - After durable discoveries (architecture decisions, debugging insights, structural findings), write a concise Markdown note to \`.kgraph/inbox/\` and immediately run \`kgraph update\`.
12
+ - **Before exploring the repository**, run \`kgraph context "<topic>"\` to load existing repo intelligence. Use the returned files, symbols, and cognition before any broad exploration.
13
+ - **After every meaningful implementation or discovery session**, write a Markdown note to \`.kgraph/inbox/<slug>.md\` (title, Key Files, Key Symbols, Decisions sections) and immediately run \`kgraph update\`.
14
14
  - If you created, moved, deleted, or renamed files or symbols, run \`kgraph scan\`.
15
15
  - Run \`kgraph visualize\` to open the interactive dependency graph at http://localhost:4242 with PNG export.
16
16
  - Run \`kgraph history\` to review the timeline of past cognition sessions with git author attribution.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kentwynn/kgraph",
3
- "version": "0.1.9",
3
+ "version": "0.1.11",
4
4
  "description": "Persistent repo intelligence for AI coding assistants.",
5
5
  "type": "module",
6
6
  "bin": {