Debug errors, test failures, or unexpected behavior. Auto-detects project type.
Investigates errors, test failures, or unexpected behavior by analyzing context and proposing fixes.
/plugin marketplace add majesticlabs-dev/majestic-marketplace/plugin install majestic-engineer@majestic-marketplace[error message or description]workflows/claude -p "/majestic:config tech_stack generic"claude -p "/majestic:config lessons_path .claude/lessons/"<bug_description>$ARGUMENTS</bug_description>
If the bug description above is empty, ask the user: "What error or issue are you experiencing? Please paste the error message or describe the unexpected behavior."
Do not proceed until you have a clear bug description.
Check if lessons directory exists, then discover similar past issues:
Task(subagent_type="majestic-engineer:workflow:lessons-discoverer",
prompt="workflow_phase: debugging | tech_stack: [tech_stack from context] | task: [bug_description]")
If lessons found with score > 70:
Present the high-confidence matches to the user BEFORE starting investigation:
Found similar past issues:
1. [Lesson title] (score: 78)
{lessons_path}/[category]/[filename].md
2. [Lesson title] (score: 65)
{lessons_path}/[category]/[filename].md
Use AskUserQuestion:
High-confidence match found. Read the documented solution first?
1. Read Lesson 1 (Recommended)
2. Read Lesson 2
3. Continue with full investigation
If user chooses to read a lesson:
Read(file_path="[lesson_path]")Error handling:
This step is non-blocking - failures do not stop the workflow.
Step 1: Check config
Use "Tech stack" from Context above. If configured, use it to determine project type.
Step 2: Check AGENTS.md for debugging guidance
Look for AGENTS.md in the project root for:
Step 3: Fall back to file-based detection only if needed
If neither config nor AGENTS.md provides context, detect project type from files:
ls Gemfile package.json pyproject.toml setup.py go.mod Cargo.toml 2>/dev/null
| File Found | Project Type | Debugger |
|---|---|---|
| Gemfile | Ruby/Rails | agent rails-debugger |
| package.json | Node.js | General debugging |
| pyproject.toml / setup.py | Python | General debugging |
| go.mod | Go | General debugging |
| Cargo.toml | Rust | General debugging |
Invoke the specialized Rails debugger agent:
agent rails-debugger "<bug_description>"
The rails-debugger will:
git log --oneline -10 and git diff HEAD~3After debugging, provide: