بنقرة واحدة
research-cache
Manage and search the research cache for previously analyzed repositories
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
القائمة
Manage and search the research cache for previously analyzed repositories
التثبيت باستخدام Codex أو Claude انسخ هذا Prompt والصقه في Codex أو Claude أو مساعد آخر ليراجع صفحة Skill ويثبّتها لك.
استنادا إلى تصنيف SOC المهني
Autonomous product factory — /make-a-goal in godmode. Point it at a north-star outcome and it runs the whole delivery machine unattended: brainstorm the feature landscape (Discover), put every idea through a Feasibility Court, cluster into a Roadmap of epics, then per epic Plan → adversarial review → Execute (model-paired build) → VERIFY (drive the real UI/TUI/API, not mocks) → ship a stacked PR, looping until the backlog is dry or a budget/time bound fires. One human gate (roadmap blessing), hard stop rules, always-on tabbed RAG dashboard, crash-proof resume from state files. Use when the user says 'godmode', 'run the factory', 'ship X to nirvana', 'execute this whole backlog autonomously', 'goals within goals', or wants a multi-epic programme driven end-to-end with real end-to-end verification. NOT for single features, one-off verification, or scoped builds — use /make-a-goal, browser/tmux verification skills, or a plain plan for those.
Sync user-level agent config changes back to the ainb-toolkit repo (works for Claude, Codex, Copilot)
Produce a self-contained, richly styled HTML explainer for any topic the user asks about. Picks the right template from a bundled set of 22 visual patterns (feature explainer, concept explainer, module map, PR review, ADR, options paper / trade-off analysis, system diagram, flow- chart, status report, slide deck, prototype, editor, etc.), fills it with real content, augments with inline diagrams via sister skills (/fireworks-tech-graph for architecture / flow / sequence diagrams, /graphify for knowledge graphs), applies a Claude-brand polish layer, and publishes it: by default onto the configured here.now custom domain (path mount + searchable categorised index + password lock per the config's protect rule, driven by ~/.herenow/explainers.json), or a plain here.now URL, or a GitHub gist (--gist / --gist --public). Local-only output is available with --local. Use when Stevie says "/explain-to-me", "explain-to-me X", "make me an explainer for X", "give me an HTML explainer", "render this as a webpage", "ADR for
Self-improvement through conversation analysis. Extracts learnings from corrections and success patterns, permanently encoding them into agent definitions. Philosophy - Correct once, never again.
Claude Code observability skill: analyze session traces stored in Langfuse, extract learnings from corrections, identify success patterns, and propose agent/skill improvements based on historical data. Powers self-improvement through trace analysis of Claude Code sessions.
Create well-formatted git commits for changes made during the session
| name | research-cache |
| description | Manage and search the research cache for previously analyzed repositories |
| user-invocable | true |
Manage the global repository analysis cache used by the /research command.
The research cache stores analysis results from external repositories discovered during web research. This prevents re-analyzing the same repositories and speeds up research workflows.
Cache Location: {{HOME_TOOL_DIR}}/research-cache/
Cache Structure:
{{HOME_TOOL_DIR}}/research-cache/
<owner>-<repo>-<commit-short>/
analysis.md # Focused analysis document
metadata.json # Cache metadata (timestamps, query hash)
When the /research command discovers external repositories:
code-archaeologist agentbash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh stats
Output:
Cache Statistics
Directory: {{HOME_TOOL_DIR}}/research-cache
Entries:
Total: 15
Valid: 12
Expired: 3
Invalid: 0
Storage:
Total Size: 45678KB
Configuration:
TTL: 604800s (7 days)
Max Age: 2592000s (30 days)
# List valid entries only
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh list
# Include expired entries
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh list --expired
Output:
Cache Directory: {{HOME_TOOL_DIR}}/research-cache
CACHE KEY STATUS CREATED QUERY HASH
---------- ------ ------- ----------
facebook-react-a1b2c3d VALID 2026-01-01T12:00:00 f3a8c91e
vercel-next.js-e4f5g6h VALID 2026-01-02T14:30:00 7b2d4a9c
golang-go-i7j8k9l EXPIRED 2025-12-20T09:15:00 3c1e5f2a
# Purge only expired entries (older than max age)
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh purge
# Force purge all entries
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh purge --force
Output:
Purging: golang-go-i7j8k9l (age: 2678400s)
Purging invalid: broken-repo-abc123
Purge Summary:
Purged: 2
Kept: 13
# Get path to cached analysis
CACHE_KEY="facebook-react-a1b2c3d"
ANALYSIS_PATH=$(bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh get "$CACHE_KEY")
if [ $? -eq 0 ]; then
echo "Found cached analysis: $ANALYSIS_PATH"
cat "$ANALYSIS_PATH"
else
echo "No cached analysis found"
fi
# Check if cache entry exists
CACHE_KEY="facebook-react-a1b2c3d"
if bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh exists "$CACHE_KEY"; then
echo "Cache hit: $CACHE_KEY"
else
echo "Cache miss: $CACHE_KEY"
fi
# Check with query hash matching
QUERY_HASH="f3a8c91e"
if bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh exists "$CACHE_KEY" "$QUERY_HASH"; then
echo "Cache hit with matching query"
else
echo "Cache miss or query mismatch"
fi
# Generate cache key from repo URL and commit
REPO_URL="https://github.com/facebook/react"
COMMIT_HASH="a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0"
CACHE_KEY=$(bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh key "$REPO_URL" "$COMMIT_HASH")
echo "Cache key: $CACHE_KEY"
# Output: facebook-react-a1b2c3d
Each cache entry includes metadata.json:
{
"cache_key": "facebook-react-a1b2c3d",
"repo_url": "https://github.com/facebook/react",
"commit_hash": "a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6q7r8s9t0",
"query": "How to implement React hooks?",
"query_hash": "f3a8c91e",
"context": "Discovered during web research for: React hooks implementation",
"created_at": 1735747200,
"created_date": "2026-01-01T12:00:00Z",
"ttl_seconds": 604800,
"expires_at": 1736352000,
"expires_date": "2026-01-08T12:00:00Z"
}
purge monthly to remove old entries--force when resetting research stateCache entries are automatically invalidated when:
# View what's cached
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh list
# Check stats before purging
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh stats
# Purge expired only
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh purge
# Force clean slate
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh purge --force
# Override cache directory
export CLAUDE_RESEARCH_CACHE="/custom/cache/path"
# Default: {{HOME_TOOL_DIR}}/research-cache
Edit {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh:
# Cache TTL in seconds (7 days)
CACHE_TTL=$((7 * 24 * 60 * 60))
# Max age before purge (30 days)
MAX_CACHE_AGE=$((30 * 24 * 60 * 60))
Symptom: Research always re-analyzes repositories
Check:
# Verify cache exists
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh stats
# Check if entry is valid
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh exists <cache-key>
Fix:
Symptom: Cache directory consuming excessive disk space
Check:
# View cache size
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh stats
Fix:
# Purge expired entries
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh purge
# Or force purge all
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh purge --force
Symptom: Cache entry exists but cannot be read
Fix:
# Manually remove corrupted entry
rm -rf {{HOME_TOOL_DIR}}/research-cache/<cache-key>
# Reinitialize cache
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh init
The research cache is automatically used by the /research command:
No manual intervention required for normal research workflows.
Without Cache:
With Cache:
Typical Savings: 99%+ time reduction for repeated research queries
# Get all valid cache keys
for cache_dir in {{HOME_TOOL_DIR}}/research-cache/*; do
if [ -f "$cache_dir/metadata.json" ]; then
CACHE_KEY=$(basename "$cache_dir")
AGE=$(jq -r '.created_at' "$cache_dir/metadata.json")
echo "$CACHE_KEY: created $(date -r $AGE)"
fi
done
# Export to JSON
bash {{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh stats > cache-stats.txt
# Parse for monitoring
grep "Total:" cache-stats.txt
# Find all React-related analyses
grep -r "React" {{HOME_TOOL_DIR}}/research-cache/*/analysis.md
# Find analyses newer than N days
find {{HOME_TOOL_DIR}}/research-cache -name "metadata.json" -mtime -7 -exec jq -r '.repo_url' {} \;
/research - Main research command that uses cachecode-archaeologist - Agent that generates cached analyses{{HOME_TOOL_DIR}}/utils/repo-analysis-cache.sh - Cache utility script