Skip to main content
Glama
vjik

My Prompts MCP

by vjik

My Prompts MCP

GitHub Release

轻量级 MCP 服务器,用于提供以 Markdown 文件定义并支持参数的用户提示词。

将你的提示词 .md 文件保存在一个仓库中(可以是专门的 git 仓库,也可以是现有仓库中的一个文件夹), 并通过此 MCP 服务器将该目录连接到你的 AI 客户端。这样你的提示词就可以进行版本控制、 共享,并能轻松地在不同机器和团队成员之间更新。

使用 Cherry Studio 运行 My Prompts MCP 的示例:

https://github.com/user-attachments/assets/32dfa36d-657f-4b9b-8086-c7a00ffe3185

IMPORTANT

本项目由Sergei Predvoditelev 开发和维护。 社区支持有助于保持项目的活跃开发和良好维护。 你可以通过以下服务支持本项目:

感谢你的支持 ❤️

常规用法

安装

GitHub Releases 下载适用于你平台的二进制文件。

创建提示词

在你的提示词目录中创建一个 .md 文件,例如 greet.md

---
description: Greet a person by name
arguments:
  - name: name
    description: The person's name
    required: true
---
Please greet {{name}} in a friendly and professional way.

连接到 MCP 客户端

将以下内容添加到你的 MCP 客户端配置中(stdio 传输):

{
  "mcpServers": {
    "my-prompts-mcp": {
      "command": "/path/to/my-prompts-mcp",
      "args": ["--path=/path/to/prompts"]
    }
  }
}

编辑 claude_desktop_config.json 文件:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

  • Linux: ~/.config/Claude/claude_desktop_config.json

将上面的代码片段添加到文件中,然后重启 Claude Desktop。

打开 设置 → MCP 服务器,点击 添加,并填入上述代码片段中的服务器命令和参数。

文档

提示词文件格式

配置目录中的每个 .md 文件都会被公开为一个提示词。默认情况下,不带 .md 扩展名的文件名会被用作 提示词名称。

Front matter 字段

文件顶部的可选 YAML front matter 用于控制提示词如何呈现给客户端。

字段

类型

必填

描述

name

string

提示词名称。默认为不带扩展名的文件名。

title

string

人类可读的标题。

description

string

显示给 AI 客户端的简短描述。

arguments

list

参数列表(见下文)。

参数

参数可以以两种形式定义:

简单形式(仅名称):

arguments:
  - arg_name

完整对象形式

arguments:
  - name: arg_name
    description: What this argument means
    required: true

每个参数字段:

字段

类型

必填

描述

name

string

参数名称。

description

string

参数描述。

required

boolean

参数是否必填。默认为 false

IMPORTANT

几乎所有 MCP 客户端都支持无参数或单参数的提示词。但并非所有客户端都普遍支持两个或更多参数的提示词。 已知支持多个参数的客户端包括:

占位符

在提示词正文中使用 {{arg_name}}。占位符会在请求时被提供的参数值替换。

提示词文件示例

---
name: name-generator
title: Name Generator
description: Generate a name for a product, project, or company
arguments:
  - name: description
    description: What needs to be named (product, project, company, etc.)
    required: true
  - name: style
    description: Naming style (e.g. minimalist, creative, technical, playful)
    required: false
---
Generate 10 name ideas for: {{description}}.

{{style}}

Requirements for the names:
- Easy to remember and pronounce
- Suitable for use as a domain name
- Unique and distinctive

For each name provide a one-line explanation of why it works.

许可证

“My Prompts MCP” 是自由软件。它在 BSD 许可证条款下发布。 请参阅 LICENSE 以获取更多信息。

A
license - permissive license
-
quality - not tested
D
maintenance

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/vjik/my-prompts-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server