skills/abtesting/abtesting-analysis/SKILL.md
--- name: abtesting-analysis cluster: abtesting description: "Results: uplift calculation, significance interpretation, long-run effects, Simpson\'s paradox, novelty effect" tags: ["analysis","uplift","novelty-effect","decision"] dependencies: [] composes: [] similar_to: [] called_by: [] authorization_required: false scope: general model_hint: claude-sonnet embedding_hint: "ab test results analysis uplift novelty effect segment decision simpson" --- # abtesting-analysis ## Purpose This skill e
npx skillsauth add alphaonedev/openclaw-graph skills/abtesting/abtesting-analysisInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill enables detailed analysis of A/B test results, including uplift calculations, statistical significance interpretation, evaluation of long-run effects, detection of Simpson's paradox, and assessment of novelty effects to inform decisions.
Use this skill when processing A/B test data from experiments, such as website variants or app features, to quantify impacts like conversion rate differences. Apply it for data-driven decisions in marketing, product development, or UX testing, especially when segmenting users or checking for hidden biases.
Invoke this skill via CLI for quick analysis or integrate it into scripts for automated workflows. Always provide input data in JSON format, specifying metrics and segments. For example, pipe data from a file and output results to console or a file. Handle authentication by setting the environment variable $OPENCLAW_API_KEY before running commands.
Example 1: Analyze a basic A/B test for click-through rate.
openclaw abtesting analyze --input results.json --metric ctr --groups control variant
This command processes the JSON file, calculates uplift, and checks significance.
Example 2: Detect Simpson's paradox in segmented data.
import os
os.environ['OPENCLAW_API_KEY'] = 'your_api_key_here'
response = requests.post('https://api.openclaw.ai/abtesting/analyze', json={'file': 'segments.json', 'check': 'simpson'})
print(response.json()['paradox_detected']) # Outputs True or False
This script sends segmented data to the API and retrieves paradox insights.
Use the CLI command openclaw abtesting analyze with these flags:
--input <file>: Path to JSON input file (e.g., {"control": {"clicks": 1000, "conversions": 50}, "variant": {"clicks": 1200, "conversions": 72}})--metric <string>: Metric to analyze, like "conversions" or "revenue".--significance: Performs statistical tests; outputs p-value and CI.--uplift: Calculates relative uplift; e.g., outputs {"uplift": 0.15} for 15% lift.--check-novelty: Analyzes time-series for novelty; requires --time-window 7d.API endpoint: POST to https://api.openclaw.ai/abtesting/analyze with JSON payload, e.g.:
{
"data": {"control": [...], "variant": [...]},
"metric": "revenue",
"options": {"significance": true, "simpson": true}
}
Response format: JSON object with keys like "uplift_value", "p_value", and "effects".
Integrate by importing the OpenClaw SDK in Python or using curl for API calls. Set $OPENCLAW_API_KEY as an environment variable for authentication. For config files, use YAML for advanced options, e.g.:
analysis:
metric: conversions
segments: [age_group, region]
Ensure data is formatted as arrays of objects (e.g., [ {"user_id": 1, "group": "control", "value": 10} ]). Avoid rate limits by batching requests; use webhooks for asynchronous processing if analyzing large datasets.
Check for common errors like invalid input formats (e.g., non-JSON files) by wrapping commands in try-catch blocks. If authentication fails, verify $OPENCLAW_API_KEY and handle with HTTP 401 errors. For API calls, catch exceptions for network issues or invalid responses:
try:
response = requests.post('https://api.openclaw.ai/abtesting/analyze', headers={'Authorization': f'Bearer {os.environ.get("OPENCLAW_API_KEY")}'})
response.raise_for_status()
except requests.exceptions.HTTPError as e:
print(f"Error: {e} - Check API key and input data")
Log errors with details like "Insufficient data points for significance" and retry with corrected inputs.
tools
Root web development: project structure, tooling selection, deployment decisions
development
WebAssembly: Rust/Go/C to WASM, wasm-bindgen, Emscripten, WASM Component Model
development
Vue 3: Composition API script setup, Pinia, Vue Router 4, SFCs, Vite, Nuxt 3
tools
Tailwind CSS 4: utility classes, config, JIT, arbitrary values, darkMode, plugins, shadcn/ui