feat: CLI-first execution policy and multi-provider support #1

Merged
metacat merged 10 commits from feat/cli-first-policy into main 2026-05-04 14:05:10 +00:00
Owner

Summary

This PR restructures the framework to use .robotz/ namespace and removes Robotz.identity in favor of CLI-managed authentication.

Major Changes

  1. Framework Restructure to .robotz/

    • Move .agents/.robotz/agents/
    • Move Robotz.yaml.robotz/Robotz.yaml
    • Delete portable_seed/ (no longer needed)
    • Delete root AGENTS.md (framework IS the coordination layer)
  2. CLI-First Execution Policy

    • All Git/forge operations MUST use CLI tools
    • API calls are forbidden
    • Agents STOP and escalate if CLI is missing/unauthenticated
  3. Robotz.identity Removed

    • Tokens managed by CLI tools (gh, glab, tea)
    • No secret files in framework
  4. AGENTS.md as Host Project File

    • AGENTS.md template embedded in INSTALLATION.md
    • Materialized in host project root during init
    • Supports merge/overwrite during initialization
  5. INSTALLATION.md as Self-Contained Installer

    • One curl command to bootstrap
    • Includes AGENTS.md template, framework templates
    • Self-deletes after successful setup
  6. .robotz/ Gitignore Question

    • Asked during initialization
    • Default: commit it (like .github/)
  7. Feature Extraction Skill

    • New feature-extract skill for legacy code transplantation

Breaking Changes

  • .agents/ no longer exists — all files under .robotz/agents/
  • Robotz.identity deleted — authenticate via CLI tools
  • AGENTS.md no longer at framework root — materialized in host projects

Testing

  • Fresh project initialization via INSTALLATION.md
  • Provider CLI detection
  • AGENTS.md merge/overwrite flow
  • Code review creation via CLI
  • Feature extraction from legacy project
  • .robotz/ gitignore question
## Summary This PR restructures the framework to use `.robotz/` namespace and removes `Robotz.identity` in favor of CLI-managed authentication. ### Major Changes 1. **Framework Restructure to `.robotz/`** - Move `.agents/` → `.robotz/agents/` - Move `Robotz.yaml` → `.robotz/Robotz.yaml` - Delete `portable_seed/` (no longer needed) - Delete root `AGENTS.md` (framework IS the coordination layer) 2. **CLI-First Execution Policy** - All Git/forge operations MUST use CLI tools - API calls are forbidden - Agents STOP and escalate if CLI is missing/unauthenticated 3. **Robotz.identity Removed** - Tokens managed by CLI tools (gh, glab, tea) - No secret files in framework 4. **AGENTS.md as Host Project File** - AGENTS.md template embedded in INSTALLATION.md - Materialized in host project root during init - Supports merge/overwrite during initialization 5. **INSTALLATION.md as Self-Contained Installer** - One curl command to bootstrap - Includes AGENTS.md template, framework templates - Self-deletes after successful setup 6. **`.robotz/` Gitignore Question** - Asked during initialization - Default: commit it (like `.github/`) 7. **Feature Extraction Skill** - New `feature-extract` skill for legacy code transplantation ### Breaking Changes - `.agents/` no longer exists — all files under `.robotz/agents/` - `Robotz.identity` deleted — authenticate via CLI tools - `AGENTS.md` no longer at framework root — materialized in host projects ### Testing - [ ] Fresh project initialization via INSTALLATION.md - [ ] Provider CLI detection - [ ] AGENTS.md merge/overwrite flow - [ ] Code review creation via CLI - [ ] Feature extraction from legacy project - [ ] `.robotz/` gitignore question
- Add GIT_PROVIDER_CONFIG.yaml registry for GitHub/GitLab/Gitea/Forgejo/Codeberg
- Remove GitHub-specific hardcoding from all skills and policies
- Update init-project skill with provider auto-detection flow
- Add repository_providers section to Robotz.yaml descriptor
- Clean up Robotz.identity: remove token_env_var, use plain token placeholder
- Update portable seed payload with multi-provider awareness
- Add comprehensive README.md for multi-project usage
- Install tea CLI v0.14.0 for Gitea/Forgejo/Codeberg support

BREAKING CHANGE: Robotz.identity no longer uses token_env_var.
Tokens are now stored directly in Robotz.identity (which is gitignored).
- Add CLI-First Execution Policy to GIT_WORKFLOW_POLICY.md
  - Mandate CLI tools over API calls for all Git/forge operations
  - Add escalation rules when CLI is missing or unauthenticated
  - Include install commands table for all providers

- Update GIT_PROVIDER_CONFIG.yaml with CLI-first policy statement
  - Add execution policy header forbidding API calls
  - Update tea minimum version to 0.14

- Enhance init-project skill with mandatory provider walkthrough
  - Add Phase 2b: Provider Setup Walkthrough
  - If no provider detected or CLI missing, walk dev through setup
  - Provide install and auth commands for all providers
  - Record provider:none if dev opts out, with warning

