{"id":51026836,"url":"https://github.com/gitstq/promptcraft","last_synced_at":"2026-06-21T20:02:25.044Z","repository":{"id":357823060,"uuid":"1238700188","full_name":"gitstq/promptcraft","owner":"gitstq","description":"🎨 PromptCraft - 轻量级AI Prompt优化与管理工具 | Lightweight AI Prompt Optimization \u0026 Management Tool","archived":false,"fork":false,"pushed_at":"2026-05-14T11:20:31.000Z","size":50,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-14T13:27:49.980Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gitstq.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-05-14T11:17:09.000Z","updated_at":"2026-05-14T11:19:38.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/gitstq/promptcraft","commit_stats":null,"previous_names":["gitstq/promptcraft"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/gitstq/promptcraft","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gitstq%2Fpromptcraft","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gitstq%2Fpromptcraft/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gitstq%2Fpromptcraft/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gitstq%2Fpromptcraft/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gitstq","download_url":"https://codeload.github.com/gitstq/promptcraft/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gitstq%2Fpromptcraft/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34623906,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-21T02:00:05.568Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-06-21T20:02:24.344Z","updated_at":"2026-06-21T20:02:25.036Z","avatar_url":"https://github.com/gitstq.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n# 🎨 PromptCraft\n\n**轻量级AI Prompt优化与管理工具**\n\n*Lightweight AI Prompt Optimization \u0026 Management Tool*\n\n[![Python](https://img.shields.io/badge/Python-3.9+-blue.svg)](https://www.python.org/)\n[![License](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE)\n[![Platform](https://img.shields.io/badge/Platform-Windows%20%7C%20macOS%20%7C%20Linux-lightgrey.svg)]()\n\n[English](#english) | [简体中文](#简体中文) | [繁體中文](#繁體中文)\n\n\u003c/div\u003e\n\n---\n\n\u003ca name=\"english\"\u003e\u003c/a\u003e\n## 🇺🇸 English\n\n### 🎉 Introduction\n\n**PromptCraft** is a lightweight, elegant AI Prompt management tool that helps you organize, optimize, and reuse high-quality AI prompts. Whether you're a developer, writer, or AI enthusiast, PromptCraft makes your AI interactions more efficient.\n\n**Key Differentiators:**\n- 🚀 **Zero-dependency lightweight**: Pure Python implementation, no complex environment setup\n- 🔒 **Privacy-first**: Local SQLite storage, your data stays on your device\n- ✨ **Smart optimization**: Built-in prompt quality analysis and auto-optimization\n- 🌐 **Cross-platform**: Full support for Windows, macOS, and Linux\n- 📚 **Multilingual**: English, Simplified Chinese, and Traditional Chinese documentation\n\n### ✨ Core Features\n\n| Feature | Description |\n|---------|-------------|\n| 📚 **Prompt Library** | Create, edit, and categorize prompts with tags |\n| 🔍 **Smart Search** | Full-text search across all prompts |\n| ⭐ **Favorites** | Quick access to frequently used prompts |\n| 🎯 **Prompt Optimizer** | One-click optimization with quality scoring |\n| 🔧 **Variable Templates** | Dynamic prompts with `{{variable}}` placeholders |\n| 📊 **Usage Analytics** | Track prompt usage statistics |\n| 📤 **Import/Export** | JSON and Markdown format support |\n\n### 🚀 Quick Start\n\n#### Installation\n\n```bash\n# Install from PyPI (coming soon)\npip install promptcraft\n\n# Or install from source\ngit clone https://github.com/gitstq/promptcraft.git\ncd promptcraft\npip install -e .\n```\n\n#### Basic Usage\n\n```bash\n# Initialize\npromptcraft init\n\n# Create a new prompt\npromptcraft create \"Code Reviewer\" \"Please review this code: {{code}}\" --category coding\n\n# List all prompts\npromptcraft list\n\n# Use a prompt\npromptcraft use 1 --var code=\"def hello(): pass\"\n\n# Analyze prompt quality\npromptcraft analyze 1\n\n# Optimize a prompt\npromptcraft optimize 1 --save\n```\n\n### 📖 Detailed Usage\n\n#### Creating Prompts\n\n```bash\n# Basic creation\npromptcraft create \"Title\" \"Content\"\n\n# With options\npromptcraft create \"My Prompt\" \"Content here\" \\\n  --description \"A helpful prompt\" \\\n  --category writing \\\n  --tags \"creative,writing\" \\\n  --model gpt-4 \\\n  --favorite\n```\n\n#### Managing Prompts\n\n```bash\n# Show prompt details\npromptcraft show 1\n\n# Update a prompt\npromptcraft update 1 --title \"New Title\"\n\n# Delete a prompt\npromptcraft delete 1\n\n# Toggle favorite\npromptcraft favorite 1\n\n# Duplicate a prompt\npromptcraft duplicate 1\n```\n\n#### Using Variables\n\nCreate prompts with variables:\n```\nHello {{name}}, welcome to {{place}}!\n```\n\nUse with variable substitution:\n```bash\npromptcraft use 1 --var name=\"Alice\" --var place=\"Wonderland\"\n```\n\n#### Optimization\n\nPromptCraft analyzes your prompts across 5 dimensions:\n- **Clarity** (25%): Clear instructions without ambiguity\n- **Structure** (25%): Well-organized with proper formatting\n- **Context** (20%): Sufficient background information\n- **Specificity** (15%): Concrete examples and constraints\n- **Length** (15%): Appropriate length (not too short or long)\n\n```bash\n# Analyze quality\npromptcraft analyze 1\n\n# Optimize and save\npromptcraft optimize 1 --save\n```\n\n### 💡 Design Philosophy\n\nPromptCraft was designed with these principles:\n\n1. **Simplicity**: Minimal learning curve, intuitive commands\n2. **Privacy**: No cloud services, everything stays local\n3. **Efficiency**: Keyboard-driven workflow for power users\n4. **Extensibility**: Clean API for future enhancements\n\n### 📦 Building from Source\n\n```bash\n# Clone repository\ngit clone https://github.com/gitstq/promptcraft.git\ncd promptcraft\n\n# Install dependencies\npip install -r requirements.txt\n\n# Run tests\npytest tests/ -v\n\n# Build package\npython setup.py sdist bdist_wheel\n\n# Build executable (optional)\npython scripts/build.py all\n```\n\n### 🤝 Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/AmazingFeature`)\n3. Commit your changes (`git commit -m 'feat: Add some AmazingFeature'`)\n4. Push to the branch (`git push origin feature/AmazingFeature`)\n5. Open a Pull Request\n\n### 📄 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n---\n\n\u003ca name=\"简体中文\"\u003e\u003c/a\u003e\n## 🇨🇳 简体中文\n\n### 🎉 项目介绍\n\n**PromptCraft** 是一个简洁优雅的AI Prompt管理工具，帮助您组织、优化和复用高质量的AI提示词。无论您是开发者、写作者还是AI爱好者，PromptCraft都能让您的AI交互更加高效。\n\n**核心差异化亮点：**\n- 🚀 **零依赖轻量**: 纯Python实现，无需复杂环境配置\n- 🔒 **本地优先**: SQLite本地存储，数据完全私有化\n- ✨ **智能优化**: 内置Prompt质量分析与自动优化\n- 🌐 **跨平台**: Windows、macOS、Linux全平台支持\n- 📚 **多语言**: 简体中文、繁体中文、英文完整文档\n\n### ✨ 核心特性\n\n| 特性 | 说明 |\n|------|------|\n| 📚 **Prompt库** | 创建、编辑、分类管理Prompt，支持标签 |\n| 🔍 **智能搜索** | 全文检索所有Prompt内容 |\n| ⭐ **收藏功能** | 快速访问常用Prompt |\n| 🎯 **Prompt优化器** | 一键优化，质量评分 |\n| 🔧 **变量模板** | `{{variable}}` 占位符动态替换 |\n| 📊 **使用统计** | 追踪Prompt使用数据 |\n| 📤 **导入导出** | 支持JSON和Markdown格式 |\n\n### 🚀 快速开始\n\n#### 安装\n\n```bash\n# 从PyPI安装（即将发布）\npip install promptcraft\n\n# 或从源码安装\ngit clone https://github.com/gitstq/promptcraft.git\ncd promptcraft\npip install -e .\n```\n\n#### 基础用法\n\n```bash\n# 初始化\npromptcraft init\n\n# 创建Prompt\npromptcraft create \"代码审查\" \"请审查这段代码: {{code}}\" --category coding\n\n# 列出所有Prompt\npromptcraft list\n\n# 使用Prompt（替换变量）\npromptcraft use 1 --var code=\"def hello(): pass\"\n\n# 分析Prompt质量\npromptcraft analyze 1\n\n# 优化Prompt\npromptcraft optimize 1 --save\n```\n\n### 📖 详细使用指南\n\n#### 创建Prompt\n\n```bash\n# 基础创建\npromptcraft create \"标题\" \"内容\"\n\n# 带选项创建\npromptcraft create \"我的Prompt\" \"内容\" \\\n  --description \"描述信息\" \\\n  --category writing \\\n  --tags \"创意,写作\" \\\n  --model gpt-4 \\\n  --favorite\n```\n\n#### 管理Prompt\n\n```bash\n# 查看详情\npromptcraft show 1\n\n# 更新\npromptcraft update 1 --title \"新标题\"\n\n# 删除\npromptcraft delete 1\n\n# 切换收藏\npromptcraft favorite 1\n\n# 复制\npromptcraft duplicate 1\n```\n\n#### 使用变量\n\n创建带变量的Prompt：\n```\n你好 {{name}}，欢迎来到 {{place}}！\n```\n\n使用时替换变量：\n```bash\npromptcraft use 1 --var name=\"张三\" --var place=\"北京\"\n```\n\n#### 优化功能\n\nPromptCraft从5个维度分析Prompt质量：\n- **清晰度** (25%): 指令明确，无歧义\n- **结构化** (25%): 格式规范，层次分明\n- **上下文** (20%): 背景信息充足\n- **具体性** (15%): 包含示例和约束条件\n- **长度适中** (15%): 不过短也不过长\n\n```bash\n# 分析质量\npromptcraft analyze 1\n\n# 优化并保存\npromptcraft optimize 1 --save\n```\n\n### 💡 设计思路\n\nPromptCraft遵循以下设计理念：\n\n1. **简洁**: 学习成本低，命令直观易懂\n2. **隐私**: 无云服务，数据完全本地存储\n3. **高效**: 键盘驱动的工作流，适合高级用户\n4. **可扩展**: 清晰的API设计，便于功能扩展\n\n### 📦 从源码构建\n\n```bash\n# 克隆仓库\ngit clone https://github.com/gitstq/promptcraft.git\ncd promptcraft\n\n# 安装依赖\npip install -r requirements.txt\n\n# 运行测试\npytest tests/ -v\n\n# 构建包\npython setup.py sdist bdist_wheel\n\n# 构建可执行文件（可选）\npython scripts/build.py all\n```\n\n### 🤝 贡献指南\n\n欢迎提交Pull Request！\n\n1. Fork本仓库\n2. 创建功能分支 (`git checkout -b feature/AmazingFeature`)\n3. 提交更改 (`git commit -m 'feat: 添加某个功能'`)\n4. 推送分支 (`git push origin feature/AmazingFeature`)\n5. 创建Pull Request\n\n### 📄 开源协议\n\n本项目采用 MIT 协议开源 - 详见 [LICENSE](LICENSE) 文件。\n\n---\n\n\u003ca name=\"繁體中文\"\u003e\u003c/a\u003e\n## 🇹","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgitstq%2Fpromptcraft","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgitstq%2Fpromptcraft","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgitstq%2Fpromptcraft/lists"}