agentleFS
chanjalmechanjalme/claude-skills/skills/ai-brain/SKILL.md

ai-brain

Skill0 starsChanged 5 months agoMITView on GitHub

Use whenever building, designing, debugging, or reasoning about any AI/LLM system: agents, chatbots, RAG, memory, tool use, multi-agent orchestration, prompting, structured output, evals, guardrails, fine-tuning, embeddings, vector DBs, model selection, or AI cost/latency tradeoffs. Triggers on 'build an AI', 'AI agent', 'chatbot', 'RAG', 'LLM app', 'prompt this', 'fine-tune', 'embeddings', 'vector db', 'which model', 'AI architecture', 'make it smarter', 'reduce hallucination', 'evaluate the AI'. The master AI-systems-architect skill: decide the right approach, then route to the deep reference for that domain.

2 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 2 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Add context (RAG): when the model lacks the knowledge.

    line 19
  2. Very specific:

    Give it tools + a loop (agent): when the task needs actions, multi-step reasoning, or external systems.

    line 20
  3. Very specific:

    Fine-tune: only for consistent style/format or to make a small cheap model do one narrow task well.

    line 21
  4. Distinctive:

    Default bias: the simplest thing that passes the eval wins.

    line 23
  5. Distinctive:

    Evals before scaling: If you can't measure it, you can't improve it.

    line 32

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

AI Brain

Makes me an AI systems architect, not just an API caller. For any AI work: decide the right approach with the decision tree below, then read the matching reference file for depth. Be opinionated, ground claims, think about cost and evals before scaling.

First move (non-negotiable)

For anything touching Claude/Anthropic specifics (model IDs, pricing, params, caching, tool-use API, token limits), read the claude-api skill. Never state model facts from memory. For other providers, verify current docs rather than guessing.

The core decision tree

Most "make it smarter" problems are solved in this order. Climb only as far as you need, each step costs more.

  1. Better prompt first. Clear instructions, role, examples, structure. Solves most problems. → references/prompting-evals.md
  2. Add context (RAG) when the model lacks the knowledge. Retrieve, don't stuff or fine-tune for facts. → references/architecture.md
  3. Give it tools + a loop (agent) when the task needs actions, multi-step reasoning, or external systems. Only when a workflow won't do. → references/architecture.md
  4. Fine-tune only for consistent style/format or to make a small cheap model do one narrow task well. Never for knowledge. → references/training-models.md

Default bias: the simplest thing that passes the eval wins. Agents and fine-tuning are where projects go to die when a prompt would have worked.

Reference map

  • Architecture (references/architecture.md) - the 5 building blocks, workflows vs agents, RAG design, memory, context engineering, tool design, multi-agent, failure modes.
  • Prompting + evals (references/prompting-evals.md) - prompting technique, structured output, caching, building eval harnesses, guardrails, killing hallucination.
  • Training + models (references/training-models.md) - prompt vs RAG vs fine-tune decision, embeddings, vector DBs, the model landscape (closed/open/local), the cost-latency-quality triangle.
  • Your stack (references/stack-playbook.md) - Christian's practical wiring: Groq vs Claude routing, Python/macOS/launchd deployment, keys, cost control, local memory/RAG.

Iron rules

  • Evals before scaling. If you can't measure it, you can't improve it. Build a tiny golden dataset before optimizing anything. → prompting-evals.
  • Context is the bottleneck, not the model. Most failures are bad/missing/bloated context, not a weak model. Engineer the context first.
  • Cost and latency are design constraints. Pick the cheapest model that passes the eval. Route easy work to fast/cheap models, escalate only hard cases.
  • Ground every factual claim. Retrieval + citations + "say I don't know" beats a confident wrong answer.
  • One change at a time. Change a single variable, re-run the eval, keep or revert. No shotgun tuning.

Stack with

assumption-check (scope the AI task), telegram-bot-factory (deploy a Groq bot), memory-hygiene / research-to-vault (persist what the system learns), mcp-builder (expose tools via MCP), fullstack-dev-skills:rag-architect / prompt-engineer / fine-tuning-expert (deep specialist passes), and an eval/audit pass to close.

Christian's defaults

macOS, UTC+8, Python. Fast/cheap high-volume work → Groq (open models). Hard reasoning, agentic, tool use, long context → Claude (read claude-api for current IDs). Never commit API keys. Plain style: no em dashes, no AI filler.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.