npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@becrafter/prompt-manager

v0.1.2

Published

Remote MCP Server for managing prompts

Downloads

260

Readme

Prompt Manager

npm version License: MIT

一个提示词管理工具,帮你把常用的 AI 提示词整理成库,随时调用。

这是什么?

想象一下,你经常用 AI 写代码、做翻译、写文案...每次都要重新输入类似的提示词,很麻烦。

Prompt Manager 就是帮你管理这些提示词的工具:

  • 📝 把提示词保存成模板,随时调用
  • 🔍 快速搜索你需要的提示词
  • 🌐 通过网页界面管理,简单直观
  • 💻 也可以作为服务运行,让其他程序调用

简单说:就像收藏夹,但专门用来管理 AI 提示词。

快速开始

方式一:命令行使用(适合技术人员)

# 1. 安装
npm install -g @becrafter/prompt-manager

# 2. 启动服务
prompt-manager

# 3. 打开浏览器访问
# http://localhost:5621/admin

就这么简单!服务启动后,打开浏览器就能看到管理界面。

方式二:桌面应用(适合所有人)

下载桌面应用,双击运行,点击菜单栏图标就能管理提示词。

💡 桌面应用正在开发中,敬请期待

怎么用?

1. 创建提示词

在管理界面点击"新建",输入提示词内容:

name: 代码审查
description: 帮我审查代码质量
messages:
  - role: user
    content:
      text: |
        请审查以下代码,找出潜在问题:
        
        {{code}}

2. 使用提示词

保存后,你可以:

  • 在管理界面直接使用
  • 通过 API 调用(适合程序员)
  • 在支持 MCP 协议的 AI 客户端中使用

3. 管理提示词

  • 📁 按文件夹分类整理
  • 🔍 快速搜索
  • ✏️ 随时编辑
  • 🗑️ 删除不需要的

常见使用场景

场景 1:团队共享提示词

  • 把团队常用的提示词整理在一起
  • 新成员直接使用,不用重复写

场景 2:个人知识库

  • 把好用的提示词保存下来
  • 按项目、按类型分类管理

场景 3:集成到其他工具

  • 作为服务运行
  • 其他程序通过 API 调用你的提示词库

提示词格式

提示词用 YAML 格式保存,很简单:

name: 提示词名称
description: 简短描述
messages:
  - role: user
    content:
      text: 提示词内容,可以用 {{变量名}} 来占位
arguments:
  - name: 变量名
    description: 变量说明
    type: string
enabled: true

示例:代码审查提示词

name: code-review
description: 代码审查助手
messages:
  - role: user
    content:
      text: |
        请审查这段 {{language}} 代码:
        
        ```{{language}}
        {{code}}
        ```
        
        请指出:
        1. 潜在问题
        2. 改进建议
arguments:
  - name: language
    description: 编程语言
    type: string
  - name: code
    description: 要审查的代码
    type: string
enabled: true

配置说明

命令行参数

prompt-manager --port 6000              # 指定端口
prompt-manager --prompts-dir ./prompts  # 指定提示词目录

环境变量

创建 .env 文件(可选):

SERVER_PORT=5621
ADMIN_USERNAME=admin
ADMIN_PASSWORD=你的密码

常见问题

Q: 提示词保存在哪里?
A: 默认保存在 ~/.prompt-manager/prompts 目录

Q: 可以多人使用吗?
A: 可以,把提示词目录共享,或者部署为服务供团队使用

Q: 支持哪些 AI 客户端?
A: 支持 MCP 协议的客户端都可以使用(如 Claude Desktop)

Q: 需要编程基础吗?
A: 使用网页界面不需要,但作为服务运行需要基本的命令行知识

技术细节(可选看)

作为库使用

import { startServer } from '@becrafter/prompt-manager-core';

await startServer({
  configOverrides: {
    promptsDir: './my-prompts',
    port: 3000
  }
});

API 接口

  • GET /prompts - 获取提示词列表
  • GET /api/prompts/:name - 获取单个提示词
  • POST /api/prompts - 创建/更新提示词
  • POST /process - 处理提示词(支持参数替换)

MCP 协议支持

支持以下 MCP 工具:

  • search_prompts - 搜索提示词
  • get_prompt - 获取提示词
  • reload_prompts - 重新加载

开发

# 克隆项目
git clone https://github.com/BeCrafter/prompt-server.git
cd prompt-server

# 安装依赖
npm install

# 启动开发服务器
npm run dev

许可证

MIT License

相关链接


Made with ❤️ by BeCrafter