woods 2.0.0.beta4 → 2.0.0

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 (79) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +480 -477
  3. data/CONTRIBUTING.md +2 -2
  4. data/README.md +11 -26
  5. data/docs/AGENT_GUIDE.md +31 -12
  6. data/docs/AGENT_SETUP.md +17 -10
  7. data/docs/AUTOMATIC_MAINTENANCE.md +222 -0
  8. data/docs/BACKEND_MATRIX.md +13 -7
  9. data/docs/CLIENT_HOOKS.md +1 -1
  10. data/docs/CONFIGURATION_REFERENCE.md +36 -26
  11. data/docs/CONSOLE_MCP_SETUP.md +10 -8
  12. data/docs/DOCKER_SETUP.md +15 -0
  13. data/docs/EVALUATION.md +10 -4
  14. data/docs/EXTRACTOR_REFERENCE.md +14 -2
  15. data/docs/FAQ.md +14 -3
  16. data/docs/GETTING_STARTED.md +18 -17
  17. data/docs/INCREMENTAL_EXTRACTION.md +8 -3
  18. data/docs/INDEX_LAYOUT.md +2 -2
  19. data/docs/MCP_SERVERS.md +28 -11
  20. data/docs/MCP_TOOL_COOKBOOK.md +1 -1
  21. data/docs/MCP_WORKTREE_SETUP.md +13 -1
  22. data/docs/PUBLISHED_INDEX.md +1 -1
  23. data/docs/README.md +2 -1
  24. data/docs/RETRIEVAL_GUIDE.md +57 -8
  25. data/docs/SOURCE_FRESHNESS.md +1 -1
  26. data/docs/TOKEN_BENCHMARK.md +16 -10
  27. data/docs/TROUBLESHOOTING.md +133 -37
  28. data/docs/UPGRADING_TO_2.md +9 -7
  29. data/docs/WATCH_DAEMON.md +172 -17
  30. data/docs/WHY_WOODS.md +9 -5
  31. data/exe/woods-console +13 -11
  32. data/exe/woods-watch +5 -0
  33. data/lib/generators/woods/watch_generator.rb +53 -0
  34. data/lib/puma/plugin/woods.rb +10 -0
  35. data/lib/tasks/woods.rake +14 -0
  36. data/lib/woods/cache/cache_middleware.rb +6 -0
  37. data/lib/woods/console/stdio_transport.rb +27 -0
  38. data/lib/woods/extractor.rb +25 -7
  39. data/lib/woods/git_command.rb +6 -7
  40. data/lib/woods/git_provenance.rb +4 -6
  41. data/lib/woods/mcp/bootstrapper.rb +3 -1
  42. data/lib/woods/mcp/initialization_guidance.rb +1 -1
  43. data/lib/woods/mcp/server.rb +41 -9
  44. data/lib/woods/retrieval/corpus_status.rb +46 -0
  45. data/lib/woods/retriever.rb +19 -7
  46. data/lib/woods/storage/local_corpus_stats.rb +32 -0
  47. data/lib/woods/storage/metadata_store.rb +20 -0
  48. data/lib/woods/storage/vector_store.rb +10 -0
  49. data/lib/woods/version.rb +1 -1
  50. data/lib/woods/watch/child_environment.rb +30 -0
  51. data/lib/woods/watch/cli.rb +91 -0
  52. data/lib/woods/watch/daemon.rb +55 -7
  53. data/lib/woods/watch/event_stream.rb +70 -0
  54. data/lib/woods/watch/guardian.rb +142 -0
  55. data/lib/woods/watch/installation/layout.rb +70 -0
  56. data/lib/woods/watch/installation/options.rb +128 -0
  57. data/lib/woods/watch/installation/planner.rb +128 -0
  58. data/lib/woods/watch/installation/probe.rb +101 -0
  59. data/lib/woods/watch/installation/receipt.rb +77 -0
  60. data/lib/woods/watch/installation/recovery.rb +64 -0
  61. data/lib/woods/watch/installation/templates.rb +58 -0
  62. data/lib/woods/watch/installation.rb +56 -0
  63. data/lib/woods/watch/lifecycle.rb +182 -0
  64. data/lib/woods/watch/managed_child.rb +113 -0
  65. data/lib/woods/watch/managed_cleanup.rb +48 -0
  66. data/lib/woods/watch/managed_process.rb +144 -0
  67. data/lib/woods/watch/puma_adapter.rb +87 -0
  68. data/lib/woods/watch/puma_child.rb +66 -0
  69. data/lib/woods/watch/supervision_records.rb +95 -0
  70. data/lib/woods/watch/supervision_status.rb +104 -0
  71. data/lib/woods/watch/supervisor.rb +161 -0
  72. data/lib/woods/watch/supervisor_reporting.rb +46 -0
  73. data/plugin/.claude-plugin/plugin.json +1 -1
  74. data/plugin/skills/woods-agent-enable/SKILL.md +1 -1
  75. data/plugin/skills/woods-diagnose/SKILL.md +77 -8
  76. data/plugin/skills/woods-investigate/SKILL.md +6 -6
  77. data/plugin/skills/woods-mcp-config/SKILL.md +28 -1
  78. data/plugin/skills/woods-setup/SKILL.md +58 -4
  79. metadata +35 -5
