佳礼资讯网

 找回密码
 注册

ADVERTISEMENT

搜索
查看: 101|回复: 6

大家觉得 Gemma 4 是 侧端AI 的 Local AI 吗?

[复制链接]
发表于 3-4-2026 11:25 AM 来自手机 | 显示全部楼层 |阅读模式
本帖最后由 aidj 于 3-4-2026 11:38 AM 编辑

侧端AI(Edge AI)是指将人工智能算法和模型部署在本地终端设备(如手机、电脑、智能汽车、IoT设备)上,而非完全依赖云端服务器的AI技术。其特点是实时性高(毫秒级响应)、安全性强(数据本地化)、节省流量/电力,能在无网环境下工作。

回复

使用道具 举报


ADVERTISEMENT

 楼主| 发表于 3-4-2026 11:33 AM 来自手机 | 显示全部楼层

Here’s what Gemma 4 actually is:

**📌 What Gemma 4 really is**
• Gemma 4 is a **family of open-weight generative AI models** released by Google under an Apache 2.0 license. ([blog.google][1])
• It’s built from the same research foundation as Google’s Gemini models, optimized for a range of hardware — from edge-friendly small models (E2B, E4B) to larger, workstation-class models (26B MoE and 31B Dense). ([SiliconANGLE][2])
• The models are aimed at enabling **on-device and offline AI** capabilities, making advanced AI usable even on resource-limited devices. ([LinkedIn][3])

**📌 Who created Gemma 4?**
Gemma 4 was developed by **Google DeepMind** researchers and engineers as part of Google’s AI research efforts — it’s not the name of an individual or startup founder. ([blog.google][1])



[1]: https://blog.google/innovation-a ... _source=chatgpt.com "Gemma 4: Byte for byte, the most capable open models"
[2]: https://siliconangle.com/2026/04 ... _source=chatgpt.com "Google's new Gemma 4 models bring complex reasoning ..."
[3]: https://www.linkedin.com/posts/w ... _source=chatgpt.com "#gemma #webai #gemma4 #edgeai #webai | Jason Mayes"
回复

使用道具 举报

 楼主| 发表于 3-4-2026 11:45 AM 来自手机 | 显示全部楼层
Here are **notable edge AI platforms, tools, companies, and frameworks** beyond just “Gemma 4”—all focused on running AI *locally*, on devices or hardware at the network edge instead of centralized cloud servers: ([AI Magazine][1])

---

## 🚀 **Edge AI Platforms & Software**

1. **Edge Impulse** – A widely-used development platform for building and deploying machine learning to edge and embedded devices. ([Gartner][2])
2. **AWS IoT Greengrass + SageMaker Edge** – Combines AWS’s edge runtime (Greengrass) with machine learning deployment from SageMaker. ([SCM Galaxy][3])
3. **Microsoft Azure Percept** – End-to-end edge AI platform with vision and audio modules integrated with Azure cloud services. ([SCM Galaxy][3])
4. **NVIDIA EGX Platform** – GPU-accelerated platform for real-time AI workloads on edge sites and industrial environments. ([Gartner][2])
5. **Tata ELXSI Edge AI Solutions** – Software suite for real-time inferencing, analytics, and computer vision at the edge. ([Gartner][2])
6. **RunAnywhere / Edge AI Management Platforms** – Platforms that focus on deploying, versioning, and monitoring AI models across fleets of edge devices. ([RunAnywhere][4])
7. **Google AI Edge Stack** – Tools and libraries for building ML pipelines across devices including MediaPipe and acceleration support. ([Google AI for Developers][5])

---

## 🧰 **Edge AI Frameworks & Runtimes**

These are *software tools* developers use to run AI models efficiently on resource-limited hardware: ([Medium][6])

* **TensorFlow Lite** – Lightweight TensorFlow runtime for mobile/embedded AI. ([Medium][6])
* **ONNX Runtime (for Edge)** – Optimized runtime for models in ONNX formats on edge platforms. ([Medium][6])
* **PyTorch Mobile** – Mobile-optimized version of PyTorch for running models on phones and small devices. ([Medium][6])
* **TensorRT & OpenVINO** – Hardware-accelerated inference libraries from NVIDIA and Intel. ([Medium][6])
* **KubeEdge / Edge Kubernetes-based Frameworks** – Tools to manage containerized AI workloads distributed across edge nodes. ([arXiv][7])

---

## 🏢 **Companies & Hardware Platforms Making Edge AI Work**

