Skip to content

Add OpenClaw integration guide for Cycles budget enforcement#32

Merged
amavashev merged 2 commits intomainfrom
claude/openclaw-budget-guard-plugin-TpEEi
Mar 15, 2026
Merged

Add OpenClaw integration guide for Cycles budget enforcement#32
amavashev merged 2 commits intomainfrom
claude/openclaw-budget-guard-plugin-TpEEi

Conversation

@amavashev
Copy link
Contributor

Summary

This PR adds comprehensive documentation for integrating the cycles-openclaw-budget-guard plugin with OpenClaw agents, enabling automatic budget enforcement without custom code.

Changes

  • New guide: how-to/integrating-cycles-with-openclaw.md — complete integration documentation covering:

    • Installation and setup instructions
    • Plugin lifecycle hooks and their behavior
    • Budget level classification (healthy/low/exhausted) and model downgrading via modelFallbacks
    • Tool cost estimation configuration via toolBaseCosts
    • Automatic prompt budget hints for model self-regulation
    • Fail-open vs fail-closed behavior patterns
    • Debugging and verification steps with example log output
    • Full configuration reference table
    • Phase 1 limitations (no per-token LLM enforcement, flat tool cost estimates)
    • Comparison with manual Cycles client integration
    • Links to related guides on degradation strategies, cost estimation, shadow mode, and incident prevention
  • Updated navigation: Added link to the new guide in .vitepress/config.ts under the "How-to" section

Implementation Details

The guide documents the plugin's automatic handling of the Cycles reserve → commit → release lifecycle across five OpenClaw hooks (before_model_resolve, before_prompt_build, before_tool_call, after_tool_call, agent_end), with emphasis on zero-custom-code operation and sensible defaults for all configuration options.

https://claude.ai/code/session_0115sU3TqN2tsqKWBiC8J3HD

claude added 2 commits March 15, 2026 14:38
New integration guide covering the cycles-openclaw-budget-guard plugin:
- Installation and minimal configuration
- Budget levels and model downgrading
- Tool cost estimation
- Prompt budget hints
- Fail-open vs fail-closed behavior
- Verification with debug logging
- Full config reference
- Comparison with manual client integration
- Cross-links to related guides

Also adds the guide to the sidebar navigation.

https://claude.ai/code/session_0115sU3TqN2tsqKWBiC8J3HD
- Remove misleading CYCLES_TENANT env var (plugin doesn't read tenant from env)
- Add Node.js >= 20.0.0 to prerequisites
- Add missing config fields: defaultModelActionKind, defaultToolActionKindPrefix
- Fix example log field name: reservations -> totalReservationsMade
- Add "Current limitations (phase 1)" section

https://claude.ai/code/session_0115sU3TqN2tsqKWBiC8J3HD
@amavashev amavashev merged commit 133c411 into main Mar 15, 2026
1 check passed
@amavashev amavashev deleted the claude/openclaw-budget-guard-plugin-TpEEi branch March 17, 2026 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants