@bodhi-ventures/aiocs 0.2.0 → 0.3.1

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.
@@ -46,6 +46,7 @@ command = "aiocs-mcp"
46
46
  9. Prefer `refresh due <source-id>` over force `fetch <source-id>` when the source already exists.
47
47
  10. Use MCP `batch` when multiple list/search/show or search/diff/coverage steps are needed.
48
48
  11. Cite `sourceId`, `snapshotId`, and `pageUrl` when they materially improve traceability.
49
+ 12. If the user is operating on a compiled research workspace, prefer `workspace_search` and `workspace_artifact_show` over raw source search.
49
50
 
50
51
  ## Automatic use in Codex
51
52
 
@@ -113,6 +114,27 @@ docs --json diff hyperliquid
113
114
  docs --json verify coverage hyperliquid /absolute/path/to/reference.md
114
115
  ```
115
116
 
117
+ Research workspaces:
118
+
119
+ ```bash
120
+ docs --json workspace create market-structure --label "Market Structure" --auto-compile
121
+ docs --json workspace bind market-structure hyperliquid nktkas-hyperliquid
122
+ docs --json workspace compile market-structure
123
+ docs --json workspace queue-run
124
+ docs --json workspace search market-structure "transport design" --scope mixed
125
+ docs --json workspace artifact show market-structure derived/index.md
126
+ docs --json workspace lint market-structure
127
+ docs --json workspace output market-structure report --name weekly-brief
128
+ docs --json workspace answer market-structure note "What changed in websocket transport?" --name websocket-note
129
+ docs --json workspace ingest add market-structure markdown-dir /absolute/path/to/notes --label "Research notes"
130
+ docs --json workspace ingest add market-structure csv /absolute/path/to/fills.csv --label "Fills CSV"
131
+ docs --json workspace ingest add market-structure json /absolute/path/to/manifest.json --label "Research manifest"
132
+ docs --json workspace ingest add market-structure jsonl /absolute/path/to/events.jsonl --label "Events JSONL"
133
+ docs --json workspace sync obsidian market-structure /absolute/path/to/vault
134
+ ```
135
+
136
+ If bound source snapshots have changed since the last compile, rerun `workspace compile` before `workspace output`. The output path now fails closed on stale derived artifacts instead of synthesizing reports from outdated summaries.
137
+
116
138
  Catalog maintenance:
117
139
 
118
140
  ```bash
@@ -134,8 +156,26 @@ If a Codex agent has access to the `aiocs-mcp` server, prefer these MCP tools ov
134
156
  - `diff_snapshots`
135
157
  - `verify_coverage`
136
158
  - `embeddings_status`
159
+ - `workspace_list`
160
+ - `workspace_status`
161
+ - `workspace_search`
162
+ - `workspace_ingest_list`
163
+ - `workspace_ingest_search`
164
+ - `workspace_artifact_list`
165
+ - `workspace_artifact_show`
166
+ - `workspace_lint`
137
167
  - `batch`
138
168
 
139
- Use mutating tools such as `source_upsert`, `refresh_due`, and `fetch` only through the `aiocs-curation` workflow.
169
+ Use mutating tools such as `source_upsert`, `refresh_due`, `fetch`, `workspace_create`, `workspace_bind`, `workspace_compile`, and `workspace_output` only through the `aiocs-curation` workflow.
170
+
171
+ ## LM Studio requirement for workspaces
172
+
173
+ Workspace compilation and output generation use LM Studio in v1. Codex should assume:
174
+
175
+ - provider: LM Studio
176
+ - model: `google/gemma-4-26b-a4b`
177
+ - default API endpoint: `ws://127.0.0.1:1234`
178
+
179
+ If `doctor` reports the `lmstudio` check as `warn` or `fail`, Codex should not claim workspace compilation is available until LM Studio is running and the configured model is loaded.
140
180
 
141
181
  The CLI remains the fallback and should always be invoked with `--json` for agent use. For normal answering flows, avoid `fetch all`; use targeted due refresh or explicit user-approved force fetches.
@@ -54,6 +54,26 @@ All of these support the root-level `--json` flag:
54
54
  - `diff`
