A C# MCP (Model Context Protocol) server that provides tools for analyzing .NET solutions, managing diagnostics, applying code fixes, and navigating C# code symbols via Roslyn
RoselineMCP demonstrates strong tool definition quality with consistent application of a documented six-component description contract (Purpose, Guidelines, Limitations, Examples, Parameter explanation, and compactness ceiling). All 14 tools have detailed descriptions (average ~180 chars, within 10-1024 range), parameter schemas with types, and explicit examples. The codebase enforces description compactness via ToolDescriptionContractTests (MaxWords=165), and every tool with optional 'project' parameter carries a shared auto-discovery limitation note. However, output schemas are not explicitly documented in parameter definitions, and error handling guidance is minimal in descriptions. Tool naming is consistently action-verb based (analyze_, list_, search_, get_, find_, create_, apply_, check_, edit_, rename_) and distinguishes operations well. All 14 tools have complete input schemas visible in test fixtures.
Analyzes a .NET solution (from filesystem path or Git URL) and returns compilation diagnostics, project counts, and top issues. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit path is given. Example: analyze_solution{pathOrGit:'./MySolution.sln'} -> {solution:'MySolution.sln', projects:5, diagnosticSummary:{error:2, warning:10}}
Applies code fixes to specified diagnostic IDs in a project (read-only by default). Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given; previewOnly defaults to true for safety. Example: apply_fixes{project:'MyProject.csproj',ids:['CS0168'],previewOnly:true} -> {project:'MyProject.csproj', fixedCount:1, previewOnly:true}
Checks if a .NET solution or project compiles successfully without executing it. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given; compilation errors are summarized, not exhaustively listed. Example: check_compilation{project:'MyProject.csproj'} -> {project:'MyProject.csproj',compiles:true,errorCount:0,warningCount:2,errors:[]}
Generates a unified diff patch between two text versions. Limitations: output is limited to practical patch sizes. Example: create_patch{before:'old line',after:'new line',fileName:'file.cs'} -> {fileName:'file.cs', hasChanges:true, patch:'--- a/file.cs...'}
Output schemas are not explicitly documented in tool descriptions or parameter metadata. LLMs cannot plan downstream tool calls or structure data extraction without knowing return types. Example: analyze_solution returns {solution, projects, diagnosticSummary} but this structure is not declared in tool metadata.
Error handling descriptions are missing from tool definitions. LLMs cannot determine what to do when a tool fails (retry? ask user? abort?). Example: analyze_solution lists no guidance for 'git clone failed' or 'invalid .sln path' scenarios.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | C | 67 | 2025-06-18+ | v2 |
Edits a C# member (method, property, etc.) by replacing its source code, with optional preview mode. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given; previewOnly defaults to true for safety. Example: edit_member{project:'MyProject.csproj',symbol:'MyMethod',operation:'replace',newSource:'public void MyMethod() { /* new impl */ }',previewOnly:true} -> {symbol:'MyMethod',project:'MyProject.csproj',previewOnly:true,affectedFiles:['MyClass.cs']}
Finds all implementations of a C# interface or abstract member throughout the project and solution. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given. Example: find_implementations{project:'MyProject.csproj',symbol:'IService'} -> {symbol:'IService', implementations:[{name:'ServiceImpl',file:'ServiceImpl.cs',line:10}]}
Finds all references to a C# symbol throughout the project and solution. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given. Example: find_references{project:'MyProject.csproj',symbol:'MyClass'} -> {symbol:'MyClass', references:[{file:'Consumer.cs',line:5,kind:'type reference'}]}
Generates a call graph for a C# method showing all methods it calls and methods that call it. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given; deep graphs may be truncated. Example: get_call_graph{project:'MyProject.csproj',symbol:'ProcessData'} -> {symbol:'ProcessData', calls:[{name:'ValidateInput',file:'Validator.cs'}], calledBy:[{name:'Execute',file:'Service.cs'}]}
Retrieves the C# symbol at a specific line and column position in a file. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given. Example: get_symbol_at_position{file:'Program.cs',line:10,column:15} -> {symbol:'Main', kind:'method', location:'Program.cs:10:15'}
Retrieves detailed information about a C# symbol including its type, location, documentation, and relationships. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given. Example: get_symbol_info{project:'MyProject.csproj',symbol:'MyClass'} -> {symbol:'MyClass', kind:'class', location:'MyClass.cs:5', baseTypes:['System.Object']}
Retrieves the type hierarchy (base types and derived types) for a C# class or interface. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given. Example: get_type_hierarchy{project:'MyProject.csproj',symbol:'BaseClass'} -> {symbol:'BaseClass', baseTypes:['System.Object'], derivedTypes:[{name:'DerivedClass',file:'Derived.cs'}]}
Lists all diagnostics (errors/warnings) in a project with optional filtering by ID or file. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given. Example: list_diagnostics{project:'MyProject.csproj',ids:['CS0168']} -> {project:'MyProject.csproj', totalDiagnostics:3, suggestedFixableIds:['CS0168']}
Renames a C# symbol throughout the project, applying the rename to all references. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given. Example: rename_symbol{project:'MyProject.csproj',symbol:'OldName',newName:'NewName'} -> {symbol:'OldName',newName:'NewName',affectedFiles:['Class1.cs','Class2.cs'],renameCount:5}
Searches for C# symbols (types, methods, properties) by name or full-text query in a project. Limitations: auto-discovery is anchored to the SERVER's cwd when no explicit project is given; query and file filters are mutually optional but at least one should be specified. Example: search_symbols{project:'MyProject.csproj',query:'ILogger'} -> {project:'MyProject.csproj', symbols:[{name:'ILogger', kind:'interface', location:'Logger.cs:10'}]}
Several tools (apply_fixes, edit_member, rename_symbol) are WRITE operations but lack confirmation/dry-run pattern. previewOnly defaults to true for safety, but descriptions do not explicitly warn that setting previewOnly=false modifies the filesystem or code, or provide undo guidance.
Parameter constraints (maxDiagnostics, max limits in multiple tools) lack explicit min/max values in descriptions. Example: 'Maximum number of diagnostics to return' does not state the valid range (e.g. 1-10000). LLMs may pass arbitrary values.
Auto-discovery limitation (project parameter auto-anchored to SERVER's cwd) is documented in 12 tool descriptions via a shared fragment, but the phrase 'auto-discovery is anchored to the SERVER's cwd when no explicit path is given' is opaque to LLMs. Should clarify: 'If project is omitted, we search the current working directory, provide an explicit path if your code is elsewhere.'