mcpField

hackathon-code-implementer

github.com/bernieweb3開発57 回インストール
リポジトリ

hackathon-code-implementer について

ハッカソンのタスクをプロトタイプにする開発者向けの実装ガイダンススキルです。タスクの背景と時間予算に基づき、手順、コードのひな型、統合箇所、近道、リスク、検証可能な完了条件を提示します。

主な機能

  1. 01順序立てた実装計画の作成
  2. 02最小限のコードひな型の提示
  3. 03統合箇所の特定
  4. 04プロトタイプ向けの近道の提案
  5. 05時間予算に関するリスクの指摘
  6. 06検証可能な完了条件の定義

活用シーン

  1. 01計画済みのハッカソンタスクの実装開始
  2. 02具体的な着手点を求める開発者の支援
  3. 03利用可能な時間に対する超過リスクの評価

インストール

コマンドをコピーしてターミナルで実行します。

$npx skills add https://github.com/bernieweb3/hackathon-ai-devkit --skill hackathon-code-implementer

インストール後、Claude Code で/hackathon-code-implementerを入力して読み込まれたか確認します。

詳細

hackathon-code-implementer

目標

ハッカソンのプロジェクトタスクについて、プロトタイプの開発速度に適したコードパターン、統合戦略、ショートカットを含む、体系的な実装ガイダンスを提供します。


トリガー条件

次の場合にこのスキルを使用します。

  • hackathon-task-planner の特定のタスクをこれから実装する
  • 実装ガイダンス、コードのひな形、またはショートカットのパターンが必要
  • 開発者が行き詰まり、具体的な着手方法を必要としている
  • タスクの予算について、[HIGH-RISK] の超過リスクを評価する必要がある
  • タスクごとに一度呼び出し、hackathon-task-planner のタスクリスト全体に沿って繰り返す

入力

入力型必須説明
task_titlestringはい実装するタスク(hackathon-task-planner から取得)
task_descriptionstringはいタスクで達成すべき内容の詳細な説明
tech_stackstring[]はい使用するテクノロジー
mvp_demo_flowobject[]はいhackathon-scope-cutter のデモフローの手順
time_budget_hoursnumberはいこのタスクに割り当てられた時間
existing_code_contextstringいいえ関連する既存コードのスニペットまたはファイル構成
fake_okbooleanいいえハードコードされたデータやシミュレーションデータを許容するか(デフォルト:false)

出力

出力説明
implementation_planタスクを完了するためのサブステップの順序付きリスト
code_scaffolds着手に使える主要なコードスニペット、パターン、またはスタブ
integration_pointsこのタスクが他のコンポーネントと接続する箇所
shortcutsハッカソンに適したショートカット(モック、ハードコード、ライブラリ)
gotchas避けるべきよくある失敗
done_criteriaタスク完了を示す条件

ルール

  1. クリーンなコードより動作するコードを優先し、技術的負債は明示します。
  2. カスタム実装より既存のライブラリを推奨します。
  3. fake_ok が true の場合は、実装パターンと併せてモック/スタブのパターンも提示します。
  4. code_scaffolds は最小限にし、完全な実装ではなくエントリーポイントのみを示します。
  5. done_criteria は、time_budget_hours の範囲内で観察・検証できるものにします。
  6. time_budget_hours の 50% を超える時間がかかるリスクのあるサブステップには [HIGH-RISK] を付けます。
  7. 本番品質のアーキテクチャは生成せず、デモを完成させることを優先します。

出力形式

implementation_plan:
  - step: <number>
    action: "<what to do>"
    risk: "<[HIGH-RISK]|normal>"

code_scaffolds:
  - label: "<purpose>"
    language: "<language>"
    snippet: |
      <code>

integration_points:
  - component: "<name>"
    connection: "<how this task connects>"

shortcuts:
  - shortcut: "<description>"
    trade_off: "<what is sacrificed>"

gotchas:
  - "<pitfall>"

done_criteria:
  - "<verifiable condition>"

例

入力:

task_title: "Implement session memory read/write (T-03)"
task_description: "Store and retrieve a rolling summary of the user's emotional state across chat sessions using Redis."
tech_stack: ["Python", "FastAPI", "Redis", "OpenAI API"]
mvp_demo_flow:
  - step: 2
    action: "User describes recurring work stress"
    outcome: "AI references last week's similar conversation from memory"
time_budget_hours: 3
fake_ok: false

出力:

implementation_plan:
  - step: 1
    action: "Install redis-py; add Redis client singleton to app startup"
    risk: "normal"
  - step: 2
    action: "After each GPT-4 response, call GPT-4 to generate a 2-sentence session summary and write to Redis key user:{id}:summary"
    risk: "normal"
  - step: 3
    action: "On each new conversation, prepend the stored summary to the system prompt"
    risk: "[HIGH-RISK] — summary injection may push context window near limit; keep summary ≤100 tokens"
  - step: 4
    action: "Test by running two sessions and verifying AI references prior context"
    risk: "normal"

code_scaffolds:
  - label: "Redis memory read/write"
    language: "python"
    snippet: |
      import redis
      r = redis.Redis(host="localhost", port=6379, decode_responses=True)

      def get_memory(user_id: str) -> str:
          return r.get(f"user:{user_id}:summary") or ""

      def save_memory(user_id: str, summary: str):
          r.set(f"user:{user_id}:summary", summary, ex=86400)

integration_points:
  - component: "OpenAI chat endpoint (T-02)"
    connection: "Prepend get_memory() result to system prompt on every request"

shortcuts:
  - shortcut: "Use a single hardcoded user_id='demo' for the hackathon"
    trade_off: "No real multi-user support; acceptable for single-demo session"

gotchas:
  - "Redis not running on demo machine → add a startup health check with a clear error message"
  - "Summary growing too long → hard-cap at 150 tokens before injection"

done_criteria:
  - "Starting a new chat session shows AI referencing content from the previous session"
  - "Redis key exists and contains non-empty summary after first session ends"

コンテキストファイル

ナレッジベース
  • ../hackathon-shared-resources/knowledge/hackathon-reference-architecture.md
  • ../hackathon-shared-resources/knowledge/hackathon-tools.md
  • ../hackathon-shared-resources/knowledge/hackathon-mvp-strategy.md
  • ../hackathon-shared-resources/knowledge/hackathon-common-failures.md
プレイブック
  • ../hackathon-shared-resources/playbooks/hackathon-workflow.md

コメント