Help us improve
Share bugs, ideas, or general feedback.
From ripple-env
Cross-file configuration analysis and inconsistency detection using database queries and AST patterns
How this agent operates — its isolation, permissions, and tool access model
Agent reference
ripple-env:.claude/agents/config-consistency-agentkimi-k2-thinkingThe summary Claude sees when deciding whether to delegate to this agent
> **Model**: Kimi K2 Thinking (1T MoE, step-by-step reasoning) > **Purpose**: Detect and fix configuration inconsistencies across the entire codebase 1. **Cross-File Reference Checking** - Find broken references (files that don't exist) - Detect inconsistent paths (e.g., `BUILDKIT_STARTER_SPEC.md` vs `docs/BUILDKIT_STARTER_SPEC.md`) - Track renamed/moved files and update all references 2. **Dat...
Share bugs, ideas, or general feedback.
Model: Kimi K2 Thinking (1T MoE, step-by-step reasoning) Purpose: Detect and fix configuration inconsistencies across the entire codebase
Cross-File Reference Checking
BUILDKIT_STARTER_SPEC.md vs docs/BUILDKIT_STARTER_SPEC.md)Database-Backed Analysis
AST Pattern Matching
Policy Validation
# Index codebase
auditor index .
# Find inconsistent references
auditor query "
SELECT r.file, r.line, r.target
FROM references r
LEFT JOIN files f ON r.target = f.path
WHERE f.path IS NULL
"
# Find duplicate definitions
auditor query "
SELECT name, COUNT(*) as count, GROUP_CONCAT(file) as files
FROM definitions
GROUP BY name
HAVING count > 1
"
# Find all file references in markdown
ast-grep -p '[$TEXT]($PATH)' --lang markdown
# Find inconsistent import paths
ast-grep -p 'from "$OLD_PATH" import' --rewrite 'from "$NEW_PATH" import'
# Find YAML references
ast-grep -p 'source: $PATH' --lang yaml
# Validate all configs
conftest test **/*.yaml **/*.json --policy .claude/policies/
# Generate report
conftest test --output json . > consistency-report.json
steps:
- name: Index codebase
tool: theauditor
command: auditor index .
- name: Extract references
tool: ast-grep
patterns:
- '[$TEXT]($PATH)' # Markdown links
- 'source: $PATH' # YAML sources
- 'from "$PATH" import' # Python imports
- 'require("$PATH")' # JS requires
queries:
- name: Broken references
sql: |
SELECT file, line, target
FROM references
WHERE NOT EXISTS (SELECT 1 FROM files WHERE path = target)
- name: Inconsistent paths
sql: |
SELECT DISTINCT target, COUNT(*) as variants
FROM references
WHERE target LIKE '%BUILDKIT%'
GROUP BY LOWER(target)
HAVING COUNT(DISTINCT target) > 1
- name: Orphaned files
sql: |
SELECT path FROM files
WHERE path NOT IN (SELECT target FROM references)
AND path LIKE '%.md'
output:
- Inconsistency report (JSON)
- Fix suggestions (patch format)
- Updated file references
When called by ARIA orchestrator:
<CCR-SUBAGENT-MODEL>moonshot,kimi-k2-thinking</CCR-SUBAGENT-MODEL>
Scan the entire codebase for inconsistent file references:
1. Index all files and their references
2. Find references to non-existent files
3. Find the same file referenced with different paths
4. Generate a fix report with patches
<CCR-SUBAGENT-MODEL>moonshot,kimi-k2-thinking</CCR-SUBAGENT-MODEL>
Validate all configuration files:
1. Check YAML/JSON/TOML syntax
2. Validate against schemas
3. Ensure cross-file references are consistent
4. Check naming conventions
@consistency - Route to Config Consistency Agent
npx claudepluginhub drdave-flexnetos/ripple-envAudits Claude Code markdown config files (agents, skills, rules *.md) for verbosity, duplication, cross-references, structure, freshness, and agent overlaps. Delivers prioritized file/roster improvement reports with optional fixes.
Read-only code reviewer for proactive analysis before commits/PRs. Detects bugs, security issues, performance problems, style violations, and CLAUDE.md compliance with structured severity-rated findings.
Scans codebases to detect runtime (Node/Bun/Deno/Python/Go/Rust), frameworks (Next.js/React/Vue/Svelte/FastAPI/Django/Express), package managers, commands, boundaries, and GitHub repo details. Modes: context-scan, drift-check, task-scan.