main
1{
2 "policies": [
3 {
4 "name": "ai-sessions-location",
5 "description": "Session files must go to unified AI storage, not old Claude paths",
6 "pathPattern": ".*/(claude|.claude)/history/sessions/.*\\.md$",
7 "blockedPaths": [
8 "~/.config/claude/history/sessions/",
9 "~/.claude/history/sessions/"
10 ],
11 "suggestedPath": "~/.local/share/ai/sessions/YYYY-MM/",
12 "action": "block",
13 "enabled": true
14 },
15 {
16 "name": "ai-sessions-format",
17 "description": "Session files must follow YYYY-MM-DD-description.md format",
18 "pathPattern": ".*/ai/sessions/.*\\.md$",
19 "requiredFilenameFormat": "^\\d{4}-\\d{2}-\\d{2}-[a-z0-9-]+\\.md$",
20 "formatDescription": "YYYY-MM-DD-description.md (lowercase, hyphens only)",
21 "formatExample": "2026-02-05-unified-ai-storage.md",
22 "action": "block",
23 "enabled": true
24 },
25 {
26 "name": "ai-plans-location",
27 "description": "Plan files must go to unified AI storage",
28 "pathPattern": ".*/(claude|.claude)/(history/)?plans/.*\\.md$",
29 "blockedPaths": [
30 "~/.config/claude/plans/",
31 "~/.claude/plans/",
32 "~/.config/claude/history/plans/"
33 ],
34 "suggestedPath": "~/.local/share/ai/plans/",
35 "action": "block",
36 "enabled": true
37 },
38 {
39 "name": "ai-plans-format",
40 "description": "Plan files must follow kebab-case.md format",
41 "pathPattern": ".*/ai/plans/.*\\.md$",
42 "requiredFilenameFormat": "^[a-z0-9-]+\\.md$",
43 "formatDescription": "kebab-case.md (lowercase, hyphens, no dates)",
44 "formatExample": "unified-ai-storage-implementation.md",
45 "action": "block",
46 "enabled": true
47 },
48 {
49 "name": "ai-learnings-location",
50 "description": "Learning files must go to unified AI storage",
51 "pathPattern": ".*/(claude|.claude)/history/learnings/.*\\.md$",
52 "blockedPaths": [
53 "~/.config/claude/history/learnings/"
54 ],
55 "suggestedPath": "~/.local/share/ai/learnings/YYYY-MM/",
56 "action": "block",
57 "enabled": true
58 },
59 {
60 "name": "ai-learnings-format",
61 "description": "Learning files must follow YYYY-MM-DD-description.md format",
62 "pathPattern": ".*/ai/learnings/.*\\.md$",
63 "requiredFilenameFormat": "^\\d{4}-\\d{2}-\\d{2}-[a-z0-9-]+\\.md$",
64 "formatDescription": "YYYY-MM-DD-description.md (lowercase, hyphens only)",
65 "formatExample": "2026-02-05-debugging-timezone-issues.md",
66 "action": "block",
67 "enabled": true
68 },
69 {
70 "name": "ai-research-location",
71 "description": "Research files must go to unified AI storage",
72 "pathPattern": ".*/(claude|.claude)/history/research/.*\\.md$",
73 "blockedPaths": [
74 "~/.config/claude/history/research/"
75 ],
76 "suggestedPath": "~/.local/share/ai/research/YYYY-MM/",
77 "action": "block",
78 "enabled": true
79 },
80 {
81 "name": "ai-research-format",
82 "description": "Research files must follow YYYY-MM-DD-description.md format",
83 "pathPattern": ".*/ai/research/.*\\.md$",
84 "requiredFilenameFormat": "^\\d{4}-\\d{2}-\\d{2}-[a-z0-9-]+\\.md$",
85 "formatDescription": "YYYY-MM-DD-description.md (lowercase, hyphens only)",
86 "formatExample": "2026-02-05-chrono-node-evaluation.md",
87 "action": "block",
88 "enabled": true
89 },
90 {
91 "name": "no-secrets-in-repos",
92 "description": "Prevent writing secrets to git repositories",
93 "filenamePattern": "\\.(env|pem|key|secret|credentials)$",
94 "blockedPaths": [
95 "~/src/*",
96 "~/projects/*"
97 ],
98 "action": "block",
99 "enabled": true
100 },
101 {
102 "name": "no-direct-org-edits",
103 "description": "Never write/edit .org files directly — use emacsclient or org_todo tool instead",
104 "filenamePattern": "\\.org$",
105 "blockedPaths": [
106 "~/desktop/org/*",
107 "~/desktop/org/notes/*"
108 ],
109 "action": "block",
110 "enabled": true
111 }
112 ]
113}