Intégration Gemini AI

VérifiéSûr

Intègre Gemini AI pour générer du contenu de projet (descriptions courtes, longues, tags) via le service geminiService.ts. Utile pour ajouter des fonctionnalités d'IA, implémenter la limitation de débit (3 par brouillon, 10 par jour) et suivre des consignes de prompt en coréen avec un persona de chef.

Spar Skills Guide Bot
Data & IAIntermédiaire
7002/06/2026
Claude Code
#gemini#content-generation#rate-limiting#ai-integration

Recommandé pour

Notre avis

Intègre l'API Gemini pour générer automatiquement des descriptions de projets avec un style de chef coréen, incluant une gestion des limites de débit.

Points forts

  • Génération structurée en JSON avec schéma validé
  • Persona et langue cohérents (coréen, chef)
  • Mécanisme de rate limiting intégré (3 par brouillon, 10 par jour)

Limites

  • Limité à un seul persona et une seule langue (coréen)
  • Nécessite une configuration manuelle des limites dans le code
Quand l'utiliser

Utilisez cette compétence lorsque vous devez ajouter un générateur de contenu IA avec des contraintes d'utilisation et un style défini.

Quand l'éviter

Évitez de l'utiliser pour des générations en anglais ou avec un autre persona sans modifier les instructions.

Analyse de sécurité

Sûr
Score qualité85/100

The skill only provides guidance for using server functions and rate limiting. It does not instruct any destructive, exfiltrating, or obfuscated actions. No shell commands, file deletion, or secret exposure is involved.

Aucun point d'attention détecté

Exemples

Generate project description
Use the gemini-ai skill to generate a short and long description for a new recipe-sharing app called 'FlavorHub'. The draft should include tags like 'recipe', 'social', 'sharing'.
Refine raw description
I have a raw description: 'This app lets users share their cooking recipes and follow others.' Refine it into a polished markdown with the Korean chef persona.
Check rate limits
Explain how to call canGenerate() before each Gemini generation and how to handle exceeded limits in the UI.

name: gemini-ai description: Integrates Gemini AI for content generation. Use when adding AI features, generating project descriptions, implementing rate limiting, or working with geminiService.ts. Includes prompting guidelines and error handling.

Gemini AI Integration Skill

Instructions

  1. Server functions in src/services/geminiService.ts
  2. Use 'use server' directive
  3. Return structured JSON via schema
  4. Apply rate limiting (3/draft, 10/day)
  5. Korean language with "Chef" persona

Existing Functions

  • generateProjectContent(draft){ shortDescription, description, tags }
  • refineDescription(rawDescription) → refined markdown

AI Rate Limits

  • 3 generations per draft
  • 10 generations per day per user
  • 5-second cooldown between requests

Prompting Style

  • Role: "SideDish 플랫폼의 수석 에디터"
  • Language: Korean (자연스러운 해요체)
  • Culinary metaphors: subtle, not forced
  • Banned: "최고의", "혁신적인", "획기적인"

Usage in Components

import { generateProjectContent } from '@/services/geminiService'
import { canGenerate, recordGeneration } from '@/lib/aiLimitService'

if (!canGenerate(draftId)) {
  toast.error('AI 생성 횟수를 초과했습니다.')
  return
}

const result = await generateProjectContent(draft)
recordGeneration(draftId)

For complete templates, error handling, and UI components, see reference.md.

Skills similaires