Add autonomy levels (L0-L4), claude-lessons tool, and MCP server guide - #29
Merged
Conversation
- scripts/validate-agents.sh used `declare -A`, which crashes on bash 3.2 (the default /bin/bash on every stock macOS install, despite the repo's own "Platform: macOS" badge). Replaced with a portable space-delimited set so the script actually runs on macOS. - tools/claude-pipeline.py `list` used a backslash-escaped quote inside an f-string nested in another f-string — a SyntaxError on every Python version, so `claude-pipeline list`/`--help` never worked at all. Hoisted the value into a local variable instead. - Added __pycache__/*.pyc to .gitignore (generated while testing tools/). Found while verifying the autonomy/lessons/MCP-guide changes in this branch.
Harness type (tight/loose/adaptive) controls output constraint; autonomy level is a separate axis for how much human checking a task needs before or after the AI acts. Adds the 5-level model (L0 human-only .. L4 fully autonomous, L2 draft+review as the common default) from the AI Agent autonomy article this branch is based on. - autonomy: field added to all 11 agent frontmatters, assigned per role - claude-harness.py: new required check (autonomy declared), `autonomy` subcommand printing the L0-L4 table, templates updated - harness-designer (09): new design step + Autonomy Level output field - docs/HARNESS-GUIDE.md(.ko): new Autonomy Levels section - README Agent Roster table: new Autonomy column - /harness command + cheatsheets: autonomy validate check + prompts Closes #26
claude-handoff captures session state; nothing in this project recorded WHY something failed and HOW it was fixed, so the next session (or agent) had no way to avoid repeating a past mistake. Unlike handoffs, lessons accumulate indefinitely and are searchable by tag/keyword rather than pruned by age. claude-lessons add # symptom / root cause / fix / tags claude-lessons list # recent, optionally filtered by tag claude-lessons search Q # keyword search claude-lessons context # pipeable into claude for session-start context Stdlib-only, mirrors tools/claude-handoff.py conventions. Wired into Makefile install-tools/status/test-python and install.sh's TOOLS array. Closes #27
Documents when to convert a CLI tool into an MCP server (Claude calls it mid-conversation) vs. keeping it a slash command or manual pipe (human stays in control of when it runs) — including a guideline against wrapping mutating/write actions as auto-callable MCP tools, tied to the autonomy levels added earlier in this branch. examples/mcp-lessons-server.py wraps tools/claude-lessons.py (add_lesson, search_lessons, recent_lessons) via the `mcp` Python SDK's FastMCP API. Lives under examples/, not tools/, since tools/ must stay dependency-free per docs/CONTRIBUTING.md — documented there as the one exception. Verified end-to-end against a real `mcp` install: `pip install mcp` now pulls a 2.x release that reworked/moved FastMCP, so the guide and example both pin `mcp>=1.2,<2`, confirmed working with 1.29.0. Closes #28
…guide - Agent Roster: new Autonomy column + explanation - Tools: 7 -> 8, new Tool 8 (claude-lessons) section, /lessons row, repo layout tree, context-cost-tips row - Nav bars + repo layout: MCP-GUIDE.md(.ko) link - README.ko.md also gets the harness/pipeline Tool 6/7 detail sections and full 11-agent repo layout it was missing — it had fallen out of sync with README.md (only the slash-command table and top badges had been updated when those tools were added), which this branch's changes would otherwise have made worse
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (33)
📝 WalkthroughWalkthrough자율성 L0-L4 선언과 검증 기능이 하네스와 에이전트 설정에 추가되었습니다. Changes자율성 검증과 설계
Lessons 기능
설치와 저장소 문서
Estimated code review effort: 3 (Moderate) | ~25 minutes Possibly related issues
Possibly related PRs
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This was referenced Aug 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Three features inspired by "AI Agent 시대, 나는 AI를 어떻게 써야 할까?", closing #26, #27, #28:
autonomy:field;claude-harnessvalidates it and gained anautonomysubcommand; documented indocs/HARNESS-GUIDE.md(.ko).claude-lessons— an 8th tool that records why something failed and how it was fixed (vs.claude-handoff's session-scoped state), searchable by tag/keyword, meant to accumulate indefinitely.docs/MCP-GUIDE.md(.ko) +examples/mcp-lessons-server.py) — when to convert a CLI tool into an MCP server Claude calls mid-conversation vs. keeping it a slash command/manual pipe, with a working example wrappingclaude-lessons.Also fixes two pre-existing bugs found while verifying this branch (unrelated to the above, see the first commit for detail):
scripts/validate-agents.shuseddeclare -A, which crashes on bash 3.2 (stock macOS/bin/bash) — the script never actually ran on macOS.tools/claude-pipeline.py'slistcommand had a nested f-string with a backslash-escaped quote that's aSyntaxErroron every Python version —claude-pipelinewas completely broken (even--helpfailed at import).And syncs
README.ko.md, which had fallen out of date (missing the Tool 6/7 detail sections and the full 11-agent repo layout thatREADME.mdalready had) — left as-is it would have only gotten worse with this PR's additions.Test plan
All run locally (Python 3.14.6; no Rust toolchain available in this environment, no
rust/files touched):python3 -m py_compileon every changed/added Python filemake test-python(sandboxedHOME) — all 6 tools pass, including the previously-brokenclaude-pipelineclaude-harness check-all— all 11 agents pass the new autonomy check (2 unrelated pre-existing failures on06/07confirmed viagit diff origin/mainto predate this branch)bash scripts/validate-agents.sh --strict— now runs at all on bash 3.2; non-strict passesclaude-lessonsexercised end-to-end (add/list/search/show/context), including a same-second ID-collision fix found during testingexamples/mcp-lessons-server.pyexercised end-to-end against a realmcp==1.29.0install (all 3 tools registered and callable) — also how themcp>=1.2,<2pin was discovered (pip install mcpalone now installs a 2.x rewrite with a different API)Summary by CodeRabbit
새 기능
claude-lessons도구와/lessons명령을 추가했습니다.문서
개선