These are notable *companies and hardware ecosystems* that enable edge AI, either through chips, tools, or integrated platforms: ([MarketsandMarkets][8])

### **Big Platform & Hardware Players**

* **NVIDIA** – Jetson modules for robotics and IoT; EGX for enterprise edge AI. ([Gartner][2])
* **Qualcomm** – Edge-optimized NPUs and partner ecosystems for edge machine learning. ([MarketsandMarkets][8])
* **Intel** – Edge AI toolchains and accelerators in its Open Edge Platform. ([Intel][9])
* **Arm** – CPU & NPU IP that powers many edge AI devices and microcontrollers. ([Arm][10])
* **Amazon Web Services** – AWS edge services with Greengrass. ([Gartner][2])
* **Microsoft** – Azure IoT/Percept edge offerings. ([MarketsandMarkets][11])
* **IBM** – Edge AI integration for enterprise and industrial use. ([MarketsandMarkets][11])

### **Emerging Startups & Niche Players**

* **ClearSpot.ai** – Drone and inspection edge AI. ([StartUs Insights][12])
* **Nexa AI** – On-device inference framework. ([StartUs Insights][12])
* **SECeDGE** – Edge security + cloud integration. ([StartUs Insights][12])
* **Dropla & Floware** – IoT sensor and environmental monitoring edge AI. ([StartUs Insights][12])

*(The above are examples of startups pushing edge AI in 2025–26; more emerge each year.)* ([StartUs Insights][12])

---

## 📈 **Why Edge AI Matters (Use Cases)**

Edge AI is used in real-world applications like smart cameras, real-time quality control in factories, wearable health analytics, autonomous vehicles, and real-time fraud detection — all with **faster responses, lower latency, and better privacy than cloud-only AI**. ([snuc.co.uk][13])

---

If you want, I can break this down further by **use case (e.g., robotics, IoT sensors, mobile apps)** or by **development versus deployment tools**!

[1]: https://aimagazine.com/top10/top-10-edge-ai-solutions?utm_source=chatgpt.com "Top 10: Edge AI Solutions"
[2]: https://www.gartner.com/reviews/market/edge-ai-solutions?utm_source=chatgpt.com "Best Edge AI Solutions Reviews 2026"
[3]: https://www.scmgalaxy.com/tutorials/top-10-edge-ai-platforms-tools-in-2025-features-pros-cons-comparison/?utm_source=chatgpt.com "Top 10 Edge AI Platforms Tools in 2025: Features, Pros ..."
[4]: https://www.runanywhere.ai/blog/best-edge-ai-management-platforms-2026?utm_source=chatgpt.com "Top 8 Edge AI Management Platforms to Deploy, Monitor & ..."
[5]: https://ai.google.dev/edge?utm_source=chatgpt.com "Google AI Edge"
[6]: https://medium.com/%40PhaniBhushanAthlur/top-edge-computing-platforms-compared-challenges-trends-and-how-to-use-ai-at-the-edge-514358d0ba8b?utm_source=chatgpt.com "Best Edge Computing Platforms Compared: Challenges ..."
[7]: https://arxiv.org/abs/2007.09227?utm_source=chatgpt.com "KubeEdge.AI: AI Platform for Edge Devices"
[8]: https://www.marketsandmarkets.com/ResearchInsight/edge-ai-hardware-market.asp?utm_source=chatgpt.com "Top Companies List of Edge AI Hardware Industry"
[9]: https://www.intel.com/content/www/us/en/software/edge-platform.html?utm_source=chatgpt.com "Intel's Edge AI Portfolio"
[10]: https://www.arm.com/markets/iot/edge-ai?utm_source=chatgpt.com "Edge AI - Arm"
[11]: https://www.marketsandmarkets.com/ResearchInsight/edge-ai-software-market.asp?utm_source=chatgpt.com "Top Companies in Edge AI Software Market - Microsoft (US ..."
[12]: https://www.startus-insights.com/innovators-guide/edge-ai-companies/?utm_source=chatgpt.com "10 Top Edge AI Companies and Startups to Watch in 2026"
[13]: https://snuc.co.uk/blog/edge-ai-examples/?utm_source=chatgpt.com "10 Examples of Industries Where Edge AI is Thriving"
回复

使用道具 举报

发表于 3-4-2026 11:56 AM | 显示全部楼层
如果它们的报告数据是差不多一样的,那么就是同一个的。
回复

