ln-770-crosscutting-setup
Sets up logging, error handling, CORS, health checks, and API docs. Use when adding cross-cutting concerns to backend projects.
What this skill does
> **Paths:** File paths (`references/`, `../ln-*`) are relative to this skill directory.
# ln-770-crosscutting-setup
**Type:** L2 Domain Coordinator
**Category:** 7XX Project Bootstrap
**Parent:** ln-700-project-bootstrap
Coordinates cross-cutting concerns configuration for .NET and Python projects.
---
## Overview
| Aspect | Details |
|--------|---------|
| **Input** | Project root directory |
| **Output** | Configured logging, error handling, CORS, health checks, API docs |
| **Workers** | ln-771 to ln-775 |
| **Stacks** | .NET (ASP.NET Core), Python (FastAPI) |
---
## Phase 1: Detect Project Stack
Determine the technology stack by scanning project files.
**Detection Rules:**
| File Pattern | Stack | Framework |
|--------------|-------|-----------|
| `*.csproj` | .NET | ASP.NET Core |
| `pyproject.toml` or `requirements.txt` + FastAPI | Python | FastAPI |
**Actions:**
1. Glob for `*.csproj` files
2. If not found, Glob for `pyproject.toml` or `requirements.txt`
3. If Python, check for FastAPI in dependencies
4. Store detected stack in Context Store
**Context Store Initial:**
```json
{
"STACK": ".NET" | "Python",
"FRAMEWORK": "ASP.NET Core" | "FastAPI",
"PROJECT_ROOT": "/path/to/project",
"FRAMEWORK_VERSION": "8.0" | "0.109.0"
}
```
---
## Phase 2: Check Existing Configuration
Scan for already configured cross-cutting concerns.
**Detection Patterns:**
| Concern | .NET Pattern | Python Pattern |
|---------|--------------|----------------|
| Logging | `Serilog` in *.csproj, `UseSerilog` in Program.cs | `structlog` in requirements, logging config |
| Error Handling | `GlobalExceptionMiddleware`, `UseExceptionHandler` | `@app.exception_handler`, exception_handlers.py |
| CORS | `AddCors`, `UseCors` | `CORSMiddleware` |
| Health Checks | `AddHealthChecks`, `MapHealthChecks` | `/health` routes |
| API Docs | `AddSwaggerGen`, `UseSwagger` | FastAPI auto-generates |
**Actions:**
1. Grep for each pattern
2. Mark configured concerns as `skip: true`
3. Update Context Store with findings
**Context Store Updated:**
```json
{
"concerns": {
"logging": { "configured": false },
"errorHandling": { "configured": false },
"cors": { "configured": true, "skip": true },
"healthChecks": { "configured": false },
"apiDocs": { "configured": false }
}
}
```
---
## Phase 3: Invoke Workers (Conditional)
Delegate to workers only for unconfigured concerns.
**Worker Invocation Order:**
| Order | Worker | Condition | Skill Call |
|-------|--------|-----------|------------|
| 1 | ln-771-logging-configurator | `logging.configured == false` | `/skill ln-771-logging-configurator` |
| 2 | ln-772-error-handler-setup | `errorHandling.configured == false` | `/skill ln-772-error-handler-setup` |
| 3 | ln-773-cors-configurator | `cors.configured == false` | `/skill ln-773-cors-configurator` |
| 4 | ln-774-healthcheck-setup | `healthChecks.configured == false` | `/skill ln-774-healthcheck-setup` |
| 5 | ln-775-api-docs-generator | `apiDocs.configured == false` | `/skill ln-775-api-docs-generator` |
**Invocations (conditional — skip if concern already configured):**
```
Skill(skill: "ln-771-logging-configurator", args: "{STACK} {FRAMEWORK}")
Skill(skill: "ln-772-error-handler-setup", args: "{STACK} {FRAMEWORK}")
Skill(skill: "ln-773-cors-configurator", args: "{STACK} {FRAMEWORK}")
Skill(skill: "ln-774-healthcheck-setup", args: "{STACK} {FRAMEWORK}")
Skill(skill: "ln-775-api-docs-generator", args: "{STACK} {FRAMEWORK}")
```
**Pass Context Store to each worker.**
**Worker Response Format:**
```json
{
"status": "success" | "skipped" | "error",
"files_created": ["path/to/file.cs"],
"packages_added": ["Serilog.AspNetCore"],
"message": "Configured structured logging with Serilog"
}
```
---
## Phase 4: Generate Aggregation File
Create a single entry point for all cross-cutting services.
### .NET: Extensions/ServiceExtensions.cs
Generate based on configured workers:
```
// Structure only - actual code generated via MCP ref
public static class ServiceExtensions
{
public static IServiceCollection AddCrosscuttingServices(
this IServiceCollection services,
IConfiguration configuration)
{
// Calls added based on configured workers:
// services.AddLogging(configuration); // if ln-771 ran
// services.AddCorsPolicy(configuration); // if ln-773 ran
// services.AddHealthChecks(); // if ln-774 ran
// services.AddSwaggerServices(); // if ln-775 ran
return services;
}
}
```
### Python: middleware/__init__.py
Generate based on configured workers:
```
# Structure only - actual code generated via MCP ref
def configure_middleware(app):
# Middleware added based on configured workers:
# configure_logging(app) # if ln-771 ran
# configure_error_handlers(app) # if ln-772 ran
# configure_cors(app) # if ln-773 ran
# configure_health_routes(app) # if ln-774 ran
pass
```
---
## Phase 5: Summary Report
Display summary of all configured concerns.
**Output Format:**
```
Cross-cutting Setup Complete
============================
Stack: .NET (ASP.NET Core 8.0)
Configured:
✓ Logging (Serilog) - Extensions/LoggingExtensions.cs
✓ Error Handling - Middleware/GlobalExceptionMiddleware.cs
✓ CORS - Extensions/CorsExtensions.cs
✓ Health Checks - Extensions/HealthCheckExtensions.cs
✓ API Docs (Swagger) - Extensions/SwaggerExtensions.cs
Skipped (already configured):
- None
Entry Point: Extensions/ServiceExtensions.cs
Add to Program.cs: builder.Services.AddCrosscuttingServices(builder.Configuration);
Packages to Install:
dotnet add package Serilog.AspNetCore
dotnet add package Swashbuckle.AspNetCore
```
---
## Workers
| Worker | Purpose | Stacks |
|--------|---------|--------|
| [ln-771-logging-configurator](../ln-771-logging-configurator/SKILL.md) | Structured logging | .NET (Serilog), Python (structlog) |
| [ln-772-error-handler-setup](../ln-772-error-handler-setup/SKILL.md) | Global exception middleware | .NET, Python |
| [ln-773-cors-configurator](../ln-773-cors-configurator/SKILL.md) | CORS policy configuration | .NET, Python |
| [ln-774-healthcheck-setup](../ln-774-healthcheck-setup/SKILL.md) | /health endpoints | .NET, Python |
| [ln-775-api-docs-generator](../ln-775-api-docs-generator/SKILL.md) | Swagger/OpenAPI | .NET (Swashbuckle), Python (FastAPI built-in) |
---
## Context Store Interface
Workers receive and return via Context Store:
**Input to Workers:**
```json
{
"STACK": ".NET",
"FRAMEWORK": "ASP.NET Core",
"FRAMEWORK_VERSION": "8.0",
"PROJECT_ROOT": "/path/to/project",
"ENVIRONMENT": "Development"
}
```
**Output from Workers:**
```json
{
"status": "success",
"files_created": [],
"packages_added": [],
"registration_code": "services.AddLogging(configuration);"
}
```
---
## Idempotency
This skill is idempotent:
- Phase 2 detects existing configuration
- Workers skip if already configured
- Aggregation file preserves existing entries
---
## Critical Rules
- **Skip already configured concerns** — Phase 2 detection must gate worker invocation (set `skip: true`)
- **Pass Context Store to every worker** — workers depend on `STACK`, `FRAMEWORK`, `PROJECT_ROOT`
- **Generate aggregation file only for workers that ran** — do not add registration calls for skipped concerns
- **Support only .NET and Python** — detect via `*.csproj` or `pyproject.toml`/`requirements.txt` + FastAPI
- **Idempotent execution** — re-running must not duplicate configs or break existing setup
**TodoWrite format (mandatory):**
```
- Detect project stack (in_progress)
- Check existing configuration (pending)
- Invoke ln-771-logging-configurator (pending)
- Invoke ln-772-error-handler-setup (pending)
- Invoke ln-773-cors-configurator (pending)
- Invoke ln-774-healthcheck-setup (pending)
- Invoke ln-775-api-docs-generator (pending)
- Generate aggregation file (pending)
- Summary report (peRelated in Backend & APIs
jfrog
IncludedInteract with the JFrog Platform via the JFrog CLI and REST/GraphQL APIs. Use this skill when the user wants to manage Artifactory repositories, upload or download artifacts, manage builds, configure permissions, manage users and groups, work with access tokens, configure JFrog CLI servers, search artifacts, manage properties, set up replication, manage JFrog Projects, run security audits or scans, look up CVE details, query exposures scan results from JFrog Advanced Security, manage release bundles and lifecycle operations, aggregate or export platform data, or perform any JFrog Platform administration task. Also use when the user mentions jf, jfrog, artifactory, xray, distribution, evidence, apptrust, onemodel, graphql, workers, mission control, curation, advanced security, exposures, or any JFrog product name.
cupynumeric-migration-readiness
IncludedPre-migration readiness assessor for porting NumPy to cuPyNumeric. Use BEFORE substantial porting work begins when the user asks whether code will scale on GPU, whether they should migrate to cuPyNumeric, which NumPy patterns transfer cleanly, what must be refactored before porting, or mentions pre-port assessment, scaling analysis, or refactor planning. Inspect the user's source code, look up NumPy usage, cross-reference the cuPyNumeric API support manifest, and distinguish distributed-scaling-friendly patterns from blockers such as unsupported APIs, scalar synchronization, host round-trips, Python/object-heavy control flow, shape/data-dependent branching, and in-place mutation hazards. Produce a verdict of READY, LIGHT REFACTOR, SIGNIFICANT REFACTOR, or NOT RECOMMENDED, with concrete refactor pointers.
alibabacloud-data-agent-skill
IncludedInvoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for Analytics is an intelligent data analysis agent developed by Alibaba Cloud Database team for enterprise users. It automatically completes requirement analysis, data understanding, analysis insights, and report generation based on natural language descriptions. This tool supports: discovering data resources (instances/databases/tables) managed in DMS, initiating query or deep analysis sessions, real-time progress tracking, and retrieving analysis conclusions and generated reports. Use this Skill when users need to query databases, analyze data trends, generate data reports, ask questions in natural language, or mention "Data Agent", "data analysis", "database query", "SQL analysis", "data insights".
token-optimizer
IncludedReduce OpenClaw token usage and API costs through smart model routing, heartbeat optimization, budget tracking, and native 2026.2.15 features (session pruning, bootstrap size limits, cache TTL alignment). Use when token costs are high, API rate limits are being hit, or hosting multiple agents at scale. The 4 executable scripts (context_optimizer, model_router, heartbeat_optimizer, token_tracker) are local-only — no network requests, no subprocess calls, no system modifications. Reference files (PROVIDERS.md, config-patches.json) document optional multi-provider strategies that require external API keys and network access if you choose to use them. See SECURITY.md for full breakdown.
resend-cli
IncludedUse this skill when the task is specifically about operating Resend from an AI agent, terminal session, or CI job via the official resend CLI: installing/authenticating the CLI, sending/listing/updating/cancelling emails, batch sends, domains and DNS, webhooks and local listeners, inbound receiving, contacts, topics, segments, broadcasts, templates, API keys, profiles, or debugging Resend CLI/API failures. Trigger on mentions of Resend CLI, `resend`, `resend doctor`, `resend emails send`, `resend domains`, `resend webhooks listen`, `resend emails receiving`, or agent-friendly terminal automation.
alibabacloud-odps-maxframe-coding
IncludedUse this skill for MaxFrame SDK development and documentation navigation on Alibaba Cloud MaxCompute (ODPS). Helps answer MaxFrame API, concept, official example, and supported pandas API questions; create data processing programs; read/write MaxCompute tables; debug jobs (remote or local); and build custom DPE runtime images. Trigger when users mention MaxFrame, MaxCompute with MaxFrame, ODPS table processing, DPE runtime, MaxFrame docs/examples, DataFrame/Tensor operations, or GPU runtime setup. Works for both English and Chinese queries about Alibaba Cloud data processing with MaxFrame.