Commit Graph

16 Commits

Author SHA1 Message Date
39b235b2e7 fix(build): add openclaw.extensions to package.json for plugin install 2026-04-11 22:12:05 -04:00
406dbf24a9 fix: use cwd instead of __file__ for config path resolution
Fixes config file not found error when installed via pip
2026-04-11 21:02:47 -04:00
e15e4ff856 fix: add configSchema to openclaw.plugin.json, add search CLI command, fix total_docs stat
- Add required configSchema to openclaw.plugin.json for OpenClaw plugin discovery
- Add search command to CLI with --limit, --dir, --from-date, --to-date, --tags filters
- Fix get_stats() to properly count unique docs (was returning 0 for non-null values)
- Remove hardcoded max_results default of 5; search now returns all results by default
- Update INSTALL.md and design docs with correct OpenClaw extension path instructions
2026-04-11 20:01:09 -04:00
de3b9c1c12 updates to install procedures 2026-04-11 16:58:46 -04:00
078576eedc updates to install procedures 2026-04-11 16:55:25 -04:00
90d6f83937 Openclaw install instructions added 2026-04-11 15:17:44 -04:00
4e991c329e Security review fixes 2026-04-11 15:11:07 -04:00
0510df067d fix: update claude settings 2026-04-11 14:14:13 -04:00
da1cf8bb60 feat: wire all 4 obsidian_rag tools to OpenClaw via AnyAgentTool factory
- Replace TypeBox + AgentToolResult with native OpenClaw AnyAgentTool pattern
- Add id, openclaw, main fields to openclaw.plugin.json manifest
- registerTools() now uses factory helpers returning typed AnyAgentTool objects
- toAgentResult() adapter bridges search/index/status/memory results to AgentToolResult shape
- Build clean — pi-agent-core peer dep not needed, openclaw exports all types
- Task list updated: Phase 4 tools + plugin registration marked complete

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-11 14:12:22 -04:00
208531d28d Sprint 0-2: TS plugin scaffolding, LanceDB utils, tooling updates
- Add index-tool.ts command implementation
- Wire lancedb.ts vector search into plugin
- Update src/tools/index.ts exports
- Bump package deps (ts-jest, jest, typescript, lancedb)
- Add .claude/settings.local.json

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-11 13:24:26 -04:00
83a54b2af6 fix: stable chunk_id eliminates duplicate rows on re-index
UUID-based chunk_ids caused merge_insert to treat same content as new rows
on each re-index run. Now uses SHA1(content_hash + index) for deterministic
chunk_ids — same section/text always produces same chunk_id.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-11 13:23:17 -04:00
5c281165c7 Sprint 0-1: Python indexer, TS plugin scaffolding, and test suite
## What's new

**Python indexer (`python/obsidian_rag/`)** — full pipeline from scan to LanceDB:
- `config.py` — JSON config loader with cross-platform path resolution
- `security.py` — path traversal prevention, HTML stripping, sensitive content detection, dir allow/deny lists
- `chunker.py` — section-split for journal entries (date-named files), sliding-window for unstructured notes
- `embedder.py` — Ollama `/api/embeddings` client with batched requests and timeout/error handling
- `vector_store.py` — LanceDB schema, upsert (merge_insert), delete, search with filters, stats
- `indexer.py` — full/sync/reindex pipeline orchestrator with progress yields
- `cli.py` — `index | sync | reindex | status` CLI commands

**TypeScript plugin (`src/`)** — OpenClaw plugin scaffold:
- `utils/` — config loader, TypeScript types, response envelope factory, LanceDB client
- `services/` — health state machine (HEALTHY/DEGRADED/UNAVAILABLE), vault watcher with debounce/batching, indexer bridge (subprocess spawner)
- `tools/` — 4 tool stubs: search, index, status, memory_store (OpenClaw wiring pending)
- `index.ts` — plugin entry point with health probe + vault watcher startup

**Config** (`obsidian-rag/config.json`, `openclaw.plugin.json`):
- 627 files / 3764 chunks indexed in dev vault

**Tests: 76 passing**
- Python: 64 pytest tests (chunker, security, vector_store, config)
- TypeScript: 12 vitest tests (lancedb client, response envelope)

## Bugs fixed

- LanceDB `tags` column filter: `LIKE '%tag%'` → `list_contains(tags, 'tag')` (List<String> column)
- LanceDB JS `db.list_tables()` returns `ListTablesResponse` object, not plain array
- LanceDB JS result score field: `_score` → `_distance`
- TypeScript regex literal with unescaped `/` in path-resolve regex
- Python: `create_table_if_not_exists` identity check → name comparison

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-10 22:56:50 -04:00
18ad47e100 Todo list 2026-04-10 19:15:38 -04:00
2c976bb75b all in 2026-04-10 19:00:38 -04:00
b8996d2ecb Add Work Breakdown Structure for Obsidian RAG Plugin
64 work packages across 5 phases and 15 work areas, organized
bottom-up through the layered protocol architecture. Includes
dependency map, critical path, parallelizable work, effort
estimates, and risk items.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-10 18:49:58 -04:00
114a6dcf50 Initial commit: Obsidian RAG Plugin design spec and TDD
Add the original design spec (obsidian-rag-design.md) and the
comprehensive Technical Design Document covering the layered
protocol model (Transport, Session, Tool, Data), OpenClaw
interaction protocol, security layers, testing strategy, and
Windows development notes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-10 16:40:46 -04:00