[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-DmitrySolana--Molt-Pi-Maker":3,"tool-DmitrySolana--Molt-Pi-Maker":62},[4,18,26,36,46,54],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":17},4358,"openclaw","openclaw\u002Fopenclaw","OpenClaw 是一款专为个人打造的本地化 AI 助手，旨在让你在自己的设备上拥有完全可控的智能伙伴。它打破了传统 AI 助手局限于特定网页或应用的束缚，能够直接接入你日常使用的各类通讯渠道，包括微信、WhatsApp、Telegram、Discord、iMessage 等数十种平台。无论你在哪个聊天软件中发送消息，OpenClaw 都能即时响应，甚至支持在 macOS、iOS 和 Android 设备上进行语音交互，并提供实时的画布渲染功能供你操控。\n\n这款工具主要解决了用户对数据隐私、响应速度以及“始终在线”体验的需求。通过将 AI 部署在本地，用户无需依赖云端服务即可享受快速、私密的智能辅助，真正实现了“你的数据，你做主”。其独特的技术亮点在于强大的网关架构，将控制平面与核心助手分离，确保跨平台通信的流畅性与扩展性。\n\nOpenClaw 非常适合希望构建个性化工作流的技术爱好者、开发者，以及注重隐私保护且不愿被单一生态绑定的普通用户。只要具备基础的终端操作能力（支持 macOS、Linux 及 Windows WSL2），即可通过简单的命令行引导完成部署。如果你渴望拥有一个懂你",349277,3,"2026-04-06T06:32:30",[13,14,15,16],"Agent","开发框架","图像","数据工具","ready",{"id":19,"name":20,"github_repo":21,"description_zh":22,"stars":23,"difficulty_score":10,"last_commit_at":24,"category_tags":25,"status":17},3808,"stable-diffusion-webui","AUTOMATIC1111\u002Fstable-diffusion-webui","stable-diffusion-webui 是一个基于 Gradio 构建的网页版操作界面，旨在让用户能够轻松地在本地运行和使用强大的 Stable Diffusion 图像生成模型。它解决了原始模型依赖命令行、操作门槛高且功能分散的痛点，将复杂的 AI 绘图流程整合进一个直观易用的图形化平台。\n\n无论是希望快速上手的普通创作者、需要精细控制画面细节的设计师，还是想要深入探索模型潜力的开发者与研究人员，都能从中获益。其核心亮点在于极高的功能丰富度：不仅支持文生图、图生图、局部重绘（Inpainting）和外绘（Outpainting）等基础模式，还独创了注意力机制调整、提示词矩阵、负向提示词以及“高清修复”等高级功能。此外，它内置了 GFPGAN 和 CodeFormer 等人脸修复工具，支持多种神经网络放大算法，并允许用户通过插件系统无限扩展能力。即使是显存有限的设备，stable-diffusion-webui 也提供了相应的优化选项，让高质量的 AI 艺术创作变得触手可及。",162132,"2026-04-05T11:01:52",[14,15,13],{"id":27,"name":28,"github_repo":29,"description_zh":30,"stars":31,"difficulty_score":32,"last_commit_at":33,"category_tags":34,"status":17},1381,"everything-claude-code","affaan-m\u002Feverything-claude-code","everything-claude-code 是一套专为 AI 编程助手（如 Claude Code、Codex、Cursor 等）打造的高性能优化系统。它不仅仅是一组配置文件，而是一个经过长期实战打磨的完整框架，旨在解决 AI 代理在实际开发中面临的效率低下、记忆丢失、安全隐患及缺乏持续学习能力等核心痛点。\n\n通过引入技能模块化、直觉增强、记忆持久化机制以及内置的安全扫描功能，everything-claude-code 能显著提升 AI 在复杂任务中的表现，帮助开发者构建更稳定、更智能的生产级 AI 代理。其独特的“研究优先”开发理念和针对 Token 消耗的优化策略，使得模型响应更快、成本更低，同时有效防御潜在的攻击向量。\n\n这套工具特别适合软件开发者、AI 研究人员以及希望深度定制 AI 工作流的技术团队使用。无论您是在构建大型代码库，还是需要 AI 协助进行安全审计与自动化测试，everything-claude-code 都能提供强大的底层支持。作为一个曾荣获 Anthropic 黑客大奖的开源项目，它融合了多语言支持与丰富的实战钩子（hooks），让 AI 真正成长为懂上",158594,2,"2026-04-16T23:34:05",[14,13,35],"语言模型",{"id":37,"name":38,"github_repo":39,"description_zh":40,"stars":41,"difficulty_score":42,"last_commit_at":43,"category_tags":44,"status":17},8272,"opencode","anomalyco\u002Fopencode","OpenCode 是一款开源的 AI 编程助手（Coding Agent），旨在像一位智能搭档一样融入您的开发流程。它不仅仅是一个代码补全插件，而是一个能够理解项目上下文、自主规划任务并执行复杂编码操作的智能体。无论是生成全新功能、重构现有代码，还是排查难以定位的 Bug，OpenCode 都能通过自然语言交互高效完成，显著减少开发者在重复性劳动和上下文切换上的时间消耗。\n\n这款工具专为软件开发者、工程师及技术研究人员设计，特别适合希望利用大模型能力来提升编码效率、加速原型开发或处理遗留代码维护的专业人群。其核心亮点在于完全开源的架构，这意味着用户可以审查代码逻辑、自定义行为策略，甚至私有化部署以保障数据安全，彻底打破了传统闭源 AI 助手的“黑盒”限制。\n\n在技术体验上，OpenCode 提供了灵活的终端界面（Terminal UI）和正在测试中的桌面应用程序，支持 macOS、Windows 及 Linux 全平台。它兼容多种包管理工具，安装便捷，并能无缝集成到现有的开发环境中。无论您是追求极致控制权的资深极客，还是渴望提升产出的独立开发者，OpenCode 都提供了一个透明、可信",144296,1,"2026-04-16T14:50:03",[13,45],"插件",{"id":47,"name":48,"github_repo":49,"description_zh":50,"stars":51,"difficulty_score":32,"last_commit_at":52,"category_tags":53,"status":17},2271,"ComfyUI","Comfy-Org\u002FComfyUI","ComfyUI 是一款功能强大且高度模块化的视觉 AI 引擎，专为设计和执行复杂的 Stable Diffusion 图像生成流程而打造。它摒弃了传统的代码编写模式，采用直观的节点式流程图界面，让用户通过连接不同的功能模块即可构建个性化的生成管线。\n\n这一设计巧妙解决了高级 AI 绘图工作流配置复杂、灵活性不足的痛点。用户无需具备编程背景，也能自由组合模型、调整参数并实时预览效果，轻松实现从基础文生图到多步骤高清修复等各类复杂任务。ComfyUI 拥有极佳的兼容性，不仅支持 Windows、macOS 和 Linux 全平台，还广泛适配 NVIDIA、AMD、Intel 及苹果 Silicon 等多种硬件架构，并率先支持 SDXL、Flux、SD3 等前沿模型。\n\n无论是希望深入探索算法潜力的研究人员和开发者，还是追求极致创作自由度的设计师与资深 AI 绘画爱好者，ComfyUI 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",108322,"2026-04-10T11:39:34",[14,15,13],{"id":55,"name":56,"github_repo":57,"description_zh":58,"stars":59,"difficulty_score":32,"last_commit_at":60,"category_tags":61,"status":17},6121,"gemini-cli","google-gemini\u002Fgemini-cli","gemini-cli 是一款由谷歌推出的开源 AI 命令行工具，它将强大的 Gemini 大模型能力直接集成到用户的终端环境中。对于习惯在命令行工作的开发者而言，它提供了一条从输入提示词到获取模型响应的最短路径，无需切换窗口即可享受智能辅助。\n\n这款工具主要解决了开发过程中频繁上下文切换的痛点，让用户能在熟悉的终端界面内直接完成代码理解、生成、调试以及自动化运维任务。无论是查询大型代码库、根据草图生成应用，还是执行复杂的 Git 操作，gemini-cli 都能通过自然语言指令高效处理。\n\n它特别适合广大软件工程师、DevOps 人员及技术研究人员使用。其核心亮点包括支持高达 100 万 token 的超长上下文窗口，具备出色的逻辑推理能力；内置 Google 搜索、文件操作及 Shell 命令执行等实用工具；更独特的是，它支持 MCP（模型上下文协议），允许用户灵活扩展自定义集成，连接如图像生成等外部能力。此外，个人谷歌账号即可享受免费的额度支持，且项目基于 Apache 2.0 协议完全开源，是提升终端工作效率的理想助手。",100752,"2026-04-10T01:20:03",[45,13,15,14],{"id":63,"github_repo":64,"name":65,"description_en":66,"description_zh":67,"ai_summary_zh":67,"readme_en":68,"readme_zh":69,"quickstart_zh":70,"use_case_zh":71,"hero_image_url":72,"owner_login":73,"owner_name":74,"owner_avatar_url":75,"owner_bio":76,"owner_company":77,"owner_location":78,"owner_email":79,"owner_twitter":73,"owner_website":79,"owner_url":80,"languages":81,"stars":86,"forks":87,"last_commit_at":88,"license":89,"difficulty_score":32,"env_os":90,"env_gpu":91,"env_ram":91,"env_deps":92,"category_tags":97,"github_topics":98,"view_count":32,"oss_zip_url":79,"oss_zip_packed_at":79,"status":17,"created_at":105,"updated_at":106,"faqs":107,"releases":108},8334,"DmitrySolana\u002FMolt-Pi-Maker","Molt-Pi-Maker","Your AI guide for Molt Pi Maker.","Molt-Pi Maker 是一款专为树莓派（Raspberry Pi）开发者打造的 AI 编程助手，旨在简化硬件项目的开发与学习过程。它能够自动生成控制 GPIO、传感器及摄像头的 Python 代码，提供详细的引脚接线指导，并在项目遇到故障时协助排查问题，让用户在动手实践中轻松掌握嵌入式开发技能。\n\n该工具主要解决了硬件初学者面对复杂电路连接和底层代码时的入门门槛高、调试困难等痛点，同时也为经验丰富的开发者提供了高效的自动化编码支持。无论是想要尝试智能硬件的学生、创客，还是从事物联网原型开发的工程师，都能从中受益。\n\n技术亮点方面，Molt-Pi Maker 具备高度稳定的自主开发循环机制，通过“双重条件退出门”和智能熔断器设计，有效防止程序陷入死循环。它支持结构化 JSON 输出、会话连续性管理（断点续建）以及现代化的命令行交互界面。此外，项目拥有完善的测试体系（308 项测试全部通过）和持续的 CI\u002FCD 流水线更新，确保了工具的可靠性与易用性。","#  Molt Pi Maker\n\nYour AI guide for Molt Pi Maker.\n\n\u003Cimg width=\"998\" height=\"278\" alt=\"62a1b8aa3587d40105c1c8f679724744\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDmitrySolana_Molt-Pi-Maker_readme_daf1bd1af36b.png\" \u002F>\n\n\n## What It Does\n\n- Generates Python code for GPIO, sensors, cameras\n- Explains wiring pin-by-pin\n- Troubleshoots when things break\n- Teaches as you build\n\n## Quick Start\n\n```python\nfrom gpiozero import LED\nled = LED(17)\nled.blink()\n```\n\n## Includes\n\n- GPIO pinout reference\n- Common libraries guide\n- Beginner → Advanced projects\n- Troubleshooting tips\n\n## Project Status\n\n**Version**: v0.9.9 - Active Development\n**Core Features**: Working and tested\n**Test Coverage**: 308 tests, 100% pass rate\n\n### What's Working Now\n- Autonomous development loops with intelligent exit detection\n- **Dual-condition exit gate**: Requires BOTH completion indicators AND explicit EXIT_SIGNAL\n- Rate limiting with hourly reset (100 calls\u002Fhour, configurable)\n- Circuit breaker with advanced error detection (prevents runaway loops)\n- Response analyzer with semantic understanding and two-stage error filtering\n- **JSON output format support with automatic fallback to text parsing**\n- **Session continuity with `--continue` flag for context preservation**\n- **Session expiration with configurable timeout (default: 24 hours)**\n- **Modern CLI flags: `--output-format`, `--allowed-tools`, `--no-continue`**\n- Multi-line error matching for accurate stuck loop detection\n- 5-hour API limit handling with user prompts\n- tmux integration for live monitoring\n- PRD import functionality\n- **CI\u002FCD pipeline with GitHub Actions**\n- **Dedicated uninstall script for clean removal**\n- 308 passing tests across 11 test files\n\n### Recent Improvements\n\n**v0.9.9 - EXIT_SIGNAL Gate & Uninstall Script**\n- Fixed premature exit bug: completion indicators now require Claude's explicit `EXIT_SIGNAL: true`\n- Added dual-condition check preventing exits when Claude reports work in progress\n- Added `response_analyzer.sh` fix to respect explicit EXIT_SIGNAL over heuristics\n- Added dedicated `uninstall.sh` script for clean Ralph removal\n- Session expiration with configurable timeout (default: 24 hours)\n- Added 32 new tests for EXIT_SIGNAL behavior and session expiration\n- Test count: 308 (up from 276)\n\n**v0.9.8 - Modern CLI for PRD Import**\n- Modernized `ralph_import.sh` to use Claude Code CLI JSON output format\n- JSON output format support with `--output-format json` for structured responses\n- Enhanced error handling with structured JSON error messages\n- Improved file verification with JSON-derived status information\n- Backward compatibility with older CLI versions (automatic text fallback)\n- Added 11 new tests for modern CLI features\n\n**v0.9.7 - Session Lifecycle Management**\n- Complete session lifecycle management with automatic reset triggers\n- Session auto-reset on: circuit breaker open, manual interrupt, project completion\n- Added `--reset-session` CLI flag for manual session reset\n- Session history tracking (last 50 transitions) for debugging\n- Added 26 new tests for session continuity features\n\n**v0.9.6 - JSON Output & Session Management**\n- Extended `parse_json_response()` to support Claude Code CLI JSON format\n- Added session management functions: `store_session_id()`, `get_last_session_id()`, `should_resume_session()`\n- Cross-platform epoch time utilities in date_utils.sh\n- Added 16 new tests covering Claude CLI format and session management\n\n**v0.9.5 - PRD Import Tests**\n- Added 22 comprehensive tests for `ralph_import.sh` PRD conversion script\n- Tests cover: file format support, output file creation, project naming, error handling\n\n**v0.9.4 - Project Setup Tests**\n- Added 36 comprehensive tests for `setup.sh` project initialization script\n- Tests cover: directory creation, template copying, git initialization\n\n**v0.9.3 - Installation Tests**\n- Added 14 comprehensive tests for `install.sh` global installation script\n- Tests cover: directory creation, command installation, dependency detection\n\n**v0.9.2 - Prompt File Fix**\n- Fixed critical bug: replaced non-existent `--prompt-file` CLI flag with `-p` flag\n- Modern CLI mode now correctly passes prompt content via `-p \"$(cat file)\"`\n- Added error handling for missing prompt files in `build_claude_command()`\n\n**v0.9.1 - Modern CLI Commands (Phase 1.1)**\n- JSON output format support with `--output-format json` (default)\n- Session continuity using `--continue` flag for cross-loop context\n- Tool permissions via `--allowed-tools` flag\n- CI\u002FCD pipeline with kcov coverage reporting\n\n**v0.9.0 - Circuit Breaker Enhancements**\n- Fixed multi-line error matching in stuck loop detection\n- Eliminated JSON field false positives (e.g., `\"is_error\": false`)\n- Added two-stage error filtering for accurate detection\n\n### In Progress\n- Expanding test coverage\n- Log rotation functionality\n- Dry-run mode\n- Configuration file support (.ralphrc)\n- Metrics and analytics tracking\n- Desktop notifications\n- Git backup and rollback system\n\n**Timeline to v1.0**: ~4 weeks | [Full roadmap](IMPLEMENTATION_PLAN.md) | **Contributions welcome!**\n\n## Features\n\n- **Autonomous Development Loop** - Continuously executes Claude Code with your project requirements\n- **Intelligent Exit Detection** - Dual-condition check requiring BOTH completion indicators AND explicit EXIT_SIGNAL\n- **Session Continuity** - Preserves context across loop iterations with automatic session management\n- **Session Expiration** - Configurable timeout (default: 24 hours) with automatic session reset\n- **Rate Limiting** - Built-in API call management with hourly limits and countdown timers\n- **5-Hour API Limit Handling** - Detects Claude's 5-hour usage limit and offers wait\u002Fexit options\n- **Live Monitoring** - Real-time dashboard showing loop status, progress, and logs\n- **Task Management** - Structured approach with prioritized task lists and progress tracking\n- **Project Templates** - Quick setup for new projects with best-practice structure\n- **Comprehensive Logging** - Detailed execution logs with timestamps and status tracking\n- **Configurable Timeouts** - Set execution timeout for Claude Code operations (1-120 minutes)\n- **Verbose Progress Mode** - Optional detailed progress updates during execution\n- **Response Analyzer** - AI-powered analysis of Claude Code responses with semantic understanding\n- **Circuit Breaker** - Advanced error detection with two-stage filtering, multi-line error matching, and automatic recovery\n- **CI\u002FCD Integration** - GitHub Actions workflow with automated testing\n- **Clean Uninstall** - Dedicated uninstall script for complete removal\n\n## Quick Start\n\nRalph has two phases: **one-time installation** and **per-project setup**.\n\n```\nINSTALL ONCE              USE MANY TIMES\n+-----------------+          +----------------------+\n| .\u002Finstall.sh    |    ->    | ralph-setup project1 |\n|                 |          | ralph-setup project2 |\n| Adds global     |          | ralph-setup project3 |\n| commands        |          | ...                  |\n+-----------------+          +----------------------+\n```\n\n### Phase 1: Install Ralph (One Time Only)\n\nInstall Ralph globally on your system:\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Ffrankbria\u002Fralph-claude-code.git\ncd ralph-claude-code\n.\u002Finstall.sh\n```\n\nThis adds `ralph`, `ralph-monitor`, and `ralph-setup` commands to your PATH.\n\n> **Note**: You only need to do this once per system. After installation, you can delete the cloned repository if desired.\n\n### Phase 2: Initialize New Projects (Per Project)\n\nFor each new project you want Ralph to work on:\n\n#### Option A: Import Existing PRD\u002FSpecifications\n```bash\n# Convert existing PRD\u002Fspecs to Ralph format (recommended)\nralph-import my-requirements.md my-project\ncd my-project\n\n# Review and adjust the generated files:\n# - PROMPT.md (Ralph instructions)\n# - @fix_plan.md (task priorities)\n# - specs\u002Frequirements.md (technical specs)\n\n# Start autonomous development\nralph --monitor\n```\n\n#### Option B: Manual Project Setup\n```bash\n# Create blank Ralph project\nralph-setup my-awesome-project\ncd my-awesome-project\n\n# Configure your project requirements manually\n# Edit PROMPT.md with your project goals\n# Edit specs\u002F with detailed specifications\n# Edit @fix_plan.md with initial priorities\n\n# Start autonomous development\nralph --monitor\n```\n\n### Ongoing Usage (After Setup)\n\nOnce Ralph is installed and your project is initialized:\n\n```bash\n# Navigate to any Ralph project and run:\nralph --monitor              # Integrated tmux monitoring (recommended)\n\n# Or use separate terminals:\nralph                        # Terminal 1: Ralph loop\nralph-monitor               # Terminal 2: Live monitor dashboard\n```\n\n### Uninstalling Ralph\n\nTo completely remove Ralph from your system:\n\n```bash\n# Run the uninstall script\n.\u002Funinstall.sh\n\n# Or if you deleted the repo, download and run:\ncurl -sL https:\u002F\u002Fraw.githubusercontent.com\u002Ffrankbria\u002Fralph-claude-code\u002Fmain\u002Funinstall.sh | bash\n```\n\n## How It Works\n\nRalph operates on a simple but powerful cycle:\n\n1. **Read Instructions** - Loads `PROMPT.md` with your project requirements\n2. **Execute Claude Code** - Runs Claude Code with current context and priorities\n3. **Track Progress** - Updates task lists and logs execution results\n4. **Evaluate Completion** - Checks for exit conditions and project completion signals\n5. **Repeat** - Continues until project is complete or limits are reached\n\n### Intelligent Exit Detection\n\nRalph uses a **dual-condition check** to prevent premature exits during productive iterations:\n\n**Exit requires BOTH conditions:**\n1. `completion_indicators >= 2` (heuristic detection from natural language patterns)\n2. Claude's explicit `EXIT_SIGNAL: true` in the RALPH_STATUS block\n\n**Example behavior:**\n```\nLoop 5: Claude outputs \"Phase complete, moving to next feature\"\n        → completion_indicators: 3 (high confidence from patterns)\n        → EXIT_SIGNAL: false (Claude says more work needed)\n        → Result: CONTINUE (respects Claude's explicit intent)\n\nLoop 8: Claude outputs \"All tasks complete, project ready\"\n        → completion_indicators: 4\n        → EXIT_SIGNAL: true (Claude confirms done)\n        → Result: EXIT with \"project_complete\"\n```\n\n**Other exit conditions:**\n- All tasks in `@fix_plan.md` marked complete\n- Multiple consecutive \"done\" signals from Claude Code\n- Too many test-focused loops (indicating feature completeness)\n- Claude API 5-hour usage limit reached (with user prompt to wait or exit)\n\n## Importing Existing Requirements\n\nRalph can convert existing PRDs, specifications, or requirement documents into the proper Ralph format using Claude Code.\n\n### Supported Formats\n- **Markdown** (.md) - Product requirements, technical specs\n- **Text files** (.txt) - Plain text requirements\n- **JSON** (.json) - Structured requirement data\n- **Word documents** (.docx) - Business requirements\n- **PDFs** (.pdf) - Design documents, specifications\n- **Any text-based format** - Ralph will intelligently parse the content\n\n### Usage Examples\n\n```bash\n# Convert a markdown PRD\nralph-import product-requirements.md my-app\n\n# Convert a text specification\nralph-import requirements.txt webapp\n\n# Convert a JSON API spec\nralph-import api-spec.json backend-service\n\n# Let Ralph auto-name the project from filename\nralph-import design-doc.pdf\n```\n\n### What Gets Generated\n\nRalph-import creates a complete project with:\n\n- **PROMPT.md** - Converted into Ralph development instructions\n- **@fix_plan.md** - Requirements broken down into prioritized tasks\n- **specs\u002Frequirements.md** - Technical specifications extracted from your document\n- **Standard Ralph structure** - All necessary directories and template files\n\nThe conversion is intelligent and preserves your original requirements while making them actionable for autonomous development.\n\n### Modern CLI Features (v0.9.8)\n\nRalph-import uses modern Claude Code CLI features for improved reliability:\n\n- **JSON Output Format**: Structured responses enable precise parsing of conversion results\n- **Automatic Fallback**: Gracefully handles older CLI versions with text-based parsing\n- **Enhanced Error Reporting**: Extracts specific error messages and codes from JSON responses\n- **Session Tracking**: Captures session IDs for potential continuation of interrupted conversions\n\n> **Note**: These features require Claude Code CLI version 2.0.76 or later. Older versions will work with standard text output.\n\n## Configuration\n\n### Rate Limiting & Circuit Breaker\n\nRalph includes intelligent rate limiting and circuit breaker functionality:\n\n```bash\n# Default: 100 calls per hour\nralph --calls 50\n\n# With integrated monitoring\nralph --monitor --calls 50\n\n# Check current usage\nralph --status\n```\n\nThe circuit breaker automatically:\n- Detects API errors and rate limit issues with advanced two-stage filtering\n- Opens circuit after 3 loops with no progress or 5 loops with same errors\n- Eliminates false positives from JSON fields containing \"error\"\n- Accurately detects stuck loops with multi-line error matching\n- Gradually recovers with half-open monitoring state\n- Provides detailed error tracking and logging with state history\n\n### Claude API 5-Hour Limit\n\nWhen Claude's 5-hour usage limit is reached, Ralph:\n1. Detects the limit error automatically\n2. Prompts you to choose:\n   - **Option 1**: Wait 60 minutes for the limit to reset (with countdown timer)\n   - **Option 2**: Exit gracefully (or auto-exits after 30-second timeout)\n3. Prevents endless retry loops that waste time\n\n### Custom Prompts\n\n```bash\n# Use custom prompt file\nralph --prompt my_custom_instructions.md\n\n# With integrated monitoring\nralph --monitor --prompt my_custom_instructions.md\n```\n\n### Execution Timeouts\n\n```bash\n# Set Claude Code execution timeout (default: 15 minutes)\nralph --timeout 30  # 30-minute timeout for complex tasks\n\n# With monitoring and custom timeout\nralph --monitor --timeout 60  # 60-minute timeout\n\n# Short timeout for quick iterations\nralph --verbose --timeout 5  # 5-minute timeout with progress\n```\n\n### Verbose Mode\n\n```bash\n# Enable detailed progress updates during execution\nralph --verbose\n\n# Combine with other options\nralph --monitor --verbose --timeout 30\n```\n\n### Session Continuity\n\nRalph maintains session context across loop iterations for improved coherence:\n\n```bash\n# Sessions are enabled by default with --continue flag\nralph --monitor                 # Uses session continuity\n\n# Start fresh without session context\nralph --no-continue             # Isolated iterations\n\n# Reset session manually (clears context)\nralph --reset-session           # Clears current session\n\n# Check session status\ncat .ralph_session              # View current session file\ncat .ralph_session_history      # View session transition history\n```\n\n**Session Auto-Reset Triggers:**\n- Circuit breaker opens (stagnation detected)\n- Manual interrupt (Ctrl+C \u002F SIGINT)\n- Project completion (graceful exit)\n- Manual circuit breaker reset (`--reset-circuit`)\n- Session expiration (default: 24 hours)\n\nSessions are persisted to `.ralph_session` with a configurable expiration (default: 24 hours). The last 50 session transitions are logged to `.ralph_session_history` for debugging.\n\n### Exit Thresholds\n\nModify these variables in `~\u002F.ralph\u002Fralph_loop.sh`:\n\n**Exit Detection Thresholds:**\n```bash\nMAX_CONSECUTIVE_TEST_LOOPS=3     # Exit after 3 test-only loops\nMAX_CONSECUTIVE_DONE_SIGNALS=2   # Exit after 2 \"done\" signals\nTEST_PERCENTAGE_THRESHOLD=30     # Flag if 30%+ loops are test-only\n```\n\n**Circuit Breaker Thresholds:**\n```bash\nCB_NO_PROGRESS_THRESHOLD=3       # Open circuit after 3 loops with no file changes\nCB_SAME_ERROR_THRESHOLD=5        # Open circuit after 5 loops with repeated errors\nCB_OUTPUT_DECLINE_THRESHOLD=70   # Open circuit if output declines by >70%\n```\n\n**Completion Indicators with EXIT_SIGNAL Gate:**\n\n| completion_indicators | EXIT_SIGNAL | Result |\n|-----------------------|-------------|--------|\n| >= 2 | `true` | **Exit** (\"project_complete\") |\n| >= 2 | `false` | **Continue** (Claude still working) |\n| >= 2 | missing | **Continue** (defaults to false) |\n| \u003C 2 | `true` | **Continue** (threshold not met) |\n\n## Project Structure\n\nRalph creates a standardized structure for each project:\n\n```\nmy-project\u002F\n├── PROMPT.md           # Main development instructions for Ralph\n├── @fix_plan.md        # Prioritized task list (@ prefix = Ralph control file)\n├── @AGENT.md           # Build and run instructions\n├── specs\u002F              # Project specifications and requirements\n│   └── stdlib\u002F         # Standard library specifications\n├── src\u002F                # Source code implementation\n├── examples\u002F           # Usage examples and test cases\n├── logs\u002F               # Ralph execution logs\n└── docs\u002Fgenerated\u002F     # Auto-generated documentation\n```\n\n## Best Practices\n\n### Writing Effective Prompts\n\n1. **Be Specific** - Clear requirements lead to better results\n2. **Prioritize** - Use `@fix_plan.md` to guide Ralph's focus\n3. **Set Boundaries** - Define what's in\u002Fout of scope\n4. **Include Examples** - Show expected inputs\u002Foutputs\n\n### Project Specifications\n\n- Place detailed requirements in `specs\u002F`\n- Use `@fix_plan.md` for prioritized task tracking\n- Keep `@AGENT.md` updated with build instructions\n- Document key decisions and architecture\n\n### Monitoring Progress\n\n- Use `ralph-monitor` for live status updates\n- Check logs in `logs\u002F` for detailed execution history\n- Monitor `status.json` for programmatic access\n- Watch for exit condition signals\n\n## System Requirements\n\n- **Bash 4.0+** - For script execution\n- **Claude Code CLI** - `npm install -g @anthropic-ai\u002Fclaude-code`\n- **tmux** - Terminal multiplexer for integrated monitoring (recommended)\n- **jq** - JSON processing for status tracking\n- **Git** - Version control (projects are initialized as git repos)\n- **Standard Unix tools** - grep, date, etc.\n\n### Testing Requirements (Development)\n\nSee [TESTING.md](TESTING.md) for the comprehensive testing guide.\n\nIf you want to run the test suite:\n\n```bash\n# Install BATS testing framework\nnpm install -g bats bats-support bats-assert\n\n# Run all tests (308 tests)\nnpm test\n\n# Run specific test suites\nbats tests\u002Funit\u002Ftest_rate_limiting.bats\nbats tests\u002Funit\u002Ftest_exit_detection.bats\nbats tests\u002Funit\u002Ftest_json_parsing.bats\nbats tests\u002Funit\u002Ftest_cli_modern.bats\nbats tests\u002Funit\u002Ftest_cli_parsing.bats\nbats tests\u002Funit\u002Ftest_session_continuity.bats\nbats tests\u002Fintegration\u002Ftest_loop_execution.bats\nbats tests\u002Fintegration\u002Ftest_prd_import.bats\nbats tests\u002Fintegration\u002Ftest_project_setup.bats\nbats tests\u002Fintegration\u002Ftest_installation.bats\n\n# Run error detection and circuit breaker tests\n.\u002Ftests\u002Ftest_error_detection.sh\n.\u002Ftests\u002Ftest_stuck_loop_detection.sh\n```\n\nCurrent test status:\n- **308 tests** across 11 test files\n- **100% pass rate** (308\u002F308 passing)\n- Comprehensive unit and integration tests\n- Specialized tests for JSON parsing, CLI flags, circuit breaker, EXIT_SIGNAL behavior, and installation workflows\n\n> **Note on Coverage**: Bash code coverage measurement with kcov has fundamental limitations when tracing subprocess executions. Test pass rate (100%) is the quality gate. See [bats-core#15](https:\u002F\u002Fgithub.com\u002Fbats-core\u002Fbats-core\u002Fissues\u002F15) for details.\n\n### Installing tmux\n\n```bash\n# Ubuntu\u002FDebian\nsudo apt-get install tmux\n\n# macOS\nbrew install tmux\n\n# CentOS\u002FRHEL\nsudo yum install tmux\n```\n\n## Monitoring and Debugging\n\n### Live Dashboard\n\n```bash\n# Integrated tmux monitoring (recommended)\nralph --monitor\n\n# Manual monitoring in separate terminal\nralph-monitor\n```\n\nShows real-time:\n- Current loop count and status\n- API calls used vs. limit\n- Recent log entries\n- Rate limit countdown\n\n**tmux Controls:**\n- `Ctrl+B` then `D` - Detach from session (keeps Ralph running)\n- `Ctrl+B` then `←\u002F→` - Switch between panes\n- `tmux list-sessions` - View active sessions\n- `tmux attach -t \u003Csession-name>` - Reattach to session\n\n### Status Checking\n\n```bash\n# JSON status output\nralph --status\n\n# Manual log inspection\ntail -f logs\u002Fralph.log\n```\n\n### Common Issues\n\n- **Rate Limits** - Ralph automatically waits and displays countdown\n- **5-Hour API Limit** - Ralph detects and prompts for user action (wait or exit)\n- **Stuck Loops** - Check `@fix_plan.md` for unclear or conflicting tasks\n- **Early Exit** - Review exit thresholds if Ralph stops too soon\n- **Premature Exit** - Check if Claude is setting `EXIT_SIGNAL: false` (Ralph now respects this)\n- **Execution Timeouts** - Increase `--timeout` value for complex operations\n- **Missing Dependencies** - Ensure Claude Code CLI and tmux are installed\n- **tmux Session Lost** - Use `tmux list-sessions` and `tmux attach` to reconnect\n- **Session Expired** - Sessions expire after 24 hours by default; use `--reset-session` to start fresh\n\n## Contributing\n\nRalph is actively seeking contributors! We're working toward v1.0.0 with clear priorities and a detailed roadmap.\n\n**See [CONTRIBUTING.md](CONTRIBUTING.md) for the complete contributor guide** including:\n- Getting started and setup instructions\n- Development workflow and commit conventions\n- Code style guidelines\n- Testing requirements (100% pass rate mandatory)\n- Pull request process and code review guidelines\n- Quality standards and checklists\n\n### Quick Start\n\n```bash\n# Fork and clone\ngit clone https:\u002F\u002Fgithub.com\u002FYOUR_USERNAME\u002Fralph-claude-code.git\ncd ralph-claude-code\n\n# Install dependencies and run tests\nnpm install\nnpm test  # All 308 tests must pass\n```\n\n### Priority Contribution Areas\n\n1. **Test Implementation** - Help expand test coverage\n2. **Feature Development** - Log rotation, dry-run mode, config files, metrics\n3. **Documentation** - Tutorials, troubleshooting guides, examples\n4. **Real-World Testing** - Use Ralph, report bugs, share feedback\n\n**Every contribution matters** - from fixing typos to implementing major features!\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Acknowledgments\n\n- Inspired by the [Ralph technique](https:\u002F\u002Fghuntley.com\u002Fralph\u002F) created by Geoffrey Huntley\n- Built for [Claude Code](https:\u002F\u002Fclaude.ai\u002Fcode) by Anthropic\n- Community feedback and contributions\n\n## Related Projects\n\n- [Claude Code](https:\u002F\u002Fclaude.ai\u002Fcode) - The AI coding assistant that powers Ralph\n- [Aider](https:\u002F\u002Fgithub.com\u002Fpaul-gauthier\u002Faider) - Original Ralph technique implementation\n\n---\n\n## Command Reference\n\n### Installation Commands (Run Once)\n```bash\n.\u002Finstall.sh              # Install Ralph globally\n.\u002Funinstall.sh            # Remove Ralph from system (dedicated script)\n.\u002Finstall.sh uninstall    # Alternative: Remove Ralph from system\n.\u002Finstall.sh --help       # Show installation help\n```\n\n### Ralph Loop Options\n```bash\nralph [OPTIONS]\n  -h, --help              Show help message\n  -c, --calls NUM         Set max calls per hour (default: 100)\n  -p, --prompt FILE       Set prompt file (default: PROMPT.md)\n  -s, --status            Show current status and exit\n  -m, --monitor           Start with tmux session and live monitor\n  -v, --verbose           Show detailed progress updates during execution\n  -t, --timeout MIN       Set Claude Code execution timeout in minutes (1-120, default: 15)\n  --output-format FORMAT  Set output format: json (default) or text\n  --allowed-tools TOOLS   Set allowed Claude tools (default: Write,Bash(git *),Read)\n  --no-continue           Disable session continuity (start fresh each loop)\n  --reset-circuit         Reset the circuit breaker\n  --circuit-status        Show circuit breaker status\n  --reset-session         Reset session state manually\n```\n\n### Project Commands (Per Project)\n```bash\nralph-setup project-name     # Create new Ralph project\nralph-import prd.md project  # Convert PRD\u002Fspecs to Ralph project\nralph --monitor              # Start with integrated monitoring\nralph --status               # Check current loop status\nralph --verbose              # Enable detailed progress updates\nralph --timeout 30           # Set 30-minute execution timeout\nralph --calls 50             # Limit to 50 API calls per hour\nralph --reset-session        # Reset session state manually\nralph-monitor                # Manual monitoring dashboard\n```\n\n### tmux Session Management\n```bash\ntmux list-sessions        # View active Ralph sessions\ntmux attach -t \u003Cname>     # Reattach to detached session\n# Ctrl+B then D           # Detach from session (keeps running)\n```\n\n---\n\n## Development Roadmap\n\nRalph is under active development with a clear path to v1.0.0. See [IMPLEMENTATION_PLAN.md](IMPLEMENTATION_PLAN.md) for the complete roadmap.\n\n### Current Status: v0.9.9\n\n**What's Delivered:**\n- Core loop functionality with intelligent exit detection\n- **Dual-condition exit gate** (completion indicators + EXIT_SIGNAL)\n- Rate limiting (100 calls\u002Fhour) and circuit breaker pattern\n- Response analyzer with semantic understanding\n- 308 comprehensive tests (100% pass rate)\n- tmux integration and live monitoring\n- PRD import functionality with modern CLI JSON parsing\n- Installation system and project templates\n- Modern CLI commands with JSON output support\n- CI\u002FCD pipeline with GitHub Actions\n- Comprehensive installation test suite\n- Session lifecycle management with auto-reset triggers\n- Session expiration with configurable timeout\n- Dedicated uninstall script\n\n**Test Coverage Breakdown:**\n- Unit Tests: 164 (CLI parsing, JSON, exit detection, rate limiting, session continuity)\n- Integration Tests: 144 (loop execution, edge cases, installation, project setup, PRD import)\n- Test Files: 11\n\n### Path to v1.0.0 (~4 weeks)\n\n**Enhanced Testing**\n- Installation and setup workflow tests\n- tmux integration tests\n- Monitor dashboard tests\n\n**Core Features**\n- Log rotation functionality\n- Dry-run mode\n- Configuration file support - .ralphrc\n\n**Advanced Features & Polish**\n- Metrics and analytics tracking\n- Desktop notifications\n- Git backup and rollback system\n- End-to-end tests\n- Final documentation and release prep\n\nSee [IMPLEMENTATION_STATUS.md](IMPLEMENTATION_STATUS.md) for detailed progress tracking.\n\n### How to Contribute\nRalph is seeking contributors! See [CONTRIBUTING.md](CONTRIBUTING.md) for the complete guide. Priority areas:\n1. **Test Implementation** - Help expand test coverage ([see plan](IMPLEMENTATION_PLAN.md))\n2. **Feature Development** - Log rotation, dry-run mode, config files\n3. **Documentation** - Usage examples, tutorials, troubleshooting guides\n4. **Bug Reports** - Real-world usage feedback and edge cases\n\n---\n**Ready to let AI build your project?** Start with `.\u002Finstall.sh` and let Ralph take it from there!\n\n## Star History\n\n[![Star History Chart](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDmitrySolana_Molt-Pi-Maker_readme_f03ddc31ea18.png)](https:\u002F\u002Fwww.star-history.com\u002F#frankbria\u002Fralph-claude-code&type=date&legend=top-left)\n","# Molt Pi 制作器\n\n您在 Molt Pi 制作器方面的 AI 指南。\n\n\u003Cimg width=\"998\" height=\"278\" alt=\"62a1b8aa3587d40105c1c8f679724744\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDmitrySolana_Molt-Pi-Maker_readme_daf1bd1af36b.png\" \u002F>\n\n\n## 功能简介\n\n- 生成用于 GPIO、传感器和摄像头的 Python 代码\n- 分步骤解释接线方式\n- 在设备出现故障时提供故障排除指导\n- 在搭建项目的过程中进行教学\n\n## 快速入门\n\n```python\nfrom gpiozero import LED\nled = LED(17)\nled.blink()\n```\n\n## 包含内容\n\n- GPIO 引脚布局参考\n- 常用库指南\n- 从入门到高级的项目示例\n- 故障排除技巧\n\n## 项目状态\n\n**版本**: v0.9.9 - 正在开发中  \n**核心功能**: 已实现并经过测试  \n**测试覆盖率**: 308 个测试，通过率 100%\n\n### 当前已实现的功能\n- 自主开发循环，具备智能退出检测功能\n- **双重条件退出机制**: 必须同时满足完成标志和显式 `EXIT_SIGNAL` 才能退出\n- 每小时限流（100 次调用\u002F小时，可配置）\n- 具有高级错误检测功能的断路器，防止无限循环\n- 响应分析器，具备语义理解能力及两阶段错误过滤功能\n- **支持 JSON 输出格式，并自动回退至文本解析**\n- **会话连续性，可通过 `--continue` 标志保留上下文**\n- **会话过期功能，可配置超时时间（默认 24 小时）**\n- **现代化 CLI 标志：`--output-format`、`--allowed-tools`、`--no-continue`**\n- 多行错误匹配，准确检测卡死循环\n- 处理 Claude API 的 5 小时使用限制，并向用户提示\n- 集成 tmux 实现实时监控\n- 支持 PRD 文件导入\n- **使用 GitHub Actions 构建 CI\u002FCD 流水线**\n- **专用卸载脚本，便于干净地移除程序**\n- 11 个测试文件中包含 308 个通过的测试用例\n\n### 最新改进\n\n**v0.9.9 - EXIT_SIGNAL 退出机制与卸载脚本**\n- 修复了过早退出的 bug：完成标志现在需要 Claude 显式的 `EXIT_SIGNAL: true`\n- 添加了双重条件检查，防止 Claude 报告仍在工作时退出\n- 修复了 `response_analyzer.sh` 脚本，使其优先考虑显式 `EXIT_SIGNAL` 而非启发式判断\n- 添加了专门的 `uninstall.sh` 卸载脚本，方便彻底移除 Ralph\n- 可配置会话超时时间（默认 24 小时）\n- 新增 32 个测试用例，用于验证 EXIT_SIGNAL 行为和会话过期功能\n- 测试总数增至 308 个（原为 276 个）\n\n**v0.9.8 - 现代化 CLI 支持 PRD 导入**\n- 将 `ralph_import.sh` 脚本升级为使用 Claude Code CLI 的 JSON 输出格式\n- 支持 `--output-format json` 参数，输出结构化响应\n- 改进了错误处理，采用结构化的 JSON 错误信息\n- 通过 JSON 数据增强文件验证功能\n- 向后兼容旧版 CLI（自动回退至文本模式）\n- 新增 11 个测试用例，用于验证现代化 CLI 功能\n\n**v0.9.7 - 会话生命周期管理**\n- 完整的会话生命周期管理，具备自动重置触发机制\n- 会话将在断路器跳闸、手动中断或项目完成后自动重置\n- 新增 `--reset-session` CLI 标志，用于手动重置会话\n- 记录会话历史（最近 50 次状态转换），便于调试\n- 新增 26 个测试用例，用于验证会话连续性功能\n\n**v0.9.6 - JSON 输出与会话管理**\n- 扩展了 `parse_json_response()` 函数，支持 Claude Code CLI 的 JSON 格式\n- 新增会话管理函数：`store_session_id()`、`get_last_session_id()`、`should_resume_session()`\n- 在 date_utils.sh 中添加了跨平台的纪元时间工具\n- 新增 16 个测试用例，涵盖 Claude CLI 格式和会话管理功能\n\n**v0.9.5 - PRD 导入测试**\n- 新增 22 个全面的测试用例，用于验证 `ralph_import.sh` PRD 转换脚本\n- 测试内容包括：文件格式支持、输出文件创建、项目命名以及错误处理\n\n**v0.9.4 - 项目初始化测试**\n- 新增 36 个全面的测试用例，用于验证 `setup.sh` 项目初始化脚本\n- 测试内容包括：目录创建、模板复制、Git 初始化等\n\n**v0.9.3 - 安装测试**\n- 新增 14 个全面的测试用例，用于验证 `install.sh` 全局安装脚本\n- 测试内容包括：目录创建、命令安装、依赖项检测等\n\n**v0.9.2 - 提示文件修复**\n- 修复了一个关键 bug：将不存在的 `--prompt-file` CLI 标志替换为 `-p` 标志\n- 现代化 CLI 模式现在可以通过 `-p \"$(cat file)\"` 正确传递提示内容\n- 在 `build_claude_command()` 函数中增加了对缺失提示文件的错误处理\n\n**v0.9.1 - 现代化 CLI 命令（第 1.1 阶段）**\n- 支持 `--output-format json`（默认）的 JSON 输出格式\n- 使用 `--continue` 标志实现跨循环的上下文保持\n- 通过 `--allowed-tools` 标志控制可用工具\n- 构建了带有 kcov 覆盖率报告的 CI\u002FCD 流水线\n\n**v0.9.0 - 断路器功能增强**\n- 修复了卡死循环检测中的多行错误匹配问题\n- 消除了 JSON 字段中的误报（例如 `\"is_error\": false`）\n- 添加了两阶段错误过滤，以实现更准确的检测\n\n### 进展中\n- 扩展测试覆盖率\n- 日志轮转功能\n- 干运行模式\n- 配置文件支持（.ralphrc）\n- 指标与数据分析跟踪\n- 桌面通知\n- Git 备份与回滚系统\n\n**距离 v1.0 的时间表**: 约 4 周 | [完整路线图](IMPLEMENTATION_PLAN.md) | **欢迎贡献！**\n\n## 主要特性\n\n- **自主开发循环** - 根据您的项目需求持续执行 Claude Code\n- **智能退出检测** - 双重条件检查，需同时满足完成标志和显式 `EXIT_SIGNAL`\n- **会话连续性** - 通过自动会话管理功能，在循环迭代中保持上下文\n- **会话过期** - 可配置超时时间（默认 24 小时），到期后自动重置会话\n- **速率限制** - 内置 API 调用管理功能，设有每小时调用上限及倒计时\n- **5 小时 API 使用限制处理** - 检测 Claude 的 5 小时使用限制，并提供等待或退出选项\n- **实时监控** - 实时仪表板显示循环状态、进度和日志\n- **任务管理** - 结构化方法，提供优先级任务列表和进度跟踪\n- **项目模板** - 提供快速设置新项目的最佳实践结构\n- **全面日志记录** - 详细的执行日志，附带时间戳和状态跟踪\n- **可配置超时时间** - 设置 Claude Code 操作的执行超时时间（1–120 分钟）\n- **详细进度模式** - 可选的详细进度更新，用于执行过程中\n- **响应分析器** - 基于 AI 的 Claude Code 响应分析工具，具备语义理解能力\n- **断路器** - 具有高级错误检测功能，采用两阶段过滤、多行错误匹配和自动恢复机制\n- **CI\u002FCD 集成** - 使用 GitHub Actions 工作流进行自动化测试\n- **干净卸载** - 专用卸载脚本，确保彻底移除\n\n## 快速入门\n\nRalph 有两个阶段：**一次性安装**和**每个项目的初始化设置**。\n\n```\n一次性安装              多次使用\n+-----------------+          +----------------------+\n| .\u002Finstall.sh    |    ->    | ralph-setup project1 |\n|                 |          | ralph-setup project2 |\n| 添加全局命令    |          | ralph-setup project3 |\n|                 |          | ...                  |\n+-----------------+          +----------------------+\n```\n\n### 第一阶段：安装 Ralph（仅需一次）\n\n在你的系统上全局安装 Ralph：\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Ffrankbria\u002Fralph-claude-code.git\ncd ralph-claude-code\n.\u002Finstall.sh\n```\n\n这会将 `ralph`、`ralph-monitor` 和 `ralph-setup` 命令添加到你的 PATH 中。\n\n> **注意**：你只需在每台设备上执行一次此操作。安装完成后，你可以选择删除克隆的仓库。\n\n### 第二阶段：为新项目初始化（按项目进行）\n\n对于每一个你想让 Ralph 参与开发的新项目：\n\n#### 选项 A：导入现有 PRD\u002F规格文档\n```bash\n# 将现有 PRD\u002F规格文档转换为 Ralph 格式（推荐）\nralph-import my-requirements.md my-project\ncd my-project\n\n# 审查并调整生成的文件：\n# - PROMPT.md（Ralph 指令）\n# - @fix_plan.md（任务优先级）\n# - specs\u002Frequirements.md（技术规格）\n\n# 开始自主开发\nralph --monitor\n```\n\n#### 选项 B：手动初始化项目\n```bash\n# 创建空白的 Ralph 项目\nralph-setup my-awesome-project\ncd my-awesome-project\n\n# 手动配置项目需求\n# 编辑 PROMPT.md 以写入项目目标\n# 编辑 specs\u002F 目录下的详细规格\n# 编辑 @fix_plan.md 以设定初始优先级\n\n# 开始自主开发\nralph --monitor\n```\n\n### 后续使用（初始化之后）\n\n一旦 Ralph 已安装且项目已初始化：\n\n```bash\n# 进入任意一个 Ralph 项目并运行：\nralph --monitor              # 集成 tmux 监控（推荐）\n\n# 或者使用独立终端：\nralph                        # 终端 1：Ralph 循环\nralph-monitor               # 终端 2：实时监控仪表盘\n```\n\n### 卸载 Ralph\n\n要从你的系统中完全移除 Ralph：\n\n```bash\n# 运行卸载脚本\n.\u002Funinstall.sh\n\n# 如果你已经删除了仓库，也可以下载并运行：\ncurl -sL https:\u002F\u002Fraw.githubusercontent.com\u002Ffrankbria\u002Fralph-claude-code\u002Fmain\u002Funinstall.sh | bash\n```\n\n## 工作原理\n\nRalph 基于一个简单而强大的循环运作：\n\n1. **读取指令** - 加载包含项目需求的 `PROMPT.md`\n2. **执行 Claude 代码** - 根据当前上下文和优先级运行 Claude 代码\n3. **跟踪进度** - 更新任务列表并记录执行结果\n4. **评估完成情况** - 检查退出条件及项目完成信号\n5. **重复** - 直到项目完成或达到限制为止\n\n### 智能退出检测\n\nRalph 使用**双重条件检查**来防止在高效迭代过程中过早退出：\n\n**必须同时满足以下两个条件才会退出：**\n1. `completion_indicators >= 2`（基于自然语言模式的启发式检测）\n2. Claude 在 RALPH_STATUS 块中明确发出的 `EXIT_SIGNAL: true`\n\n**示例行为：**\n```\n第 5 轮：Claude 输出“阶段完成，进入下一个功能”\n        → completion_indicators: 3（由模式判断出高置信度）\n        → EXIT_SIGNAL: false（Claude 表示还需继续工作）\n        → 结果：继续执行（尊重 Claude 的明确意图）\n\n第 8 轮：Claude 输出“所有任务已完成，项目准备就绪”\n        → completion_indicators: 4\n        → EXIT_SIGNAL: true（Claude 确认已完成）\n        → 结果：退出，并标记为“project_complete”\n```\n\n**其他退出条件：**\n- `@fix_plan.md` 中的所有任务都被标记为完成\n- Claude 代码连续多次发出“完成”信号\n- 测试相关的循环次数过多（表明功能已完善）\n- 达到 Claude API 的 5 小时使用上限（此时会提示用户等待或退出）\n\n## 导入现有需求\n\nRalph 可以利用 Claude 代码将现有的 PRD、规格说明或其他需求文档转换为适合 Ralph 的格式。\n\n### 支持的格式\n- **Markdown** (.md) - 产品需求、技术规格\n- **文本文件** (.txt) - 纯文本需求\n- **JSON** (.json) - 结构化需求数据\n- **Word 文档** (.docx) - 商业需求\n- **PDF** (.pdf) - 设计文档、规格说明\n- **任何基于文本的格式** - Ralph 会智能解析内容\n\n### 使用示例\n\n```bash\n# 转换 Markdown 格式的 PRD\nralph-import product-requirements.md my-app\n\n# 转换文本格式的规格说明\nralph-import requirements.txt webapp\n\n# 转换 JSON 格式的 API 规格\nralph-import api-spec.json backend-service\n\n# 让 Ralph 自动根据文件名命名项目\nralph-import design-doc.pdf\n```\n\n### 生成的内容\n\nRalph-import 会创建一个完整的项目结构，包含：\n- **PROMPT.md** - 转换后的 Ralph 开发指令\n- **@fix_plan.md** - 将需求分解为优先级任务\n- **specs\u002Frequirements.md** - 从原始文档中提取的技术规格\n- **标准的 Ralph 目录结构** - 包含所有必要的目录和模板文件\n\n转换过程智能且保留了你原有的需求，同时使其可被用于自主开发。\n\n### 现代 CLI 特性（v0.9.8）\n\nRalph-import 利用现代 Claude 代码 CLI 功能以提高可靠性：\n\n- **JSON 输出格式**：结构化的响应便于精确解析转换结果\n- **自动回退机制**：能够优雅地处理旧版 CLI 的文本解析\n- **增强的错误报告**：从 JSON 响应中提取具体的错误信息和代码\n- **会话追踪**：捕获会话 ID，以便在中断后继续转换\n\n> **注意**：这些特性需要 Claude 代码 CLI 2.0.76 或更高版本。较旧的版本将使用标准的文本输出。\n\n## 配置\n\n### 速率限制与断路器\n\nRalph 内置了智能的速率限制和断路器功能：\n\n```bash\n# 默认每小时 100 次调用\nralph --calls 50\n\n# 结合集成监控\nralph --monitor --calls 50\n\n# 查看当前使用情况\nralph --status\n```\n\n断路器会自动：\n- 通过两阶段过滤检测 API 错误和速率限制问题\n- 在连续 3 轮无进展或连续 5 轮出现相同错误时触发断路\n- 避免因 JSON 字段中包含“error”而导致的误判\n- 通过多行错误匹配准确检测卡住的循环\n- 以半开状态逐步恢复\n- 提供详细的错误跟踪和日志记录，包括状态历史\n\n### Claude API 5 小时限制\n\n当 Claude 的 5 小时使用上限被达到时，Ralph 会：\n1. 自动检测到限流错误\n2. 提示你选择：\n   - **选项 1**：等待 60 分钟直到限流重置（带有倒计时）\n   - **选项 2**：正常退出（或在 30 秒超时后自动退出）\n3. 防止无休止的重试循环浪费时间\n\n### 自定义提示词\n\n```bash\n# 使用自定义提示词文件\nralph --prompt my_custom_instructions.md\n\n# 带集成监控\nralph --monitor --prompt my_custom_instructions.md\n```\n\n### 执行超时\n\n```bash\n# 设置 Claude Code 执行超时（默认：15 分钟）\nralph --timeout 30  # 复杂任务的 30 分钟超时\n\n# 带监控和自定义超时\nralph --monitor --timeout 60  # 60 分钟超时\n\n# 快速迭代的短超时\nralph --verbose --timeout 5  # 带进度的 5 分钟超时\n```\n\n### 详细模式\n\n```bash\n# 启用执行过程中的详细进度更新\nralph --verbose\n\n# 结合其他选项\nralph --monitor --verbose --timeout 30\n```\n\n### 会话连续性\n\nRalph 在循环迭代中保持会话上下文，以提高连贯性：\n\n```bash\n# 默认启用会话连续性，使用 --continue 标志\nralph --monitor                 # 使用会话连续性\n\n# 不带会话上下文从头开始\nralph --no-continue             # 独立的迭代\n\n# 手动重置会话（清除上下文）\nralph --reset-session           # 清除当前会话\n\n# 检查会话状态\ncat .ralph_session              # 查看当前会话文件\ncat .ralph_session_history      # 查看会话转换历史\n```\n\n**会话自动重置触发条件：**\n- 断路器打开（检测到停滞）\n- 手动中断（Ctrl+C \u002F SIGINT）\n- 项目完成（正常退出）\n- 手动重置断路器（`--reset-circuit`）\n- 会话过期（默认：24 小时）\n\n会话会持久化到 `.ralph_session` 文件中，过期时间可配置（默认：24 小时）。最近 50 次会话转换会被记录到 `.ralph_session_history` 文件中，用于调试。\n\n### 退出阈值\n\n在 `~\u002F.ralph\u002Fralph_loop.sh` 中修改以下变量：\n\n**退出检测阈值：**\n```bash\nMAX_CONSECUTIVE_TEST_LOOPS=3     # 连续 3 次仅测试循环后退出\nMAX_CONSECUTIVE_DONE_SIGNALS=2   # 收到 2 次“完成”信号后退出\nTEST_PERCENTAGE_THRESHOLD=30     # 如果 30% 及以上循环仅为测试，则标记\n```\n\n**断路器阈值：**\n```bash\nCB_NO_PROGRESS_THRESHOLD=3       # 连续 3 次无文件更改后打开断路器\nCB_SAME_ERROR_THRESHOLD=5        # 连续 5 次出现相同错误后打开断路器\nCB_OUTPUT_DECLINE_THRESHOLD=70   # 输出下降超过 70% 后打开断路器\n```\n\n**完成指标与 EXIT_SIGNAL 门控：**\n\n| completion_indicators | EXIT_SIGNAL | Result |\n|-----------------------|-------------|--------|\n| >= 2 | `true` | **退出**（“project_complete”） |\n| >= 2 | `false` | **继续**（Claude 仍在工作） |\n| >= 2 | 缺失 | **继续**（默认为 false） |\n| \u003C 2 | `true` | **继续**（未达到阈值） |\n\n## 项目结构\n\nRalph 为每个项目创建标准化结构：\n\n```\nmy-project\u002F\n├── PROMPT.md           # Ralph 的主要开发说明\n├── @fix_plan.md        # 优先级任务列表（@ 前缀表示 Ralph 控制文件）\n├── @AGENT.md           # 构建和运行指令\n├── specs\u002F              # 项目规格和需求\n│   └── stdlib\u002F         # 标准库规格\n├── src\u002F                # 源代码实现\n├── examples\u002F           # 使用示例和测试用例\n├── logs\u002F               # Ralph 执行日志\n└── docs\u002Fgenerated\u002F     # 自动生成的文档\n```\n\n## 最佳实践\n\n### 编写有效提示词\n\n1. **明确具体** - 清晰的需求带来更好的结果\n2. **优先排序** - 使用 `@fix_plan.md` 引导 Ralph 的关注点\n3. **设定边界** - 定义范围内外的内容\n4. **包含示例** - 展示预期的输入\u002F输出\n\n### 项目规格\n\n- 将详细需求放在 `specs\u002F` 目录下\n- 使用 `@fix_plan.md` 跟踪优先级任务\n- 保持 `@AGENT.md` 更新，包含构建指令\n- 记录关键决策和架构设计\n\n### 监控进度\n\n- 使用 `ralph-monitor` 获取实时状态更新\n- 检查 `logs\u002F` 目录中的详细执行历史\n- 监控 `status.json` 文件以进行程序化访问\n- 注意退出条件信号\n\n## 系统要求\n\n- **Bash 4.0+** - 用于脚本执行\n- **Claude Code CLI** - `npm install -g @anthropic-ai\u002Fclaude-code`\n- **tmux** - 推荐使用终端多路复用器进行集成监控\n- **jq** - 用于状态跟踪的 JSON 处理工具\n- **Git** - 版本控制（项目初始化为 Git 仓库）\n- **标准 Unix 工具** - grep、date 等\n\n### 测试要求（开发）\n\n完整的测试指南请参阅 [TESTING.md](TESTING.md)。\n\n如果要运行测试套件：\n\n```bash\n# 安装 BATS 测试框架\nnpm install -g bats bats-support bats-assert\n\n# 运行所有测试（308 个测试）\nnpm test\n\n# 运行特定测试套件\nbats tests\u002Funit\u002Ftest_rate_limiting.bats\nbats tests\u002Funit\u002Ftest_exit_detection.bats\nbats tests\u002Funit\u002Ftest_json_parsing.bats\nbats tests\u002Funit\u002Ftest_cli_modern.bats\nbats tests\u002Funit\u002Ftest_cli_parsing.bats\nbats tests\u002Funit\u002Ftest_session_continuity.bats\nbats tests\u002Fintegration\u002Ftest_loop_execution.bats\nbats tests\u002Fintegration\u002Ftest_prd_import.bats\nbats tests\u002Fintegration\u002Ftest_project_setup.bats\nbats tests\u002Fintegration\u002Ftest_installation.bats\n\n# 运行错误检测和断路器测试\n.\u002Ftests\u002Ftest_error_detection.sh\n.\u002Ftests\u002Ftest_stuck_loop_detection.sh\n```\n\n当前测试状态：\n- **308 个测试**分布在 11 个测试文件中\n- **100% 通过率**（308\u002F308 通过）\n- 全面的单元和集成测试\n- 专门针对 JSON 解析、CLI 标志、断路器、EXIT_SIGNAL 行为以及安装流程的测试\n\n> **关于覆盖率的说明**：使用 kcov 测量 Bash 代码覆盖率时，在追踪子进程执行方面存在根本性限制。测试通过率（100%）是质量门槛。详情请参阅 [bats-core#15](https:\u002F\u002Fgithub.com\u002Fbats-core\u002Fbats-core\u002Fissues\u002F15)。\n\n### 安装 tmux\n\n```bash\n# Ubuntu\u002FDebian\nsudo apt-get install tmux\n\n# macOS\nbrew install tmux\n\n# CentOS\u002FRHEL\nsudo yum install tmux\n```\n\n## 监控与调试\n\n### 实时仪表盘\n\n```bash\n# 推荐使用集成的 tmux 监控\nralph --monitor\n\n# 在单独终端手动监控\nralph-monitor\n```\n\n实时显示：\n- 当前循环次数和状态\n- 已使用的 API 调用数及剩余限额\n- 最近的日志条目\n- 速率限制倒计时\n\n**tmux 控制键：**\n- `Ctrl+B` 后接 `D` - 从会话分离（Ralph 继续运行）\n- `Ctrl+B` 后接 `←\u002F→` - 切换窗格\n- `tmux list-sessions` - 查看活动会话\n- `tmux attach -t \u003Csession-name>` - 重新连接到会话\n\n### 状态检查\n\n```bash\n# JSON 格式的状态输出\nralph --status\n\n# 手动检查日志\ntail -f logs\u002Fralph.log\n```\n\n### 常见问题\n\n- **速率限制** - Ralph 会自动等待并显示倒计时\n- **5 小时 API 限制** - Ralph 会检测并提示用户采取行动（等待或退出）\n- **卡住的循环** - 检查 `@fix_plan.md` 文件，查看是否存在不明确或冲突的任务\n- **过早退出** - 如果 Ralph 过早停止，请检查退出阈值\n- **过早退出** - 检查 Claude 是否设置了 `EXIT_SIGNAL: false`（Ralph 现在会尊重这一设置）\n- **执行超时** - 对于复杂操作，可增加 `--timeout` 参数的值\n- **缺少依赖项** - 确保已安装 Claude Code CLI 和 tmux\n- **tmux 会话丢失** - 使用 `tmux list-sessions` 和 `tmux attach` 重新连接\n- **会话过期** - 默认情况下，会话会在 24 小时后过期；使用 `--reset-session` 可以重新开始\n\n## 贡献说明\n\nRalph 正在积极寻求贡献者！我们正朝着 v1.0.0 版本努力，拥有清晰的优先级和详细的路线图。\n\n**请参阅 [CONTRIBUTING.md](CONTRIBUTING.md) 获取完整的贡献指南**，其中包括：\n- 入门和设置说明\n- 开发工作流程和提交规范\n- 代码风格指南\n- 测试要求（必须达到 100% 的通过率）\n- 拉取请求流程和代码审查指南\n- 质量标准和检查清单\n\n### 快速入门\n\n```bash\n# 分支并克隆\ngit clone https:\u002F\u002Fgithub.com\u002FYOUR_USERNAME\u002Fralph-claude-code.git\ncd ralph-claude-code\n\n# 安装依赖并运行测试\nnpm install\nnpm test  # 所有 308 个测试必须通过\n```\n\n### 优先贡献领域\n\n1. **测试实现** - 帮助扩展测试覆盖率\n2. **功能开发** - 日志轮转、试运行模式、配置文件、指标\n3. **文档编写** - 教程、故障排除指南、示例\n4. **实际测试** - 使用 Ralph，报告 bug，分享反馈\n\n**每一次贡献都很重要**，无论是修复错别字还是实现重大功能！\n\n## 许可证\n\n本项目采用 MIT 许可证授权，详情请参阅 [LICENSE](LICENSE) 文件。\n\n## 致谢\n\n- 灵感来源于 Geoffrey Huntley 创造的 [Ralph 技术](https:\u002F\u002Fghuntley.com\u002Fralph\u002F)\n- 专为 Anthropic 的 [Claude Code](https:\u002F\u002Fclaude.ai\u002Fcode) 构建\n- 感谢社区的反馈与贡献\n\n## 相关项目\n\n- [Claude Code](https:\u002F\u002Fclaude.ai\u002Fcode) - 驱动 Ralph 的 AI 编码助手\n- [Aider](https:\u002F\u002Fgithub.com\u002Fpaul-gauthier\u002Faider) - Ralph 技术的原始实现\n\n---\n\n## 命令参考\n\n### 安装命令（只需执行一次）\n```bash\n.\u002Finstall.sh              # 全局安装 Ralph\n.\u002Funinstall.sh            # 从系统中移除 Ralph（专用脚本）\n.\u002Finstall.sh uninstall    # 替代方案：从系统中移除 Ralph\n.\u002Finstall.sh --help       # 显示安装帮助\n```\n\n### Ralph 循环选项\n```bash\nralph [OPTIONS]\n  -h, --help              显示帮助信息\n  -c, --calls NUM         设置每小时最大调用次数（默认：100）\n  -p, --prompt FILE       设置提示文件（默认：PROMPT.md）\n  -s, --status            显示当前状态并退出\n  -m, --monitor           启动时开启 tmux 会话并进行实时监控\n  -v, --verbose           在执行过程中显示详细进度更新\n  -t, --timeout MIN       设置 Claude Code 执行超时时间（1-120 分钟，默认：15 分钟）\n  --output-format FORMAT  设置输出格式：json（默认）或文本\n  --allowed-tools TOOLS   设置允许使用的 Claude 工具（默认：Write,Bash(git *),Read）\n  --no-continue           禁用会话连续性（每次循环都从头开始）\n  --reset-circuit         重置断路器\n  --circuit-status        显示断路器状态\n  --reset-session         手动重置会话状态\n```\n\n### 项目相关命令\n```bash\nralph-setup project-name     # 创建新的 Ralph 项目\nralph-import prd.md project  # 将 PRD\u002F规格转换为 Ralph 项目\nralph --monitor              # 启动时启用集成监控\nralph --status               # 检查当前循环状态\nralph --verbose              # 启用详细进度更新\nralph --timeout 30           # 设置 30 分钟的执行超时\nralph --calls 50             # 限制每小时最多 50 次 API 调用\nralph --reset-session        # 手动重置会话状态\nralph-monitor                # 手动监控仪表板\n```\n\n### tmux 会话管理\n```bash\ntmux list-sessions        # 查看当前活跃的 Ralph 会话\ntmux attach -t \u003Cname>     # 重新连接到已分离的会话\n# Ctrl+B 然后 D           # 分离会话（会话仍继续运行）\n```\n\n---\n\n## 开发路线图\n\nRalph 处于积极开发阶段，正朝着 v1.0.0 版本稳步前进。完整路线图请参阅 [IMPLEMENTATION_PLAN.md](IMPLEMENTATION_PLAN.md)。\n\n### 当前状态：v0.9.9\n\n**已完成内容：**\n- 核心循环功能，具备智能退出检测\n- **双重退出条件**（完成指标 + EXIT_SIGNAL）\n- 速率限制（每小时 100 次调用）和断路器模式\n- 具备语义理解能力的响应分析器\n- 308 个全面测试（100% 通过率）\n- tmux 集成和实时监控\n- 支持现代 CLI JSON 解析的 PRD 导入功能\n- 安装系统和项目模板\n- 支持 JSON 输出的现代化 CLI 命令\n- 使用 GitHub Actions 的 CI\u002FCD 流程\n- 全面的安装测试套件\n- 自动重置触发器的会话生命周期管理\n- 可配置超时的会话过期机制\n- 专用的卸载脚本\n\n**测试覆盖率细分：**\n- 单元测试：164 个（CLI 解析、JSON、退出检测、速率限制、会话连续性）\n- 集成测试：144 个（循环执行、边缘案例、安装、项目设置、PRD 导入）\n- 测试文件：11 个\n\n### 通往 v1.0.0 的路径（约 4 周）\n\n**增强测试**\n- 安装和设置工作流测试\n- tmux 集成测试\n- 监控仪表板测试\n\n**核心功能**\n- 日志轮转功能\n- 试运行模式\n- 配置文件支持 - .ralphrc\n\n**高级功能与完善**\n- 指标和分析跟踪\n- 桌面通知\n- Git 备份和回滚系统\n- 端到端测试\n- 最终文档和发布准备\n\n详细进度跟踪请参阅 [IMPLEMENTATION_STATUS.md](IMPLEMENTATION_STATUS.md)。\n\n### 如何贡献\nRalph 正在寻找贡献者！请参阅 [CONTRIBUTING.md](CONTRIBUTING.md) 获取完整指南。优先领域：\n1. **测试实现** - 帮助扩展测试覆盖率（[查看计划](IMPLEMENTATION_PLAN.md)）\n2. **功能开发** - 日志轮转、试运行模式、配置文件\n3. **文档编写** - 使用示例、教程、故障排除指南\n4. **Bug 报告** - 实际使用中的反馈和边缘案例\n\n---\n**准备好让 AI 构建你的项目了吗？** 从 `.\u002Finstall.sh` 开始，剩下的就交给 Ralph 吧！\n\n## 星标历史\n\n[![星标历史图表](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDmitrySolana_Molt-Pi-Maker_readme_f03ddc31ea18.png)](https:\u002F\u002Fwww.star-history.com\u002F#frankbria\u002Fralph-claude-code?type=date&legend=top-left)","# Molt-Pi-Maker (Ralph) 快速上手指南\n\nMolt-Pi-Maker（项目代号 Ralph）是一个基于 Claude Code 的自主开发循环工具，专为树莓派及嵌入式项目设计。它能自动生成 GPIO\u002F传感器代码、解释接线细节、排查故障，并在构建过程中提供教学指导。\n\n## 环境准备\n\n在开始之前，请确保您的系统满足以下要求：\n\n*   **操作系统**: Linux 或 macOS (Windows 用户建议使用 WSL2)。\n*   **核心依赖**:\n    *   **Git**: 用于克隆仓库。\n    *   **Python 3**: 运行生成的 GPIO 代码（需安装 `gpiozero` 库）。\n    *   **Node.js & npm**: 用于运行底层 CLI 工具。\n    *   **Claude Code CLI**: 必须已安装并配置好 Anthropic API Key。\n*   **网络环境**: 需要能够稳定访问 GitHub 和 Anthropic API。\n    *   *提示*: 若在国内访问 GitHub 较慢，可配置本地 hosts 或使用加速代理。\n\n## 安装步骤\n\n安装过程分为两个阶段：**全局安装**（只需一次）和 **项目初始化**（每个新项目执行一次）。\n\n### 第一阶段：全局安装 (One-time Install)\n\n将工具安装到系统路径中：\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Ffrankbria\u002Fralph-claude-code.git\ncd ralph-claude-code\n.\u002Finstall.sh\n```\n\n> **注意**: 执行成功后，系统中将新增 `ralph`, `ralph-monitor`, `ralph-setup` 和 `ralph-import` 命令。安装完成后，您可以删除克隆的仓库目录。\n\n### 第二阶段：项目初始化 (Per-Project Setup)\n\n为您想要开发的每个新项目创建工作环境。\n\n#### 方式 A：导入现有需求文档 (推荐)\n如果您已有 PRD、技术规格书或需求文档（支持 .md, .txt, .json, .pdf, .docx 等格式）：\n\n```bash\n# 将现有文档转换为 Ralph 项目结构\nralph-import my-requirements.md my-pi-project\ncd my-pi-project\n\n# 启动自主开发循环（带实时监控）\nralph --monitor\n```\n\n#### 方式 B：手动创建新项目\n从零开始构建：\n\n```bash\n# 创建空白项目\nralph-setup my-awesome-project\ncd my-awesome-project\n\n# 手动编辑以下文件以定义目标：\n# - PROMPT.md (项目目标指令)\n# - specs\u002F (详细技术规格)\n# - @fix_plan.md (任务优先级列表)\n\n# 启动自主开发循环\nralph --monitor\n```\n\n## 基本使用\n\n安装并初始化项目后，Molt-Pi-Maker 将进入“自主开发循环”模式。它会自动读取 `PROMPT.md`，调用 Claude Code 编写代码、测试并修复错误，直到任务完成。\n\n### 1. 启动开发循环\n在项目目录下运行：\n\n```bash\nralph --monitor\n```\n*   该命令会启动一个集成 `tmux` 的监控面板，实时显示日志、进度和循环状态。\n*   或者分屏运行：终端 1 运行 `ralph`，终端 2 运行 `ralph-monitor`。\n\n### 2. 简单示例：控制 LED 灯\n假设您的 `PROMPT.md` 中包含“让连接在 GPIO 17 的 LED 灯闪烁”的需求，工具将自动生成并执行类似以下的 Python 代码：\n\n```python\nfrom gpiozero import LED\nled = LED(17)\nled.blink()\n```\n\n### 3. 会话管理\n*   **断点续传**: 如果中途停止，下次运行可使用 `--continue` 标志保留上下文：\n    ```bash\n    ralph --continue --monitor\n    ```\n*   **自动退出**: 当所有任务完成且检测到明确的退出信号 (`EXIT_SIGNAL: true`) 时，循环会自动停止。\n\n### 4. 卸载工具\n如需完全移除工具：\n\n```bash\n# 在原克隆目录运行\n.\u002Funinstall.sh\n\n# 或直接从网络运行卸载脚本\ncurl -sL https:\u002F\u002Fraw.githubusercontent.com\u002Ffrankbria\u002Fralph-claude-code\u002Fmain\u002Funinstall.sh | bash\n```","一位嵌入式开发初学者试图在树莓派上搭建一个基于温湿度传感器的自动灌溉系统，但在硬件连接和代码调试阶段陷入了困境。\n\n### 没有 Molt-Pi-Maker 时\n- **接线迷茫**：面对复杂的 GPIO 引脚图，不敢动手连接传感器，担心接错正负极导致硬件烧毁，只能反复查阅枯燥的数据手册。\n- **代码报错无助**：编写的 Python 脚本因库版本冲突或引脚定义错误无法运行，搜索引擎返回的结果碎片化，难以定位具体是硬件故障还是逻辑漏洞。\n- **学习曲线陡峭**：从点亮 LED 到读取传感器数据需要跨越巨大的知识鸿沟，缺乏循序渐进的引导，容易在环境配置阶段就放弃项目。\n- **调试效率低下**：遇到程序死循环或无响应时，只能手动重启设备并盲目修改代码，缺乏智能的错误分析和自动恢复机制。\n\n### 使用 Molt-Pi-Maker 后\n- **引脚指引清晰**：Molt-Pi-Maker 生成逐针脚的解释说明和可视化接线方案，明确告知哪根线接 GPIO17、哪根接地，让硬件连接变得安全可控。\n- **智能故障排查**：当代码运行失败时，工具自动分析错误日志，区分是电路接触不良还是代码语法问题，并提供修复后的完整代码片段。\n- **边做边学模式**：工具根据当前进度动态生成从基础到进阶的教学内容，用户在完成“读取温度”任务的同时，自然掌握了 `gpiozero` 库的核心用法。\n- **自动化开发闭环**：利用其会话连续性和断路器机制，Molt-Pi-Maker 能自动检测并跳出死循环，保留上下文断点续传，大幅减少了重复配置环境的时间。\n\nMolt-Pi-Maker 将原本令人望而生畏的硬件开发过程，转化为一个有智能向导陪伴、容错率高且能即时反馈的学习与构建旅程。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002FDmitrySolana_Molt-Pi-Maker_70997d10.png","DmitrySolana","Dmitry","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002FDmitrySolana_682d5a1f.jpg","I like building some special things💻\r\n\r\nBuilding @DriftProtocol || Prev. @leptonai || nCMO @Solana || frame @SolanaFloor⌨️\r\n\r\n","DriftProtocol","London",null,"https:\u002F\u002Fgithub.com\u002FDmitrySolana",[82],{"name":83,"color":84,"percentage":85},"Shell","#89e051",100,838,66,"2026-04-06T13:47:07","MIT","Linux, macOS","未说明",{"notes":93,"python":91,"dependencies":94},"该工具是一个用于管理 Claude Code AI 自主开发循环的 Shell 脚本包装器，主要依赖系统自带的 Bash 环境和 tmux 进行终端监控。它通过调用外部的 'Claude Code CLI' 来执行任务，因此需要预先安装并配置好 Claude Code 及其 API 密钥。文中提到的 'gpiozero' 仅作为生成代码的示例库，并非工具本身的运行依赖。支持通过 curl 一键安装或卸载，具备会话管理和速率限制功能。",[95,96],"gpiozero","Claude Code CLI",[13,45],[99,100,101,102,103,104],"ai-agent","ai-agents","claude-code","claude-code-cli","development-tools","development-workflow","2026-03-27T02:49:30.150509","2026-04-17T09:53:29.169547",[],[]]