xint
X Intelligence CLI — search, monitor, analyze, and engage on X/Twitter. TypeScript + Bun. AI agent skill.
OpenClaw Optimizer Skill
请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。
SkillHub CLI
skillhub install idanmann10/startclaw-optimizer打开来源仓库,查看说明和兼容环境后,按来源提供的命令或步骤安装。
将来源链接提供给你的 Agent,让它先读取说明、核对依赖,并向你说明将执行的安装步骤。
The OpenClaw Optimizer is a comprehensive performance and cost optimization skill designed to enhance the efficiency of Clawdbot's subagent workflows.
Before Optimization: $90/day After Optimization: $3-5/day Savings: 95%
npm install @startclaw/openclaw-optimizer
const { TaskRouter, OptimizerScheduler, BrowserGovernor } = require('@startclaw/openclaw-optimizer');
const router = new TaskRouter();
const scheduler = new OptimizerScheduler();
const browserGovernor = new BrowserGovernor();
// Automatic model and cost optimization
const modelSelection = router.selectModel(taskDescription);
await scheduler.execute(task, modelSelection);
# Real-time dashboard
python3 scripts/dashboard.py watch
StartClaw Internal Use License
这些信息来自收录时的来源分析,可能滞后;使用前请核对最新来源文件。
const { SubagentContextCompactor } = require('./context-compaction');
// Initialize compactor
const compactor = new SubagentContextCompactor({
tokenThreshold: 50000,
summaryModel: 'claude-3-5-haiku'
});
// Before spawning subagent
const preparedContext = await compactor.prepareForSubagent(fullContext, sessionKey);
sessions_spawn({
context: preparedContext,
// other spawn parameters
});
Compaction events are logged with:
# OpenClaw Optimizer Skill
## Overview
The OpenClaw Optimizer is a comprehensive performance and cost optimization skill designed to enhance the efficiency of Clawdbot's subagent workflows.
## Core Components
### 1. Task Router
- Intelligent model selection based on task complexity
- Automatic routing between Haiku, Sonnet, and Opus models
- Cost prediction and optimization
### 2. Scheduler
- Robust task execution with retry mechanism
- Configurable preflight and postflight hooks
- Timeout and exponential backoff handling
### 3. Browser Governor
- Browser tab serialization
- Concurrent tab management
- Circuit breaker for preventing runaway processes
### 4. Context Compaction
- Automatic token tracking
- Summarization at 50,000 token threshold
- Preserves critical context
### 5. Real-time Dashboard
- Monitor daily budget
- Track task execution
- Visualize model distribution
- Circuit breaker status
## Expected Savings
**Before Optimization:** $90/day
**After Optimization:** $3-5/day
**Savings:** 95%
## Installation
```bash
npm install @startclaw/openclaw-optimizer
```
## Usage
```javascript
const { TaskRouter, OptimizerScheduler, BrowserGovernor } = require('@startclaw/openclaw-optimizer');
const router = new TaskRouter();
const scheduler = new OptimizerScheduler();
const browserGovernor = new BrowserGovernor();
// Automatic model and cost optimization
const modelSelection = router.selectModel(taskDescription);
await scheduler.execute(task, modelSelection);
```
## Monitoring
```bash
# Real-time dashboard
python3 scripts/dashboard.py watch
```
## License
StartClaw Internal Use License# OpenClaw Optimizer: Context Compaction for Subagents
## Context Compaction Feature
### Key Capabilities
- Automatic token tracking across sessions
- Auto-summarization at 50,000 token threshold
- Preserves critical context and task intent
- Cost-effective summarization using Haiku model
### Usage Example
```javascript
const { SubagentContextCompactor } = require('./context-compaction');
// Initialize compactor
const compactor = new SubagentContextCompactor({
tokenThreshold: 50000,
summaryModel: 'claude-3-5-haiku'
});
// Before spawning subagent
const preparedContext = await compactor.prepareForSubagent(fullContext, sessionKey);
sessions_spawn({
context: preparedContext,
// other spawn parameters
});
```
### How It Works
1. Tracks token usage across main and subagent sessions
2. Detects when context approaches 50,000 tokens
3. Extracts and preserves critical information
4. Generates a concise summary using Haiku
5. Maintains session continuity
### Performance Impact
- Minimal overhead
- Reduces API costs by 70-90%
- Prevents runaway context growth
## Logging and Telemetry
Compaction events are logged with:
- Session Key
- Original Token Count
- Compacted Token Count
- Detected Key Themes
## Customization
- Adjust token threshold
- Modify critical information patterns
- Configure preservation of recent exchangesX Intelligence CLI — search, monitor, analyze, and engage on X/Twitter. TypeScript + Bun. AI agent skill.
Bambu Lab 3D printer control and automation. Activate when user mentions: printer status, 3D printing, slice, analyze model, generate 3D, AMS filament, print monitor, Bambu Lab, or any 3D printing task. Full pi...
Track flight prices from Google Flights with this OpenClaw skill. Search routes, monitor prices, and get alerts when prices drop.
openclaw trading assistant| openclaw trading skill | nof1.ai & openclaw [moltbot] collaboration | We get the best practices from alpha arena trading seasons and bring it to clawdbot All top AI agents, realtime...