exocortex-cli 0.1.0 → 13.92.6

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 (3) hide show
  1. package/README.md +146 -92
  2. package/dist/index.js +108 -105
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -2,6 +2,24 @@
2
2
 
3
3
  Command-line interface for Exocortex knowledge management system. Manage tasks, projects, and planning from the terminal without needing Obsidian.
4
4
 
5
+ ## API Stability
6
+
7
+ **Current Version: 0.1.x (Stable API)**
8
+
9
+ This CLI follows [Semantic Versioning](https://semver.org/). The commands documented below are considered **stable** and covered by versioning guarantees.
10
+
11
+ **Documentation:**
12
+ - [CLI API Reference](docs/CLI_API_REFERENCE.md) - Formal command signatures and options
13
+ - [Versioning Policy](VERSIONING.md) - What constitutes breaking changes
14
+ - [SPARQL Guide](docs/SPARQL_GUIDE.md) - Complete query reference
15
+ - [SPARQL Cookbook](docs/SPARQL_COOKBOOK.md) - Real-world query examples
16
+ - [Ontology Reference](docs/ONTOLOGY_REFERENCE.md) - Available predicates
17
+
18
+ **For MCP Integration:**
19
+ - Pin to `^0.1.0` for stable API access
20
+ - Use exit codes for status (not console messages)
21
+ - Use `--format json` for machine-readable output
22
+
5
23
  ## Installation
6
24
 
7
25
  ```bash
@@ -24,13 +42,8 @@ exocortex --help
24
42
 
25
43
  Execute SPARQL queries against your Obsidian vault as an RDF knowledge graph.
26
44
 
27
- **Documentation:**
28
- - [SPARQL Guide](docs/SPARQL_GUIDE.md) - Complete query reference
29
- - [SPARQL Cookbook](docs/SPARQL_COOKBOOK.md) - Real-world examples
30
- - [Ontology Reference](docs/ONTOLOGY_REFERENCE.md) - Available predicates
31
-
32
45
  ```bash
33
- exo query "SELECT ?s ?p ?o WHERE { ?s ?p ?o } LIMIT 10" --vault ~/vault
46
+ exocortex sparql query "SELECT ?s ?p ?o WHERE { ?s ?p ?o } LIMIT 10" --vault ~/vault
34
47
  ```
35
48
 
36
49
  **Options:**
@@ -45,7 +58,7 @@ exo query "SELECT ?s ?p ?o WHERE { ?s ?p ?o } LIMIT 10" --vault ~/vault
45
58
 
46
59
  ```bash
47
60
  # Find all tasks
48
- exo query \
61
+ exocortex sparql query \
49
62
  "PREFIX exo: <https://exocortex.my/ontology/exo#>
50
63
  PREFIX ems: <https://exocortex.my/ontology/ems#>
51
64
  SELECT ?task ?label
@@ -56,15 +69,15 @@ exo query \
56
69
  --vault ~/vault
57
70
 
58
71
  # Query from file
59
- exo query queries/my-query.sparql --vault ~/vault
72
+ exocortex sparql query queries/my-query.sparql --vault ~/vault
60
73
 
61
74
  # JSON output for automation
62
- exo query "SELECT ?s ?p ?o WHERE { ?s ?p ?o }" \
75
+ exocortex sparql query "SELECT ?s ?p ?o WHERE { ?s ?p ?o }" \
63
76
  --vault ~/vault \
64
77
  --format json > results.json
65
78
 
66
79
  # Show query plan and stats
67
- exo query "SELECT ?task WHERE { ?task exo:Instance_class ems:Task }" \
80
+ exocortex sparql query "SELECT ?task WHERE { ?task exo:Instance_class ems:Task }" \
68
81
  --vault ~/vault \
69
82
  --explain \
70
83
  --stats
@@ -90,92 +103,82 @@ exo query "SELECT ?task WHERE { ?task exo:Instance_class ems:Task }" \
90
103
  └────────────────────────────────────────────────────────────┘
91
104
  ```
92
105
 
93
- ### Create Task
106
+ ### Command Execution
94
107
 
95
- Create a new task from an area or project:
108
+ Execute plugin commands on single assets. All commands follow the pattern:
96
109
 
97
110
  ```bash
98
- exocortex create task \
99
- --source ~/vault/areas/work.md \
100
- --label "Implement feature X" \
101
- --size small \
102
- --root ~/vault
111
+ exocortex command <command-name> <filepath> [options]
103
112
  ```
104
113
 
105
- **Options:**
106
- - `-s, --source <path>` - Path to source file (area or project) **[required]**
107
- - `-l, --label <label>` - Task label
108
- - `--size <size>` - Task size (small, medium, large)
109
- - `-r, --root <path>` - Root directory of vault (default: current directory)
114
+ **Common Options:**
115
+ - `--vault <path>` - Path to Obsidian vault (default: current directory)
116
+ - `--dry-run` - Preview changes without modifying files
117
+
118
+ See [CLI API Reference](docs/CLI_API_REFERENCE.md) for complete command documentation.
110
119
 
111
- **Example:**
120
+ #### Status Commands
112
121
 
113
122
  ```bash
114
- cd ~/my-vault
115
- exocortex create task -s areas/product.md -l "Design mockups" --size medium
116
- ```
123
+ # Start a task (ToDo → Doing)
124
+ exocortex command start "tasks/my-task.md" --vault ~/vault
117
125
 
118
- ### Create Instance
126
+ # Complete a task (Doing → Done)
127
+ exocortex command complete "tasks/my-task.md" --vault ~/vault
119
128
 
120
- Create an instance from a task or meeting prototype:
129
+ # Move to backlog
130
+ exocortex command move-to-backlog "tasks/defer-task.md" --vault ~/vault
121
131
 
122
- ```bash
123
- exocortex create instance \
124
- --prototype ~/vault/prototypes/weekly-review.md \
125
- --label "Weekly Review 2025-10-26" \
126
- --root ~/vault
127
- ```
128
-
129
- **Options:**
130
- - `-p, --prototype <path>` - Path to prototype file **[required]**
131
- - `-l, --label <label>` - Instance label
132
- - `--size <size>` - Task size (for task instances)
133
- - `-r, --root <path>` - Root directory of vault (default: current directory)
132
+ # Move to ToDo
133
+ exocortex command move-to-todo "tasks/ready-task.md" --vault ~/vault
134
134
 
135
- **Example:**
135
+ # Trash a task
136
+ exocortex command trash "tasks/obsolete-task.md" --vault ~/vault
136
137
 
137
- ```bash
138
- exocortex create instance -p prototypes/standup.md -l "Daily Standup"
138
+ # Archive a task
139
+ exocortex command archive "tasks/old-task.md" --vault ~/vault
139
140
  ```
140
141
 
141
- ### Change Status
142
-
143
- Move a task to ToDo status:
142
+ #### Creation Commands
144
143
 
145
144
  ```bash
146
- exocortex status todo \
147
- --task ~/vault/tasks/abc-123.md \
148
- --root ~/vault
149
- ```
145
+ # Create a new task
146
+ exocortex command create-task "tasks/new-task.md" \
147
+ --label "Implement feature X" \
148
+ --area "areas/product" \
149
+ --vault ~/vault
150
150
 
151
- **Options:**
152
- - `-t, --task <path>` - Path to task file **[required]**
153
- - `-r, --root <path>` - Root directory of vault (default: current directory)
151
+ # Create a new meeting
152
+ exocortex command create-meeting "meetings/standup.md" \
153
+ --label "Daily Standup $(date +%Y-%m-%d)" \
154
+ --prototype "prototypes/standup-template" \
155
+ --vault ~/vault
154
156
 
155
- **Example:**
157
+ # Create a new project
158
+ exocortex command create-project "projects/website-redesign.md" \
159
+ --label "Website Redesign Q1 2026" \
160
+ --vault ~/vault
156
161
 
157
- ```bash
158
- exocortex status todo -t tasks/feature-implementation.md
162
+ # Create a new area
163
+ exocortex command create-area "areas/product.md" \
164
+ --label "Product Development" \
165
+ --vault ~/vault
159
166
  ```
160
167
 
161
- ### Plan Task
162
-
163
- Plan a task for today:
168
+ #### Property Commands
164
169
 
165
170
  ```bash
166
- exocortex plan today \
167
- --task ~/vault/tasks/abc-123.md \
168
- --root ~/vault
169
- ```
171
+ # Rename file to match its UID
172
+ exocortex command rename-to-uid "tasks/My Task Name.md" --vault ~/vault
170
173
 
171
- **Options:**
172
- - `-t, --task <path>` - Path to task file **[required]**
173
- - `-r, --root <path>` - Root directory of vault (default: current directory)
174
+ # Update asset label
175
+ exocortex command update-label "tasks/task.md" --label "New Label" --vault ~/vault
174
176
 
175
- **Example:**
177
+ # Schedule task for a date
178
+ exocortex command schedule "tasks/feature.md" --date "2025-12-15" --vault ~/vault
176
179
 
177
- ```bash
178
- exocortex plan today -t tasks/write-documentation.md
180
+ # Set deadline
181
+ exocortex command set-deadline "tasks/feature.md" --date "2025-12-31" --vault ~/vault
179
182
  ```
180
183
 
181
184
  ## Workflow Examples
@@ -183,31 +186,62 @@ exocortex plan today -t tasks/write-documentation.md
183
186
  ### Morning Planning
184
187
 
185
188
  ```bash
186
- # Plan high-priority tasks for today
187
- exocortex plan today -t tasks/task1.md
188
- exocortex plan today -t tasks/task2.md
189
- exocortex plan today -t tasks/task3.md
189
+ # Schedule tasks for today
190
+ exocortex command schedule "tasks/task1.md" --date "$(date +%Y-%m-%d)" --vault ~/vault
191
+ exocortex command schedule "tasks/task2.md" --date "$(date +%Y-%m-%d)" --vault ~/vault
190
192
 
191
193
  # Move them to ToDo
192
- exocortex status todo -t tasks/task1.md
193
- exocortex status todo -t tasks/task2.md
194
- exocortex status todo -t tasks/task3.md
194
+ exocortex command move-to-todo "tasks/task1.md" --vault ~/vault
195
+ exocortex command move-to-todo "tasks/task2.md" --vault ~/vault
195
196
  ```
196
197
 
197
198
  ### Creating Tasks from Project
198
199
 
199
200
  ```bash
200
201
  # Create multiple tasks for a project
201
- exocortex create task -s projects/website-redesign.md -l "Update homepage" --size small
202
- exocortex create task -s projects/website-redesign.md -l "Redesign navigation" --size medium
203
- exocortex create task -s projects/website-redesign.md -l "Test on mobile" --size small
202
+ exocortex command create-task "tasks/update-homepage.md" \
203
+ --label "Update homepage" \
204
+ --parent "projects/website-redesign" \
205
+ --vault ~/vault
206
+
207
+ exocortex command create-task "tasks/redesign-nav.md" \
208
+ --label "Redesign navigation" \
209
+ --parent "projects/website-redesign" \
210
+ --vault ~/vault
211
+
212
+ exocortex command create-task "tasks/test-mobile.md" \
213
+ --label "Test on mobile" \
214
+ --parent "projects/website-redesign" \
215
+ --vault ~/vault
204
216
  ```
205
217
 
206
218
  ### Weekly Review Workflow
207
219
 
208
220
  ```bash
209
- # Create this week's review instance
210
- exocortex create instance -p prototypes/weekly-review.md -l "Weekly Review $(date +%Y-%m-%d)"
221
+ # Create this week's review meeting
222
+ exocortex command create-meeting "meetings/weekly-review-$(date +%Y-%m-%d).md" \
223
+ --label "Weekly Review $(date +%Y-%m-%d)" \
224
+ --prototype "prototypes/weekly-review-template" \
225
+ --vault ~/vault
226
+ ```
227
+
228
+ ### Task Lifecycle
229
+
230
+ ```bash
231
+ # 1. Create task
232
+ exocortex command create-task "tasks/feature.md" --label "Implement feature" --vault ~/vault
233
+
234
+ # 2. Move to ToDo when ready
235
+ exocortex command move-to-todo "tasks/feature.md" --vault ~/vault
236
+
237
+ # 3. Start working
238
+ exocortex command start "tasks/feature.md" --vault ~/vault
239
+
240
+ # 4. Complete when done
241
+ exocortex command complete "tasks/feature.md" --vault ~/vault
242
+
243
+ # 5. Archive for cleanup
244
+ exocortex command archive "tasks/feature.md" --vault ~/vault
211
245
  ```
212
246
 
213
247
  ## Architecture
@@ -298,19 +332,39 @@ ems__Effort_status: "[[ems__EffortStatusDraft]]"
298
332
 
299
333
  ## Roadmap
300
334
 
335
+ ### Implemented Commands
336
+
337
+ **SPARQL Query:**
338
+ - `exocortex sparql query` - Execute SPARQL queries against vault
339
+
340
+ **Status Transitions:**
341
+ - `exocortex command start` - Start effort (ToDo → Doing)
342
+ - `exocortex command complete` - Complete effort (Doing → Done)
343
+ - `exocortex command trash` - Trash effort
344
+ - `exocortex command archive` - Archive effort
345
+ - `exocortex command move-to-backlog` - Move to Backlog
346
+ - `exocortex command move-to-analysis` - Move to Analysis
347
+ - `exocortex command move-to-todo` - Move to ToDo
348
+
349
+ **Asset Creation:**
350
+ - `exocortex command create-task` - Create new task
351
+ - `exocortex command create-meeting` - Create new meeting
352
+ - `exocortex command create-project` - Create new project
353
+ - `exocortex command create-area` - Create new area
354
+
355
+ **Property Mutations:**
356
+ - `exocortex command rename-to-uid` - Rename file to match UID
357
+ - `exocortex command update-label` - Update asset label
358
+ - `exocortex command schedule` - Set planned start date
359
+ - `exocortex command set-deadline` - Set planned end date
360
+
301
361
  ### Planned Commands
302
362
 
303
- - `exocortex status backlog` - Move to Backlog
304
- - `exocortex status doing` - Start effort
305
- - `exocortex status done` - Mark as done
306
- - `exocortex status rollback` - Rollback status
307
- - `exocortex plan date <date>` - Plan for specific date
308
- - `exocortex plan shift forward` - Shift day forward
309
- - `exocortex plan shift backward` - Shift day backward
310
- - `exocortex create project` - Create project from area
311
- - `exocortex query` - Query vault by metadata
312
- - `exocortex list tasks` - List all tasks
313
- - `exocortex list today` - List today's tasks
363
+ - `exocortex command rollback-status` - Rollback to previous status
364
+ - `exocortex command shift-schedule` - Shift planned date forward/backward
365
+ - `exocortex list tasks` - List all tasks (with filters)
366
+ - `exocortex list today` - List today's scheduled tasks
367
+ - `exocortex report weekly` - Generate weekly effort report
314
368
 
315
369
  ## License
316
370