Rules Context
A powerful rule management system that allows users to create, configure, and apply behavioral rules that govern how AI agents respond in different scenarios. Provides persistent rule storage, import/export capabilities, and seamless integration with chat conversations.
Preview

Features
- Create custom rules with names, descriptions, and content
- Toggle rules active/inactive for different contexts
- Import rules from files (.rules, .cursorrules, etc.)
- Persistent storage in browser localStorage
Installation
Integration & Configuration
Installation
Instructions
# Initialize HAX in your project agntcy-hax init # Add the rules context agntcy-hax add composer rules-context
Usage
The rules context system provides a management interface and context integration for behavioral rules.
Component Setup
Setup
import { RulesProvider, useRules, RulesModal } from "@/hax/composer/rules-context";export function ChatWithRules() {const [showRulesModal, setShowRulesModal] = useState(false);return (<RulesProvider><div className="chat-interface"><button onClick={() => setShowRulesModal(true)}>Manage Rules</button><RulesModalopen={showRulesModal}onOpenChange={setShowRulesModal}/>{/* Chat interface */}</div></RulesProvider>);}
Rules Context
A powerful rule management system that allows users to create, configure, and apply behavioral rules that govern how AI agents respond in different scenarios. Provides persistent rule storage, import/export capabilities, and seamless integration with chat conversations.
Preview

Features
- Create custom rules with names, descriptions, and content
- Toggle rules active/inactive for different contexts
- Import rules from files (.rules, .cursorrules, etc.)
- Persistent storage in browser localStorage
Installation
Integration & Configuration
Installation
Instructions
# Initialize HAX in your project agntcy-hax init # Add the rules context agntcy-hax add composer rules-context
Usage
The rules context system provides a management interface and context integration for behavioral rules.
Component Setup
Setup
import { RulesProvider, useRules, RulesModal } from "@/hax/composer/rules-context";export function ChatWithRules() {const [showRulesModal, setShowRulesModal] = useState(false);return (<RulesProvider><div className="chat-interface"><button onClick={() => setShowRulesModal(true)}>Manage Rules</button><RulesModalopen={showRulesModal}onOpenChange={setShowRulesModal}/>{/* Chat interface */}</div></RulesProvider>);}