fundamentals-gate

Verify code quality standards are met - naming, structure, DRY principles. Issues result in SUGGESTIONS for improvement.

25 stars

Best use case

fundamentals-gate is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Verify code quality standards are met - naming, structure, DRY principles. Issues result in SUGGESTIONS for improvement.

Teams using fundamentals-gate should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/fundamentals-gate/SKILL.md --create-dirs "https://raw.githubusercontent.com/ComeOnOliver/skillshub/main/skills/aiskillstore/marketplace/danielpodolsky/fundamentals-gate/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/fundamentals-gate/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How fundamentals-gate Compares

Feature / Agentfundamentals-gateStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Verify code quality standards are met - naming, structure, DRY principles. Issues result in SUGGESTIONS for improvement.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Gate 5: Fundamentals Review

> "Good code is not just code that works. It's code that others can work with."

## Purpose

This gate checks general code quality against engineering standards. Issues are SUGGESTIONS, not blockers — they're polish, not problems.

## Gate Status

- **PASS** — Code quality is solid
- **SUGGESTIONS** — Minor improvements recommended

---

## Gate Questions

### Question 1: Naming Clarity
> "Would a new developer understand what `[variable/function]` does from its name alone?"

**Looking for:**
- Descriptive, intention-revealing names
- No abbreviations or single letters
- Boolean prefixes (is, has, can)
- Function verbs (get, set, handle)

### Question 2: Function Focus
> "Can you describe what this function does in one sentence without using 'and'?"

**Looking for:**
- Single responsibility
- Reasonable size (under 30 lines)
- Clear input/output relationship
- No hidden side effects

### Question 3: Code Reuse
> "I see this pattern in a few places. Is it intentional duplication or should it be extracted?"

**Looking for:**
- Awareness of duplication
- Appropriate abstraction (rule of three)
- Not over-engineering for one-time use

---

## Fundamentals Checklist

### Naming
- [ ] Variables are descriptive (no `temp`, `data`, `x`)
- [ ] Booleans prefixed with `is`, `has`, `can`, `should`
- [ ] Functions start with verbs
- [ ] No unnecessary abbreviations
- [ ] Consistent naming patterns

### Functions
- [ ] Single responsibility
- [ ] Under 30 lines (generally)
- [ ] Fewer than 4 parameters
- [ ] Early returns instead of deep nesting
- [ ] No magic numbers (use named constants)

### Structure
- [ ] Related code grouped together
- [ ] Appropriate file organization
- [ ] Clear separation of concerns
- [ ] Consistent formatting

### Comments
- [ ] Explain WHY, not WHAT
- [ ] No commented-out code (delete it)
- [ ] No obvious comments (`// increment counter`)
- [ ] Complex logic documented

---

## Response Templates

### If PASS

```
✅ FUNDAMENTALS GATE: PASSED

Code quality is solid:
- Naming is clear and consistent
- Functions are focused
- Good structure overall

All gates passed! Let's move to code review...
```

### If SUGGESTIONS

```
💡 FUNDAMENTALS GATE: SUGGESTIONS

A few polish items for consideration:

**Suggestion 1: [Naming]**
`const d = new Date()` → `const createdAt = new Date()`
Why: Descriptive names help future readers

**Suggestion 2: [Function size]**
`processOrder()` is 80 lines. Consider splitting into:
- `validateOrder()`
- `calculateTotal()`
- `saveOrder()`

**Suggestion 3: [Magic number]**
`if (status === 2)` → `if (status === STATUS.ACTIVE)`
Why: Named constants are self-documenting

These are suggestions, not blockers. The code works — this is about polish.
Proceed to code review? Or address these first?
```

---

## Common Issues to Check

### 1. Unclear Naming
```
❌ const d = new Date();
   const temp = getUser();
   const flag = true;

✅ const createdAt = new Date();
   const currentUser = getUser();
   const isAuthenticated = true;
```

### 2. Magic Numbers
```
❌ if (status === 2) { ... }
   setTimeout(fn, 86400000);

✅ const STATUS = { ACTIVE: 2, INACTIVE: 1 };
   if (status === STATUS.ACTIVE) { ... }

   const ONE_DAY_MS = 24 * 60 * 60 * 1000;
   setTimeout(fn, ONE_DAY_MS);
```

### 3. Deep Nesting
```
❌ function check(user) {
     if (user) {
       if (user.active) {
         if (user.role === 'admin') {
           return true;
         }
       }
     }
     return false;
   }

✅ function check(user) {
     if (!user) return false;
     if (!user.active) return false;
     if (user.role !== 'admin') return false;
     return true;
   }
```

### 4. God Functions
```
❌ function processOrder(order) {
     // 100+ lines of validation, calculation, saving, emailing...
   }

✅ function processOrder(order) {
     validateOrder(order);
     const total = calculateTotal(order);
     await saveOrder(order, total);
     await sendConfirmation(order);
   }
```

### 5. Meaningless Comments
```
❌ // Increment counter
   counter++;

   // Get user
   const user = getUser();

✅ // Rate limit: max 100 requests per minute per user
   if (requestCount >= 100) {
     throw new RateLimitError();
   }
```

---

## Socratic Fundamentals Questions

Instead of pointing out fixes, ask:

