Borrowing it
Nothing to install: this file belongs to HeshamFS/mcp-tool-factory-ts. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/HeshamFS/mcp-tool-factory-ts/main/CLAUDE.mdgit clone --depth 1 https://github.com/HeshamFS/mcp-tool-factory-tsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/heshamfs/mcp-tool-factory-ts/claude-md)<a href="https://agentmods.dev/instructions/heshamfs/mcp-tool-factory-ts/claude-md"><img src="https://agentmods.dev/badge/instructions/heshamfs/mcp-tool-factory-ts/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/heshamfs/mcp-tool-factory-ts/claude-md"><img src="https://agentmods.dev/badge/instructions/heshamfs/mcp-tool-factory-ts/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.01372 | $0.01372 |
| Opus 5 | $0.00686 | $0.00686 |
| Sonnet 5 | $0.00274 | $0.00274 |
| Haiku 4.5 | $0.00137 | $0.00137 |
Grade A, and why
mcp-tool-factory-ts CLAUDE.md scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Runs shell commandslowCapability
Expected in a hook, worth knowing in a rule or an instructions file.
Tests use vitest. Integration tests require API keys to be set. Generated server tests use `InMemoryTransport` (not child_process spawn). The server template exports a `createServer()` factory function to support this pa How it starts
The opening of the file, as written. The whole thing — 132 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Project Overview
MCP Tool Factory generates production-ready MCP (Model Context Protocol) servers from natural language descriptions, OpenAPI specs, database schemas, GraphQL schemas, or ontologies. It supports multiple LLM providers (Anthropic Claude, Claude Code OAuth, OpenAI, Google Gemini) and is itself an MCP server that can be used with Claude to generate servers on-the-fly.
Commands
# Install dependencies
pnpm install
# Build (uses tsup, copies templates to dist)
pnpm run build
# Run tests (vitest)
pnpm test
pnpm test:watch # Watch mode
pnpm test path/to/file.test.ts # Single test file
# Type check
pnpm run typecheck
# Lint
pnpm run lint
pnpm run lint:fix
Architecture
Core Flow
Input (description/OpenAPI/database/GraphQL/ontology) → ToolFactoryAgent → Generators → GeneratedServer
-
ToolFactoryAgent (
src/agent/agent.ts) - Main orchestrator that:- Takes input (natural language, OpenAPI spec, database path, GraphQL SDL, or ontology)
- Uses LLM to extract tool, resource, and prompt specifications from descriptions
- Generates implementations (parallel or sequential)
- Coordinates generators to produce all output files
-
LLM Providers (
src/providers/) - Pluggable provider system:BaseLLMProvider- Abstract base with caching, streaming, error handling- Implementations:
AnthropicProvider,OpenAIProvider,GoogleProvider,ClaudeCodeProvider - Auto-detection from environment variables via
createProvider()
-
Generators (
src/generators/) - Produce output artifacts:ServerGenerator- Main server code, package.json, Dockerfile, GitHub Actions, server.jsonDocsGenerator- README, skill.md, changelog, API docsTestsGenerator- Vitest test files
-
MCP Server Mode (
src/server/index.ts) - The factory itself as an MCP server exposing:generate_mcp_server- From natural languagegenerate_from_openapi- From OpenAPI specgenerate_from_database- From database schemagenerate_from_graphql- From GraphQL SDL schemagenerate_from_ontology- From ontology (RDF/OWL, JSON-LD, YAML)validate_typescript- Code validationlist_providers,get_factory_info- Discovery tools
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 10d ago First seen · 132 lines · 1,372 tokens per session scan A 0c3a70d94d8b
mcp-tool-factory-ts CLAUDE.md is an instructions file published in the GitHub repository HeshamFS/mcp-tool-factory-ts (1 stars, last pushed 6mo ago), licensed MIT. It adds 1,372 tokens to every session, about $0.0069 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other instructions, from other repositories
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.