clawvault 1.10.1 → 1.10.2

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.
@@ -540,7 +540,8 @@ var Router = class {
540
540
  const filePath = path.join(categoryDir, `${item.date}.md`);
541
541
  const existing = fs.existsSync(filePath) ? fs.readFileSync(filePath, "utf-8").trim() : "";
542
542
  if (existing.includes(item.content)) return;
543
- const entry = `- ${item.priority} ${item.content}`;
543
+ const linkedContent = this.addWikiLinks(item.content);
544
+ const entry = `- ${item.priority} ${linkedContent}`;
544
545
  const header = existing ? "" : `# ${category} \u2014 ${item.date}
545
546
  `;
546
547
  const newContent = existing ? `${existing}
@@ -550,6 +551,160 @@ ${entry}
550
551
  `;
551
552
  fs.writeFileSync(filePath, newContent, "utf-8");
552
553
  }
554
+ /**
555
+ * Auto-link proper nouns and known entities with [[wiki-links]].
556
+ * Scans for capitalized names, project names, and tool names.
557
+ * Skips content already inside [[brackets]].
558
+ */
559
+ addWikiLinks(content) {
560
+ if (content.includes("[[")) return content;
561
+ const namePattern = /\b([A-Z][a-z]{2,}(?:\s+[A-Z][a-z]{2,})?)\b/g;
562
+ const skipWords = /* @__PURE__ */ new Set([
563
+ "The",
564
+ "This",
565
+ "That",
566
+ "These",
567
+ "Those",
568
+ "There",
569
+ "Then",
570
+ "Than",
571
+ "When",
572
+ "Where",
573
+ "What",
574
+ "Which",
575
+ "While",
576
+ "With",
577
+ "Would",
578
+ "Will",
579
+ "Should",
580
+ "Could",
581
+ "About",
582
+ "After",
583
+ "Before",
584
+ "Between",
585
+ "Because",
586
+ "Also",
587
+ "Always",
588
+ "Already",
589
+ "Another",
590
+ "Any",
591
+ "Each",
592
+ "Every",
593
+ "From",
594
+ "Have",
595
+ "Has",
596
+ "Had",
597
+ "Into",
598
+ "Just",
599
+ "Keep",
600
+ "Like",
601
+ "Made",
602
+ "Make",
603
+ "Many",
604
+ "More",
605
+ "Most",
606
+ "Much",
607
+ "Must",
608
+ "Need",
609
+ "Never",
610
+ "Next",
611
+ "None",
612
+ "Not",
613
+ "Now",
614
+ "Only",
615
+ "Other",
616
+ "Over",
617
+ "Same",
618
+ "Some",
619
+ "Such",
620
+ "Sure",
621
+ "Take",
622
+ "Them",
623
+ "They",
624
+ "Too",
625
+ "Under",
626
+ "Until",
627
+ "Upon",
628
+ "Very",
629
+ "Want",
630
+ "Were",
631
+ "Work",
632
+ "Yet",
633
+ "Decision",
634
+ "Error",
635
+ "Deadline",
636
+ "Friday",
637
+ "Monday",
638
+ "Tuesday",
639
+ "Wednesday",
640
+ "Thursday",
641
+ "Saturday",
642
+ "Sunday",
643
+ "January",
644
+ "February",
645
+ "March",
646
+ "April",
647
+ "May",
648
+ "June",
649
+ "July",
650
+ "August",
651
+ "September",
652
+ "October",
653
+ "November",
654
+ "December",
655
+ "Today",
656
+ "Tomorrow",
657
+ "Yesterday",
658
+ "Message",
659
+ "Feature",
660
+ "Session",
661
+ "Update",
662
+ "System",
663
+ "User",
664
+ "Processed",
665
+ "Working",
666
+ "Built",
667
+ "Deployed",
668
+ "Discussed",
669
+ "Talked",
670
+ "Mentioned",
671
+ "Requested",
672
+ "Asked",
673
+ "Said"
674
+ ]);
675
+ const knownEntities = /* @__PURE__ */ new Set([
676
+ "PostgreSQL",
677
+ "MongoDB",
678
+ "Railway",
679
+ "Vercel",
680
+ "React",
681
+ "Vue",
682
+ "Svelte",
683
+ "Express",
684
+ "NestJS",
685
+ "Prisma",
686
+ "Docker",
687
+ "Kubernetes",
688
+ "Redis",
689
+ "GraphQL",
690
+ "Stripe",
691
+ "ClawVault",
692
+ "OpenClaw",
693
+ "GitHub",
694
+ "Obsidian"
695
+ ]);
696
+ return content.replace(namePattern, (match) => {
697
+ if (skipWords.has(match)) return match;
698
+ if (knownEntities.has(match)) return `[[${match}]]`;
699
+ if (/^[A-Z][a-z]+$/.test(match) && match.length >= 3) {
700
+ return `[[${match}]]`;
701
+ }
702
+ if (/^[A-Z][a-z]+ [A-Z][a-z]+$/.test(match)) {
703
+ return `[[${match}]]`;
704
+ }
705
+ return match;
706
+ });
707
+ }
553
708
  buildSummary(routed) {
554
709
  if (routed.length === 0) return "No items routed to vault categories.";
555
710
  const byCat = /* @__PURE__ */ new Map();
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  Observer,
3
3
  parseSessionFile
4
- } from "./chunk-SIDM2I2C.js";
4
+ } from "./chunk-CC7IJJ32.js";
5
5
 
6
6
  // src/commands/observe.ts
7
7
  import * as fs2 from "fs";
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  observeCommand,
3
3
  registerObserveCommand
4
- } from "../chunk-2MP4EHJ7.js";
5
- import "../chunk-SIDM2I2C.js";
4
+ } from "../chunk-GENGXU34.js";
5
+ import "../chunk-CC7IJJ32.js";
6
6
  export {
7
7
  observeCommand,
8
8
  registerObserveCommand
@@ -13,7 +13,7 @@ import {
13
13
  import {
14
14
  Observer,
15
15
  parseSessionFile
16
- } from "../chunk-SIDM2I2C.js";
16
+ } from "../chunk-CC7IJJ32.js";
17
17
 
18
18
  // src/commands/sleep.ts
19
19
  import * as fs from "fs";
package/dist/index.js CHANGED
@@ -41,13 +41,13 @@ import {
41
41
  SessionWatcher,
42
42
  observeCommand,
43
43
  registerObserveCommand
44
- } from "./chunk-2MP4EHJ7.js";
44
+ } from "./chunk-GENGXU34.js";
45
45
  import {
46
46
  Compressor,
47
47
  Observer,
48
48
  Reflector,
49
49
  parseSessionFile
50
- } from "./chunk-SIDM2I2C.js";
50
+ } from "./chunk-CC7IJJ32.js";
51
51
 
52
52
  // src/index.ts
53
53
  import * as fs from "fs";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clawvault",
3
- "version": "1.10.1",
3
+ "version": "1.10.2",
4
4
  "description": "ClawVault™ - 🐘 An elephant never forgets. Structured memory for OpenClaw agents. Context death resilience, Obsidian-compatible markdown, local semantic search.",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs",