A Model Context Protocol (MCP) server that provides structured workflows and tools for AI agents working with software development projects, with specialized focus on Rails applications.
Railagent provides AI agents with a comprehensive workflow system for software development. It guides agents through the entire development lifecycle from requirements gathering to implementation, ensuring consistent and high-quality outcomes.
- Functional Requirements: Use the functional requirements tool to collect necessary information about the project (purpose, users, capabilities, workflows, context, edge cases)
- Product Requirements Document (PRD): Generate a complete PRD from the functional requirements, breaking down the project into features and user stories
- Feature Requirements Document (FRD): For each feature, create a detailed FRD that breaks large features into individual PR-sized units
- Task Design Document (TDD): Transform the FRD into an implementation plan with specific subtasks, where each subtask corresponds to a commit
- Skip directly to step 4 (TDD) above when you have a clear understanding of what needs to be built
- Initialize Tasks: Call the initialize tool to set up subtasks based on your TDD implementation plan (stored in
.cursor/scratch/tasks/) - Execute Tasks: Use the execute tool to work on each task individually. Each task represents exactly one commit, and the agent waits for review before committing
- Track Progress: Progress is maintained in
.cursor/scratch/todo.mdwith notes and status updates
All documents and tasks are automatically stored in the .cursor/scratch/ folder for easy access and organization.
- build_functional_requirements: Collects comprehensive project requirements
- build_prd: Generates Product Requirements Documents from functional requirements
- build_frd: Creates Feature Requirements Documents for specific features
- build_tdd: Breaks down features into detailed implementation plans with commit-level subtasks
- build_architecture: Generates comprehensive architecture documentation
- initialize_task: Sets up implementation subtasks from TDD plans
- execute_task: Executes individual tasks with review checkpoints
Add to your mcp.json file:
{
"mcpServers": {
"Railagent": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"cestbalez/railagent:latest"
]
}
}
}Restart your MCP client to load the new server.
Note: The Docker image will be automatically pulled from DockerHub on first use. No manual installation or repository cloning required!
railagent/
├── app.rb # Main application entry point
├── lib/ # Tool implementations
│ ├── docs/ # Documentation tools
│ └── workflow/ # Workflow management tools
├── prompts/ # Workflow prompts and templates
│ ├── docs/ # Documentation workflow prompts
│ └── workflow/ # Implementation workflow templates
├── Dockerfile # Docker configuration
├── Gemfile # Ruby dependencies
└── README.md # This file
The easiest way to use Railagent is with the pre-built Docker image:
docker run -i --rm cestbalez/railagent:latestIf you want to contribute or modify the code:
git clone <your-repo-url>
cd railagent
bundle install
ruby app.rbgit clone <your-repo-url>
cd railagent
docker build -t railagent .- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the terms specified in the LICENSE file.