
为 PineScript v6 开发的 AI- 优化的 MCP 服务器, 具有文档访问和代码审查能力
概览
AI-优化了用于PineScript v6开发的模型上下文协议(MCP)服务器,提供了全面的文档访问,样式指导遵守,以及专门为AI编码代理设计了代码审查能力. : 4,277x通过内存-第一架构以 <15ms响应时间快速访问数据. : - 错误检测: SHORT TITLE TOO LONG (39个字符 > 10个限制) - 错误检测: INVALID PRECISION (15 > 最大允许) - 性能:分-15ms响应时间 - 输出:结构化 JSON 有重度级别并固定建议 (pinescript reference): - 语义搜索,在457个函数中同义词扩展 + 427个变量 - 通过JSON块流送大结果集 - 技术术语增强关键词匹配 (pinescript review): - 整个PineScript项目的目录支持 - 多格式输出(JSON,Markdown,流出) - 严重性过滤(错误,警告,建议) - 大代码库实时流出 - 9个验证规则,100%...
概述(AI 翻译)
AI-优化了用于PineScript v6开发的模型上下文协议(MCP)服务器,提供了全面的文档访问,样式指导遵守,以及专门为AI编码代理设计了代码审查能力.
** 业绩计量**:4 277x通过内存第一架构更快地访问数据,有10个限制)
- 错误检测: INVALID PRECISION (15 > 最大允许 8)
- 性能:分-15ms响应时间
- 产出:结构化的JSON具有严重性,并固定建议
□ 核心能力
** 文件搜索** ([T0]):
- 语义搜索,同义词可扩展到457个函数+427个变量
- 通过JSON块进行大额结果的输送
- 技术术语强化关键词匹配
** 守则审查**([T1]):
- 整个PineScript项目的目录支持
- 多格式产出(JSON、Markdown、流出)
- 严重性过滤(错误、警告、建议)
- 大代码库的实时流线
- 9项验证规则,测试覆盖率为100%
□ 基本使用命令
** 代码验证**:
** 文件研究**:
** 项目审查**:
** 业绩核查**:
□ 集成设置
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
PineScript MCP Documentation Server
AI-optimized Model Context Protocol (MCP) server for PineScript v6 development, providing comprehensive documentation access, style guide adherence, and code review capabilities specifically designed for AI coding agents.
Performance Metrics: 4,277x faster data access through memory-first architecture with <15ms response times.
Quick Start (2 minutes)
Installation & Verification:
# 1. Install and connect
npm install [email protected]:iamrichardD/mcp-server-pinescript.git
claude mcp add pinescript-docs node ./node_modules/mcp-server-pinescript/index.js
# 2. Verify connection
claude mcp list # Should show "pinescript-docs: Connected ✓"
# 3. Test validation (this code has deliberate errors)
claude -p "Use pinescript_review to check: //@version=6
indicator('RSI Test', shorttitle='RSI_INDICATOR_WITH_LONG_TITLE', overlay=false, precision=15)
plot(ta.rsi(close,14))"
# Expected: 2 errors detected in <15ms with actionable fixes
Verification Indicators:
- Error detection: SHORT_TITLE_TOO_LONG (39 chars > 10 limit)
- Error detection: INVALID_PRECISION (15 > max allowed 8)
- Performance: Sub-15ms response times
- Output: Structured JSON with severity levels and fix suggestions
Core Capabilities
Documentation Search (pinescript_reference):
- Semantic search with synonym expansion across 457 functions + 427 variables
- Streaming delivery for large result sets via JSON chunks
- Enhanced keyword matching for technical terms
Code Review (pinescript_review):
- Directory support for entire PineScript projects
- Multi-format output (JSON, Markdown, streaming)
- Severity filtering (errors, warnings, suggestions)
- Real-time streaming for large codebases
- 9 validation rules with 100% test coverage
Basic Usage Commands
Code Validation:
claude -p "Use pinescript_review to check this code: [your PineScript code]"
Documentation Research:
claude -p "Use pinescript_reference to search 'array functions'"
Project Review:
claude -p "Use pinescript_review with source_type=directory, directory_path=./src"
Performance Verification:
time claude -p "Use pinescript_reference to search 'ta.sma'"
# Target: <15ms total response time
Integration Setup
Claude Desktop Integration - Add to @claude_desktop_config.json:
{
"mcpServers": {
"pinescript": {
"command": "node",
"args": ["/path/to/mcp-server-pinescript/index.js"]
}
}
}
Local Development Mode:
git clone https://github.com/iamrichardD/mcp-server-pinescript.git
cd mcp-server-pinescript && npm install && npm start
# Should show: "PineScript MCP Server ready with preloaded documentation!"
Performance & Architecture
Performance Characteristics:
- Response Times: 5-15ms for typical queries (70-85% faster than baseline)
- Memory Usage: ~12MB RAM with 555KB preloaded documentation
安装
This server does not publish a one-line install command.
Open the repository installation guide 新手?先看 mcpskill.org 教程 →配置
{
"mcpServers": {
"pinescript": {
"command": "node",
"args": ["/path/to/mcp-server-pinescript/index.js"]
}
}
}