使用道具 举报

 楼主| 发表于 3-4-2026 12:13 PM 来自手机 | 显示全部楼层
使用者 发表于 3-4-2026 11:56 AM
如果它们的报告数据是差不多一样的,那么就是同一个的。

同樣是 MoE、同樣跑在消費級硬體上,Qwen3.5-35B-A3B 和 Gemma 4-26B-A4B 的架構哲學卻完全不同。
把兩個模型的 Ollama blob metadata 和 tensor shape 都翻出來看,整理一下心得。

--

先看數字

- Qwen3.5-35B-A3B:35B 總參數,推理只動 3B(稀疏率 91%),40 層
- Gemma 4-26B-A4B:26B 總參數,推理啟動約 3.8B,30 層(從 Ollama blob 的 block_count 直接讀到)

兩者都靠 MoE 把「真正在算的參數」壓到 4B 以下,速度和小模型差不多,但能力強很多。換算成 dense model 的品質等效,社群常用 √(總參數 × active 參數) 估算:Qwen3.5 = √(35×3) ≈ 10B dense,Gemma 4 = √(26×3.8) ≈ 10B dense——跟實際 benchmark 觀察吻合。

--

Attention 機制:最大的根本分歧

標準 Transformer 的 attention 讓每個 token 都能看到整個序列,時間與記憶體複雜度都是 O(n²)。兩個模型各自用不同的方式削減這個代價。

Qwen3.5 走 Hybrid 路線,40 層裡有 30 層是 Gated DeltaNet(線性 attention),只有 10 層是標準 attention。DeltaNet 的時間複雜度接近 O(n),推理時的 state 記憶體大小固定不隨序列長度增加。從 blob 可以直接讀到 ssm.state_size=128——這是 DeltaNet 每個 head 的 state dimension,不管 context 多長,DeltaNet 層的工作記憶就是這塊固定大小的狀態矩陣(實際佔用 = head 數 × 128 × head_dim)。代價是需要特殊 kernel,FlashAttention 不直接支援。

Gemma 4 完全放棄線性 attention,走純 Transformer 精煉路線。大部分層用 Sliding Window Attention(只看前方固定視窗內的 token,window=1024),每隔 5 層插一層全局 attention 讓模型能「刷新視野」。SWA 層的 KV cache 大小受視窗限制,不隨序列增長。各種推理框架原生支援。

但兩者都是 hybrid 架構——Qwen3.5 仍有 10 層 full attention,Gemma 4 仍有 5 層 global attention,這些層的 KV cache 照樣隨序列長度線性增長。整體記憶體複雜度仍然是 O(n),只是比起純 Transformer,需要維護 KV cache 的層數大幅減少(Qwen 10/40 層、Gemma 5/30 層),常數因子小很多。

DeltaNet 層和 SWA 層各自用固定大小的記憶體裝不同的東西:

- SWA:記得清楚,但記得少(視窗外的直接丟)
- DeltaNet:什麼都記,但記得模糊(壓縮進固定大小的狀態矩陣,有損)

--

MoE FFN 設計:都有 shared + routed 並行,但哲學不同

從 blob tensor shape 才看得出來——兩個模型每層都不是純 MoE 替換 FFN,而是有一條「永遠啟動的路徑」搭配 routed experts 並行運作。

差別在設計比重和實作方式:Gemma 4-26B 的永遠啟動路徑是一條完整的 dense FFN(dim=2112),有自己獨立的 norm 層,遠大於每個 routed expert(dim=704),更像是「dense FFN 主幹 + MoE 增強」的設計;Qwen3.5 的 shared expert 則和 routed experts 尺寸相同(dim=512),共用 MoE 框架的 router gate,地位對等,比較像「多一個永遠被選到的 expert」。

--

GQA 壓縮的非對稱設計

Gemma 4-26B 的 KV head 數因 attention 類型而異:sliding window 層的 GQA 壓縮比較保守(16:8 = 2:1),全局 attention 層則壓縮得很猛(16:2 = 8:1)。全局層的 KV cache 才是記憶體殺手,Google 在刀口上省力氣。

Qwen3.5 的標準 attention 層(每 4 層一次)GQA 壓縮比是 16:1(從 tensor shape 算:attn_q 維度 8192 / key_length 256 = 32 Q heads,attn_k 維度 512 / 256 = 2 KV heads),比 Gemma 4 全局層的 8:1 還猛。DeltaNet 層根本沒有 KV cache,直接是 recurrent state,blob 顯示 head_count_kv=[0, 0, 0, 2, ...],0 就是 DeltaNet 層。