- Update RULES.md with CLI-First Execution Rule
  - Explicitly forbid curl/wget/HTTP library API calls
  - Stop and escalate if CLI is missing

- Update AGENTS.md and portable seed with CLI-first note

- Update README.md with comprehensive CLI-First Policy section
  - Explain why CLI-first (security, auditability, reliability)
  - Show do/don't examples
  - Add missing CLI troubleshooting flow
  - Add provider CLI quick reference table

BREAKING CHANGE: Agents will now STOP and escalate if provider
CLI tools are not installed, rather than attempting API calls.
With CLI-first execution policy, Robotz.identity became redundant:
- Tokens are managed by CLI tools (gh, glab, tea) in their own configs/keyrings
- Provider detection flows from git remote -> Robotz.yaml
- Auth checks use CLI-native commands (gh auth status, tea whoami)

Changes:
- Delete Robotz.identity file and remove from git tracking
- Update Robotz.yaml: remove workspace_ops.include_from
- Update GIT_WORKFLOW_POLICY.md: remove token reading from identity file
- Update GIT_PROVIDER_CONFIG.yaml: remove Robotz.identity references
- Rewrite init-project skill: remove token questions, add CLI auth verification
- Update AGENTS.md and portable seed: remove identity from detection flow
- Update README.md: replace identity section with CLI auth explanation

BREAKING CHANGE: Robotz.identity is removed. Users must authenticate
via their provider's CLI tool instead of storing tokens in a file.
Add INSTALATION.md following the oh-my-openagent installation pattern:
- For Humans: one-liner to paste into agent session
- For LLM Agents: detailed step-by-step workflow
- Step 0: Prerequisites check
- Step 1: Detect current state
- Step 2: Provider detection + CLI verification (critical)
- Step 3: Run init-project skill with questions
- Step 4: Post-init verification
- Step 5: Test task creation
- Step 6: Framework explanation and congratulations

Emphasizes CLI-first throughout with clear escalation paths
when CLI is missing or unauthenticated.
When AGENTS.md already exists during initialization:
- Present merge vs overwrite options to user
- 'Ignore' is explicitly not an option (framework won't work without it)
- merge: Append framework authority sections while preserving existing content
- overwrite: Replace with framework version after explicit confirmation
- If user cancels: STOP initialization with clear warning

Updated:
- init-project/SKILL.md Phase 1 with AGENTS.md handling
- init-project agent config with AGENTS.md behavior note
- INSTALATION.md Step 1 with AGENTS.md detection and decision flow
Add surgical extraction skill to port specific features from legacy
projects into the current codebase without importing entire codebases.

Skill features:
- Phase 1: Feature scoping via human interview (scope first, extract second)
- Phase 2: Legacy code analysis with targeted search and dependency mapping
- Phase 3: Surgical extraction with staging area and interface documentation
- Phase 4: Adaptation for current project conventions
- Phase 5: Integration with commit, context capsule, and handover
- Phase 6: Validation (tests, compilation, dependency leakage check)

Includes:
- SKILL.md with 6-phase workflow
- Agent configuration (openai.yaml)
- Safety rules and anti-patterns
- Completion checklist

Use cases:
- Extract handshake logic from old TCP server
- Port auth flow from legacy app
- Reuse payment processing module
- Migrate specific algorithm/utility

Updated agents_brain.md skill inventory.
- Move Robotz.yaml → .robotz/Robotz.yaml
- Move .agents/ → .robotz/agents/
- Delete portable_seed/ (no longer needed)
- Delete root AGENTS.md (framework IS the coordination layer)
- Preserve git history via git mv

BREAKING CHANGE: Framework files relocated. All paths must be updated.
- Replace all .agents/ references with .robotz/agents/ across all files
- Update /Robotz.yaml paths to /.robotz/Robotz.yaml
- Fix README.md directory tree to show .robotz/ structure
- Update framework internal files: BOOT.md, RULES.md, GIT_WORKFLOW_POLICY.md, etc.
- Update all skill files to reference .robotz/agents/ paths
- Update README.md and INSTALATION.md root file references
INSTALLATION.md:
- Add Framework Materialization section showing host project structure
- Add  Gitignore Question section for install interview
- Add AGENTS.md Template appendix with full template content
- Add Post-Installation: Delete Installer section
- Update Step 3 to include AGENTS.md materialization and gitignore question

init-project skill:
- Add Phase 5b: Materialize AGENTS.md from template
- Add Phase 5c: .robotz/ gitignore question
- Add Phase 8: Delete INSTALLATION.md after setup
- Update completion summary
- Remove Method B (portable seed) — replaced with installer method
- Update Method C (manual setup) to use .robotz/ paths
- Add AGENTS.md creation step to manual setup
- Remove portable_seed references
- Update directory tree for new structure
metacat deleted branch feat/cli-first-policy 2026-05-04 14:05:10 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
atomika/aibook!1
No description provided.