55
55
  - `project link`
56
56
  - `project unlink`
57
+ - `workspace create`
58
+ - `workspace configure`
59
+ - `workspace list`
60
+ - `workspace bind`
61
+ - `workspace unbind`
62
+ - `workspace compile`
63
+ - `workspace queue-run`
64
+ - `workspace status`
65
+ - `workspace search`
66
+ - `workspace ingest add`
67
+ - `workspace ingest list`
68
+ - `workspace ingest show`
69
+ - `workspace ingest search`
70
+ - `workspace ingest remove`
71
+ - `workspace artifact list`
72
+ - `workspace artifact show`
73
+ - `workspace lint`
74
+ - `workspace output`
75
+ - `workspace answer`
76
+ - `workspace sync obsidian`
57
77
  - `backup export`
58
78
  - `backup import`
59
79
  - `embeddings status`
@@ -131,6 +151,7 @@ Check ids are currently:
131
151
  - `source-spec-dirs`
132
152
  - `freshness`
133
153
  - `daemon-heartbeat`
154
+ - `lmstudio`
134
155
  - `embedding-provider`
135
156
  - `vector-store`
136
157
  - `embeddings`
@@ -245,6 +266,405 @@ Summary status values:
245
266
  }
246
267
  ```
247
268
 
269
+ ### Workspace commands
270
+
271
+ Workspace commands manage derived wiki artifacts backed by canonical source snapshots and LM Studio compilation.
272
+
273
+ #### `workspace.create`
274
+
275
+ ```json
276
+ {
277
+ "workspace": {
278
+ "id": "market-structure",
279
+ "label": "Market Structure",
280
+ "compilerProfile": {
281
+ "provider": "lmstudio",
282
+ "model": "google/gemma-4-26b-a4b",
283
+ "temperature": 0.1,
284
+ "topP": 0.9,
285
+ "maxInputChars": 12000,
286
+ "maxOutputTokens": 4096,
287
+ "concurrency": 1
288
+ },
289
+ "defaultOutputFormats": ["report", "slides"]
290
+ }
291
+ }
292
+ ```
293
+
294
+ #### `workspace.list`
295
+
296
+ ```json
297
+ {
298
+ "workspaces": [
299
+ {
300
+ "id": "market-structure",
301
+ "label": "Market Structure",
302
+ "bindingCount": 2,
303
+ "artifactCount": 5,
304
+ "lastCompileStatus": "success"
305
+ }
306
+ ]
307
+ }
308
+ ```
309
+
310
+ #### `workspace.bind` and `workspace.unbind`
311
+
312
+ ```json
313
+ {
314
+ "workspaceId": "market-structure",
315
+ "sourceIds": ["hyperliquid", "nktkas-hyperliquid"]
316
+ }
317
+ ```
318
+
319
+ #### `workspace.configure`
320
+
321
+ ```json
322
+ {
323
+ "workspace": {
324
+ "id": "market-structure",
325
+ "label": "Market Structure",
326
+ "autoCompileEnabled": true
327
+ }
328
+ }
329
+ ```
330
+
331
+ #### `workspace.compile`
332
+
333
+ ```json
334
+ {
335
+ "workspaceId": "market-structure",
336
+ "skipped": false,
337
+ "sourceFingerprint": "sha256...",
338
+ "changedSourceIds": ["hyperliquid"],
339
+ "changedRawInputIds": [],
340
+ "updatedArtifactPaths": [
341
+ "derived/sources/hyperliquid/summary.md",
342
+ "derived/concepts/hyperliquid.md",
343
+ "derived/index.md"
344
+ ],
345
+ "artifactCount": 3,
346
+ "compileRunId": "wrkcmp_..."
347
+ }
348
+ ```
349
+
350
+ #### `workspace.queue-run`
351
+
352
+ ```json
353
+ {
354
+ "processedJobs": 1,
355
+ "succeededJobs": [
356
+ {
357
+ "workspaceId": "market-structure",
358
+ "sourceFingerprint": "sha256...",
359
+ "changedSourceIds": ["hyperliquid"],
360
+ "changedRawInputIds": []
361
+ }
362
+ ],
363
+ "failedJobs": []
364
+ }
365
+ ```
366
+
367
+ #### `workspace.status`
368
+
369
+ ```json
370
+ {
371
+ "workspace": {
372
+ "id": "market-structure",
373
+ "label": "Market Structure",
374
+ "autoCompileEnabled": true
375
+ },
376
+ "bindings": [
377
+ {
378
+ "workspaceId": "market-structure",
379
+ "sourceId": "hyperliquid",
380
+ "createdAt": "2026-04-03T10:00:00.000Z"
381
+ }
382
+ ],
383
+ "artifacts": [
384
+ {
385
+ "workspaceId": "market-structure",
386
+ "path": "derived/index.md",
387
+ "kind": "index",
388
+ "stale": false,
389
+ "chunkCount": 3
390
+ }
391
+ ],
392
+ "compileJob": {
393
+ "workspaceId": "market-structure",
394
+ "status": "pending",
395
+ "requestedSourceIds": ["hyperliquid"],
396
+ "requestedRawInputIds": [],
397
+ "requestedFingerprint": null
398
+ },
399
+ "rawInputs": [],
400
+ "syncTargets": [],
401
+ "questionRuns": [],
402
+ "links": [],
403
+ "graph": {
404
+ "linkCount": 4,
405
+ "brokenLinkCount": 0,
406
+ "orphanArtifactCount": 0,
407
+ "backlinkCount": 4,
408
+ "relationCounts": {
409
+ "explicit_link": 0,
410
+ "derived_from": 1,
411
+ "mentions": 1,
412
+ "related_to": 2,
413
+ "expands": 1,
414
+ "index_entry": 2,
415
+ "summary_of": 1,
416
+ "concept_of": 1,
417
+ "output_depends_on": 0
418
+ },
419
+ "mostLinkedArtifacts": [
420
+ {
421
+ "artifactPath": "derived/index.md",
422
+ "incomingCount": 0,
423
+ "outgoingCount": 2
424
+ }
425
+ ]
426
+ },
427
+ "lintSummary": {
428
+ "status": "pass",
429
+ "findingCount": 0,
430
+ "staleArtifactCount": 0,
431
+ "missingProvenanceCount": 0,
432
+ "missingArtifactCount": 0,
433
+ "brokenLinkCount": 0,
434
+ "orphanArtifactCount": 0,
435
+ "suggestedConceptCount": 0,
436
+ "duplicateConceptCandidateCount": 0,
437
+ "missingArticleCandidateCount": 0,
438
+ "followUpQuestionCount": 0
439
+ },
440
+ "health": {
441
+ "status": "healthy",
442
+ "staleArtifactCount": 0,
443
+ "pendingCompileJobs": 0,
444
+ "failedCompileJobs": 0,
445
+ "brokenLinkCount": 0,
446
+ "orphanArtifactCount": 0,
447
+ "rawInputCount": 0,
448
+ "lintFindingCount": 0,
449
+ "duplicateConceptCandidateCount": 0,
450
+ "missingArticleCandidateCount": 0,
451
+ "followUpQuestionCount": 0
452
+ },
453
+ "compileRuns": [
454
+ {
455
+ "id": "wrkcmp_...",
456
+ "status": "success"
457
+ }
458
+ ]
459
+ }
460
+ ```
461
+
462
+ #### `workspace.ingest.*`
463
+
464
+ ```json
465
+ {
466
+ "workspaceId": "market-structure",
467
+ "rawInput": {
468
+ "id": "csv-fills-abc123def0",
469
+ "workspaceId": "market-structure",
470
+ "kind": "csv",
471
+ "label": "Fills CSV",
472
+ "sourcePath": "/absolute/path/to/fills.csv",
473
+ "storagePath": "raw/csv-fills-abc123def0/fills.csv",
474
+ "extractedTextPath": "raw/csv-fills-abc123def0/fills.csv.txt",
475
+ "contentHash": "sha256...",
476
+ "chunkCount": 12
477
+ }
478
+ }
479
+ ```
480
+
481
+ Raw-input search returns:
482
+
483
+ ```json
484
+ {
485
+ "workspaceId": "market-structure",
486
+ "query": "fee tier",
487
+ "total": 1,
488
+ "limit": 10,
489
+ "offset": 0,
490
+ "hasMore": false,
491
+ "results": [
492
+ {
493
+ "rawInputId": "csv-fills-abc123def0",
494
+ "kind": "csv",
495
+ "label": "Fills CSV",
496
+ "sectionTitle": "Fills CSV rows 1-2",
497
+ "markdown": "...",
498
+ "filePath": "fills.csv",
499
+ "score": 0.42
500
+ }
501
+ ]
502
+ }
503
+ ```
504
+
505
+ #### `workspace.search`
506
+
507
+ ```json
508
+ {
509
+ "workspaceId": "market-structure",
510
+ "query": "transport design",
511
+ "scope": "mixed",
512
+ "limit": 10,
513
+ "offset": 0,
514
+ "hasMore": false,
515
+ "modeRequested": "auto",
516
+ "modeUsed": "hybrid",
517
+ "total": 2,
518
+ "results": [
519
+ {
520
+ "kind": "source",
521
+ "scope": "source",
522
+ "chunkId": 42,
523
+ "sourceId": "nktkas-hyperliquid",
524
+ "snapshotId": "snp_...",
525
+ "pageUrl": "file://src/transports/websocket.ts",
526
+ "pageTitle": "src/transports/websocket.ts",
527
+ "sectionTitle": "WebSocketTransport",
528
+ "markdown": "...",
529
+ "pageKind": "file",
530
+ "filePath": "src/transports/websocket.ts",
531
+ "language": "typescript",
532
+ "score": 0.91,
533
+ "signals": ["lexical", "vector"]
534
+ },
535
+ {
536
+ "kind": "derived",
537
+ "scope": "derived",
538
+ "artifactPath": "derived/concepts/nktkas-hyperliquid.md",
539
+ "artifactKind": "concept",
540
+ "sectionTitle": "Transport design",
541
+ "markdown": "...",
542
+ "stale": false,
543
+ "score": 0.74
544
+ }
545
+ ]
546
+ }
547
+ ```
548
+
549
+ #### `workspace.artifact.list`
550
+
551
+ ```json
552
+ {
553
+ "workspaceId": "market-structure",
554
+ "artifacts": [
555
+ {
556
+ "workspaceId": "market-structure",
557
+ "path": "derived/index.md",
558
+ "kind": "index",
559
+ "stale": false,
560
+ "chunkCount": 3
561
+ }
562
+ ]
563
+ }
564
+ ```
565
+
566
+ #### `workspace.artifact.show`
567
+
568
+ ```json
569
+ {
570
+ "workspaceId": "market-structure",
571
+ "artifact": {
572
+ "workspaceId": "market-structure",
573
+ "path": "derived/index.md",
574
+ "kind": "index",
575
+ "stale": false
576
+ },
577
+ "content": "# Workspace Index\n...",
578
+ "provenance": [
579
+ {
580
+ "workspaceId": "market-structure",
581
+ "path": "derived/index.md",
582
+ "sourceId": "hyperliquid",
583
+ "snapshotId": "snp_...",
584
+ "chunkIds": [42, 43]
585
+ }
586
+ ],
587
+ "rawInputProvenance": []
588
+ }
589
+ ```
590
+
591
+ #### `workspace.lint`
592
+
593
+ ```json
594
+ {
595
+ "workspaceId": "market-structure",
596
+ "summary": {
597
+ "status": "warn",
598
+ "findingCount": 1,
599
+ "staleArtifactCount": 1,
600
+ "missingProvenanceCount": 0,
601
+ "missingArtifactCount": 0,
602
+ "brokenLinkCount": 0,
603
+ "orphanArtifactCount": 0,
604
+ "suggestedConceptCount": 0,
605
+ "duplicateConceptCandidateCount": 1,
606
+ "missingArticleCandidateCount": 1,
607
+ "followUpQuestionCount": 2
608
+ },
609
+ "findings": [
610
+ {
611
+ "kind": "stale-artifact",
612
+ "severity": "warn",
613
+ "summary": "Artifact provenance points at an older snapshot.",
614
+ "artifactPath": "derived/sources/hyperliquid/summary.md"
615
+ },
616
+ {
617
+ "kind": "follow-up-question-suggestion",
618
+ "severity": "warn",
619
+ "summary": "What important workflows, caveats, or open questions remain unresolved for derived/concepts/hyperliquid.md?",
620
+ "artifactPath": "derived/concepts/hyperliquid.md"
621
+ }
622
+ ],
623
+ "suggestionsArtifactPath": "outputs/suggestions/lint.md"
624
+ }
625
+ ```
626
+
627
+ #### `workspace.output`
628
+
629
+ ```json
630
+ {
631
+ "workspaceId": "market-structure",
632
+ "format": "report",
633
+ "path": "outputs/reports/weekly-brief.md",
634
+ "artifactCount": 8
635
+ }
636
+ ```
637
+
638
+ #### `workspace.answer`
639
+
640
+ ```json
641
+ {
642
+ "workspaceId": "market-structure",
643
+ "format": "note",
644
+ "path": "derived/notes/websocket-note.md",
645
+ "artifactCount": 9,
646
+ "questionRun": {
647
+ "id": "wrkq_...",
648
+ "workspaceId": "market-structure",
649
+ "question": "What changed in websocket transport?",
650
+ "format": "note",
651
+ "artifactPath": "derived/notes/websocket-note.md",
652
+ "status": "success"
653
+ }
654
+ }
655
+ ```
656
+
657
+ #### `workspace.sync.obsidian`
658
+
659
+ ```json
660
+ {
661
+ "workspaceId": "market-structure",
662
+ "vaultPath": "/absolute/path/to/vault",
663
+ "targetPath": "/absolute/path/to/vault/aiocs/market-structure",
664
+ "exportSubdir": "aiocs/market-structure"
665
+ }
666
+ ```
667
+
248
668
  ### `diff`
249
669
 
250
670
  ```json
