skillwiki 0.2.1-beta.1 → 0.2.1-beta.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/dist/cli.js CHANGED
@@ -878,6 +878,10 @@ function hasOrphanedCitations(body) {
878
878
  }
879
879
  return false;
880
880
  }
881
+ function hasWikilinkCitations(body) {
882
+ const stripped = stripFences(body);
883
+ return /\[\[raw\/[^\]]+\]\]/.test(stripped);
884
+ }
881
885
 
882
886
  // src/commands/audit.ts
883
887
  async function runAudit(input) {
@@ -1704,7 +1708,7 @@ function hasDuplicateFrontmatter(body) {
1704
1708
  }
1705
1709
  var ERROR_ORDER = ["broken_wikilinks", "invalid_frontmatter", "raw_dedup", "tag_not_in_taxonomy"];
1706
1710
  var WARNING_ORDER = ["index_incomplete", "index_link_format", "stale_page", "page_too_large", "log_rotate_needed", "orphans", "legacy_citation_style", "orphaned_citations", "duplicate_frontmatter", "missing_overview"];
1707
- var INFO_ORDER = ["bridges", "page_structure", "topic_map_recommended", "frontmatter_wikilink"];
1711
+ var INFO_ORDER = ["bridges", "page_structure", "topic_map_recommended", "frontmatter_wikilink", "wikilink_citation"];
1708
1712
  async function runLint(input) {
1709
1713
  const buckets = {};
1710
1714
  const links = await runLinks({ vault: input.vault });
@@ -1757,6 +1761,7 @@ async function runLint(input) {
1757
1761
  const dupFrontmatter = [];
1758
1762
  const noOverview = [];
1759
1763
  const fmWikilinkFlags = [];
1764
+ const wikilinkCitationFlags = [];
1760
1765
  for (const page of scan.data.typedKnowledge) {
1761
1766
  const text = await readPage(page);
1762
1767
  const split = splitFrontmatter(text);
@@ -1766,6 +1771,7 @@ async function runLint(input) {
1766
1771
  if (hasDuplicateFrontmatter(body)) dupFrontmatter.push(page.relPath);
1767
1772
  if (isLegacyCitationStyle(body)) legacyPages.push(page.relPath);
1768
1773
  if (hasOrphanedCitations(body)) orphanedPages.push(page.relPath);
1774
+ if (hasWikilinkCitations(body)) wikilinkCitationFlags.push(page.relPath);
1769
1775
  const fmLinks = rawFm.match(/\[\[([^\[\]|]+)(?:\|[^\[\]]*)?\]\]/g) ?? [];
1770
1776
  for (const link of fmLinks) {
1771
1777
  const target = link.replace(/^\[\[/, "").replace(/(?:\|[^\[\]]*)?\]\]$/, "").trim();
@@ -1794,6 +1800,7 @@ async function runLint(input) {
1794
1800
  if (dupFrontmatter.length > 0) buckets.duplicate_frontmatter = dupFrontmatter;
1795
1801
  if (noOverview.length > 0) buckets.missing_overview = noOverview;
1796
1802
  if (fmWikilinkFlags.length > 0) buckets.frontmatter_wikilink = fmWikilinkFlags;
1803
+ if (wikilinkCitationFlags.length > 0) buckets.wikilink_citation = wikilinkCitationFlags;
1797
1804
  }
1798
1805
  const errorOut = ERROR_ORDER.flatMap((k) => buckets[k] ? [{ kind: k, items: buckets[k] }] : []);
1799
1806
  const warningOut = WARNING_ORDER.flatMap((k) => buckets[k] ? [{ kind: k, items: buckets[k] }] : []);
package/package.json CHANGED
@@ -1,7 +1,6 @@
1
1
  {
2
2
  "name": "skillwiki",
3
- "version": "0.2.1-beta.1",
4
- "version": "0.2.1-beta.1",
3
+ "version": "0.2.1-beta.3",
5
4
  "type": "module",
6
5
  "bin": {
7
6
  "skillwiki": "dist/cli.js"
@@ -1,9 +1,8 @@
1
1
  {
2
2
  "name": "skillwiki",
3
- "version": "0.2.1-beta.1",
4
- "version": "0.2.1-beta.1",
3
+ "version": "0.2.1-beta.3",
5
4
  "skills": "./",
6
- "description": "Project-aware Karpathy-style knowledge base for Claude Code: 11 prompt-only skills (wiki-*, proj-*, using-skillwiki) backed by the deterministic `skillwiki` CLI (8 subcommands, JSON-by-default).",
5
+ "description": "Project-aware Karpathy-style knowledge base for Claude Code: 15 prompt-only skills (wiki-*, proj-*, using-skillwiki) backed by the deterministic `skillwiki` CLI.",
7
6
  "author": {
8
7
  "name": "karlorz",
9
8
  "url": "https://github.com/karlorz"
@@ -1,7 +1,6 @@
1
1
  {
2
2
  "name": "@skillwiki/skills",
3
- "version": "0.2.1-beta.1",
4
- "version": "0.2.1-beta.1",
3
+ "version": "0.2.1-beta.3",
5
4
  "private": true,
6
5
  "files": [
7
6
  "wiki-*",
@@ -20,6 +20,7 @@ Invoke a skillwiki skill when the user:
20
20
  - Wants a health check or lint on their vault
21
21
  - Mentions crystallizing a session into a note
22
22
  - Talks about project workspaces, ADRs, or distillation
23
+ - Wants to quickly capture an idea, bug, task, or note without interrupting their workflow
23
24
  - Wants to archive or clean up old vault pages
24
25
  - Needs to detect source drift or re-ingest updated content
25
26
  - Has a spec/plan in a non-skillwiki format (CodeStable, RFC, AIDE)
@@ -27,15 +28,15 @@ Invoke a skillwiki skill when the user:
27
28
 
28
29
  ## Vault Structure
29
30
 
30
- A skillwiki vault has two layers:
31
+ A skillwiki vault has three layers. The canonical architecture lives in `SCHEMA.md` at the vault root — read it before creating any new directories.
31
32
 
32
- **Layer 1 — Raw (`raw/`):** Immutable source material. Never modify after ingest.
33
+ **Layer 1 — Raw (`raw/`):** Immutable source material. Never modify after ingest. `raw/transcripts/` doubles as the ad-hoc capture point for meeting notes and unprocessed ideas.
33
34
 
34
35
  ```
35
36
  raw/
36
37
  ├── articles/ # Web articles, clippings
37
38
  ├── papers/ # PDFs, arxiv papers
38
- ├── transcripts/ # Meeting notes, interviews
39
+ ├── transcripts/ # Meeting notes, interviews, ad-hoc captures
39
40
  └── assets/ # Images, diagrams referenced by sources
40
41
  ```
41
42
 
@@ -48,7 +49,11 @@ sha256: # computed by skillwiki hash over body bytes after closing ---
48
49
  ---
49
50
  ```
50
51
 
51
- **Layer 2 — Agent-owned pages:** `entities/`, `concepts/`, `comparisons/`, `queries/`, `meta/`, `projects/`. Citations use `^[raw/articles/source-file.md]` markers at paragraph-end.
52
+ **Layer 2 — Typed Knowledge:** `entities/`, `concepts/`, `comparisons/`, `queries/`, `meta/`. Agent-owned pages with `^[raw/...]` citation markers at paragraph-end. Global scope — project association via `provenance_projects:` frontmatter, not directory nesting.
53
+
54
+ **Layer 3 — Project Workspaces (`projects/{slug}/`):** Per-project lifecycle directories with `work/` (spec + plan + retro), `compound/` (distilled lessons/patterns), `architecture/` (ADRs), and `history/` (archived specs/plans).
55
+
56
+ **No `inbox/` directory.** Ad-hoc captures go to `raw/transcripts/` or directly into a project work item via `proj-work`. Do not invent new top-level directories — extend Layer 2 via SCHEMA.md tag taxonomy if needed.
52
57
 
53
58
  ## Skill Map
54
59
 
@@ -62,6 +67,7 @@ sha256: # computed by skillwiki hash over body bytes after closing ---
62
67
  | `wiki-audit` | Verify raw provenance references and source frontmatter integrity |
63
68
  | `wiki-archive` | Archive a typed-knowledge page — move to `_archive/`, remove from index |
64
69
  | `wiki-reingest` | Detect drift in raw sources (sha256 comparison) and re-ingest updated content |
70
+ | `wiki-add-task` | Quick-capture ideas, bugs, tasks, notes into `raw/transcripts/` without leaving the current workflow |
65
71
  | `wiki-adapter-prd` | Map foreign PRD formats (CodeStable, RFC, AIDE, Hermes) into vault pages |
66
72
  | `proj-init` | Bootstrap a project workspace (README, requirements, architecture) |
67
73
  | `proj-work` | Open or run a work item under a project's work/ directory |
@@ -0,0 +1,74 @@
1
+ ---
2
+ name: wiki-add-task
3
+ description: Capture ad-hoc ideas, bugs, tasks, or notes into the vault without leaving the current workflow.
4
+ ---
5
+
6
+ # wiki-add-task
7
+
8
+ Quick-capture skill for ad-hoc ideas, bugs, tasks, and notes. Writes directly to `raw/transcripts/` — the vault's designated ad-hoc capture point (Layer 1). No new directories or inbox folders needed.
9
+
10
+ ## When This Skill Activates
11
+
12
+ - User wants to quickly jot down an idea, bug, task, or note without interrupting their current workflow.
13
+ - User says "add task", "capture this", "note this", "remember this", "log this idea", or similar.
14
+ - User provides a short text description and optionally a type tag.
15
+
16
+ ## Output language
17
+
18
+ Run `skillwiki lang` at the start. Entry prose and `--human` summaries use the resolved language. Frontmatter keys, file names, and structural markers stay English.
19
+
20
+ ## Steps
21
+
22
+ 0. **Resolve vault and language.** Run `skillwiki path` (fail if NO_VAULT_CONFIGURED) and `skillwiki lang`.
23
+ 1. **Parse arguments.** Extract from the user's message:
24
+ - `text` — the idea/bug/task/note content (required)
25
+ - `type` — one of: `idea`, `bug`, `task`, `note` (default: `idea`)
26
+ - `project` — optional project slug to cross-reference (e.g., `llm-wiki`)
27
+ 2. **Determine target file.** The capture file is `raw/transcripts/YYYY-MM-DD-ad-hoc-captures.md` where YYYY-MM-DD is today's date. If the file exists, append; otherwise create it with standard raw frontmatter.
28
+ 3. **Write the entry.** Append to the capture file:
29
+ ```markdown
30
+ ### HH:MM — [type]
31
+
32
+ [text]
33
+
34
+ <!---meta: {"captured_at": "YYYY-MM-DDTHH:MM:SS", "type": "[type]"}--->
35
+ ```
36
+ - Use 24-hour time for HH:MM.
37
+ - Do not overwrite or modify existing entries.
38
+ 4. **Cross-reference (optional).** If a `project` slug was provided:
39
+ - Check that `projects/{slug}/` exists in the vault.
40
+ - Append a one-line reference to the project's work log or compound notes:
41
+ `- [YYYY-MM-DD] capture: [text] → raw/transcripts/YYYY-MM-DD-ad-hoc-captures.md`
42
+ - Do NOT create a full work item (that's `proj-work`'s job).
43
+ 5. **Update log.md.** Append: `## [YYYY-MM-DD] capture | [type]: [text (first 60 chars)]`
44
+ 6. **Confirm to user.** Report what was captured and where. Suggest next steps:
45
+ - If `type: idea` → "Consider ingesting related sources to develop this idea."
46
+ - If `type: bug` → "Use proj-work to create a bug-fix work item."
47
+ - If `type: task` → "Use proj-work to track this task through the dev loop."
48
+ - If `type: note` → "Will be available for future wiki-query searches."
49
+
50
+ ## Ad-hoc captures file format
51
+
52
+ The file `raw/transcripts/YYYY-MM-DD-ad-hoc-captures.md` is a standard raw source with frontmatter:
53
+
54
+ ```yaml
55
+ ---
56
+ source_url:
57
+ ingested: YYYY-MM-DD
58
+ sha256:
59
+ ---
60
+ ```
61
+
62
+ The `sha256` is computed over the body after the closing `---`. On each append, recompute and update `sha256`. This keeps source-drift detection functional even though the file grows throughout the day.
63
+
64
+ ## Stop conditions
65
+
66
+ - `skillwiki path` returns NO_VAULT_CONFIGURED.
67
+ - No `text` provided (prompt user once, then stop).
68
+
69
+ ## Forbidden
70
+
71
+ - Creating an `inbox/` directory. All captures go to `raw/transcripts/`.
72
+ - Modifying existing entries in the captures file — only append.
73
+ - Creating a work item — this is capture-only. Use `proj-work` for full work items.
74
+ - Writing to any Layer 2 or Layer 3 location. Captures are Layer 1 (raw).