woods 1.6.4 → 2.0.0.beta1
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +1879 -37
- data/CONTRIBUTING.md +195 -137
- data/README.md +162 -520
- data/SECURITY.md +92 -0
- data/assets/woods-wordmark-white-with-bg.png +0 -0
- data/docs/AGENT_GUIDE.md +204 -0
- data/docs/AGENT_SETUP.md +205 -0
- data/docs/BACKEND_MATRIX.md +470 -0
- data/docs/CONFIGURATION_REFERENCE.md +620 -0
- data/docs/CONSOLE_MCP_SETUP.md +829 -0
- data/docs/DOCKER_SETUP.md +454 -0
- data/docs/EMBEDDING_MODELS.md +136 -0
- data/docs/EVALUATION.md +91 -0
- data/docs/EXTRACTOR_REFERENCE.md +765 -0
- data/docs/FAQ.md +544 -0
- data/docs/GETTING_STARTED.md +183 -0
- data/docs/INCREMENTAL_EXTRACTION.md +415 -0
- data/docs/INTERNALS.md +415 -0
- data/docs/MCP_HTTP_TRANSPORT.md +144 -0
- data/docs/MCP_SERVERS.md +231 -0
- data/docs/MCP_TOOL_COOKBOOK.md +987 -0
- data/docs/MCP_WORKTREE_SETUP.md +127 -0
- data/docs/NOTION_INTEGRATION.md +283 -0
- data/docs/OBSIDIAN_INTEGRATION.md +170 -0
- data/docs/PUBLISHED_INDEX.md +197 -0
- data/docs/README.md +94 -0
- data/docs/RETRIEVAL_GUIDE.md +267 -0
- data/docs/TOKEN_BENCHMARK.md +68 -0
- data/docs/TROUBLESHOOTING.md +841 -0
- data/docs/UNBLOCKED_INTEGRATION.md +279 -0
- data/docs/UPGRADING_TO_2.md +321 -0
- data/docs/WATCH_DAEMON.md +667 -0
- data/docs/WHY_WOODS.md +219 -0
- data/exe/woods-console +39 -3
- data/exe/woods-console-mcp +21 -35
- data/exe/woods-mcp +20 -7
- data/exe/woods-mcp-http +78 -24
- data/exe/woods-mcp-start +57 -52
- data/lib/generators/woods/install_generator.rb +6 -5
- data/lib/generators/woods/pgvector_generator.rb +6 -3
- data/lib/generators/woods/templates/add_pgvector_to_woods.rb.erb +29 -9
- data/lib/generators/woods/templates/create_woods_tables.rb.erb +5 -1
- data/lib/generators/woods/templates/woods.rb.tt +49 -28
- data/lib/tasks/woods.rake +622 -168
- data/lib/tasks/woods_checks.rake +107 -0
- data/lib/tasks/woods_evaluation.rake +164 -80
- data/lib/woods/ast/call_site_extractor.rb +6 -15
- data/lib/woods/ast/method_extractor.rb +19 -9
- data/lib/woods/ast/parser.rb +54 -8
- data/lib/woods/atomic_file.rb +40 -1
- data/lib/woods/builder.rb +310 -22
- data/lib/woods/cache/cache_middleware.rb +18 -13
- data/lib/woods/cache/cache_store.rb +9 -1
- data/lib/woods/cache/solid_cache_store.rb +6 -4
- data/lib/woods/change_set.rb +88 -0
- data/lib/woods/checks/generation_resolution.rb +34 -0
- data/lib/woods/checks/moved_messages.rb +186 -0
- data/lib/woods/chunking/semantic_chunker.rb +160 -18
- data/lib/woods/console/audit_logger.rb +12 -3
- data/lib/woods/console/bridge_protocol.rb +3 -16
- data/lib/woods/console/connection_manager.rb +51 -136
- data/lib/woods/console/credential_index.rb +5 -53
- data/lib/woods/console/credential_scanner.rb +15 -16
- data/lib/woods/console/dispatch_pipeline.rb +46 -34
- data/lib/woods/console/embedded_executor.rb +806 -257
- data/lib/woods/console/eval_guard.rb +27 -20
- data/lib/woods/console/input_contract.rb +78 -0
- data/lib/woods/console/model_validator.rb +24 -6
- data/lib/woods/console/rack_middleware.rb +62 -63
- data/lib/woods/console/redactor.rb +10 -24
- data/lib/woods/console/safe_context.rb +45 -45
- data/lib/woods/console/scope_predicate_parser.rb +41 -0
- data/lib/woods/console/server.rb +136 -267
- data/lib/woods/console/sql_noise_stripper.rb +20 -51
- data/lib/woods/console/sql_table_scanner.rb +39 -90
- data/lib/woods/console/sql_validator.rb +455 -85
- data/lib/woods/console/table_gate.rb +2 -2
- data/lib/woods/console/tool_specs.rb +462 -88
- data/lib/woods/console/tools/tier1.rb +0 -3
- data/lib/woods/console/tools/tier4.rb +17 -7
- data/lib/woods/coordination/lock_heartbeat.rb +103 -0
- data/lib/woods/coordination/pipeline_lock.rb +263 -53
- data/lib/woods/db/migrations/007_typed_snapshot_units.rb +45 -0
- data/lib/woods/db/migrator.rb +3 -9
- data/lib/woods/db/schema_version.rb +47 -2
- data/lib/woods/dependency_graph.rb +898 -64
- data/lib/woods/embedding/fake.rb +138 -0
- data/lib/woods/embedding/indexer.rb +832 -40
- data/lib/woods/embedding/openai.rb +77 -19
- data/lib/woods/embedding/provider.rb +189 -11
- data/lib/woods/embedding/text_preparer.rb +1 -1
- data/lib/woods/embedding/token_counter.rb +0 -7
- data/lib/woods/evaluation/ablation_agent_payload.rb +38 -0
- data/lib/woods/evaluation/ablation_executor.rb +67 -0
- data/lib/woods/evaluation/ablation_provenance.rb +38 -0
- data/lib/woods/evaluation/ablation_report_writer.rb +43 -0
- data/lib/woods/evaluation/ablation_runner.rb +173 -0
- data/lib/woods/evaluation/ablation_summary.rb +65 -0
- data/lib/woods/evaluation/ablation_task.rb +66 -0
- data/lib/woods/evaluation/ablation_task_set.rb +77 -0
- data/lib/woods/evaluation/ablation_timed_executor.rb +91 -0
- data/lib/woods/evaluation/ablation_worktree.rb +71 -0
- data/lib/woods/evaluation/baseline.rb +60 -0
- data/lib/woods/evaluation/baseline_runner.rb +11 -3
- data/lib/woods/evaluation/evaluator.rb +41 -8
- data/lib/woods/evaluation/query_set.rb +79 -13
- data/lib/woods/evaluation/report_generator.rb +20 -1
- data/lib/woods/export/unit_facts.rb +0 -11
- data/lib/woods/extracted_unit.rb +22 -63
- data/lib/woods/extractor.rb +2503 -192
- data/lib/woods/extractors/action_cable_extractor.rb +9 -4
- data/lib/woods/extractors/ast_source_extraction.rb +20 -2
- data/lib/woods/extractors/caching_extractor.rb +46 -12
- data/lib/woods/extractors/callback_analyzer.rb +39 -9
- data/lib/woods/extractors/component_discovery.rb +123 -0
- data/lib/woods/extractors/concern_extractor.rb +17 -3
- data/lib/woods/extractors/controller_extractor.rb +389 -29
- data/lib/woods/extractors/decorator_extractor.rb +7 -14
- data/lib/woods/extractors/engine_extractor.rb +53 -8
- data/lib/woods/extractors/event_extractor.rb +55 -4
- data/lib/woods/extractors/factory_extractor.rb +49 -11
- data/lib/woods/extractors/graphql_extractor.rb +162 -66
- data/lib/woods/extractors/i18n_extractor.rb +6 -1
- data/lib/woods/extractors/job_extractor.rb +51 -21
- data/lib/woods/extractors/lib_extractor.rb +23 -17
- data/lib/woods/extractors/line_neutralizer.rb +171 -0
- data/lib/woods/extractors/mailer_extractor.rb +9 -1
- data/lib/woods/extractors/manager_extractor.rb +19 -2
- data/lib/woods/extractors/migration_extractor.rb +22 -11
- data/lib/woods/extractors/model_extractor.rb +292 -57
- data/lib/woods/extractors/package_extractor.rb +154 -0
- data/lib/woods/extractors/phlex_extractor.rb +18 -3
- data/lib/woods/extractors/policy_extractor.rb +6 -5
- data/lib/woods/extractors/poro_extractor.rb +13 -14
- data/lib/woods/extractors/pundit_extractor.rb +3 -3
- data/lib/woods/extractors/rails_source_extractor.rb +24 -7
- data/lib/woods/extractors/rake_task_extractor.rb +158 -30
- data/lib/woods/extractors/reference_patterns.rb +38 -0
- data/lib/woods/extractors/route_extractor.rb +58 -2
- data/lib/woods/extractors/scheduled_job_extractor.rb +51 -35
- data/lib/woods/extractors/serializer_extractor.rb +3 -4
- data/lib/woods/extractors/service_extractor.rb +11 -1
- data/lib/woods/extractors/shared_dependency_scanner.rb +24 -34
- data/lib/woods/extractors/shared_utility_methods.rb +36 -6
- data/lib/woods/extractors/source_nesting.rb +560 -0
- data/lib/woods/extractors/state_machine_extractor.rb +30 -18
- data/lib/woods/extractors/test_mapping_extractor.rb +26 -9
- data/lib/woods/extractors/view_component_extractor.rb +28 -3
- data/lib/woods/extractors/view_engines/erb.rb +17 -3
- data/lib/woods/feedback/gap_detector.rb +9 -3
- data/lib/woods/feedback/store.rb +7 -1
- data/lib/woods/filename_utils.rb +29 -1
- data/lib/woods/flow_analysis/operation_extractor.rb +22 -10
- data/lib/woods/flow_assembler.rb +63 -21
- data/lib/woods/flow_document.rb +1 -0
- data/lib/woods/flow_precomputer.rb +138 -22
- data/lib/woods/gem_mapper.rb +285 -0
- data/lib/woods/generation.rb +185 -0
- data/lib/woods/git_command.rb +38 -0
- data/lib/woods/git_provenance.rb +16 -2
- data/lib/woods/graph_analyzer.rb +408 -34
- data/lib/woods/index_artifact.rb +93 -23
- data/lib/woods/mcp/bearer_auth.rb +92 -22
- data/lib/woods/mcp/bootstrap_state.rb +77 -0
- data/lib/woods/mcp/bootstrapper.rb +582 -77
- data/lib/woods/mcp/config_resolver.rb +66 -6
- data/lib/woods/mcp/errors.rb +60 -0
- data/lib/woods/mcp/index_reader.rb +836 -117
- data/lib/woods/mcp/index_reader_pinning.rb +78 -0
- data/lib/woods/mcp/origin_guard.rb +108 -23
- data/lib/woods/mcp/protocol_policy.rb +98 -0
- data/lib/woods/mcp/provider_probe.rb +45 -6
- data/lib/woods/mcp/renderers/markdown_renderer.rb +72 -4
- data/lib/woods/mcp/renderers/plain_renderer.rb +54 -6
- data/lib/woods/mcp/server.rb +907 -154
- data/lib/woods/mcp/tasks/extension.rb +196 -0
- data/lib/woods/mcp/tasks/request_capture.rb +45 -0
- data/lib/woods/mcp/tasks/store.rb +518 -0
- data/lib/woods/mcp/tool_contract.rb +171 -0
- data/lib/woods/mcp/tool_response_renderer.rb +7 -0
- data/lib/woods/mcp/version_aware_tool_dispatch.rb +3 -9
- data/lib/woods/model_name_cache.rb +19 -1
- data/lib/woods/notion/client.rb +132 -36
- data/lib/woods/notion/exporter.rb +456 -61
- data/lib/woods/notion/mappers/column_mapper.rb +34 -5
- data/lib/woods/notion/mappers/migration_mapper.rb +32 -8
- data/lib/woods/notion/mappers/model_mapper.rb +21 -6
- data/lib/woods/notion/mappers/shared.rb +45 -3
- data/lib/woods/notion/sync_manifest.rb +258 -0
- data/lib/woods/obsidian/errors.rb +6 -0
- data/lib/woods/obsidian/name_mapper.rb +40 -24
- data/lib/woods/obsidian/vault_exporter.rb +103 -36
- data/lib/woods/operator/pipeline_guard.rb +118 -21
- data/lib/woods/operator/status_reporter.rb +20 -3
- data/lib/woods/path_dispatcher.rb +276 -0
- data/lib/woods/payload_store.rb +223 -0
- data/lib/woods/published_index/edge_shaper.rb +61 -0
- data/lib/woods/published_index/generation_catalog.rb +72 -0
- data/lib/woods/published_index/typed_unit_reader.rb +48 -0
- data/lib/woods/published_index.rb +287 -0
- data/lib/woods/railtie.rb +70 -38
- data/lib/woods/railtie_support.rb +167 -0
- data/lib/woods/release.rb +12 -0
- data/lib/woods/reload_policy.rb +206 -0
- data/lib/woods/resilience/circuit_breaker.rb +47 -8
- data/lib/woods/resilience/index_validator.rb +296 -10
- data/lib/woods/resilience/retryable_provider.rb +71 -6
- data/lib/woods/resolved_config.rb +55 -11
- data/lib/woods/retrieval/context_assembler.rb +132 -40
- data/lib/woods/retrieval/query_classifier.rb +25 -6
- data/lib/woods/retrieval/ranker.rb +193 -28
- data/lib/woods/retrieval/search_executor.rb +206 -39
- data/lib/woods/retriever.rb +317 -71
- data/lib/woods/retry_after.rb +22 -2
- data/lib/woods/ruby_analyzer/class_analyzer.rb +10 -14
- data/lib/woods/ruby_analyzer/fqn_builder.rb +2 -0
- data/lib/woods/ruby_analyzer/mermaid_renderer.rb +14 -4
- data/lib/woods/ruby_analyzer/method_analyzer.rb +1 -1
- data/lib/woods/ruby_analyzer.rb +21 -5
- data/lib/woods/session_tracer/file_store.rb +138 -19
- data/lib/woods/session_tracer/redis_store.rb +122 -12
- data/lib/woods/session_tracer/session_flow_assembler.rb +54 -11
- data/lib/woods/session_tracer/session_flow_document.rb +52 -6
- data/lib/woods/session_tracer/solid_cache_coordination.rb +192 -0
- data/lib/woods/session_tracer/solid_cache_store.rb +560 -91
- data/lib/woods/session_tracer/store.rb +14 -1
- data/lib/woods/storage/metadata_store.rb +230 -26
- data/lib/woods/storage/pgvector.rb +180 -22
- data/lib/woods/storage/qdrant.rb +367 -41
- data/lib/woods/storage/snapshotter/metadata.rb +79 -16
- data/lib/woods/storage/snapshotter/vector.rb +128 -17
- data/lib/woods/storage/snapshotter.rb +23 -5
- data/lib/woods/storage/vector_store.rb +49 -8
- data/lib/woods/storage_identity.rb +28 -0
- data/lib/woods/tasks.rb +53 -2
- data/lib/woods/temporal/json_snapshot_store.rb +112 -42
- data/lib/woods/temporal/snapshot_store.rb +139 -42
- data/lib/woods/unblocked/client.rb +119 -17
- data/lib/woods/unblocked/document_builder.rb +34 -2
- data/lib/woods/unblocked/exporter.rb +63 -27
- data/lib/woods/unblocked/rate_limiter.rb +23 -9
- data/lib/woods/unblocked/sync_manifest.rb +16 -8
- data/lib/woods/update_check.rb +24 -1
- data/lib/woods/util/uuid5.rb +124 -0
- data/lib/woods/version.rb +1 -1
- data/lib/woods/watch/daemon.rb +1345 -0
- data/lib/woods/watch/listen_watcher.rb +81 -0
- data/lib/woods/watch/polling_watcher.rb +137 -0
- data/lib/woods/watch/status.rb +169 -0
- data/lib/woods/watch/tree_scan.rb +163 -0
- data/lib/woods/watch/watcher.rb +100 -0
- data/lib/woods.rb +53 -9
- data/plugin/.claude-plugin/plugin.json +18 -0
- data/plugin/hooks/hooks.json +29 -0
- data/plugin/hooks/woods-post-edit.sh +226 -0
- data/plugin/hooks/woods-session-start.sh +77 -0
- data/plugin/skills/woods-agent-enable/SKILL.md +51 -0
- data/plugin/skills/woods-diagnose/SKILL.md +75 -0
- data/plugin/skills/woods-investigate/SKILL.md +39 -0
- data/plugin/skills/woods-mcp-config/SKILL.md +101 -0
- data/plugin/skills/woods-setup/SKILL.md +99 -0
- metadata +102 -30
- data/lib/woods/console/adapter_family.rb +0 -39
- data/lib/woods/console/adapters/cache_adapter.rb +0 -58
- data/lib/woods/console/adapters/good_job_adapter.rb +0 -33
- data/lib/woods/console/adapters/job_adapter.rb +0 -74
- data/lib/woods/console/adapters/sidekiq_adapter.rb +0 -33
- data/lib/woods/console/adapters/solid_queue_adapter.rb +0 -33
- data/lib/woods/console/bridge.rb +0 -210
- data/lib/woods/console/credential_scanner_registry.rb +0 -36
- data/lib/woods/console/encrypted_credential_snapshot.rb +0 -16
- data/lib/woods/console/sql_output_policy.rb +0 -535
- data/lib/woods/console/sqlite_read_guard.rb +0 -46
- data/lib/woods/formatting/claude_adapter.rb +0 -98
- data/lib/woods/formatting/generic_adapter.rb +0 -56
- data/lib/woods/formatting/gpt_adapter.rb +0 -64
- data/lib/woods/mcp/http_transport_options.rb +0 -15
- data/lib/woods/mcp/origin_policy.rb +0 -113
- data/lib/woods/notion/mapper.rb +0 -40
- data/lib/woods/observability/health_check.rb +0 -79
- data/lib/woods/observability/instrumentation.rb +0 -34
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: woods-mcp-config
|
|
3
|
+
description: Configure Woods MCP connections with the exact client JSON shapes and token rules — the Index Server over stdio or Docker, and the authorized Console server over stdio or authenticated HTTP. Use when wiring a Woods server into any MCP client configuration (.mcp.json, Claude Code, desktop clients), pointing an agent at a Rails app's index, or enabling live-data Console access.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Woods MCP configuration
|
|
7
|
+
|
|
8
|
+
## Preflight
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
bundle info woods
|
|
12
|
+
bin/rails woods:validate
|
|
13
|
+
bin/rails woods:stats
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
This skill describes the Woods 2.x line; the authoritative minimum version lives in the marketplace entry. Operate only against capabilities the recorded installed version provides. Detect the MCP client, app root, host vs Docker Rails process, the filesystem context that contains the application bundle and index, and whether live-data access is actually required.
|
|
17
|
+
|
|
18
|
+
Default to Index-only. It reads generated code context and exposes 14 tools. Console MCP boots Rails and reads live data; ask before enabling it.
|
|
19
|
+
|
|
20
|
+
## Shape 1: Index-only
|
|
21
|
+
|
|
22
|
+
```json
|
|
23
|
+
{
|
|
24
|
+
"mcpServers": {
|
|
25
|
+
"woods": {
|
|
26
|
+
"command": "bundle",
|
|
27
|
+
"args": ["exec", "woods-mcp-start", "./tmp/woods"],
|
|
28
|
+
"cwd": "/absolute/path/to/app"
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
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.
|
|
35
|
+
|
|
36
|
+
When Woods is installed only in Docker, prefer running the server through the application container:
|
|
37
|
+
|
|
38
|
+
```json
|
|
39
|
+
{
|
|
40
|
+
"mcpServers": {
|
|
41
|
+
"woods": {
|
|
42
|
+
"command": "docker",
|
|
43
|
+
"args": ["compose", "exec", "-T", "app", "bundle", "exec", "woods-mcp", "/app/tmp/woods"],
|
|
44
|
+
"cwd": "/absolute/host/path/to/app"
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
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`.
|
|
51
|
+
|
|
52
|
+
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.
|
|
53
|
+
|
|
54
|
+
## Shape 2: Index plus authorized Console
|
|
55
|
+
|
|
56
|
+
After explicit authorization, enable the live-data master switch in the Rails initializer. The process exits while it remains false:
|
|
57
|
+
|
|
58
|
+
```ruby
|
|
59
|
+
Woods.configure do |config|
|
|
60
|
+
config.console_mcp_enabled = true
|
|
61
|
+
config.console_mcp_token = ENV["WOODS_CONSOLE_MCP_TOKEN"]
|
|
62
|
+
end
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
The token authenticates HTTP requests and is not sent by a stdio client. Production Rails boot still requires `WOODS_CONSOLE_MCP_TOKEN` to contain at least 32 characters whenever Console is enabled, including for a stdio-only setup. Keep it in the application's secret store. Outside production, omitting it warns and leaves the Console HTTP endpoint guarded with 401.
|
|
66
|
+
|
|
67
|
+
Then add a direct Console process:
|
|
68
|
+
|
|
69
|
+
```json
|
|
70
|
+
"woods-console": {
|
|
71
|
+
"command": "bundle",
|
|
72
|
+
"args": ["exec", "woods-console-mcp"],
|
|
73
|
+
"cwd": "/absolute/path/to/app"
|
|
74
|
+
}
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
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.
|
|
78
|
+
|
|
79
|
+
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.
|
|
80
|
+
|
|
81
|
+
## Shape 3: Authenticated Console HTTP
|
|
82
|
+
|
|
83
|
+
Use only after authorization and server-side setup:
|
|
84
|
+
|
|
85
|
+
```json
|
|
86
|
+
"woods-console": {
|
|
87
|
+
"type": "streamable-http",
|
|
88
|
+
"url": "https://app.example.test/mcp/console",
|
|
89
|
+
"headers": { "Authorization": "Bearer <token>" }
|
|
90
|
+
}
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
Require `console_mcp_enabled`, a strong token, allowed origins, TLS, and the Console security controls. Never commit the token or expose an unauthenticated listener.
|
|
94
|
+
|
|
95
|
+
## Verify
|
|
96
|
+
|
|
97
|
+
Reconnect through the client so it performs its supported MCP negotiation. Clients on current MCP protocol revisions use per-request metadata/discovery; older clients initialize first — the server supports both. Call `woods_status`, `search`, and `lookup`. For Console, inspect the registered list and call `console_status` only in the authorized environment.
|
|
98
|
+
|
|
99
|
+
Do not use an isolated raw JSON-RPC request as proof of MCP health. Do not claim conditional Index or inventory-only Console schemas are callable.
|
|
100
|
+
|
|
101
|
+
Canonical guide: [MCP_SERVERS.md](https://github.com/lost-in-the/woods/blob/main/docs/MCP_SERVERS.md).
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: woods-setup
|
|
3
|
+
description: Install, upgrade, and first-run-configure the Woods Rails code-intelligence gem — Gemfile entry, generator, extraction, index verification, MCP registration, and the 1.x-to-2.x upgrade path. Use whenever a user wants Woods added to or upgraded in a Rails app, or asks for a runtime-accurate codebase index for AI tools, even without naming Woods' components.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Woods setup
|
|
7
|
+
|
|
8
|
+
Install a structural Index Server first. Embeddings and Console MCP are separate opt-ins.
|
|
9
|
+
|
|
10
|
+
## Preflight
|
|
11
|
+
|
|
12
|
+
Read repository instructions and preserve unrelated changes. Record:
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
git status --short --branch
|
|
16
|
+
ruby --version
|
|
17
|
+
bundle exec rails --version
|
|
18
|
+
bundle info woods 2>/dev/null || true
|
|
19
|
+
bundle exec rails runner 'puts Rails.application.class.name'
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
This skill describes the Woods 2.x line; the authoritative minimum version lives in the marketplace entry. Operate only against capabilities the recorded installed version provides, and for an older gem use the documentation on that version's tag. Determine host vs Docker execution, database adapter, migration policy, existing Woods config/tables, and which filesystem context contains the application bundle and `tmp/woods/`.
|
|
23
|
+
|
|
24
|
+
## Install and inspect
|
|
25
|
+
|
|
26
|
+
Add `gem "woods", "~> 2.0"` to the development group, then:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
bundle install
|
|
30
|
+
bundle exec ruby -rwoods/version -e 'puts Woods::VERSION'
|
|
31
|
+
bin/rails generate woods:install
|
|
32
|
+
git diff -- config/initializers/woods.rb db/migrate
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
The generator creates an initializer and a legacy application migration for `woods_units`, `woods_edges`, and `woods_embeddings`. Woods 2's shipped structural index and storage backends do not use those application tables. For a new default installation, propose removing the generated migration and obtain approval first. Keep or run it only when repository history proves an older/custom integration uses those tables, after normal migration authorization and conflict checks.
|
|
36
|
+
|
|
37
|
+
Do not broadly update gems or overwrite existing configuration.
|
|
38
|
+
|
|
39
|
+
## Upgrading from 1.x
|
|
40
|
+
|
|
41
|
+
When the preflight records an installed 1.x version, this is an upgrade, not an install. Woods 2.0 changes observable index identifiers, the publication layout, vector-store reconciliation, and the supported MCP surface, so plan a clean re-index and follow the canonical runbook: [UPGRADING_TO_2.md](https://github.com/lost-in-the/woods/blob/main/docs/UPGRADING_TO_2.md).
|
|
42
|
+
|
|
43
|
+
Before changing the Gemfile: back up any shared or durable index and agree on a rollback window — never upgrade one in place. After `bundle update woods`, run a full `bin/rails woods:extract` (not incremental; the old index is not a valid baseline across the major), then `woods:validate`. With embeddings configured, re-embed from scratch into a store matching the configured model; expect identifier-level churn in anything that consumed 1.x identifiers (exports, saved queries, downstream tooling). Verify MCP clients against the new surface rather than assuming 1.x tool behavior.
|
|
44
|
+
|
|
45
|
+
## Extract and verify
|
|
46
|
+
|
|
47
|
+
Structural setup needs no embedding provider:
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
bin/rails woods:extract
|
|
51
|
+
bin/rails woods:validate
|
|
52
|
+
bin/rails woods:stats
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
If extraction fails, reproduce Rails boot and eager loading first. Do not inspect internal payload files when Woods tasks provide the check.
|
|
56
|
+
|
|
57
|
+
Configure the Index Server with the application bundle, absolute app `cwd`, and an index path visible to that process. For a host-installed bundle:
|
|
58
|
+
|
|
59
|
+
```json
|
|
60
|
+
{
|
|
61
|
+
"mcpServers": {
|
|
62
|
+
"woods": {
|
|
63
|
+
"command": "bundle",
|
|
64
|
+
"args": ["exec", "woods-mcp-start", "./tmp/woods"],
|
|
65
|
+
"cwd": "/absolute/path/to/app"
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
When Woods is installed only in Docker, launch it through the application service instead:
|
|
72
|
+
|
|
73
|
+
```json
|
|
74
|
+
{
|
|
75
|
+
"mcpServers": {
|
|
76
|
+
"woods": {
|
|
77
|
+
"command": "docker",
|
|
78
|
+
"args": ["compose", "exec", "-T", "app", "bundle", "exec", "woods-mcp", "/app/tmp/woods"],
|
|
79
|
+
"cwd": "/absolute/host/path/to/app"
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
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.
|
|
86
|
+
|
|
87
|
+
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. State that boot-captured changes require supervisor restart, Docker may need `WOODS_WATCH_POLL=1`, and semantic vectors still need `woods:embed_incremental`.
|
|
88
|
+
|
|
89
|
+
The plugin also ships two hooks (Woods 2.3 or later), shipped disabled. A `PostToolUse` hook runs `woods:incremental` in the background when an edit touches models, routes, migrations, schema, or a `package.yml`, reading `cwd` from the hook payload so linked worktrees refresh their own index; it batches paths from overlapping edits instead of dropping them under lock contention. A `SessionStart` hook warns when the published generation predates the last commit, a check scoped to commit timestamps, so it does not cover uncommitted edits or an older checkout. Both do nothing until `tmp/woods/generation.json` exists and until the user sets `WOODS_HOOKS_ENABLED=1`; set `WOODS_HOOK_RAKE="docker compose exec -T app bundle exec rake"` when the bundle lives in a container, `WOODS_OUTPUT` when the index directory is non-default, and `WOODS_HOOKS_DISABLED=1` to turn both back off.
|
|
90
|
+
|
|
91
|
+
## Ask before expanding scope
|
|
92
|
+
|
|
93
|
+
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.
|
|
94
|
+
|
|
95
|
+
## Handoff
|
|
96
|
+
|
|
97
|
+
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.
|
|
98
|
+
|
|
99
|
+
Canonical runbook: [AGENT_SETUP.md](https://github.com/lost-in-the/woods/blob/main/docs/AGENT_SETUP.md).
|
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:
|
|
4
|
+
version: 2.0.0.beta1
|
|
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-
|
|
11
|
+
date: 2026-09-09 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: mcp
|
|
@@ -16,20 +16,20 @@ dependencies:
|
|
|
16
16
|
requirements:
|
|
17
17
|
- - ">="
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version:
|
|
19
|
+
version: '1.2'
|
|
20
20
|
- - "<"
|
|
21
21
|
- !ruby/object:Gem::Version
|
|
22
|
-
version: '
|
|
22
|
+
version: '2.0'
|
|
23
23
|
type: :runtime
|
|
24
24
|
prerelease: false
|
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
|
26
26
|
requirements:
|
|
27
27
|
- - ">="
|
|
28
28
|
- !ruby/object:Gem::Version
|
|
29
|
-
version:
|
|
29
|
+
version: '1.2'
|
|
30
30
|
- - "<"
|
|
31
31
|
- !ruby/object:Gem::Version
|
|
32
|
-
version: '
|
|
32
|
+
version: '2.0'
|
|
33
33
|
- !ruby/object:Gem::Dependency
|
|
34
34
|
name: json
|
|
35
35
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -56,7 +56,7 @@ dependencies:
|
|
|
56
56
|
requirements:
|
|
57
57
|
- - ">="
|
|
58
58
|
- !ruby/object:Gem::Version
|
|
59
|
-
version:
|
|
59
|
+
version: 1.8.2
|
|
60
60
|
- - "<"
|
|
61
61
|
- !ruby/object:Gem::Version
|
|
62
62
|
version: '2'
|
|
@@ -66,7 +66,7 @@ dependencies:
|
|
|
66
66
|
requirements:
|
|
67
67
|
- - ">="
|
|
68
68
|
- !ruby/object:Gem::Version
|
|
69
|
-
version:
|
|
69
|
+
version: 1.8.2
|
|
70
70
|
- - "<"
|
|
71
71
|
- !ruby/object:Gem::Version
|
|
72
72
|
version: '2'
|
|
@@ -126,6 +126,36 @@ files:
|
|
|
126
126
|
- CONTRIBUTING.md
|
|
127
127
|
- LICENSE.txt
|
|
128
128
|
- README.md
|
|
129
|
+
- SECURITY.md
|
|
130
|
+
- assets/woods-wordmark-white-with-bg.png
|
|
131
|
+
- docs/AGENT_GUIDE.md
|
|
132
|
+
- docs/AGENT_SETUP.md
|
|
133
|
+
- docs/BACKEND_MATRIX.md
|
|
134
|
+
- docs/CONFIGURATION_REFERENCE.md
|
|
135
|
+
- docs/CONSOLE_MCP_SETUP.md
|
|
136
|
+
- docs/DOCKER_SETUP.md
|
|
137
|
+
- docs/EMBEDDING_MODELS.md
|
|
138
|
+
- docs/EVALUATION.md
|
|
139
|
+
- docs/EXTRACTOR_REFERENCE.md
|
|
140
|
+
- docs/FAQ.md
|
|
141
|
+
- docs/GETTING_STARTED.md
|
|
142
|
+
- docs/INCREMENTAL_EXTRACTION.md
|
|
143
|
+
- docs/INTERNALS.md
|
|
144
|
+
- docs/MCP_HTTP_TRANSPORT.md
|
|
145
|
+
- docs/MCP_SERVERS.md
|
|
146
|
+
- docs/MCP_TOOL_COOKBOOK.md
|
|
147
|
+
- docs/MCP_WORKTREE_SETUP.md
|
|
148
|
+
- docs/NOTION_INTEGRATION.md
|
|
149
|
+
- docs/OBSIDIAN_INTEGRATION.md
|
|
150
|
+
- docs/PUBLISHED_INDEX.md
|
|
151
|
+
- docs/README.md
|
|
152
|
+
- docs/RETRIEVAL_GUIDE.md
|
|
153
|
+
- docs/TOKEN_BENCHMARK.md
|
|
154
|
+
- docs/TROUBLESHOOTING.md
|
|
155
|
+
- docs/UNBLOCKED_INTEGRATION.md
|
|
156
|
+
- docs/UPGRADING_TO_2.md
|
|
157
|
+
- docs/WATCH_DAEMON.md
|
|
158
|
+
- docs/WHY_WOODS.md
|
|
129
159
|
- exe/woods-console
|
|
130
160
|
- exe/woods-console-mcp
|
|
131
161
|
- exe/woods-mcp
|
|
@@ -137,6 +167,7 @@ files:
|
|
|
137
167
|
- lib/generators/woods/templates/create_woods_tables.rb.erb
|
|
138
168
|
- lib/generators/woods/templates/woods.rb.tt
|
|
139
169
|
- lib/tasks/woods.rake
|
|
170
|
+
- lib/tasks/woods_checks.rake
|
|
140
171
|
- lib/tasks/woods_evaluation.rake
|
|
141
172
|
- lib/woods.rb
|
|
142
173
|
- lib/woods/ast.rb
|
|
@@ -150,27 +181,22 @@ files:
|
|
|
150
181
|
- lib/woods/cache/cache_store.rb
|
|
151
182
|
- lib/woods/cache/redis_cache_store.rb
|
|
152
183
|
- lib/woods/cache/solid_cache_store.rb
|
|
184
|
+
- lib/woods/change_set.rb
|
|
185
|
+
- lib/woods/checks/generation_resolution.rb
|
|
186
|
+
- lib/woods/checks/moved_messages.rb
|
|
153
187
|
- lib/woods/chunking/chunk.rb
|
|
154
188
|
- lib/woods/chunking/semantic_chunker.rb
|
|
155
|
-
- lib/woods/console/adapter_family.rb
|
|
156
|
-
- lib/woods/console/adapters/cache_adapter.rb
|
|
157
|
-
- lib/woods/console/adapters/good_job_adapter.rb
|
|
158
|
-
- lib/woods/console/adapters/job_adapter.rb
|
|
159
|
-
- lib/woods/console/adapters/sidekiq_adapter.rb
|
|
160
|
-
- lib/woods/console/adapters/solid_queue_adapter.rb
|
|
161
189
|
- lib/woods/console/audit_logger.rb
|
|
162
|
-
- lib/woods/console/bridge.rb
|
|
163
190
|
- lib/woods/console/bridge_protocol.rb
|
|
164
191
|
- lib/woods/console/confirmation.rb
|
|
165
192
|
- lib/woods/console/connection_manager.rb
|
|
166
193
|
- lib/woods/console/console_response_renderer.rb
|
|
167
194
|
- lib/woods/console/credential_index.rb
|
|
168
195
|
- lib/woods/console/credential_scanner.rb
|
|
169
|
-
- lib/woods/console/credential_scanner_registry.rb
|
|
170
196
|
- lib/woods/console/dispatch_pipeline.rb
|
|
171
197
|
- lib/woods/console/embedded_executor.rb
|
|
172
|
-
- lib/woods/console/encrypted_credential_snapshot.rb
|
|
173
198
|
- lib/woods/console/eval_guard.rb
|
|
199
|
+
- lib/woods/console/input_contract.rb
|
|
174
200
|
- lib/woods/console/model_validator.rb
|
|
175
201
|
- lib/woods/console/rack_middleware.rb
|
|
176
202
|
- lib/woods/console/redactor.rb
|
|
@@ -179,16 +205,15 @@ files:
|
|
|
179
205
|
- lib/woods/console/scope_predicate_parser.rb
|
|
180
206
|
- lib/woods/console/server.rb
|
|
181
207
|
- lib/woods/console/sql_noise_stripper.rb
|
|
182
|
-
- lib/woods/console/sql_output_policy.rb
|
|
183
208
|
- lib/woods/console/sql_table_scanner.rb
|
|
184
209
|
- lib/woods/console/sql_validator.rb
|
|
185
|
-
- lib/woods/console/sqlite_read_guard.rb
|
|
186
210
|
- lib/woods/console/table_gate.rb
|
|
187
211
|
- lib/woods/console/tool_specs.rb
|
|
188
212
|
- lib/woods/console/tools/tier1.rb
|
|
189
213
|
- lib/woods/console/tools/tier2.rb
|
|
190
214
|
- lib/woods/console/tools/tier3.rb
|
|
191
215
|
- lib/woods/console/tools/tier4.rb
|
|
216
|
+
- lib/woods/coordination/lock_heartbeat.rb
|
|
192
217
|
- lib/woods/coordination/pipeline_lock.rb
|
|
193
218
|
- lib/woods/cost_model.rb
|
|
194
219
|
- lib/woods/cost_model/embedding_cost.rb
|
|
@@ -201,14 +226,27 @@ files:
|
|
|
201
226
|
- lib/woods/db/migrations/004_create_snapshots.rb
|
|
202
227
|
- lib/woods/db/migrations/005_create_snapshot_units.rb
|
|
203
228
|
- lib/woods/db/migrations/006_rename_tables.rb
|
|
229
|
+
- lib/woods/db/migrations/007_typed_snapshot_units.rb
|
|
204
230
|
- lib/woods/db/migrator.rb
|
|
205
231
|
- lib/woods/db/schema_version.rb
|
|
206
232
|
- lib/woods/dependency_graph.rb
|
|
233
|
+
- lib/woods/embedding/fake.rb
|
|
207
234
|
- lib/woods/embedding/indexer.rb
|
|
208
235
|
- lib/woods/embedding/openai.rb
|
|
209
236
|
- lib/woods/embedding/provider.rb
|
|
210
237
|
- lib/woods/embedding/text_preparer.rb
|
|
211
238
|
- lib/woods/embedding/token_counter.rb
|
|
239
|
+
- lib/woods/evaluation/ablation_agent_payload.rb
|
|
240
|
+
- lib/woods/evaluation/ablation_executor.rb
|
|
241
|
+
- lib/woods/evaluation/ablation_provenance.rb
|
|
242
|
+
- lib/woods/evaluation/ablation_report_writer.rb
|
|
243
|
+
- lib/woods/evaluation/ablation_runner.rb
|
|
244
|
+
- lib/woods/evaluation/ablation_summary.rb
|
|
245
|
+
- lib/woods/evaluation/ablation_task.rb
|
|
246
|
+
- lib/woods/evaluation/ablation_task_set.rb
|
|
247
|
+
- lib/woods/evaluation/ablation_timed_executor.rb
|
|
248
|
+
- lib/woods/evaluation/ablation_worktree.rb
|
|
249
|
+
- lib/woods/evaluation/baseline.rb
|
|
212
250
|
- lib/woods/evaluation/baseline_runner.rb
|
|
213
251
|
- lib/woods/evaluation/evaluator.rb
|
|
214
252
|
- lib/woods/evaluation/metrics.rb
|
|
@@ -222,6 +260,7 @@ files:
|
|
|
222
260
|
- lib/woods/extractors/behavioral_profile.rb
|
|
223
261
|
- lib/woods/extractors/caching_extractor.rb
|
|
224
262
|
- lib/woods/extractors/callback_analyzer.rb
|
|
263
|
+
- lib/woods/extractors/component_discovery.rb
|
|
225
264
|
- lib/woods/extractors/concern_extractor.rb
|
|
226
265
|
- lib/woods/extractors/configuration_extractor.rb
|
|
227
266
|
- lib/woods/extractors/controller_extractor.rb
|
|
@@ -234,17 +273,20 @@ files:
|
|
|
234
273
|
- lib/woods/extractors/i18n_extractor.rb
|
|
235
274
|
- lib/woods/extractors/job_extractor.rb
|
|
236
275
|
- lib/woods/extractors/lib_extractor.rb
|
|
276
|
+
- lib/woods/extractors/line_neutralizer.rb
|
|
237
277
|
- lib/woods/extractors/mailer_extractor.rb
|
|
238
278
|
- lib/woods/extractors/manager_extractor.rb
|
|
239
279
|
- lib/woods/extractors/middleware_extractor.rb
|
|
240
280
|
- lib/woods/extractors/migration_extractor.rb
|
|
241
281
|
- lib/woods/extractors/model_extractor.rb
|
|
282
|
+
- lib/woods/extractors/package_extractor.rb
|
|
242
283
|
- lib/woods/extractors/phlex_extractor.rb
|
|
243
284
|
- lib/woods/extractors/policy_extractor.rb
|
|
244
285
|
- lib/woods/extractors/poro_extractor.rb
|
|
245
286
|
- lib/woods/extractors/pundit_extractor.rb
|
|
246
287
|
- lib/woods/extractors/rails_source_extractor.rb
|
|
247
288
|
- lib/woods/extractors/rake_task_extractor.rb
|
|
289
|
+
- lib/woods/extractors/reference_patterns.rb
|
|
248
290
|
- lib/woods/extractors/route_extractor.rb
|
|
249
291
|
- lib/woods/extractors/route_helper_resolver.rb
|
|
250
292
|
- lib/woods/extractors/scheduled_job_extractor.rb
|
|
@@ -252,6 +294,7 @@ files:
|
|
|
252
294
|
- lib/woods/extractors/service_extractor.rb
|
|
253
295
|
- lib/woods/extractors/shared_dependency_scanner.rb
|
|
254
296
|
- lib/woods/extractors/shared_utility_methods.rb
|
|
297
|
+
- lib/woods/extractors/source_nesting.rb
|
|
255
298
|
- lib/woods/extractors/state_machine_extractor.rb
|
|
256
299
|
- lib/woods/extractors/test_mapping_extractor.rb
|
|
257
300
|
- lib/woods/extractors/validator_extractor.rb
|
|
@@ -268,10 +311,10 @@ files:
|
|
|
268
311
|
- lib/woods/flow_document.rb
|
|
269
312
|
- lib/woods/flow_precomputer.rb
|
|
270
313
|
- lib/woods/formatting/base.rb
|
|
271
|
-
- lib/woods/formatting/claude_adapter.rb
|
|
272
|
-
- lib/woods/formatting/generic_adapter.rb
|
|
273
|
-
- lib/woods/formatting/gpt_adapter.rb
|
|
274
314
|
- lib/woods/formatting/human_adapter.rb
|
|
315
|
+
- lib/woods/gem_mapper.rb
|
|
316
|
+
- lib/woods/generation.rb
|
|
317
|
+
- lib/woods/git_command.rb
|
|
275
318
|
- lib/woods/git_provenance.rb
|
|
276
319
|
- lib/woods/graph_analyzer.rb
|
|
277
320
|
- lib/woods/index_artifact.rb
|
|
@@ -280,29 +323,31 @@ files:
|
|
|
280
323
|
- lib/woods/mcp/bootstrapper.rb
|
|
281
324
|
- lib/woods/mcp/config_resolver.rb
|
|
282
325
|
- lib/woods/mcp/errors.rb
|
|
283
|
-
- lib/woods/mcp/http_transport_options.rb
|
|
284
326
|
- lib/woods/mcp/index_reader.rb
|
|
327
|
+
- lib/woods/mcp/index_reader_pinning.rb
|
|
285
328
|
- lib/woods/mcp/origin_guard.rb
|
|
286
|
-
- lib/woods/mcp/
|
|
329
|
+
- lib/woods/mcp/protocol_policy.rb
|
|
287
330
|
- lib/woods/mcp/provider_probe.rb
|
|
288
331
|
- lib/woods/mcp/renderers/claude_renderer.rb
|
|
289
332
|
- lib/woods/mcp/renderers/json_renderer.rb
|
|
290
333
|
- lib/woods/mcp/renderers/markdown_renderer.rb
|
|
291
334
|
- lib/woods/mcp/renderers/plain_renderer.rb
|
|
292
335
|
- lib/woods/mcp/server.rb
|
|
336
|
+
- lib/woods/mcp/tasks/extension.rb
|
|
337
|
+
- lib/woods/mcp/tasks/request_capture.rb
|
|
338
|
+
- lib/woods/mcp/tasks/store.rb
|
|
339
|
+
- lib/woods/mcp/tool_contract.rb
|
|
293
340
|
- lib/woods/mcp/tool_response_renderer.rb
|
|
294
341
|
- lib/woods/mcp/version_aware_tool_dispatch.rb
|
|
295
342
|
- lib/woods/model_name_cache.rb
|
|
296
343
|
- lib/woods/notion/client.rb
|
|
297
344
|
- lib/woods/notion/exporter.rb
|
|
298
|
-
- lib/woods/notion/mapper.rb
|
|
299
345
|
- lib/woods/notion/mappers/column_mapper.rb
|
|
300
346
|
- lib/woods/notion/mappers/migration_mapper.rb
|
|
301
347
|
- lib/woods/notion/mappers/model_mapper.rb
|
|
302
348
|
- lib/woods/notion/mappers/shared.rb
|
|
303
349
|
- lib/woods/notion/rate_limiter.rb
|
|
304
|
-
- lib/woods/
|
|
305
|
-
- lib/woods/observability/instrumentation.rb
|
|
350
|
+
- lib/woods/notion/sync_manifest.rb
|
|
306
351
|
- lib/woods/observability/structured_logger.rb
|
|
307
352
|
- lib/woods/obsidian/errors.rb
|
|
308
353
|
- lib/woods/obsidian/name_mapper.rb
|
|
@@ -312,7 +357,16 @@ files:
|
|
|
312
357
|
- lib/woods/operator/error_escalator.rb
|
|
313
358
|
- lib/woods/operator/pipeline_guard.rb
|
|
314
359
|
- lib/woods/operator/status_reporter.rb
|
|
360
|
+
- lib/woods/path_dispatcher.rb
|
|
361
|
+
- lib/woods/payload_store.rb
|
|
362
|
+
- lib/woods/published_index.rb
|
|
363
|
+
- lib/woods/published_index/edge_shaper.rb
|
|
364
|
+
- lib/woods/published_index/generation_catalog.rb
|
|
365
|
+
- lib/woods/published_index/typed_unit_reader.rb
|
|
315
366
|
- lib/woods/railtie.rb
|
|
367
|
+
- lib/woods/railtie_support.rb
|
|
368
|
+
- lib/woods/release.rb
|
|
369
|
+
- lib/woods/reload_policy.rb
|
|
316
370
|
- lib/woods/resilience/circuit_breaker.rb
|
|
317
371
|
- lib/woods/resilience/index_validator.rb
|
|
318
372
|
- lib/woods/resilience/retryable_provider.rb
|
|
@@ -335,6 +389,7 @@ files:
|
|
|
335
389
|
- lib/woods/session_tracer/redis_store.rb
|
|
336
390
|
- lib/woods/session_tracer/session_flow_assembler.rb
|
|
337
391
|
- lib/woods/session_tracer/session_flow_document.rb
|
|
392
|
+
- lib/woods/session_tracer/solid_cache_coordination.rb
|
|
338
393
|
- lib/woods/session_tracer/solid_cache_store.rb
|
|
339
394
|
- lib/woods/session_tracer/store.rb
|
|
340
395
|
- lib/woods/storage/graph_store.rb
|
|
@@ -346,6 +401,7 @@ files:
|
|
|
346
401
|
- lib/woods/storage/snapshotter/metadata.rb
|
|
347
402
|
- lib/woods/storage/snapshotter/vector.rb
|
|
348
403
|
- lib/woods/storage/vector_store.rb
|
|
404
|
+
- lib/woods/storage_identity.rb
|
|
349
405
|
- lib/woods/tasks.rb
|
|
350
406
|
- lib/woods/temporal/json_snapshot_store.rb
|
|
351
407
|
- lib/woods/temporal/snapshot_store.rb
|
|
@@ -357,16 +413,32 @@ files:
|
|
|
357
413
|
- lib/woods/unblocked/sync_manifest.rb
|
|
358
414
|
- lib/woods/update_check.rb
|
|
359
415
|
- lib/woods/util/host_guard.rb
|
|
416
|
+
- lib/woods/util/uuid5.rb
|
|
360
417
|
- lib/woods/version.rb
|
|
418
|
+
- lib/woods/watch/daemon.rb
|
|
419
|
+
- lib/woods/watch/listen_watcher.rb
|
|
420
|
+
- lib/woods/watch/polling_watcher.rb
|
|
421
|
+
- lib/woods/watch/status.rb
|
|
422
|
+
- lib/woods/watch/tree_scan.rb
|
|
423
|
+
- lib/woods/watch/watcher.rb
|
|
424
|
+
- plugin/.claude-plugin/plugin.json
|
|
425
|
+
- plugin/hooks/hooks.json
|
|
426
|
+
- plugin/hooks/woods-post-edit.sh
|
|
427
|
+
- plugin/hooks/woods-session-start.sh
|
|
428
|
+
- plugin/skills/woods-agent-enable/SKILL.md
|
|
429
|
+
- plugin/skills/woods-diagnose/SKILL.md
|
|
430
|
+
- plugin/skills/woods-investigate/SKILL.md
|
|
431
|
+
- plugin/skills/woods-mcp-config/SKILL.md
|
|
432
|
+
- plugin/skills/woods-setup/SKILL.md
|
|
361
433
|
homepage: https://github.com/lost-in-the/woods
|
|
362
434
|
licenses:
|
|
363
435
|
- MIT
|
|
364
436
|
metadata:
|
|
365
437
|
homepage_uri: https://github.com/lost-in-the/woods
|
|
366
|
-
source_code_uri: https://github.com/lost-in-the/woods/tree/
|
|
367
|
-
changelog_uri: https://github.com/lost-in-the/woods/blob/
|
|
438
|
+
source_code_uri: https://github.com/lost-in-the/woods/tree/v2.0.0.beta1
|
|
439
|
+
changelog_uri: https://github.com/lost-in-the/woods/blob/v2.0.0.beta1/CHANGELOG.md
|
|
368
440
|
bug_tracker_uri: https://github.com/lost-in-the/woods/issues
|
|
369
|
-
documentation_uri: https://github.com/lost-in-the/woods/tree/
|
|
441
|
+
documentation_uri: https://github.com/lost-in-the/woods/tree/v2.0.0.beta1/docs
|
|
370
442
|
rubygems_mfa_required: 'true'
|
|
371
443
|
post_install_message:
|
|
372
444
|
rdoc_options: []
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Woods
|
|
4
|
-
module Console
|
|
5
|
-
# Adapter names differ from the SQL grammar and session settings they use.
|
|
6
|
-
module AdapterFamily
|
|
7
|
-
# Classify a live connection by adapter ancestry, database configuration,
|
|
8
|
-
# then its display name. Unknown families remain nil: SQL callers must
|
|
9
|
-
# refuse rather than silently omit dialect-specific safeguards.
|
|
10
|
-
# @param connection [Object] Active Record connection or compatible adapter
|
|
11
|
-
# @return [Symbol, nil] :postgres, :mysql, :sqlite, or unknown
|
|
12
|
-
def self.for(connection)
|
|
13
|
-
ancestry = connection.class.ancestors.filter_map(&:name)
|
|
14
|
-
return :postgres if ancestry.include?('ActiveRecord::ConnectionAdapters::PostgreSQLAdapter')
|
|
15
|
-
return :mysql if ancestry.any? { |name| name.match?(/::(?:AbstractMysql|Mysql2|Trilogy)Adapter\z/) }
|
|
16
|
-
return :sqlite if ancestry.include?('ActiveRecord::ConnectionAdapters::SQLite3Adapter')
|
|
17
|
-
|
|
18
|
-
from_name(configured_adapter(connection)) || from_name(connection.adapter_name)
|
|
19
|
-
end
|
|
20
|
-
|
|
21
|
-
def self.configured_adapter(connection)
|
|
22
|
-
return unless connection.respond_to?(:pool) && connection.pool.respond_to?(:db_config)
|
|
23
|
-
|
|
24
|
-
connection.pool.db_config.adapter
|
|
25
|
-
end
|
|
26
|
-
private_class_method :configured_adapter
|
|
27
|
-
|
|
28
|
-
def self.from_name(value)
|
|
29
|
-
name = value.to_s.downcase
|
|
30
|
-
return :mysql if name.include?('mysql') || %w[trilogy mariadb].include?(name)
|
|
31
|
-
return :postgres if name.include?('postgre') || %w[postgis cockroachdb redshift].include?(name)
|
|
32
|
-
return :sqlite if name.include?('sqlite')
|
|
33
|
-
|
|
34
|
-
nil
|
|
35
|
-
end
|
|
36
|
-
private_class_method :from_name
|
|
37
|
-
end
|
|
38
|
-
end
|
|
39
|
-
end
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Woods
|
|
4
|
-
module Console
|
|
5
|
-
module Adapters
|
|
6
|
-
# Cache adapter that auto-detects the active cache store.
|
|
7
|
-
#
|
|
8
|
-
# Supports Redis, Solid Cache, memory, and file cache stores.
|
|
9
|
-
# Detection checks Rails.cache class name first, then falls back
|
|
10
|
-
# to checking for SolidCache constant.
|
|
11
|
-
#
|
|
12
|
-
# @example
|
|
13
|
-
# CacheAdapter.detect # => :redis
|
|
14
|
-
# CacheAdapter.stats # => { tool: 'cache_stats', params: {} }
|
|
15
|
-
#
|
|
16
|
-
module CacheAdapter
|
|
17
|
-
STORE_PATTERNS = {
|
|
18
|
-
'RedisCacheStore' => :redis,
|
|
19
|
-
'MemoryStore' => :memory,
|
|
20
|
-
'FileStore' => :file
|
|
21
|
-
}.freeze
|
|
22
|
-
|
|
23
|
-
module_function
|
|
24
|
-
|
|
25
|
-
# Detect the active cache store backend.
|
|
26
|
-
#
|
|
27
|
-
# @return [Symbol] One of :redis, :solid_cache, :memory, :file, :unknown
|
|
28
|
-
def detect
|
|
29
|
-
if defined?(::Rails) && ::Rails.respond_to?(:cache) && ::Rails.cache
|
|
30
|
-
class_name = ::Rails.cache.class.name.to_s
|
|
31
|
-
STORE_PATTERNS.each do |pattern, backend|
|
|
32
|
-
return backend if class_name.include?(pattern)
|
|
33
|
-
end
|
|
34
|
-
end
|
|
35
|
-
|
|
36
|
-
return :solid_cache if defined?(::SolidCache)
|
|
37
|
-
|
|
38
|
-
:unknown
|
|
39
|
-
end
|
|
40
|
-
|
|
41
|
-
# Get cache store statistics.
|
|
42
|
-
#
|
|
43
|
-
# @param namespace [String, nil] Cache namespace filter
|
|
44
|
-
# @return [Hash] Bridge request
|
|
45
|
-
def stats(namespace: nil)
|
|
46
|
-
{ tool: 'cache_stats', params: { namespace: namespace }.compact }
|
|
47
|
-
end
|
|
48
|
-
|
|
49
|
-
# Get cache store info (backend type, configuration).
|
|
50
|
-
#
|
|
51
|
-
# @return [Hash] Bridge request
|
|
52
|
-
def info
|
|
53
|
-
{ tool: 'cache_info', params: {} }
|
|
54
|
-
end
|
|
55
|
-
end
|
|
56
|
-
end
|
|
57
|
-
end
|
|
58
|
-
end
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
require_relative 'job_adapter'
|
|
4
|
-
|
|
5
|
-
module Woods
|
|
6
|
-
module Console
|
|
7
|
-
module Adapters
|
|
8
|
-
# Job backend adapter for GoodJob.
|
|
9
|
-
#
|
|
10
|
-
# Builds bridge requests for GoodJob queue stats, failure listing,
|
|
11
|
-
# job lookup, scheduled jobs, and retry operations.
|
|
12
|
-
#
|
|
13
|
-
# @example
|
|
14
|
-
# adapter = GoodJobAdapter.new
|
|
15
|
-
# adapter.queue_stats # => { tool: 'good_job_queue_stats', params: {} }
|
|
16
|
-
#
|
|
17
|
-
class GoodJobAdapter < JobAdapter
|
|
18
|
-
# Check if GoodJob is available in the current environment.
|
|
19
|
-
#
|
|
20
|
-
# @return [Boolean]
|
|
21
|
-
def self.available?
|
|
22
|
-
!!defined?(::GoodJob)
|
|
23
|
-
end
|
|
24
|
-
|
|
25
|
-
private
|
|
26
|
-
|
|
27
|
-
def prefix
|
|
28
|
-
'good_job'
|
|
29
|
-
end
|
|
30
|
-
end
|
|
31
|
-
end
|
|
32
|
-
end
|
|
33
|
-
end
|