--

設計哲學的根本分歧

Qwen3.5 在賭:線性 attention 是未來,長 context 效率才是關鍵戰場。
Gemma 4 在賭:把純 Transformer 做到極致、對量化和跨平台友善,才是開放模型真正的護城河。

兩個都是 Apache 2.0,兩個都能本機跑。不同的賭注,就看接下來哪個方向先被硬體生態收編。

#AI #LLM #MoE #Gemma4 #Qwen #開源模型
回复

使用道具 举报

发表于 3-4-2026 12:39 PM | 显示全部楼层
aidj 发表于 3-4-2026 12:13 PM
同樣是 MoE、同樣跑在消費級硬體上,Qwen3.5-35B-A3B 和 Gemma 4-26B-A4B 的架構哲學卻完全不同。
把兩個 ...

看了你的资料,嗯,他们是同一个的东西,这是名称和结构不同。
回复

使用道具 举报

Follow Us
 楼主| 发表于 3-4-2026 06:52 PM 来自手机 | 显示全部楼层
使用者 发表于 3-4-2026 12:39 PM
看了你的资料,嗯,他们是同一个的东西,这是名称和结构不同。

Gemma 4 E2B/Q4 , E4B/Q3 在 M2 MacBook Air(8GB)實測心得

Google 在 2026/04/02 發佈了 Gemma 4 開源模型家族,首次採用 Apache 2.0 授權。之前在 M2 MacBook Air(8GB)上跑本地模型,基本上沒什麼實用性,這次 Gemma 4 讓我第一次覺得「8GB 的機器真的能跑有用的地端小模型」。
.
複雜的結構分析和程式,還是要靠 Claude,不過知識問答是可以用的,我先用聖經知識問答試水溫:大方向的神學問題還行,但精確引用或跨卷對照就會出現幻覺。不過「給資料讓它整理」的能力明顯強於同級模型,於是測試方向就轉成:餵食 RAG 檢索回來的文章,看彙整品質到底能到什麼程度。
.
幾個心得:
1. 最佳甜蜜點:4篇 x 1000字。
- 第 5 篇幾乎不被引用,浪費 token
- 1000 字剛好涵蓋一個完整論點,不會切在句子中間
- 來源越少,模型越不容易忽略指令
.
2.Thinking 在 RAG 場景適得其反
- Thinking tokens 佔用了生成配額,回答空間被擠壓,在 RAG 這類吃文字量的場景,建議關閉 thinking。
.
3. 量化等級測試
- E2B:Q4 是最低可用門檻
- E4B:Q3 更大的底子能撐住更壓縮的量化,E4B 的 4.5B 參數底子彌補了 Q3 量化的損失,用不到一半的記憶體達到接近的品質。這是 8GB 機器的最佳省記憶體選擇。
.
4. 同級模型 RAG 品質排名
- 本地 Gemma 4 完勝同量級雲端模型 — E2B Q4 以 8.5/10 大勝 Qwen 2.5 7B(6.5/10)和 Llama 3.1 8B(4/10)。Gemma 4 的指令遵循和引用標記能力突出。
- Llama 和 Qwen 2.5 有簡體中文混入問題。Gemma 4 繁體輸出穩定。
.
結論:
.
1. gemma 4 小模型的彙整能力沒問題,問題出在知識的地基,不是蓋房子的技術。有正確資料餵食,2-4B 的模型就能做出 8/10 不錯表現。

2. 量化不能無腦壓,E2B 從 Q4 到 Q3 就崩壞,但 E4B Q3 卻可用,較大的模型底子能承受更激進的量化。

3. Prompt 工程對小模型至關重要,question-first、控制餵食量、關閉 thinking、Streaming 等,這些在大模型上不需要注意的細節,在小模型上決定成敗。

4. 一般知識問答,Thinking 可用,專業知識搭配餵食資料(範圍內),Thinking 關掉比較好。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

 

ADVERTISEMENT



ADVERTISEMENT



ADVERTISEMENT

ADVERTISEMENT


版权所有 © 1996-2026 Cari Internet Sdn Bhd (483575-W)|IPSERVERONE 提供云主机|广告刊登|关于我们|私隐权|免控|投诉|联络|脸书|佳礼资讯网

GMT+8, 4-4-2026 06:08 AM , Processed in 0.088125 second(s), 28 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表