rails_get_context
Get cross-layer context for a Rails controller action or model in one call, combining schema, routes, controller, views, Stimulus, and tests.
Instructions
Get cross-layer context in a single call - combines schema, model, controller, routes, views, stimulus, and tests. Use when: you need full context for implementing a feature or modifying an action. Specify controller:"PostsController" action:"create" to get everything for that action in one call.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | No | Model name (e.g. 'Post'). Returns schema, associations, validations, scopes, callbacks, tests. | |
| action | No | Specific action name (e.g. 'create'). Requires controller. Returns full action context. | |
| feature | No | Feature keyword (e.g. 'post'). Like analyze_feature but includes schema columns and scope bodies. | |
| include | No | Additional context to bundle: 'stimulus', 'turbo', 'services', 'jobs', 'conventions', 'helpers', 'env', 'callbacks', 'tests', 'config', 'gems', 'security'. Appends these to any mode. | |
| controller | No | Controller name (e.g. 'PostsController'). Returns action source, filters, strong params, routes, views. |