본문으로 건너뛰기
Skillpedia
API 및 서버 (백엔드)22k · #10255

developing-genkit-dart

하는 일

이 스킬은 Genkit SDK를 사용해 Dart와 Flutter에서 AI 기능을 만들도록 돕습니다. Dart 앱에 AI 에이전트나 모델 호출을 추가하려는 사람을 위한 스킬입니다.

사용하는 경우

  • ✓Genkit을 써서 Dart로 AI 에이전트나 플로우를 만들고 싶을 때.
  • ✓Dart 또는 Flutter 앱에 언어 모델 호출을 추가하고 싶을 때.
  • ✓Genkit Dart 코드를 이전 버전에서 1.0 API로 업데이트할 때.

스킬 링크

https://github.com/google/skills/blob/main/skills/cloud/developing-genkit-dart/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/google/skills/blob/main/skills/cloud/developing-genkit-dart/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“주제를 받아 언어 모델로부터 짧은 농담을 돌려주는 Genkit 플로우를 Dart로 만들어 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

Genkit Dart 1.0 API의 현재 이름과 패턴을 사용해 코드를 작성하고, 각 기능에 대한 참조 가이드를 안내합니다. 설정, 생성, 도구, 플로우를 돕습니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Genkit Dart

Genkit Dart is an AI SDK for Dart that provides a unified interface for code generation, structured outputs, tools, flows, and AI agents.

Core Features and Usage

If you need help with initializing Genkit (Genkit()), Generation (ai.generate), Tooling (ai.defineTool), Flows (ai.defineFlow), Embeddings (ai.embed), streaming, or calling remote flow endpoints, please load the core framework reference: references/genkit.md

1.0 vs pre-1.0 APIs

This skill targets Genkit Dart 1.0 (genkit: ^1.0.0). Older code and training data use pre-1.0 names that no longer compile; the common ones:

  • HTTP: startFlowServer / per-route shelfHandler / shelf_cors_headers are now GenkitRouter + serve() or asShelfHandler(), with CorsOptions; context providers take RequestData (genkit_shelf.md).
  • StatusCodes.UNAUTHENTICATED is StatusCode.unauthenticated (lowerCamelCase, same for EvalStatus.pass, ToolChoice.required).
  • No RetryPlugin; retry() is built in and takes Durations (initialDelay, maxDelay, also cacheTtl elsewhere).
  • Renames: GenerateResponseHelper -> GenerateResult (modelResponse, chunk.modelChunk), ExecutablePrompt -> Prompt<Input, Output>, embedMany -> embed, ToolFnArgs -> ToolFnArg, toolOutputSchema -> outputSchema, underlyingException -> cause, modelInfo: -> info:, RemoteAction.dispose() -> close(), prompt(input, PromptGenerateOptions(config: ...)) -> prompt(input, config: ...) (named options, like generate), defineMiddleware -> ai.defineGenerateMiddleware (app) / generateMiddleware (plugins).
  • Provider config types are prefixed: GeminiThinkingConfig, GeminiSafetySettings, GeminiGoogleSearch, GeminiSpeechConfig, GoogleGenAiEmbedderOptions, AnthropicThinkingConfig.
  • Removed: ToolInterruptException / ctx.interrupt() (return .interrupt(...)), GoogleAiModels / OpenAIModels constants (use googleAI.gemini('...'), openAI.model('...')). Simulated constrained output is opt-in via simulateConstrainedGeneration().
  • .prompt Picoschema is spec-compliant: name: type, description, never name(description): type (dotprompt.md).

Prompts (Dotprompt)

.prompt files keep prompt content out of Dart code with YAML frontmatter plus a Handlebars template. See references/dotprompt.md: promptDir, ai.prompt() (call/stream/render), variants, partials, named schemas via defineSchema, and the tools/maxTurns/returnToolRequests/use (middleware) frontmatter fields. A .prompt file can also back an agent directly via definePromptAgent.

Agents

Genkit Dart has an agent API for persistent, multi-turn conversations (sessions, snapshots, interrupts, branching, background execution, custom state, artifacts, and multi-agent delegation). The agent/session/snapshot APIs are experimental and live behind opt-in imports: server APIs come from package:genkit/experimental.dart (alongside package:genkit/genkit.dart), the browser/HTTP client from package:genkit/experimental_client.dart (alongside package:genkit/client.dart), and dart:io extras like FileSessionStore from package:genkit/experimental_io.dart. These entry points are @experimental, so importing them raises an experimental_member_use analyzer warning you can silence in analysis_options.yaml. The remoteAgent client works from any Dart app, including Flutter, and the backend is fully interchangeable — it can talk to a Genkit agent implemented in Dart, JS/TypeScript, or Go over the same HTTP protocol. A few Dart specifics: interrupts are ai.defineInterrupt(...) or tools that return .interrupt(...) (there is no ctx.interrupt()), sub-agent delegation uses the agents() middleware from package:genkit_middleware, and there is no artifacts() middleware yet (define artifact tools directly).

For more details see:

자주 묻는 질문

이전 Genkit 버전도 지원하나요?

Genkit Dart 1.0을 대상으로 하며, 이전 버전과 이름이 바뀐 항목을 알려 줍니다.

Flutter 앱도 다루나요?

네. Dart 앱과 Flutter 앱 모두에 언어 모델을 연결하도록 돕습니다.

어떤 기능을 다루나요?

설정, 생성, 도구, 플로우, 임베딩, 스트리밍, 원격 플로우 엔드포인트 호출을 다룹니다.

상세 정보

작성자의 원본 설명

Generates code and provides documentation for the Genkit Dart SDK. Use when the user asks to build AI agents in Dart, use Genkit flows, or integrate LLMs into Dart/Flutter applications.

repo: google/skills

인기도

GitHub 스타
22k
순위
#10255
라이선스
Apache-2.0
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