serverless
Skill15 starsChanged 42 days agoMITView on GitHub
Expert Serverless architecture assistance covering Function-as-a-Service (FaaS), event triggers, cold start mitigation, stateless execution, and cloud BaaS integration. Use when building AWS Lambda, Google Cloud Functions, or Cloudflare Workers systems with event-driven scale.
- Reads credentials
2 other projects use a version of this.
Adopted by
Most recently taken up by
- Mindrally/skillstheir own version, first seen Oct 8, 2026
- ffsshhttiikk/opencode-agents-skillstheir own version, first seen Feb 28, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 2
- Mindrally/skills★ 275same name
- ffsshhttiikk/opencode-agents-skills★ 2same name
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.
In this repository350 other files it gives its agents.
- airflowSkill
- catboostSkill
- claudeSkill
- comfyuiSkill
- cursor-aiSkill
- dalleSkill
- daskSkill
- dbtSkill
- deepseekSkill
- fastaiSkill
- geminiSkill
- github-copilotSkill
- huggingfaceSkill
- jaxSkill
- jupyterSkill
- kerasSkill
- langchainSkill
- lightgbmSkill
- llamaindexSkill
- llamaSkill
- matplotlibSkill
- midjourneySkill
- mistralSkill
- mlflowSkill
- nltkSkill
- numpySkill
- ollamaSkill
- openai-gptSkill
- opencvSkill
- pandasSkill
- perplexitySkill
- plotlySkill
- polarsSkill
- pytorchSkill
- raySkill
- scikit-learnSkill
- seabornSkill
- spacySkill
- sparkSkill
- stable-diffusionSkill
- tensorflowSkill
- vaexSkill
- weights-biasesSkill
- whisperSkill
- xgboostSkill
- api-gatewaySkill
- clean-architectureSkill
- cqrsSkill
- domain-driven-designSkill
- event-drivenSkill
- event-sourcingSkill
- graphqlSkill
- grpcSkill
- hexagonalSkill
- microservicesSkill
- modular-monolithSkill
- monolithSkill
- rest-apiSkill
- sagaSkill
- service-meshSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 3 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 136
Keep Deployment Packages Compact: Minify JavaScript with esbuild.
- Distinctive: line 143
Run long-running monolithic services in Lambda: Functions exceeding 15-minute limits or requiring continuous memory belong in …
- Distinctive: line 144
Create unpooled relational database connections: Use RDS Proxy or HTTP-based database drivers (Neon, PlanetScale) to prevent connection …
≈ “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.
Files
Serverless
Serverless is a cloud-native development model for building and running applications without managing servers. The cloud provider handles the routine work of provisioning, maintaining, and scaling the server infrastructure.
When to Use
- Event-Driven Workloads: Processing file uploads (S3), stream events (Kafka/Kinesis), and asynchronous queue workers.
- Variable & Spiky Traffic: Applications with unpredictable request volumes scaling automatically from 0 to thousands of instances.
- Low-Maintenance Web APIs: Deploying micro-APIs or webhook handlers without managing servers, operating systems, or patching.
- Scheduled Background Tasks: Running cron jobs, batch data transformations, and reporting tasks via EventBridge / CloudWatch.
Quick Start
// AWS Lambda Handler (Node.js)
export const handler = async (event) => {
console.log("Event received:", JSON.stringify(event));
const name = event.queryStringParameters?.name || "World";
return {
statusCode: 200,
body: JSON.stringify({ message: `Hello, ${name}!` }),
};
};# serverless.yml (Serverless Framework)
service: my-api
provider:
name: aws
runtime: nodejs20.x
functions:
hello:
handler: handler.hello
events:
- httpApi:
path: /hello
method: getCore Concepts
Ephemeral Stateless Execution
Instances spin up on demand and shut down after idle periods; in-memory state is destroyed when containers terminate:
// AWS Lambda / Cloudflare Worker Handler
export const handler = async (
event: APIGatewayProxyEvent,
): Promise<APIGatewayProxyResult> => {
// Global variables persist across warm starts, but local handler state resets
const result = await processItem(event.body);
return {
statusCode: 200,
headers: { "Content-Type": "application/json" },
body: JSON.stringify(result),
};
};Cold Start Lifecycle & Mitigation
Understanding initialization phases:
[ Download Runtime ] ──→ [ Init Execution Context (Cold Start) ] ──→ [ Execute Handler (Warm) ]// Optimize Cold Starts: Initialize heavy clients outside the handler function
import { DynamoDBClient } from "@aws-sdk/client-dynamodb";
const ddbClient = new DynamoDBClient({ region: "us-east-1" }); // Reused on warm startsCloud BaaS Integration & Event Mappings
Connects functions directly to cloud managed services without polling:
# serverless.yml event mapping
functions:
processInvoice:
handler: src/invoice.handler
events:
- s3:
bucket: enterprise-invoices
event: s3:ObjectCreated:*
rules:
- suffix: .pdfCommon Patterns
Connection Pool Management Outside Handler
Problem: Serverless functions initialize new database connections on every invocation, exhausting connection limits.
Solution: Initialize database pools outside the lambda handler to reuse connections across warm invocations.
import { Pool } from "pg";
// Initialized in global scope during cold start, reused across invocations
const pool = new Pool({
connectionString: process.env.DATABASE_URL,
max: 2, // Keep pool small for serverless instances
idleTimeoutMillis: 30000,
});
export const handler = async (event: any) => {
const client = await pool.connect();
try {
const { rows } = await client.query("SELECT * FROM items WHERE id = $1", [
event.pathParameters.id,
]);
return { statusCode: 200, body: JSON.stringify(rows[0]) };
} finally {
client.release();
}
};Best Practices
Do:
- Keep Deployment Packages Compact: Minify JavaScript with esbuild; keep lambda zip files small to reduce cold start initialization times.
- Reuse Persistent Connections in Global Scope: Instantiate database connection pools, AWS SDK clients, and HTTP agents outside the handler.
- Enforce Fine-Grained IAM Permissions: Grant functions least-privilege access to only the specific database tables or S3 buckets needed.
- Implement Structured Logging with Correlation IDs: Inject invocation request IDs and tracing headers into every log output.
Don't:
- Run long-running monolithic services in Lambda: Functions exceeding 15-minute limits or requiring continuous memory belong in ECS/Kubernetes.
- Create unpooled relational database connections: Use RDS Proxy or HTTP-based database drivers (Neon, PlanetScale) to prevent connection exhaustion.
- Store files on local disk: The
/tmpdirectory is ephemeral and shared only during warm invocations; store assets in S3.
Troubleshooting
| Error | Cause | Solution |
Timeout | Function took too long. | Increase timeout setting; optimize code; move to async pattern. |
OOM (Out of Memory) | Processing large files. | Increase RAM (allocates more CPU too); stream data instead of loading all in memory. |
References
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
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.

