image-processor-guidelines

Provide development guidelines for a Python FastAPI image processor microservice.

Updated Nov 9, 2025
One-click install
npx skills add https://github.com/ZeroGravitySkin-Ron/Claude --skill image-processor-guidelines
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: image-processor-guidelines
Source: https://github.com/ZeroGravitySkin-Ron/Claude/tree/main/skills/image-processor-guidelines
Command: npx skills add https://github.com/ZeroGravitySkin-Ron/Claude --skill image-processor-guidelines

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides a concise, actionable blueprint for developing and validating a Python FastAPI image processing microservice, covering integration with Perfect Corp API, MediaPipe FaceMesh validation, and robust error handling.

Core Features & Use Cases

  • FastAPI patterns: recommended structure, dependencies, middleware.
  • MediaPipe FaceMesh validation: guidance for integration and validation.
  • Perfect Corp API integration: best practices, mock mode, and error handling.
  • Structured logging & tracing: guidelines for correlating requests.

Quick Start

Review the guidelines and apply them to your project setup:

  • Ensure routes under /v1 are versioned and have proper dependencies.
  • Implement correlation headers (X-Request-Id, X-Analysis-Session, X-Frame-Seq).
  • Use structured logging with request IDs.
  • Configure mock mode for testing and a real mode for production.
  • Validate access control with CIDR and X-Internal-Secret.

Frequently Asked Questions about image-processor-guidelines

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a FastAPI image processor with MediaPipe face validation?

FastAPI image processors validate faces using MediaPipe FaceMesh by configuring detection routes under /v1, implementing Pydantic v2 models for request validation, and integrating MediaPipe's face landmark detection. The Skill provides structured patterns for routes, dependencies, and error handling to ensure robust validation.

What's the best way to integrate Perfect Corp API with FastAPI?

Integrate Perfect Corp API by implementing mock and real modes in FastAPI routes, handling provider normalization, configuring structured logging with correlation headers (X-Request-Id, X-Analysis-Session, X-Frame-Seq), and applying CIDR plus X-Internal-Secret access control. The Skill covers best practices for error handling and request tracing.

How do I set up structured logging and request tracing in FastAPI?

Structured logging in FastAPI correlates requests using headers like X-Request-Id and X-Analysis-Session, logging each frame sequence with X-Frame-Seq. The Skill provides guidelines for middleware configuration, dependency injection, and logging patterns that maintain request context across microservice calls.

Can I use CIDR-based access control with X-Internal-Secret in FastAPI?

Yes. FastAPI access control combines CIDR validation (checking client IP ranges) with X-Internal-Secret header verification in middleware or route dependencies. The Skill details configuration patterns for both authentication methods and their implementation within FastAPI's dependency system.

What testing and deployment strategies work with FastAPI image processors?

Testing strategies include mock mode for Perfect Corp integration, unit tests for Pydantic model validation, and integration tests for MediaPipe face detection. Deployment follows versioned route patterns (/v1) and structured logging. The Skill covers testing approaches and production deployment checklist items.

When should I use mock mode versus real mode in image processing services?

Use mock mode during development and testing to avoid Perfect Corp API costs and latency; switch to real mode for production. Mock mode returns synthetic responses while real mode processes actual image data. The Skill guides configuration management and mode switching for different deployment environments.