@@ -494,6 +914,11 @@ Current stable CLI error codes include:
494
914
 
495
915
  - `INVALID_ARGUMENT`
496
916
  - `SOURCE_NOT_FOUND`
917
+ - `WORKSPACE_NOT_FOUND`
918
+ - `WORKSPACE_ARTIFACT_NOT_FOUND`
919
+ - `WORKSPACE_ARTIFACTS_STALE`
920
+ - `WORKSPACE_COMPILER_CONFIG_INVALID`
921
+ - `WORKSPACE_COMPILER_UNAVAILABLE`
497
922
  - `SNAPSHOT_NOT_FOUND`
498
923
  - `NO_PAGES_FETCHED`
499
924
  - `NO_PROJECT_SCOPE`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bodhi-ventures/aiocs",
3
- "version": "0.2.0",
3
+ "version": "0.3.1",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "description": "Local-only documentation store, fetcher, and search CLI for AI agents.",
@@ -48,12 +48,15 @@
48
48
  "test:watch": "vitest"
49
49
  },
50
50
  "dependencies": {
51
+ "@lmstudio/sdk": "1.5.0",
51
52
  "@modelcontextprotocol/sdk": "1.28.0",
52
53
  "@mozilla/readability": "0.6.0",
53
54
  "@qdrant/js-client-rest": "1.17.0",
54
55
  "better-sqlite3": "12.4.1",
55
56
  "commander": "14.0.1",
57
+ "csv-parse": "6.2.1",
56
58
  "jsdom": "27.0.1",
59
+ "pdf-parse": "2.4.5",
57
60
  "playwright": "1.57.0",
58
61
  "turndown": "7.2.1",
59
62
  "turndown-plugin-gfm": "1.0.2",
@@ -12,6 +12,8 @@ Use this skill when you need authoritative local documentation lookup through th
12
12
  - The user is asking about exchange or product docs that may already exist in the local `aiocs` catalog.
13
13
  - You need authoritative local docs for an exchange, SDK, or product without browsing the live site every time.
14
14
  - You need reusable reference search over a curated external git repository that already lives in `aiocs`.
15
+ - You need to read from a compiled `aiocs` workspace wiki or inspect derived workspace artifacts.
16
+ - You need to inspect workspace status, queued compile health, or raw ingested evidence before deciding whether curation is needed.
15
17
  - You want machine-readable search/show/diff/coverage results for an AI agent.
16
18
  - You need hybrid docs retrieval with lexical plus semantic/vector recall.
17
19
  - You need to validate runtime health before relying on the local docs catalog.
@@ -77,6 +79,18 @@ Inspect a specific chunk:
77
79
  docs --json show 42
78
80
  ```
79
81
 
82
+ Search or inspect a compiled workspace:
83
+
84
+ ```bash
85
+ docs --json workspace status market-structure
86
+ docs --json workspace search market-structure "transport design" --scope mixed
87
+ docs --json workspace ingest list market-structure
88
+ docs --json workspace ingest search market-structure "fee tier"
89
+ docs --json workspace artifact list market-structure
90
+ docs --json workspace artifact show market-structure derived/index.md
91
+ docs --json workspace lint market-structure
92
+ ```
93
+
80
94
  Inspect source availability and health:
81
95
 
82
96
  ```bash
@@ -132,6 +146,15 @@ The `aiocs-mcp` server exposes the same core operations without shell parsing:
132
146
  - `backup_import`
133
147
  - `search`
134
148
  - `show`
149
+ - `workspace_list`
150
+ - `workspace_status`
151
+ - `workspace_search`
152
+ - `workspace_ingest_list`
153
+ - `workspace_ingest_show`
154
+ - `workspace_ingest_search`
155
+ - `workspace_artifact_list`
156
+ - `workspace_artifact_show`
157
+ - `workspace_lint`
135
158
  - `verify_coverage`
136
159
  - `batch`
137
160
 
@@ -142,9 +165,10 @@ Mutation-capable MCP tools such as `source_upsert`, `refresh_due`, and `fetch` b
142
165
  1. If runtime health is in doubt, run `doctor`.
143
166
  2. Run `source_list` to see whether the source already exists.
144
167
  3. Use `search` in `auto` mode first, then `show` for the selected chunk.
145
- 4. Use `canary`, `diff_snapshots`, or `verify_coverage` when the question is about drift, changes, or completeness.
146
- 5. If the source is missing or stale and the next step is to mutate `aiocs`, load `aiocs-curation`.
147
- 6. Use `batch` when combining list/search/show or diff/coverage checks in one pass.
168
+ 4. If the user is asking against a compiled research wiki, prefer `workspace_search` and `workspace_artifact_show`.
169
+ 5. Use `canary`, `diff_snapshots`, or `verify_coverage` when the question is about drift, changes, or completeness.
170
+ 6. If the source is missing or stale and the next step is to mutate `aiocs`, load `aiocs-curation`.
171
+ 7. Use `batch` when combining list/search/show or diff/coverage checks in one pass.
148
172
 
149
173
  ## Operational notes
150
174
 
@@ -153,6 +177,7 @@ Mutation-capable MCP tools such as `source_upsert`, `refresh_due`, and `fetch` b
153
177
  - Use `docs daemon` or the Docker daemon service when the catalog should stay fresh automatically.
154
178
  - `docs search --mode auto` is the right default for agents; it uses hybrid retrieval only when embeddings are current and healthy for the requested scope.
155
179
  - The Docker Compose stack includes a dedicated `aiocs-qdrant` container and expects Ollama to be reachable separately.
180
+ - Compiled research workspaces use LM Studio as the v1 compiler backend and expect `google/gemma-4-26b-a4b` to be loaded unless the environment overrides it.
156
181
  - Canaries are the first place to look when a docs site changed and fetches started degrading.
157
182
  - Newly added or changed sources become due immediately, so `refresh due <source-id>` is the safe first refresh path after upsert.
158
183
  - CLI failures expose machine-readable `error.code` fields in `--json` mode.
@@ -14,6 +14,8 @@ Use this skill when you need to add, refresh, repair, or otherwise mutate `aiocs
14
14
  - A source spec needs to be created, updated, or upserted under `~/.aiocs/sources`.
15
15
  - A reusable external git repository should be added as a `kind: git` source under `~/.aiocs/sources`.
16
16
  - A canary is failing and the source needs remediation or targeted refetch.
17
+ - A research workspace needs to be created, rebound, compiled, or asked to generate a report/slide artifact.
18
+ - A workspace needs raw evidence ingest, auto-compile setup, queued compile processing, or Obsidian sync.
17
19
  - The user explicitly wants `aiocs` maintenance, source onboarding, or catalog repair.
18
20
 
19
21
  ## Trigger guidance for Codex
@@ -69,6 +71,24 @@ docs --json fetch my-source
69
71
  docs --json canary my-source
70
72
  ```
71
73
 
74
+ Compile or regenerate a workspace wiki:
75
+
76
+ ```bash
77
+ docs --json workspace create market-structure --label "Market Structure"
78
+ docs --json workspace bind market-structure hyperliquid nktkas-hyperliquid
79
+ docs --json workspace compile market-structure
80
+ docs --json workspace configure market-structure --auto-compile true
81
+ docs --json workspace queue-run
82
+ docs --json workspace ingest add market-structure markdown-dir /absolute/path/to/notes --label "Research notes"
83
+ docs --json workspace ingest add market-structure csv /absolute/path/to/fills.csv --label "Fills CSV"
84
+ docs --json workspace ingest add market-structure json /absolute/path/to/manifest.json --label "Research manifest"
85
+ docs --json workspace ingest add market-structure jsonl /absolute/path/to/events.jsonl --label "Events JSONL"
86
+ docs --json workspace output market-structure report --name weekly-brief
87
+ docs --json workspace output market-structure slides --name weekly-brief
88
+ docs --json workspace answer market-structure note "What changed?" --name quick-note
89
+ docs --json workspace sync obsidian market-structure /absolute/path/to/vault
90
+ ```
91
+
72
92
  Heavy maintenance remains explicit:
73
93
 
74
94
  ```bash
@@ -91,6 +111,17 @@ The `aiocs-mcp` server exposes the same curation operations without shell parsin
91
111
  - `embeddings_backfill`
92
112
  - `embeddings_clear`
93
113
  - `embeddings_run`
114
+ - `workspace_create`
115
+ - `workspace_bind`
116
+ - `workspace_unbind`
117
+ - `workspace_update`
118
+ - `workspace_compile`
119
+ - `workspace_queue_run`
120
+ - `workspace_ingest_add`
121
+ - `workspace_ingest_remove`
122
+ - `workspace_output`
123
+ - `workspace_answer`
124
+ - `workspace_sync_obsidian`
94
125
  - `batch`
95
126
 
96
127
  ## Recommended Codex workflow
@@ -100,7 +131,10 @@ The `aiocs-mcp` server exposes the same curation operations without shell parsin
100
131
  3. If the source is missing but worth curating, create a spec under `~/.aiocs/sources`, then `source_upsert` it.
101
132
  4. After upsert, use `refresh due <source-id>` as the safe first fetch path.
102
133
  5. Use `canary` when the site changed or extraction drift is suspected.
103
- 6. Escalate to `fetch <source-id>` or `fetch all` only for explicit maintenance or when due-based refresh is not enough.
134
+ 6. For research workspaces, bind curated sources and/or ingest raw evidence, then run `workspace compile`.
135
+ 7. Use `workspace output` and `workspace answer` only after a successful compile so outputs have source-backed provenance.
136
+ 8. Prefer `autoCompileEnabled` plus targeted queue processing over broad global rebuilds.
137
+ 9. Escalate to `fetch <source-id>` or `fetch all` only for explicit maintenance or when due-based refresh is not enough.
104
138
 
105
139
  ## Operational notes
106
140
 
@@ -108,3 +142,4 @@ The `aiocs-mcp` server exposes the same curation operations without shell parsin
108
142
  - `~/.aiocs/sources` and bundled repo sources behave the same once bootstrapped into the catalog.
109
143
  - Targeted refresh is the default. Broad refresh is a maintenance task, not a normal answering step.
110
144
  - Use `aiocs` for read/search flows and this skill only for catalog mutation.
145
+ - Workspace compilation uses LM Studio and expects the configured model to be loaded before `workspace compile`, `workspace output`, or `workspace answer`.