agentsclimarketplace

Flask

Skill G1Joshi/Agent-Skills/skills/frameworks/flask

Flask Python microframework with blueprints and extensions. Use for lightweight APIs.From its SKILL.md

Install
npx -y skills add G1Joshi/Agent-Skills --skill flask

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 12 stars12 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

1.6 KB, 369 tokens by cl100k_base, as published. Nobody here has run it

Flask

Flask is a lightweight WSGI web application framework. It is designed to make getting started quick and easy, with the ability to scale up to complex applications. Flask 3.0 (2025) fully supports async routes.

When to Use

  • Microservices: Minimal boilerplate makes it great for small services.
  • Flexibility: You validly choose your ORM (SQLAlchemy, Peewee) and Auth provider.
  • Data Science APIs: The standard for wrapping ML models (PyTorch/TensorFlow) in an API.

Quick Start (Async)

from flask import Flask
import asyncio

app = Flask(__name__)

@app.route("/")
async def hello():
    await asyncio.sleep(1)
    return "Hello form Async Flask!"

Core Concepts

The Application Context

Flask uses thread-locals (or context-vars in async) to make request and g globally accessible during a request.

Blueprints

Organize a group of related views and other code. auth_bp = Blueprint('auth', __name__).

Best Practices (2025)

Do:

  • Use Quart or Flask 3.0+: Ensure you are using modern async features if your app is I/O bound.
  • Use pydantic: Use Pydantic for request validation (via libraries like flask-pydantic or just raw).
  • Application Factory Pattern: Always use create_app() to ensure your app is testable.

Don't:

  • Don't use global state: Use current_app or g to store request-scoped data.

References

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.