1. "What does `d` stand for? Would a new developer know?"
2. "What does the number 2 mean in this context?"
3. "Can you describe this function without saying 'and'?"
4. "I see this pattern three times — is that intentional?"
5. "Would you understand this comment in 6 months?"

---

## Standards Reference

See detailed patterns in:
- `/standards/global/naming-conventions.md`
- `/standards/global/error-handling.md`
- `/standards/frontend/component-architecture.md`

---

## Naming Quick Reference

| Type | Pattern | Example |
|------|---------|---------|
| Variable | camelCase, descriptive | `userEmail`, `isLoading` |
| Boolean | is/has/can/should prefix | `isActive`, `hasPermission` |
| Function | verb + noun | `getUser()`, `handleSubmit()` |
| Constant | UPPER_SNAKE_CASE | `MAX_RETRIES`, `API_URL` |
| Class | PascalCase | `UserService`, `ApiClient` |

---

## When to Skip Suggestions

Not every suggestion needs addressing:

- **Prototype code** — Polish can wait
- **Time pressure** — Ship working code, polish later
- **Minimal impact** — If it's just style preference
- **Existing patterns** — Match codebase conventions even if imperfect

Fundamentals are about growth, not perfection. Note suggestions for learning, but don't block shipping.

Related Skills

building-api-gateway

25
from ComeOnOliver/skillshub

Create API gateways with routing, load balancing, rate limiting, and authentication. Use when routing and managing multiple API services. Trigger with phrases like "build API gateway", "create API router", or "setup API gateway".

api-gateway-config

25
from ComeOnOliver/skillshub

Api Gateway Config - Auto-activating skill for AWS Skills. Triggers on: api gateway config, api gateway config Part of the AWS Skills skill category.

marketing-fundamentals

25
from ComeOnOliver/skillshub

Core marketing concepts, psychology, and frameworks for effective marketing. Use for foundational knowledge on funnels, customer journey, positioning, value propositions, and marketing psychology.

routeros-fundamentals

25
from ComeOnOliver/skillshub

RouterOS v7 domain knowledge for AI agents. Use when: working with MikroTik RouterOS, writing RouterOS CLI/script commands, calling RouterOS REST API, debugging why a Linux command fails on RouterOS, or when the user mentions MikroTik, RouterOS, CHR, or /ip /system /interface paths. Scope: RouterOS 7.x (long-term and newer) only — v6 is NOT covered and accuracy for v6 problems will be low.

geo-fundamentals

25
from ComeOnOliver/skillshub

Generative Engine Optimization for AI search engines (ChatGPT, Claude, Perplexity).

clarity-gate

25
from ComeOnOliver/skillshub

Pre-ingestion verification for epistemic quality in RAG systems with 9-point verification and Two-Round HITL workflow

azure-aigateway

25
from ComeOnOliver/skillshub

Configure Azure API Management (APIM) as AI Gateway to secure, observe, control AI models, MCP servers, agents. Helps with rate limiting, semantic caching, content safety, load balancing. USE FOR: AI Gateway, APIM, setup gateway, configure gateway, add gateway, model gateway, MCP server, rate limit, token limit, semantic cache, content safety, load balance, OpenAPI import, convert API to MCP. DO NOT USE FOR: deploy models (use microsoft-foundry), Azure Functions (use azure-functions), databases (use azure-postgres).

gate-mcp-installer

25
from ComeOnOliver/skillshub

One-click installer and configurator for Gate MCP (mcporter) in OpenClaw. Use when the user wants to (1) Install mcporter CLI tool, (2) Configure Gate MCP server connection, (3) Verify Gate MCP setup, or (4) Troubleshoot Gate MCP connectivity issues.

gate-exchange-spot

25
from ComeOnOliver/skillshub

Gate spot trading and account operations skill. Use this skill whenever the user asks to buy/sell crypto, check account value, cancel/amend spot orders, place conditional buy/sell plans, verify fills, or perform coin-to-coin swaps in Gate spot trading. Trigger phrases include 'buy coin', 'sell coin', 'monitor market', 'cancel order', 'amend order', 'break-even price', 'rebalance', 'spot trading', 'buy/sell', or any request that combines spot order execution with account checks.

gate-exchange-marketanalysis

25
from ComeOnOliver/skillshub

The market analysis function of Gate Exchange — liquidity, momentum, liquidation, funding arbitrage, basis, manipulation risk, order book explainer, slippage simulation. Use when the user asks about liquidity, depth, slippage, buy/sell pressure, liquidation, funding rate arbitrage, basis/premium, manipulation risk, order book explanation, or slippage simulation (e.g. market buy $X slippage). Trigger phrases: liquidity, depth, slippage, momentum, buy/sell pressure, liquidation, squeeze, funding rate, arbitrage, basis, premium, manipulation, order book, spread, slippage simulation.

gate-exchange-futures

25
from ComeOnOliver/skillshub

The USDT perpetual futures trading function of Gate Exchange: open position, close position, cancel order, amend order. Trigger phrases: open position, close position, cancel order, amend order, reverse, close all.

gate-dex-market

25
from ComeOnOliver/skillshub

Gate Wallet market data and token info queries. K-line, transaction stats, liquidity, token details, rankings, security audit, new token discovery. Use when users ask about market data, prices, or token info. All queries require no authentication. Not for executing trades.