deterministic safety hook enforcement via pretooluse/posttooluse protocol
Intercepts Claude Code tool invocations at the PreToolUse and PostToolUse lifecycle hooks, executing hard-coded Bash/PowerShell scripts that return definitive deny decisions based on file paths, command patterns, and git state. Unlike probabilistic CLAUDE.md rules that degrade with context growth, these hooks enforce boundaries through portable shell scripts requiring only jq, ensuring consistent enforcement across any environment where Claude Code runs.
Unique: Implements hard-coded, portable shell-based safety enforcement that returns definitive deny decisions via Claude Code's PreToolUse/PostToolUse protocol, eliminating the probabilistic degradation of prompt-based rules and requiring zero external dependencies beyond jq
vs alternatives: Provides deterministic enforcement where prompt-based guardrails (CLAUDE.md) fail; unlike cloud-based safety services, operates entirely offline with no latency from external validation
autonomous agent loop orchestration with scheduled execution
A Rust-based loop runner (src/main.rs) that manages the complete lifecycle of autonomous Claude Code execution: reading configuration from boucle.toml, assembling context from memory and plugins, invoking Claude Code in a loop, capturing tool execution results, and persisting state back to the Broca memory system. The runner implements fail-safe semantics, allowing graceful degradation when hooks block operations, and integrates with the Self-Observation Engine (Improve) to enable agents to reflect on their own performance.
Unique: Implements a Rust-based loop runner that integrates Claude Code's PreToolUse/PostToolUse hooks with a self-observing agent architecture, using git-native Markdown/YAML memory to maintain transparent, version-controlled state across autonomous execution cycles
vs alternatives: Unlike generic LLM orchestration frameworks (LangChain, LlamaIndex), Boucle is purpose-built for Claude Code's tool ecosystem and provides deterministic safety enforcement; unlike simple cron-based approaches, it maintains structured memory and self-observation capabilities
hook installation and enforcement orchestration (enforce-hooks)
A Python-based tool that automates the installation, configuration, and enforcement of all Boucle safety hooks across an environment. The enforce-hooks script reads hook specifications, validates prerequisites (Bash/PowerShell version, jq availability), installs hooks to the correct locations, and configures them with project-specific allowlists/blocklists. It also provides an 'enforce' mode that validates all hooks are active before allowing agent execution.
Unique: Automates the installation and configuration of all Boucle safety hooks through a Python orchestrator that validates prerequisites, installs hooks to correct locations, and provides an 'enforce' mode that validates hook activation before allowing agent execution
vs alternatives: Provides automated hook deployment where manual installation is error-prone; unlike generic configuration management tools (Ansible, Terraform), enforce-hooks is purpose-built for Boucle's hook ecosystem and understands hook-specific validation requirements
known limitations database and web interface
A structured database of known agent limitations, bypass patterns, and mitigations that is accessible through a web interface. The system allows teams to document discovered hook bypasses, edge cases, and limitations in a centralized location, enabling knowledge sharing across agent deployments. The web interface provides search and filtering capabilities to help developers understand what protections are in place and what gaps remain.
Unique: Provides a centralized, web-accessible database of known agent limitations, hook bypass patterns, and mitigations, enabling teams to document and share security knowledge about Boucle's safety model and its edge cases
vs alternatives: Unlike generic vulnerability databases (CVE, NVD), this is purpose-built for Boucle's safety model; unlike scattered documentation, it provides a searchable, centralized knowledge base
mcp server integration for claude desktop (broca mcp)
An MCP (Model Context Protocol) server that exposes Boucle's Broca memory system and agent capabilities as tools available to Claude Desktop. The server implements standard MCP tool definitions, allowing Claude to query agent memory, trigger agent loops, and inspect execution state directly from the Claude Desktop interface. This enables interactive debugging and manual agent control without requiring command-line access.
Unique: Exposes Boucle's Broca memory system and agent capabilities as an MCP server, enabling Claude Desktop to query agent state, trigger loops, and inspect execution results through standard MCP tool definitions without CLI access
vs alternatives: Provides GUI-based agent interaction where CLI-only approaches require terminal access; unlike REST APIs, MCP integration is native to Claude Desktop and requires no additional tooling
configuration-driven agent setup (boucle.toml)
A TOML-based configuration file that defines agent behavior, memory paths, plugin locations, hook policies, and execution schedules. The Boucle loop runner reads boucle.toml at startup, assembling the complete agent context from the configuration. This enables teams to version-control agent configuration alongside code and enables rapid agent setup without code changes.
Unique: Provides TOML-based configuration that enables version-controlled, environment-specific agent setup without code changes, allowing teams to define agent behavior, memory paths, plugins, and hook policies declaratively
vs alternatives: Provides declarative configuration where hardcoded setup requires code changes; unlike environment variables, TOML enables structured, hierarchical configuration with validation
git-native structured memory system (broca) with transparent state management
A memory architecture that stores agent state as standard Markdown and YAML files in the git repository, making agent knowledge and execution history human-readable, version-controlled, and auditable. The Broca system uses a structured schema for memory entries, enabling the Self-Observation Engine to query and update memory programmatically while maintaining git history for debugging and rollback. This approach eliminates the black-box nature of vector databases and enables agents to reason about their own memory.
Unique: Replaces opaque vector databases with git-native Markdown/YAML files, enabling agents to maintain transparent, auditable, version-controlled memory that is human-readable and queryable by the agent itself through the Self-Observation Engine
vs alternatives: Provides full auditability and version history where vector databases (Pinecone, Weaviate) offer only current state; enables direct human inspection and git-based debugging where RAG systems require specialized tools to understand memory contents
self-observation engine (improve) for autonomous agent reflection and learning
A subsystem that enables agents to query their own Broca memory, analyze past execution outcomes, and generate improvement strategies without human intervention. The Improve engine reads execution logs and memory state, identifies patterns in successes and failures, and updates agent knowledge or strategy documents in the memory system. This creates a feedback loop where agents can reason about their own performance and adapt behavior across execution cycles.
Unique: Implements a closed-loop self-observation system where agents query their own git-native memory to identify execution patterns, generate improvement hypotheses, and update their own knowledge base — enabling autonomous learning without external feedback or retraining
vs alternatives: Unlike fine-tuning approaches (which require external data and retraining), Improve operates within a single agent's memory; unlike human-in-the-loop systems, it enables continuous autonomous adaptation without manual review cycles
+6 more capabilities