@@ -36,26 +36,57 @@ bundle exec rails runner 'Rails.application.eager_load!; puts "eager load ok"'
36
36
 
37
37
  Use the application's normal Docker command and environment variables when applicable. Fix boot/eager-load failures before Woods.
38
38
 
39
+ ### Watcher setup cannot find already installed Rails or dependencies
40
+
41
+ Compare normal task discovery with installer preflight in the same container and
42
+ application environment. Early Git builds of the watcher installer stripped
43
+ `BUNDLE_PATH` and `BUNDLE_APP_CONFIG`; Woods `2.0.0` includes the #540 fix.
44
+ Record the loaded revision and bundle configuration source before
45
+ reinstalling dependencies or writing a local bundle-path workaround. Follow the
46
+ [watcher installation guide](https://github.com/lost-in-the/woods/blob/main/docs/WATCH_DAEMON.md#managed-development-startup).
47
+
48
+ ### Puma cannot load the Woods plugin after switching branches
49
+
50
+ Early generated guards checked only whether Woods was activated. An older gem
51
+ can satisfy that check without providing `puma/plugin/woods.rb`. The #542 fix is
52
+ included in Woods `2.0.0`: verify the loaded revision, then use a supporting
53
+ bundle to preview and apply `bin/rails generate woods:watch --operation update
54
+ --mode puma`. The updated guard checks the active gem's require paths, so older
55
+ gems boot without a watcher. Repeating setup does not upgrade the guard. Follow
56
+ the [owned setup runbook](https://github.com/lost-in-the/woods/blob/main/docs/WATCH_DAEMON.md#ownership-updates-and-removal);
57
+ do not change the owned directive or receipt manually.
58
+
39
59
  ### Watch repeatedly exits 75
40
60
 
61
+ First identify the lifecycle owner. The raw task deliberately exits 75; a bare
62
+ Foreman entry then stops all services. Managed `woods-watch`/Puma setup (#538)
63
+ is included in Woods `2.0.0`: verify installed executable/generator help and
64
+ loaded revision before proposing it. Supporting launchers retry boot failures,
65
+ reject idle TTL, and park ownership/protocol conflicts until owner restart.
66
+ Inspect separate supervision state rather than treating its parent PID as a
67
+ healthy daemon. Before the first resolved index path, use launcher logs.
68
+ Do not remove claims or kill PIDs from status to force takeover. See
69
+ [startup diagnosis](https://github.com/lost-in-the/woods/blob/main/docs/TROUBLESHOOTING.md#watcher-startup-or-planned-restart-fails).
70
+
41
71
  Check the installed version's watch guide. Older releases, including
42
72
  `2.0.0.beta2`, can rediscover the same restart-trigger paths on every boot. Stop
43
73
  the supervisor, run one successful full extraction, then restart the standalone
44
74
  watch task. Do not assume automatic startup reconciliation exists in that release.
45
75
  For versions documenting environment-boot snapshots, confirm that the command is
46
- `bundle exec rake woods:watch`, with no preceding `environment` task, and check
76
+ the application's actual `rails woods:watch` or `rake woods:watch` entrypoint,
77
+ with no preceding `environment` task, and check
47
78
  whether boot inputs keep changing during initialization or catch-up.
48
79
 
49
80
  ### Watch retains facts from an initializer deleted while stopped
50
81
 
51
- Record the installed revision. Unreleased after `2.0.0.beta3`, startup preserves
82
+ Record the installed revision. In Woods `2.0.0`, startup preserves
52
83
  registered deleted boot inputs as full-extraction obligations. On earlier builds,
53
84
  stop watch, run a successful full extraction in a fresh process, then restart
54
85
  standalone `woods:watch`. See the installed version's watch guide.
55
86
 
56
87
  ### A cleaned index directory still exists
57
88
 
58
- Unreleased after `2.0.0.beta3`, `woods:clean` retains the output directory and
89
+ In Woods `2.0.0`, `woods:clean` retains the output directory and
59
90
  hidden extraction guard for concurrent writer coordination. Verify published
60
91
  artifacts are gone; do not remove that guard while writers may be running.
61
92
 
@@ -134,7 +165,7 @@ with `server.version`; missing/null is unknown, not a failure. A validator
134
165
  major-version warning calls for full extraction and upgrade review, while a match
135
166
  does not certify retained units were migrated. See [writer provenance](https://github.com/lost-in-the/woods/blob/main/docs/PUBLISHED_INDEX.md#manifest-writer-provenance).
136
167
 
137
- Unreleased after `2.0.0.beta3`: incremental/refresh handled source errors keep
168
+ Included in Woods `2.0.0`: incremental/refresh handled source errors keep
138
169
  the previous generation active and leave watch batches pending. Repair the
139
170
  logged source error and retry the complete batch; see
140
171
  [handled source errors](https://github.com/lost-in-the/woods/blob/main/docs/INCREMENTAL_EXTRACTION.md#handled-source-errors-and-retry).
@@ -177,6 +208,24 @@ access with its `WOODS_GIT_DIR` setting. A failed history stream is discarded;
177
208
  repair git access and run full extraction to refresh retained metadata. See the
178
209
  [history contract](https://github.com/lost-in-the/woods/blob/main/docs/CONFIGURATION_REFERENCE.md#git-enrichment-history).
179
210
 
211
+ If per-unit Git metadata is absent, check `git --version` inside the extraction
212
+ process/container as well as repository access. Builds with #551 warn when Git
213
+ cannot execute and a repository is expected; older versions may be silent.
214
+ Source archives without a Git directory remain supported. `GIT_SHA` and
215
+ structural `ready` do not certify history availability. After repairing Git,
216
+ run full extraction; see the
217
+ [missing-executable diagnostic](https://github.com/lost-in-the/woods/blob/main/docs/TROUBLESHOOTING.md#git-executable-is-missing-from-the-extraction-environment).
218
+
219
+ For linked-worktree provenance/history mismatches, check the installed version's
220
+ `WOODS_GIT_DIR` support and compare the selected branch and exact SHA inside the
221
+ extraction environment. Mount the complete shared `.git` at its original path
222
+ with no override, or select `/mounted-common/worktrees/<id>` within a relocated
223
+ complete mount. Derive `<id>` from Git metadata, not the branch name. Selecting
224
+ the shared root uses the primary checkout's HEAD and also changes incremental
225
+ ranges. A commit alone may leave the source-file watcher idle; run full
226
+ extraction after repair or when current Git history is required. See the
227
+ [worktree mount guide](https://github.com/lost-in-the/woods/blob/main/docs/TROUBLESHOOTING.md#git-directory-mounts-for-linked-worktrees).
228
+
180
229
  After a bundle change or removal of a dynamically defined job, incremental
181
230
  extraction can retain stale runtime units. Use a fresh process with the updated
182
231
  bundle for full extraction, then validate. For missing external gem paths,
@@ -205,13 +254,13 @@ Compare the client config with the exact command, absolute `cwd`, bundle, and in
205
254
  bundle exec woods-mcp-start ./tmp/woods
206
255
  ```
207
256
 
208
- If startup says `Could not resolve a published Woods index` (unreleased after
209
- `2.0.0.beta3`) or names a missing `manifest.json` on older versions, first check
257
+ If startup says `Could not resolve a published Woods index` (included in Woods
258
+ `2.0.0`) or names a missing `manifest.json` on older versions, first check
210
259
  the selected index path: an atomic index uses `generation.json` to locate its
211
260
  payload manifest. The new headline does not change index validation or recovery.
212
261
  Point at an existing index before suggesting a new extraction. Prefer the
213
- explicit path above; `WOODS_DIR` is also supported. An unreleased change after
214
- `2.0.0.beta3` adds `WOODS_OUTPUT` after those two choices, so verify the installed
262
+ explicit path above; `WOODS_DIR` is also supported. Woods `2.0.0` includes
263
+ `WOODS_OUTPUT` after those two choices, so verify the installed
215
264
  version's configuration guide before relying on that fallback.
216
265
 
217
266
  Then reconnect through the MCP client and call `woods_status`. Use client-native tool inspection after initialization. Expect 14 packaged Index tools, not all conditional schemas.
@@ -253,6 +302,18 @@ paging alone only visits the discovered prefix. See the
253
302
 
254
303
  ## 4. Check semantic retrieval
255
304
 
305
+ Do not treat structural `ready: true` or bootstrap `hydrated` as proof that
306
+ embeddings exist. Check the installed reader's capabilities: builds with #549
307
+ expose `woods_status.retriever.corpus`, including locally known vector and
308
+ metadata record counts by type. Missing fields or `null` counts mean unknown,
309
+ not zero. Counts include chunks and do not certify complete unit coverage.
310
+ When both stores are known empty, supporting readers return `empty_index` with
311
+ embed or explicit lexical-mode guidance. Follow the
312
+ [corpus diagnostic contract](https://github.com/lost-in-the/woods/blob/main/docs/RETRIEVAL_GUIDE.md#semantic-corpus-diagnostics).
313
+ Older readers need direct embedding-artifact checks; installing this plugin
314
+ does not update the serving gem. Keep reader revision and index writer version
315
+ separate when comparing results.
316
+
256
317
  Configured retrieval defaults (#446) are available in Woods `2.0.0.beta3`. For an installed
257
318
  version that supports them, an omitted tool budget uses the serving retriever's
258
319
  configured default; an explicit budget overrides it. Standalone MCP does not
@@ -296,6 +357,14 @@ endpoint to silence this warning.
296
357
 
297
358
  Console failures are live Rails/config/security failures, not Index failures. Verify authorized environment, Rails boot, `WOODS_CONSOLE_CONFIG` or direct `cwd`, blocked-table policy, credentials, and stderr.
298
359
 
360
+ For stdio parse errors or response mismatches during tool calls, check for Rails
361
+ logs on stdout. Through Woods `2.0.0.beta4`, stdout is restored after boot;
362
+ configure the Console process's logger to use stderr or a file. Runtime stdout
363
+ isolation is included in Woods `2.0.0`: verify a patched installed revision
364
+ before relying on it. Prefer `bundle exec rake woods:console`; direct Rails
365
+ runner invocation cannot capture output already emitted during Rails boot.
366
+ See the [Console logging diagnosis](https://github.com/lost-in-the/woods/blob/main/docs/CONSOLE_MCP_SETUP.md#rails-logs-break-mcp-protocol).
367
+
299
368
  For MySQL SQL refusals, inspect the executing session's `sql_mode` and the installed version's Console guide. Do not change quote modes to bypass a security refusal.
300
369
 
301
370
  For SQLite SQL refusals on `2.0.0.beta4` or a reviewed revision containing its Console corrections, consult the installed Console guide for supported identifier and table-reference syntax. Simplify the query to supported syntax; never relax the blocked-table or function policy. These builds also check resolved default scopes and scan normalized response values. Confirm a patched gem is published before recommending it, and check the installed version’s canonical Console guide; do not infer release availability from this plugin.
@@ -16,7 +16,7 @@ Follow the [agent guide](https://github.com/lost-in-the/woods/blob/main/docs/AGE
16
16
  when instructions are absent. A registered tool does not establish retrieval
17
17
  readiness or authorize maintenance or live Console access.
18
18
 
19
- Call `woods_status` before relying on the index. Require a ready index with a current generation and non-zero counts for the types you need; use `codebase_retrieve` only when status reports retrieval enabled. If status is unhealthy or the generation predates the code under review, report that and ask the owner to run `woods:incremental` or `woods:extract` — do not present "not found" as proof the code does not exist.
19
+ Call `woods_status` before relying on the index. Require a ready index with a current generation and non-zero counts for the types you need; verify the retrieval mode and its data before using `codebase_retrieve` (see Conceptual questions below). If status is unhealthy or the generation predates the code under review, report that and ask the owner to run `woods:incremental` or `woods:extract` — do not present "not found" as proof the code does not exist.
20
20
 
21
21
  ## The default loop
22
22
 
@@ -31,9 +31,9 @@ Identifiers are namespaced and typed; never invent one from a filename when `sea
31
31
 
32
32
  - **Code review / change impact**: `lookup` the changed unit, then `dependents` at depth 1 before going deeper. Group results by relationship type and layer; report direct dependents separately from inferred downstream impact. A graph edge is not test coverage — select tests from mappings and repository search.
33
33
  - **Audit / architecture assessment**: `graph_analysis` for orphans, dead ends, hubs, cycles, bridges, cross-database edges, volatile dependencies, and undeclared package edges; `domain_clusters` for architectural domains; `pagerank` for high-impact units worth reading first.
34
- - **Investigating behavior / debugging**: `trace_flow` from the user-visible entry point (route, controller action, job, mailer, service), `lookup` at ambiguous steps, and verify anything conditional or dynamically dispatched in source and tests — do not infer call order from a dependency edge.
34
+ - **Investigating behavior / debugging**: find the exact indexed unit with `search` and `lookup`, then use `trace_flow` with `UnitIdentifier` or `UnitIdentifier#method` (for example, `CheckoutService#order`). Bare `order` names a unit, potentially a factory, rather than locating an application method. Receiverless local calls may remain unexpanded; inspect their source or trace the owning unit's method explicitly. Flow output is not proof of runtime execution or exhaustive call coverage. See the [flow workflow](https://github.com/lost-in-the/woods/blob/main/docs/AGENT_GUIDE.md#trace-a-feature-flow).
35
35
  - **Onboarding**: `structure` for the codebase overview, `lookup` and `dependencies`/`dependents` for a unit's neighborhood, and `domain_clusters` for the domain map, then the default loop on the units that matter.
36
- - **Conceptual questions**: `codebase_retrieve` when status says ready; govern with `budget` (never `limit`), then verify key units with `lookup`.
36
+ - **Conceptual questions**: check retrieval mode and data before `codebase_retrieve`; structural `ready` alone does not establish semantic availability. On readers supporting #549, inspect `retriever.corpus`; missing or unknown counts require checking embedding artifacts. Govern with `budget` (never `limit`), then verify key units with `lookup`.
37
37
 
38
38
  ## Boundaries
39
39
 
@@ -60,12 +60,12 @@ PORO and library targets. No dependents or test-only dependents do not establish
60
60
  absence of production callers; check source before making that claim.
61
61
 
62
62
  The response `graph_coverage` notice, `total_is_exact` field, and human label
63
- `witness types unambiguous` (#470/#471) are unreleased after Woods `2.0.0.beta3`.
63
+ `witness types unambiguous` (#470/#471) are included in Woods `2.0.0`.
64
64
  Verify the installed server version and actual response fields; this plugin does
65
65
  not add them. Apply these limits to older servers even without the notice.
66
66
  Supporting stdio and HTTP servers expose the paginated traversal payload in
67
67
  `structuredContent.data` independently of the text renderer (#481, also
68
- unreleased after `2.0.0.beta3`). Check the installed response; older default
68
+ included in Woods `2.0.0`). Check the installed response; older default
69
69
  responses may carry only text. Do not pass an unsupported `format` argument.
70
70
 
71
71
  `total_is_exact: false` means a budget-limited prefix; a true value describes only
@@ -106,7 +106,7 @@ recorded reachability does not establish observed execution. See the
106
106
 
107
107
  Pass explicit `limit` and `offset` when paging `graph_analysis`. Enforcing the
108
108
  advertised default of 20 rows per section and preserving total/offset on last
109
- and empty pages (#519) are unreleased after `2.0.0.beta3`; check the installed
109
+ and empty pages (#519) are included in Woods `2.0.0`; check the installed
110
110
  response rather than inferring support from the plugin version. On supporting
111
111
  servers, read `<section>_total` and `<section>_offset` in JSON, or the human
112
112
  pagination notice. An empty later page does not mean no findings. Totals count
@@ -55,11 +55,26 @@ when unavailable. See the
55
55
 
56
56
  Use this shape for any stdio-capable MCP client, adapted to the client's configuration location. `woods-mcp-start` validates and launches; it does not install or auto-restart.
57
57
 
58
+ MCP registration does not start automatic indexing. Existing readers observe
59
+ published generations without reconnecting; separately verify the watcher owner,
60
+ startup catch-up, and a real edit. Native launcher/Puma installation (#538) is
61
+ included in Woods `2.0.0`: check installed `woods-watch` and generator help
62
+ before offering it. Preserve the existing external service in Docker/Grove and
63
+ keep its source/index aligned across switches. See
64
+ [automatic maintenance](https://github.com/lost-in-the/woods/blob/main/docs/AUTOMATIC_MAINTENANCE.md).
65
+
58
66
  Writer-version provenance (#323) is available in Woods `2.0.0.beta3`; check the installed
59
67
  gem version's release notes before expecting `index.woods_version` in `woods_status`. It reports
60
68
  the last manifest publisher, independently of `server.version`. Treat missing/null
61
69
  as unknown and see [writer provenance](https://github.com/lost-in-the/woods/blob/main/docs/PUBLISHED_INDEX.md#manifest-writer-provenance).
62
70
 
71
+ Verify semantic retrieval separately from structural `ready`. A reachable
72
+ provider and bootstrap `hydrated` can coexist with empty stores. If the recorded
73
+ reader supports #549, inspect `retriever.corpus` for local record counts and
74
+ known-empty diagnostics; absent or unknown counts require checking embedding
75
+ artifacts. These fields do not certify embedding coverage. See the
76
+ [readiness distinction](https://github.com/lost-in-the/woods/blob/main/docs/RETRIEVAL_GUIDE.md#semantic-corpus-diagnostics).
77
+
63
78
  When Woods is installed only in Docker, prefer running the server through the application container:
64
79
 
65
80
  ```json
@@ -74,7 +89,13 @@ When Woods is installed only in Docker, prefer running the server through the ap
74
89
  }
75
90
  ```
76
91
 
77
- Use a host-side bundle only after verifying Ruby, the application bundle, and the index are available on the host. Always pass the path visible to the process that runs `woods-mcp`. Prefer an explicit index path on all versions. After `2.0.0.beta3`, an unreleased change adds `WOODS_OUTPUT` as a fallback after the positional path and `WOODS_DIR`; check the installed version's configuration guide before relying on it. `woods-mcp-start` still refuses a missing path rather than selecting its working directory.
92
+ Use a host-side bundle only after verifying Ruby, the application bundle, and the index are available on the host. Always pass the path visible to the process that runs `woods-mcp`. Prefer an explicit index path on all versions. Woods `2.0.0` includes `WOODS_OUTPUT` as a fallback after the positional path and `WOODS_DIR`; check the installed version's configuration guide before relying on it. `woods-mcp-start` still refuses a missing path rather than selecting its working directory.
93
+
94
+ For linked worktrees, verify source/index alignment and the extraction's Git
95
+ branch and exact SHA. Preserve the complete shared Git layout and select the
96
+ worktree-specific directory when using the installed version's `WOODS_GIT_DIR`
97
+ override; the shared root selects the primary checkout's HEAD. Follow the
98
+ [worktree mount guide](https://github.com/lost-in-the/woods/blob/main/docs/TROUBLESHOOTING.md#git-directory-mounts-for-linked-worktrees).
78
99
 
79
100
  A read-only index mount is sufficient for structural tools. The `reload` tool for in-memory semantic retrieval also takes Woods' shared on-disk writer lock, so the MCP process needs write access to the index directory. Without it, reload returns a typed degraded error and keeps serving the previous aligned generation. Either grant that access or restart the MCP process after publishing a new embedded index.
80
101
 
@@ -116,6 +137,12 @@ Then add a direct Console process:
116
137
 
117
138
  For Docker/SSH, configure `~/.woods/console.yml` or `WOODS_CONSOLE_CONFIG`; the launcher owns process replacement. Direct Docker stdio uses `docker exec -i`, or `docker compose exec -T` to disable Compose's pseudo-TTY while retaining stdin.
118
139
 
140
+ Reserve stdout for MCP. Through Woods `2.0.0.beta4`, configure the Console
141
+ process's Rails logger to use stderr or a file, including logs during queries.
142
+ Runtime stdout isolation is included in Woods `2.0.0`; verify the installed
143
+ revision before relying on it. Use the rake entry point to capture Rails boot
144
+ output as well.
145
+
119
146
  Console registers nine default tools. `config.console_embedded_read_tools = true` explicitly adds `console_sql` and `console_query` for eleven total. Tier 2, Tier 3, and `console_eval` are inventory-only in supported packaged modes.
120
147
 
121
148
  ## Shape 3: Authenticated Console HTTP
@@ -38,7 +38,7 @@ This skill describes the Woods 2.x line; the authoritative minimum version lives
38
38
 
39
39
  Choose the published version using the canonical
40
40
  [installation guide](https://github.com/lost-in-the/woods/blob/main/docs/GETTING_STARTED.md#1-install-the-gem)
41
- and its linked README release table. When only prereleases are published for
41
+ and confirm the selected version on RubyGems. When only prereleases are published for
42
42
  2.x, add the exact published beta/RC constraint shown there to the development
43
43
  group; `~> 2.0` does not select prereleases. Use `gem "woods", "~> 2.0"` only after
44
44
  a stable 2.x release is published. Follow the selected version's tag docs and
@@ -108,9 +108,58 @@ When Woods is installed only in Docker, launch it through the application servic
108
108
  }
109
109
  ```
110
110
 
111
+ For linked worktrees, verify source/index alignment and the extraction's Git
112
+ branch and exact SHA. Preserve the complete shared Git layout and select the
113
+ worktree-specific directory when using the installed version's `WOODS_GIT_DIR`
114
+ override; the shared root selects the primary checkout's HEAD. Follow the
115
+ [worktree mount guide](https://github.com/lost-in-the/woods/blob/main/docs/TROUBLESHOOTING.md#git-directory-mounts-for-linked-worktrees).
116
+
111
117
  Reconnect and call `woods_status`, then `search`, `lookup`, and `dependents` for a known class. The normal Index Server has 14 tools. `codebase_retrieve` requires configured embeddings in semantic mode; see the lexical capability check below for the opt-in provider-free mode.
112
118
 
113
- Offer to add `bundle exec rake woods:watch` to the existing development process manager. When authorized, it catches up missed changes and automatically maintains the structural index; the Index Server refreshes on its next call, so ordinary edits need no manual extraction or MCP restart. Use the standalone watch command; do not prepend the `environment` task. Check the installed version's watch guide before relying on automatic startup reconciliation. State that live boot-captured changes require supervisor restart, Docker may need `WOODS_WATCH_POLL=1`, and semantic vectors still need `woods:embed_incremental`.
119
+ Structural readiness alone does not verify semantic retrieval. If that mode is
120
+ requested, confirm an embedding run and a useful retrieval result. Readers with
121
+ #549 expose `retriever.corpus` counts; check the installed capability before
122
+ expecting them. Unknown counts are not zero, and positive counts do not certify
123
+ complete embedding coverage. See
124
+ [corpus diagnostics](https://github.com/lost-in-the/woods/blob/main/docs/RETRIEVAL_GUIDE.md#semantic-corpus-diagnostics).
125
+
126
+ Offer one automatic-maintenance owner within the setup scope. The managed launcher,
127
+ watcher generator, and Puma adapter (#538) are **included in Woods `2.0.0`**.
128
+ Record the loaded gem path and revision, then verify `bundle exec woods-watch
129
+ --help` and `bin/rails generate woods:watch --help` before using them. Follow the
130
+ [managed startup runbook](https://github.com/lost-in-the/woods/blob/main/docs/WATCH_DAEMON.md#managed-development-startup):
131
+ Puma for simple Rails startup, an explicit verified Foreman command/Procfile, or
132
+ the existing external Docker/Grove supervisor. Preview before applying within
133
+ existing authorization. Preserve `bin/dev`; never claim an unused Procfile is
134
+ active. Keep the portable receipt with generated files and respect edit conflicts.
135
+ Puma installation supports the normal default `config/puma.rb` route; an existing
136
+ environment-specific file or custom `-C` route needs a different explicit owner.
137
+ The #542 guard included in Woods `2.0.0` checks plugin files in the active gem, including Git/path
138
+ bundles. Older gems without the plugin skip watcher startup. Existing generated
139
+ Puma setups need an explicit `--operation update --mode puma` (preview first) to
140
+ upgrade the owned guard in place; repeating setup preserves it. The wrapper and
141
+ Foreman entry still require a supporting gem. Remove owned setup before a permanent
142
+ downgrade; do not hand-edit the receipt or its managed block.
143
+ Run setup in the normal application bundle environment. The #540 fix in Woods `2.0.0`
144
+ preserves `BUNDLE_PATH`, `BUNDLE_APP_CONFIG`, and group selection during preflight;
145
+ older Git builds may falsely report missing gems. Check the loaded revision
146
+ before changing persistent Bundler settings to work around that error.
147
+ The #544 fix in Woods `2.0.0` makes generator refusals exit nonzero. Earlier Git builds
148
+ can exit zero after printing a refusal; verify the diagnostic and applied setup
149
+ before treating their exit status as installation success.
150
+ For an interrupted install, use the generator's `--operation recover --pretend`
151
+ before applying recovery; preserve journals when concurrent edits block it. The
152
+ Rails generator command boots the app first: use the runbook's direct bundled
153
+ Ruby recovery helper when an initializer prevents boot.
154
+
155
+ On older gems, use the raw task only with a restart-capable external supervisor;
156
+ do not place it bare in Foreman, where exit 75 stops the whole stack. Use the
157
+ application's real Rails task entrypoint without a preceding `environment` task.
158
+ Managed mode rejects idle TTL and does not take over conflicting owners. Verify
159
+ startup catch-up, an edit, and a planned restart through the existing MCP reader;
160
+ for Grove, also verify worktree/source/index alignment. Docker may need polling.
161
+ Semantic vectors still need `woods:embed_incremental`; hooks and MCP registration
162
+ do not install watcher startup.
114
163
 
115
164
  Foreign-host heartbeat trust (`WOODS_WATCH_TRUST_FOREIGN_HOST=1`, #321) is available in
116
165
  Woods `2.0.0.beta3`.
@@ -155,13 +204,18 @@ for transport, retry and custom-root limits.
155
204
 
156
205
  ## Ask before expanding scope
157
206
 
158
- For pgvector, match the provider output and migration dimensions within 1–2,000. Default `text-embedding-3-large` output (3,072) needs an explicit smaller provider width or another backend; never silently truncate vectors. Early adapter/generator refusal is unreleased after `2.0.0.beta3`, so check the installed revision. See the [dimension contract](https://github.com/lost-in-the/woods/blob/main/docs/CONFIGURATION_REFERENCE.md#pgvector-postgresql).
207
+ For pgvector, match the provider output and migration dimensions within 1–2,000. Default `text-embedding-3-large` output (3,072) needs an explicit smaller provider width or another backend; never silently truncate vectors. Early adapter/generator refusal is included in Woods `2.0.0`, so check the installed revision. See the [dimension contract](https://github.com/lost-in-the/woods/blob/main/docs/CONFIGURATION_REFERENCE.md#pgvector-postgresql).
159
208
 
160
209
  Require explicit approval before adding Ollama/OpenAI, pgvector/Qdrant, secrets, Console MCP/live-data access, HTTP transport, or purge overrides. The `:local` preset avoids cloud keys but requires the `sqlite3` gem, an installed/running Ollama service, and a pulled model (`ollama pull nomic-embed-text` by default); `:shared_filesystem` avoids sqlite3 but still uses Ollama. Recommend `gem "tokenizers", "~> 0.5"` for exact counting on dense Ruby source, while stating that it is optional.
161
210
 
162
211
  ## Handoff
163
212
 
164
- Report the Woods version, branch, files changed, commands/results, index path, MCP calls verified, semantic retrieval status, Console status, and unresolved risks. Never infer availability from source schemas alone.
213
+ Report the Woods version/revision, branch, files changed, commands/results, index
214
+ path, MCP calls verified, semantic retrieval and Console status, and unresolved
215
+ risks. For automatic maintenance record the owner, actual startup command,
216
+ completed catch-up, observed edit/restart, and worktree verification. Report
217
+ refresh hooks, session checks, and context hints separately. Never infer
218
+ availability from source schemas or a live process alone.
165
219
 
166
220
  Canonical runbook: [AGENT_SETUP.md](https://github.com/lost-in-the/woods/blob/main/docs/AGENT_SETUP.md).
167
221
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: woods
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0.beta4
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Leah Armstrong
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-09-22 00:00:00.000000000 Z
11
+ date: 2026-09-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mcp
@@ -113,6 +113,7 @@ description: |
113
113
  email:
114
114
  - info@leah.wtf
115
115
  executables:
116
+ - woods-watch
116
117
  - woods-mcp
117
118
  - woods-mcp-start
118
119
  - woods-console-mcp
@@ -133,6 +134,7 @@ files:
133
134
  - assets/woods-wordmark-white-with-bg.png
134
135
  - docs/AGENT_GUIDE.md
135
136
  - docs/AGENT_SETUP.md
137
+ - docs/AUTOMATIC_MAINTENANCE.md
136
138
  - docs/BACKEND_MATRIX.md
137
139
  - docs/CLIENT_HOOKS.md
138
140
  - docs/CONFIGURATION_REFERENCE.md
@@ -171,11 +173,14 @@ files:
171
173
  - exe/woods-mcp
172
174
  - exe/woods-mcp-http
173
175
  - exe/woods-mcp-start
176
+ - exe/woods-watch
174
177
  - lib/generators/woods/install_generator.rb
175
178
  - lib/generators/woods/pgvector_generator.rb
176
179
  - lib/generators/woods/templates/add_pgvector_to_woods.rb.erb
177
180
  - lib/generators/woods/templates/create_woods_tables.rb.erb
178
181
  - lib/generators/woods/templates/woods.rb.tt
182
+ - lib/generators/woods/watch_generator.rb
183
+ - lib/puma/plugin/woods.rb
179
184
  - lib/tasks/woods.rake
180
185
  - lib/tasks/woods_checks.rake
181
186
  - lib/tasks/woods_evaluation.rake
@@ -235,6 +240,7 @@ files:
235
240
  - lib/woods/console/sql_table_scanner.rb
236
241
  - lib/woods/console/sql_validator.rb
237
242
  - lib/woods/console/sqlite_read_guard.rb
243
+ - lib/woods/console/stdio_transport.rb
238
244
  - lib/woods/console/table_gate.rb
239
245
  - lib/woods/console/tool_specs.rb
240
246
  - lib/woods/console/tools/tier1.rb
@@ -430,6 +436,7 @@ files:
430
436
  - lib/woods/resilience/retryable_provider.rb
431
437
  - lib/woods/resolved_config.rb
432
438
  - lib/woods/retrieval/context_assembler.rb
439
+ - lib/woods/retrieval/corpus_status.rb
433
440
  - lib/woods/retrieval/lexical_assembler.rb
434
441
  - lib/woods/retrieval/lexical_index.rb
435
442
  - lib/woods/retrieval/query_classifier.rb
@@ -469,6 +476,7 @@ files:
469
476
  - lib/woods/source_inputs/verifier.rb
470
477
  - lib/woods/storage/graph_store.rb
471
478
  - lib/woods/storage/inapplicable_backend.rb
479
+ - lib/woods/storage/local_corpus_stats.rb
472
480
  - lib/woods/storage/metadata_store.rb
473
481
  - lib/woods/storage/pgvector.rb
474
482
  - lib/woods/storage/qdrant.rb
@@ -491,10 +499,32 @@ files:
491
499
  - lib/woods/util/uuid5.rb
492
500
  - lib/woods/version.rb
493
501
  - lib/woods/watch/boot_snapshot.rb
502
+ - lib/woods/watch/child_environment.rb
503
+ - lib/woods/watch/cli.rb
494
504
  - lib/woods/watch/daemon.rb
505
+ - lib/woods/watch/event_stream.rb
506
+ - lib/woods/watch/guardian.rb
507
+ - lib/woods/watch/installation.rb
508
+ - lib/woods/watch/installation/layout.rb
509
+ - lib/woods/watch/installation/options.rb
510
+ - lib/woods/watch/installation/planner.rb
511
+ - lib/woods/watch/installation/probe.rb
512
+ - lib/woods/watch/installation/receipt.rb
513
+ - lib/woods/watch/installation/recovery.rb
514
+ - lib/woods/watch/installation/templates.rb
515
+ - lib/woods/watch/lifecycle.rb
495
516
  - lib/woods/watch/listen_watcher.rb
517
+ - lib/woods/watch/managed_child.rb
518
+ - lib/woods/watch/managed_cleanup.rb
519
+ - lib/woods/watch/managed_process.rb
496
520
  - lib/woods/watch/polling_watcher.rb
521
+ - lib/woods/watch/puma_adapter.rb
522
+ - lib/woods/watch/puma_child.rb
497
523
  - lib/woods/watch/status.rb
524
+ - lib/woods/watch/supervision_records.rb
525
+ - lib/woods/watch/supervision_status.rb
526
+ - lib/woods/watch/supervisor.rb
527
+ - lib/woods/watch/supervisor_reporting.rb
498
528
  - lib/woods/watch/tree_scan.rb
499
529
  - lib/woods/watch/watcher.rb
500
530
  - plugin/.claude-plugin/plugin.json
@@ -517,10 +547,10 @@ licenses:
517
547
  - MIT
518
548
  metadata:
519
549
  homepage_uri: https://github.com/lost-in-the/woods
520
- source_code_uri: https://github.com/lost-in-the/woods/tree/v2.0.0.beta4
521
- changelog_uri: https://github.com/lost-in-the/woods/blob/v2.0.0.beta4/CHANGELOG.md
550
+ source_code_uri: https://github.com/lost-in-the/woods/tree/v2.0.0
551
+ changelog_uri: https://github.com/lost-in-the/woods/blob/v2.0.0/CHANGELOG.md
522
552
  bug_tracker_uri: https://github.com/lost-in-the/woods/issues
523
- documentation_uri: https://github.com/lost-in-the/woods/tree/v2.0.0.beta4/docs
553
+ documentation_uri: https://github.com/lost-in-the/woods/tree/v2.0.0/docs
524
554
  rubygems_mfa_required: 'true'
525
555
  post_install_message:
526
556
  rdoc_options: []