Write RFC Skill
This skill helps you write high-quality RFCs for the ToolHive ecosystem following established patterns and conventions.
Overview
ToolHive RFCs follow a specific format with the naming convention THV-{NUMBER}-{descriptive-name}.md. The NUMBER must match the PR number and be zero-padded to 4 digits.
Workflow
Step 1: Gather Requirements
Before writing an RFC, ask the user about:
- Problem Statement: What problem are they trying to solve?
- Target Repository: Which repo does this affect?
toolhive - Core runtime, CLI (thv), operator (thv-operator), proxy-runner (thv-proxyrunner), virtual MCP (vmcp)
toolhive-studio - Desktop UI application (Electron/TypeScript)
toolhive-registry - MCP server registry data
toolhive-registry-server - Registry API server (thv-registry-api)
toolhive-cloud-ui - Cloud/Enterprise web UI (Next.js)
dockyard - Container packaging for MCP servers
multiple - Cross-cutting changes
- Scope: What are the goals and explicit non-goals?
Step 2: Research the Ecosystem
Before drafting, research the relevant codebase:
2.1 Fetch Architectural Documentation
Use mcp__github__get_file_contents to read from stacklok/toolhive repo's docs/arch/ directory:
| Document |
Content |
00-overview.md |
Platform overview, key components |
01-deployment-modes.md |
Local vs Kubernetes modes |
02-core-concepts.md |
Nouns (Workloads, Transports, Proxy, etc.) and Verbs |
03-transport-architecture.md |
stdio, SSE, streamable-http transports |
04-secrets-management.md |
Secrets handling, providers |
05-runconfig-and-permissions.md |
Configuration format, permission profiles |
06-registry-system.md |
Registry architecture, MCPRegistry CRD |
07-groups.md |
Server grouping concepts |
08-workloads-lifecycle.md |
Lifecycle management |
09-operator-architecture.md |
K8s operator, CRDs |
10-virtual-mcp-architecture.md |
Virtual MCP aggregation |
2.2 Review Existing RFCs
Read rfcs/ directory in this repository to understand patterns and check for related proposals.
2.3 Search Relevant Codebases
Use mcp__github__search_code or mcp__github__get_file_contents to explore:
| Repository |
Purpose |
stacklok/toolhive |
Core platform, CLI, operator, proxy |
stacklok/toolhive-studio |
Desktop UI |
stacklok/toolhive-registry-server |
Registry API server |
stacklok/toolhive-registry |
Registry data |
stacklok/toolhive-cloud-ui |
Cloud/Enterprise UI |
stacklok/dockyard |
Container packaging |
Step 3: Draft the RFC
Create the RFC following the template structure from rfcs/0000-template.md.
Required Metadata
# RFC-XXXX: Title
- **Status**: Draft
- **Author(s)**: Name (@github-handle)
- **Created**: YYYY-MM-DD
- **Last Updated**: YYYY-MM-DD
- **Target Repository**: [from step 1]
- **Related Issues**: [links if applicable]
Core Sections
- Summary - 2-3 sentences capturing the essence
- Problem Statement - Current limitation, who's affected, why it matters
- Goals - Specific objectives (bulleted)
- Non-Goals - Explicit scope boundaries
- Proposed Solution
- High-Level Design (with Mermaid diagrams)
- Detailed Design: Component changes, API changes, configuration changes, data model changes
- Security Considerations (REQUIRED) - See security checklist below
- Alternatives Considered - Other approaches evaluated
- Compatibility - Backward and forward compatibility
- Implementation Plan - Phased approach with tasks
- Testing Strategy - Unit, integration, E2E, performance, security tests
- Documentation - What needs documenting
- Open Questions - Unresolved items
- References - Related links
Security Considerations Checklist (REQUIRED)
Every RFC MUST address:
Step 4: Use Proper Conventions
Code Examples
- Use Go for API changes in toolhive, toolhive-registry-server
- Use TypeScript for toolhive-studio, toolhive-cloud-ui changes
- Use YAML for configuration examples
- Use Mermaid for diagrams (flowcharts, sequence diagrams)
Kubernetes CRDs
If the RFC involves Kubernetes, include CRD examples:
apiVersion: toolhive.stacklok.dev/v1alpha1
kind: MCPServer
metadata:
name: example
spec:
# ...
CRD types: MCPServer, MCPRegistry, MCPToolConfig, MCPExternalAuthConfig, MCPGroup, VirtualMCPServer
Step 5: File Naming
The RFC file should be named THV-XXXX-{descriptive-name}.md where XXXX is the PR number. Since you don't know the PR number yet, use a placeholder like THV-XXXX-{name}.md and remind the user to rename it to match the PR number after creating the PR.
Step 6: Review Checklist
Before finalizing, verify:
ToolHive Architecture Summary
Platform Overview
ToolHive is a platform for MCP server management (not just a container runner):
- Proxy layer with middleware (auth, authz, audit, rate limiting)
- Security by default (network isolation, permission profiles)
- Aggregation via Virtual MCP Server
- Registry for curated MCP servers
- Multi-deployment: Local (CLI/UI) and Kubernetes (operator)
Key Binaries
| Binary |
Location |
Purpose |
thv |
toolhive |
Main CLI |
thv-operator |
toolhive |
Kubernetes operator |
thv-proxyrunner |
toolhive |
K8s proxy container |
vmcp |
toolhive |
Virtual MCP server (aggregation) |
thv-registry-api |
toolhive-registry-server |
Registry API server |
Transport Types
- stdio - Standard input/output (requires protocol translation)
- SSE - Server-Sent Events (HTTP, transparent proxy)
- streamable-http - HTTP streaming (transparent proxy)
Design Principles
- Platform abstraction over direct execution
- Security by default (network isolation, permissions)
- Extensibility through middleware
- Cloud-native (K8s operators, containers)
- RunConfig as portable API contract
Reference Files
- Template:
rfcs/0000-template.md
- Contributing guide:
CONTRIBUTING.md
- Existing RFCs:
rfcs/THV-*.md
Converted and distributed by TomeVault — claim your Tome and manage your conversions.
1---2name: write-rfc3description: Write RFCs for the ToolHive ecosystem. Use when the user wants to create a new RFC, proposal, or design document for toolhive, toolhive-studio, toolhive-registry, toolhive-registry-server, toolhive-cloud-ui, or dockyard projects. Use when this capability is needed.4---56# Write RFC Skill78This skill helps you write high-quality RFCs for the ToolHive ecosystem following established patterns and conventions.910## Overview1112ToolHive RFCs follow a specific format with the naming convention `THV-{NUMBER}-{descriptive-name}.md`. The NUMBER must match the PR number and be zero-padded to 4 digits.1314## Workflow1516### Step 1: Gather Requirements1718Before writing an RFC, ask the user about:19201. **Problem Statement**: What problem are they trying to solve?212. **Target Repository**: Which repo does this affect?22 - `toolhive` - Core runtime, CLI (`thv`), operator (`thv-operator`), proxy-runner (`thv-proxyrunner`), virtual MCP (`vmcp`)23 - `toolhive-studio` - Desktop UI application (Electron/TypeScript)24 - `toolhive-registry` - MCP server registry data25 - `toolhive-registry-server` - Registry API server (`thv-registry-api`)26 - `toolhive-cloud-ui` - Cloud/Enterprise web UI (Next.js)27 - `dockyard` - Container packaging for MCP servers28 - `multiple` - Cross-cutting changes293. **Scope**: What are the goals and explicit non-goals?3031### Step 2: Research the Ecosystem3233Before drafting, research the relevant codebase:3435#### 2.1 Fetch Architectural Documentation3637Use `mcp__github__get_file_contents` to read from `stacklok/toolhive` repo's `docs/arch/` directory:3839| Document | Content |40|----------|---------|41| `00-overview.md` | Platform overview, key components |42| `01-deployment-modes.md` | Local vs Kubernetes modes |43| `02-core-concepts.md` | Nouns (Workloads, Transports, Proxy, etc.) and Verbs |44| `03-transport-architecture.md` | stdio, SSE, streamable-http transports |45| `04-secrets-management.md` | Secrets handling, providers |46| `05-runconfig-and-permissions.md` | Configuration format, permission profiles |47| `06-registry-system.md` | Registry architecture, MCPRegistry CRD |48| `07-groups.md` | Server grouping concepts |49| `08-workloads-lifecycle.md` | Lifecycle management |50| `09-operator-architecture.md` | K8s operator, CRDs |51| `10-virtual-mcp-architecture.md` | Virtual MCP aggregation |5253#### 2.2 Review Existing RFCs5455Read `rfcs/` directory in this repository to understand patterns and check for related proposals.5657#### 2.3 Search Relevant Codebases5859Use `mcp__github__search_code` or `mcp__github__get_file_contents` to explore:6061| Repository | Purpose |62|------------|---------|63| `stacklok/toolhive` | Core platform, CLI, operator, proxy |64| `stacklok/toolhive-studio` | Desktop UI |65| `stacklok/toolhive-registry-server` | Registry API server |66| `stacklok/toolhive-registry` | Registry data |67| `stacklok/toolhive-cloud-ui` | Cloud/Enterprise UI |68| `stacklok/dockyard` | Container packaging |6970### Step 3: Draft the RFC7172Create the RFC following the template structure from `rfcs/0000-template.md`.7374#### Required Metadata7576```markdown77# RFC-XXXX: Title7879- **Status**: Draft80- **Author(s)**: Name (@github-handle)81- **Created**: YYYY-MM-DD82- **Last Updated**: YYYY-MM-DD83- **Target Repository**: [from step 1]84- **Related Issues**: [links if applicable]85```8687#### Core Sections88891. **Summary** - 2-3 sentences capturing the essence902. **Problem Statement** - Current limitation, who's affected, why it matters913. **Goals** - Specific objectives (bulleted)924. **Non-Goals** - Explicit scope boundaries935. **Proposed Solution**94 - High-Level Design (with Mermaid diagrams)95 - Detailed Design: Component changes, API changes, configuration changes, data model changes966. **Security Considerations** (REQUIRED) - See security checklist below977. **Alternatives Considered** - Other approaches evaluated988. **Compatibility** - Backward and forward compatibility999. **Implementation Plan** - Phased approach with tasks10010. **Testing Strategy** - Unit, integration, E2E, performance, security tests10111. **Documentation** - What needs documenting10212. **Open Questions** - Unresolved items10313. **References** - Related links104105#### Security Considerations Checklist (REQUIRED)106107Every RFC MUST address:108109- [ ] **Threat Model** - Potential threats, attacker capabilities110- [ ] **Authentication and Authorization** - Auth changes, permission models111- [ ] **Data Security** - Sensitive data handling, encryption112- [ ] **Input Validation** - User input, injection vectors113- [ ] **Secrets Management** - Credentials storage, rotation114- [ ] **Audit and Logging** - Security events, compliance115- [ ] **Mitigations** - Security controls implemented116117### Step 4: Use Proper Conventions118119#### Code Examples120121- Use **Go** for API changes in toolhive, toolhive-registry-server122- Use **TypeScript** for toolhive-studio, toolhive-cloud-ui changes123- Use **YAML** for configuration examples124- Use **Mermaid** for diagrams (flowcharts, sequence diagrams)125126#### Kubernetes CRDs127128If the RFC involves Kubernetes, include CRD examples:129130```yaml131apiVersion: toolhive.stacklok.dev/v1alpha1132kind: MCPServer133metadata:134 name: example135spec:136 # ...137```138139CRD types: `MCPServer`, `MCPRegistry`, `MCPToolConfig`, `MCPExternalAuthConfig`, `MCPGroup`, `VirtualMCPServer`140141### Step 5: File Naming142143The RFC file should be named `THV-XXXX-{descriptive-name}.md` where XXXX is the PR number. Since you don't know the PR number yet, use a placeholder like `THV-XXXX-{name}.md` and remind the user to rename it to match the PR number after creating the PR.144145### Step 6: Review Checklist146147Before finalizing, verify:148149- [ ] Problem is clearly stated150- [ ] Goals and non-goals are explicit151- [ ] Security section is complete (all 7 areas addressed)152- [ ] Alternatives are discussed153- [ ] Diagrams illustrate complex flows154- [ ] Code examples are concrete and in the correct language155- [ ] Implementation phases are defined156- [ ] Testing strategy covers all levels157- [ ] File follows naming convention158159## ToolHive Architecture Summary160161### Platform Overview162163ToolHive is a **platform** for MCP server management (not just a container runner):164165- **Proxy layer** with middleware (auth, authz, audit, rate limiting)166- **Security** by default (network isolation, permission profiles)167- **Aggregation** via Virtual MCP Server168- **Registry** for curated MCP servers169- **Multi-deployment**: Local (CLI/UI) and Kubernetes (operator)170171### Key Binaries172173| Binary | Location | Purpose |174|--------|----------|---------|175| `thv` | toolhive | Main CLI |176| `thv-operator` | toolhive | Kubernetes operator |177| `thv-proxyrunner` | toolhive | K8s proxy container |178| `vmcp` | toolhive | Virtual MCP server (aggregation) |179| `thv-registry-api` | toolhive-registry-server | Registry API server |180181### Transport Types182183- **stdio** - Standard input/output (requires protocol translation)184- **SSE** - Server-Sent Events (HTTP, transparent proxy)185- **streamable-http** - HTTP streaming (transparent proxy)186187### Design Principles1881891. Platform abstraction over direct execution1902. Security by default (network isolation, permissions)1913. Extensibility through middleware1924. Cloud-native (K8s operators, containers)1935. RunConfig as portable API contract194195## Reference Files196197- Template: `rfcs/0000-template.md`198- Contributing guide: `CONTRIBUTING.md`199- Existing RFCs: `rfcs/THV-*.md`200201---202> Converted and distributed by [TomeVault](https://tomevault.io/claim/stacklok) — claim your Tome and manage your conversions.203<!-- tomevault:4.0:skill_md:2026-04-13 -->