Skip to content

Commit fdb0a2d

Browse files
committed
Update README to English and improve content
1 parent c427a10 commit fdb0a2d

File tree

1 file changed

+52
-52
lines changed

1 file changed

+52
-52
lines changed

README.md

Lines changed: 52 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -3,41 +3,41 @@
33
[![npm version](https://img.shields.io/npm/v/@mcpfun/mcp-server-leetcode.svg)](https://www.npmjs.com/package/@mcpfun/mcp-server-leetcode)
44
[![license](https://img.shields.io/npm/l/@mcpfun/mcp-server-leetcode.svg)](https://github.com/doggybee/mcp-server-leetcode/blob/main/LICENSE)
55

6-
一个基于 Model Context Protocol (MCP) LeetCode 服务器,让你的 AI 助手能够访问 LeetCode 的问题、用户信息和竞赛数据。
6+
A Model Context Protocol (MCP) server for LeetCode that enables AI assistants to access LeetCode problems, user information, and contest data.
77

8-
## 特点
8+
## Features
99

10-
- 🚀 快速访问 LeetCode API
11-
- 🔍 搜索问题、获取每日挑战、查看用户信息
12-
- 🏆 查询竞赛数据和排名
13-
- 🧩 完整支持 MCP 工具和资源
14-
- 📦 提供命令行接口和可编程 API
10+
- 🚀 Fast access to LeetCode API
11+
- 🔍 Search problems, retrieve daily challenges, and check user profiles
12+
- 🏆 Query contest data and rankings
13+
- 🧩 Full support for MCP tools and resources
14+
- 📦 Provides both CLI and programmable API
1515

16-
## 安装
16+
## Installation
1717

18-
### 全局安装
18+
### Global Installation
1919

2020
```bash
2121
npm install -g @mcpfun/mcp-server-leetcode
2222
```
2323

24-
然后可以直接使用命令行运行:
24+
Once installed, you can run it directly from the command line:
2525

2626
```bash
2727
mcp-server-leetcode
2828
```
2929

30-
### 本地安装
30+
### Local Installation
3131

3232
```bash
3333
npm install @mcpfun/mcp-server-leetcode
3434
```
3535

36-
## 使用方法
36+
## Usage
3737

38-
### Claude for Desktop 集成
38+
### Integration with Claude for Desktop
3939

40-
Claude for Desktop `claude_desktop_config.json` 文件中添加:
40+
Add the following to your Claude for Desktop `claude_desktop_config.json` file:
4141

4242
```json
4343
{
@@ -49,7 +49,7 @@ npm install @mcpfun/mcp-server-leetcode
4949
}
5050
```
5151

52-
对于本地开发:
52+
For local development:
5353

5454
```json
5555
{
@@ -62,93 +62,93 @@ npm install @mcpfun/mcp-server-leetcode
6262
}
6363
```
6464

65-
### 作为库使用
65+
### Use as a Library
6666

6767
```javascript
6868
import { LeetCodeService } from '@mcpfun/mcp-server-leetcode';
6969

70-
// 初始化服务
70+
// Initialize the service
7171
const leetcodeService = new LeetCodeService();
7272

73-
// 获取每日挑战
73+
// Get daily challenge
7474
const dailyChallenge = await leetcodeService.getDailyChallenge();
7575

76-
// 搜索问题
76+
// Search problems
7777
const problems = await leetcodeService.searchProblems({
7878
difficulty: 'MEDIUM',
7979
tags: 'array+dynamic-programming'
8080
});
8181
```
8282

83-
## 可用工具
83+
## Available Tools
8484

85-
### 问题相关工具
85+
### Problem-related Tools
8686

87-
| 工具名 | 描述 | 参数 |
87+
| Tool Name | Description | Parameters |
8888
|--------|------|------|
89-
| `get-daily-challenge` | 获取每日挑战 | |
90-
| `get-problem` | 获取指定问题详情 | `titleSlug` (字符串) |
91-
| `search-problems` | 搜索满足条件的问题 | `tags` (可选), `difficulty` (可选), `limit` (默认20), `skip` (默认0) |
89+
| `get-daily-challenge` | Get the daily challenge | None |
90+
| `get-problem` | Get details for a specific problem | `titleSlug` (string) |
91+
| `search-problems` | Search for problems based on criteria | `tags` (optional), `difficulty` (optional), `limit` (default 20), `skip` (default 0) |
9292

93-
### 用户相关工具
93+
### User-related Tools
9494

95-
| 工具名 | 描述 | 参数 |
95+
| Tool Name | Description | Parameters |
9696
|--------|------|------|
97-
| `get-user-profile` | 获取用户信息 | `username` (字符串) |
98-
| `get-user-submissions` | 获取用户提交历史 | `username` (字符串), `limit` (可选, 默认20) |
99-
| `get-user-contest-ranking` | 获取用户竞赛排名 | `username` (字符串) |
97+
| `get-user-profile` | Get user information | `username` (string) |
98+
| `get-user-submissions` | Get user submission history | `username` (string), `limit` (optional, default 20) |
99+
| `get-user-contest-ranking` | Get user contest rankings | `username` (string) |
100100

101-
### 竞赛相关工具
101+
### Contest-related Tools
102102

103-
| 工具名 | 描述 | 参数 |
103+
| Tool Name | Description | Parameters |
104104
|--------|------|------|
105-
| `get-contest-details` | 获取竞赛详情 | `contestSlug` (字符串) |
105+
| `get-contest-details` | Get contest details | `contestSlug` (string) |
106106

107-
## 可用资源
107+
## Available Resources
108108

109-
### 问题资源
109+
### Problem Resources
110110

111-
- `leetcode://daily-challenge`: 每日挑战
112-
- `leetcode://problem/{titleSlug}`: 问题详情
113-
- `leetcode://problems{?tags,difficulty,limit,skip}`: 问题列表
111+
- `leetcode://daily-challenge`: Daily challenge
112+
- `leetcode://problem/{titleSlug}`: Problem details
113+
- `leetcode://problems{?tags,difficulty,limit,skip}`: Problem list
114114

115-
### 用户资源
115+
### User Resources
116116

117-
- `leetcode://user/{username}/profile`: 用户资料
118-
- `leetcode://user/{username}/submissions{?limit}`: 用户提交
119-
- `leetcode://user/{username}/contest-ranking`: 用户竞赛排名
117+
- `leetcode://user/{username}/profile`: User profile
118+
- `leetcode://user/{username}/submissions{?limit}`: User submissions
119+
- `leetcode://user/{username}/contest-ranking`: User contest ranking
120120

121-
## 本地开发
121+
## Local Development
122122

123-
克隆仓库并安装依赖:
123+
Clone the repository and install dependencies:
124124

125125
```bash
126126
git clone https://github.com/doggybee/mcp-server-leetcode.git
127127
cd mcp-server-leetcode
128128
npm install
129129
```
130130

131-
以开发模式运行:
131+
Run in development mode:
132132

133133
```bash
134134
npm run dev
135135
```
136136

137-
构建项目:
137+
Build the project:
138138

139139
```bash
140140
npm run build
141141
```
142142

143-
## 许可证
143+
## License
144144

145145
MIT
146146

147-
## 相关项目
147+
## Related Projects
148148

149-
- [Model Context Protocol](https://modelcontextprotocol.io) - MCP 规范和文档
150-
- [Claude for Desktop](https://claude.ai/download) - 支持 MCP 的 AI 助手
149+
- [Model Context Protocol](https://modelcontextprotocol.io) - MCP specifications and documentation
150+
- [Claude for Desktop](https://claude.ai/download) - AI assistant with MCP support
151151

152-
## 致谢
152+
## Acknowledgements
153153

154-
- 这个项目受到 [alfa-leetcode-api](https://github.com/alfaarghya/alfa-leetcode-api) 的启发
154+
- This project was inspired by [alfa-leetcode-api](https://github.com/alfaarghya/alfa-leetcode-api)

0 commit comments

Comments
 (0)