code-documentation
Skill1.1k starsChanged 8 months agoMITView on GitHub
Writing effective code documentation - API docs, README files, inline comments, and technical guides. Use for documenting codebases, APIs, or writing developer guides.
- Reads credentials
- Installs packages
Files
Code Documentation
README Structure
Standard README Template
# Project Name
Brief description of what this project does.
## Quick Start
\`\`\`bash
npm install
npm run dev
\`\`\`
## Installation
Detailed installation instructions...
## Usage
\`\`\`typescript
import { something } from 'project';
// Example usage
const result = something.doThing();
\`\`\`
## API Reference
### `functionName(param: Type): ReturnType`
Description of what the function does.
**Parameters:**
- `param` - Description of parameter
**Returns:** Description of return value
**Example:**
\`\`\`typescript
const result = functionName('value');
\`\`\`
## Configuration
| Option | Type | Default | Description |
|--------|------|---------|-------------|
| `option1` | `string` | `'default'` | What it does |
## Contributing
How to contribute...
## License
MITAPI Documentation
JSDoc/TSDoc Style
/**
* Creates a new user account.
*
* @param userData - The user data for account creation
* @param options - Optional configuration
* @returns The created user object
* @throws {ValidationError} If email is invalid
* @example
* ```ts
* const user = await createUser({
* email: 'user@example.com',
* name: 'John'
* });
* ```
*/
async function createUser(
userData: UserInput,
options?: CreateOptions
): Promise<User> {
// Implementation
}
/**
* Configuration options for the API client.
*/
interface ClientConfig {
/** The API base URL */
baseUrl: string;
/** Request timeout in milliseconds @default 5000 */
timeout?: number;
/** Custom headers to include in requests */
headers?: Record<string, string>;
}OpenAPI/Swagger
openapi: 3.0.0
info:
title: My API
version: 1.0.0
paths:
/users:
post:
summary: Create a user
description: Creates a new user account
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UserInput'
responses:
'201':
description: User created successfully
content:
application/json:
schema:
$ref: '#/components/schemas/User'
'400':
description: Invalid input
components:
schemas:
UserInput:
type: object
required:
- email
- name
properties:
email:
type: string
format: email
name:
type: string
User:
type: object
properties:
id:
type: string
email:
type: string
name:
type: string
createdAt:
type: string
format: date-timeInline Comments
When to Comment
// GOOD: Explain WHY, not WHAT
// Use binary search because the list is always sorted and
// can contain millions of items - O(log n) vs O(n)
const index = binarySearch(items, target);
// GOOD: Explain complex business logic
// Users get 20% discount if they've been members for 2+ years
// AND have made 10+ purchases (per marketing team decision Q4 2024)
if (user.memberYears >= 2 && user.purchaseCount >= 10) {
applyDiscount(0.2);
}
// GOOD: Document workarounds
// HACK: Safari doesn't support this API, fallback to polling
// TODO: Remove when Safari adds support (tracking: webkit.org/b/12345)
if (!window.IntersectionObserver) {
startPolling();
}When NOT to Comment
// BAD: Stating the obvious
// Increment counter by 1
counter++;
// BAD: Explaining clear code
// Check if user is admin
if (user.role === 'admin') { ... }
// BAD: Outdated comments (worse than no comment)
// Returns the user's full name <-- Actually returns email now!
function getUserIdentifier(user) {
return user.email;
}Architecture Documentation
ADR (Architecture Decision Record)
# ADR-001: Use PostgreSQL for Primary Database
## Status
Accepted
## Context
We need a database for storing user data and transactions.
Options considered: PostgreSQL, MySQL, MongoDB, DynamoDB.
## Decision
Use PostgreSQL with Supabase hosting.
## Rationale
- Strong ACID compliance needed for financial data
- Team has PostgreSQL experience
- Supabase provides auth and realtime features
- pgvector extension for future AI features
## Consequences
- Need to manage schema migrations
- May need read replicas for scale
- Team needs to learn Supabase-specific featuresComponent Documentation
## Authentication Module
### Overview
Handles user authentication using JWT tokens with refresh rotation.
### Flow
1. User submits credentials to `/auth/login`
2. Server validates and returns access + refresh tokens
3. Access token used for API requests (15min expiry)
4. Refresh token used to get new access token (7d expiry)
### Dependencies
- `jsonwebtoken` - Token generation/validation
- `bcrypt` - Password hashing
- `redis` - Refresh token storage
### Configuration
- `JWT_SECRET` - Secret for signing tokens
- `ACCESS_TOKEN_EXPIRY` - Access token lifetime
- `REFRESH_TOKEN_EXPIRY` - Refresh token lifetimeDocumentation Principles
- Write for your audience - New devs vs API consumers
- Keep it close to code - Docs in same repo, near relevant code
- Update with code - Stale docs are worse than none
- Examples over explanations - Show, don't just tell
- Progressive disclosure - Quick start first, details later
Trending
More talk lately.thin dataabout the whole repository
Who's talking about MoizIbnYousaf/Ai-Agent-Skills
- ProSkillsMD/proskills“[Candidate] moizibnyousaf/ai-agent-skills/skills/backend-development - backend-development”GitHub · Oct 9, 2026
- ProSkillsMD/proskills“[Candidate] moizibnyousaf/ai-agent-skills/skills/audit-library-health - audit-library-health”GitHub · Oct 9, 2026
- ProSkillsMD/proskills“[Candidate] moizibnyousaf/ai-agent-skills/skills/ask-questions-if-underspecified - …”GitHub · Oct 9, 2026
- sudosubin/agents.nix“agent-skills.github.moizibnyousaf.ai-agent-skills: init at 4.3.2”GitHub · Sep 30, 2026
The biggest 4 of 4 mentions linking to the repository that our crawl found. Each line is their own headline.
Other versions15 projects use a version of this.
Word for word · 2
- skillcreatorai/Ai-Agent-Skills★ 1.1k100% same
- MoizIbnYousaf/ai-agent-skills★ 1.1k100% same
Edited · 2
- myths-labs/muse★ 3799% same
- pepebot-space/skills★ 299% same
Wrote their own version · 11
- bytedance/deer-flow★ 84ksame name
- mryeminaung/documentation-assistant★ 9same name
- CreamyLong/quill★ 2same name
- gilsmt/skills★ 2same name
- gspencergoog/skills★ 2same name
- Suuunboy/code-documentation-skill★ 2same name
- KMaruthi2002/universal-llm-skills★ 1same name
- hellobrophy/claude-skills★ 0same name
- LWaetzig/claude-code-skills★ 0same name
- snuffish/dotfiles★ 0same name
1 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
Used alongsideProjects with it also use data-analysis.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
shanggqmSkilldata-analysis
数据分析技能,提供结构化的数据查询、统计分析和报告生成工作流。当用户需要查询数据库、进行数据统计分析、生成分析报告时使用。按规范输出原始数据、计算结果、Markdown报告和HTML可视化报告。
Also in 3 projects that use this
In this repository17 other files it gives its agents.
- ask-questions-if-underspecifiedSkill
- audit-library-healthSkill
- backend-developmentSkill
- best-practicesSkill
- browse-and-evaluateSkill
- build-workspace-docsSkill
- changelog-generatorSkill
- content-research-writerSkill
- curate-a-team-librarySkill
- database-designSkill
- install-from-remote-librarySkill
- llm-application-devSkill
- migrate-skills-between-librariesSkill
- review-a-skillSkill
- share-a-librarySkill
- update-installed-skillsSkill
- verification-agentSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
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.

