Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Add support for Gemma 4

オープン
#32 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
20/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
kotlin

調査の方向性

Start with the Gemma3n implementation and the listed child issue files, ISSUE-skainet-gemma4-text-only.md and ISSUE-skainet-gemma4-multimodal.md, to map existing runtime entry points and split the work into milestones. The parent issue defines end-to-end inference, CLI detection, backward compatibility, tests, and attribution as acceptance criteria; its scope spans model loading, attention, and multimodal capabilities.

索引モデルが issue の本文から書いたものです。

説明

[Parent] Gemma 4 Support for SKaiNET-transformers

Summary

Add full Gemma 4 model family support to SKaiNET-transformers, starting with text-only inference and progressing to multimodal capabilities. Gemma 4 introduces hybrid attention (sliding + global), proportional RoPE (p-RoPE), Per-Layer Embeddings (PLE), new control tokens, and (optionally) Mixture-of-Experts — all requiring new config parsing, weight loading, prompt formatting, and runtime extensions beyond the existing Gemma3n implementation.

Motivation

Gemma 4 (Apache-2.0) offers up to 256K context, on-device efficiency via PLE, and broad model sizes (E2B, E4B, 31B dense; 26B A4B MoE). Supporting it positions SKaiNET-transformers as a competitive Kotlin Multiplatform inference runtime for the latest open models.

Scope

This parent issue tracks the overall Gemma 4 integration. Work is split into child issues:

  • Text-Only Support — Config, weight loading, tokenizer, prompt formatter, hybrid attention, kgemma CLI integration, tests
  • Multimodal & Advanced Features — Vision/audio encoders, MoE dispatcher, multimodal prompt handling, fine-tuning adapter ingestion

Key Architectural Decisions

  • Gemma3n code path remains untouched; kgemma differentiates at runtime via model_type in config.json
  • InferenceRuntime.generate(...) API stays generic — new Gemma4Runtime plugs into existing call sites
  • SafeTensors (single + sharded) and GGUF loading paths are both required
  • KV-cache compression (TurboQuant) integration planned for long-context performance phase

Acceptance Criteria

  • Gemma 4 E2B and E4B models load and run text inference end-to-end from HF SafeTensors
  • Existing Gemma3n functionality is unaffected (backward compatibility)
  • kgemma CLI auto-detects Gemma 4 vs Gemma3n based on model artifacts
  • CI passes with new Gemma 4 test suite (unit, integration, smoke)
  • Multimodal roadmap is outlined with clear milestones
  • Apache-2.0 license attribution and responsible-use references are documented

Child Issues

  • ISSUE-skainet-gemma4-text-only.md — Text-Only Support
  • ISSUE-skainet-gemma4-multimodal.md — Multimodal & Advanced Features

References

主要言語
Kotlin
スター
8
フォーク
3
平均マージ
1日 16時間
マージ済み PR(30日)
48

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

SKaiNET-developers/SKaiNET-transformers のほかの issue

SKaiNET-developers/SKaiNET-transformers の issue をすべて見る

似ている issue

Kotlin の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。