← スキル一覧に戻る

adk-progress-bridge
by ilteris
⭐ 0🍴 0📅 2026年1月15日
SKILL.md
name: ADK Progress Bridge description: Transform long-running AI tools into real-time SSE progress streams
ADK Progress Bridge Skill
This skill teaches how to implement real-time progress streaming for GenAI/ADK tools using async generators and Server-Sent Events.
When to Use This Skill
- Building long-running AI tools (>5 seconds) that need user feedback
- Implementing multi-step workflows with progress tracking
- Creating audit, analysis, or data processing tools
- Any tool where "silence" during execution is a UX problem
Core Pattern
1. Backend: Async Generator Tool
from backend.app.bridge import progress_tool, ProgressPayload
@progress_tool(name="my_tool")
async def my_tool(args):
# Yield progress updates
yield ProgressPayload(step="Working...", pct=50, log="Details here")
# Yield final result (must be dict)
yield {"status": "complete", "data": result}
2. Frontend: SSE Composable
import { useAgentStream } from '@/composables/useAgentStream'
const { state, runTool } = useAgentStream()
await runTool('my_tool', { arg: 'value' })
// Reactive state: state.progressPct, state.currentStep, state.logs
Key Files Reference
| File | Purpose |
|---|---|
backend/app/bridge.py | Core: ProgressPayload, @progress_tool, ToolRegistry |
backend/app/main.py | API: /start_task, /stream endpoints |
frontend/src/composables/useAgentStream.ts | Vue composable for SSE |
frontend/src/components/TaskMonitor.vue | UI component example |
SSE Event Schema
{
"call_id": "uuid",
"type": "progress|result|error",
"payload": { "step": "...", "pct": 0-100, "log": "..." }
}
Adding a New Tool Checklist
- Create
backend/app/my_tool.pywith@progress_tooldecorator - Implement async generator yielding
ProgressPayload+ finaldict - Import in
backend/app/main.pyto register - Test via
/verify-streamworkflow orverify_stream.py
Common Mistakes
- ❌ Forgetting to yield a final
dict(tool hangs) - ❌ Not importing tool in
main.py(404 on/start_task) - ❌ Using sync functions instead of async generators
- ❌ Not closing EventSource on result/error in frontend
スコア
総合スコア
50/100
リポジトリの品質指標に基づく評価
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
レビュー
💬
レビュー機能は近日公開予定です