| title | How to run a local coding agent with Gemma 4 and Pi | |
|---|---|---|
| spoiler | Set up Gemma 4 running in LM Studio, connected to Pi as the terminal agent | |
| date | 2026-04-27 | |
| permalink | /gemma-4-pi-agent/ | |
| tags |
|
| jq '(.cells[] | select(.execution_count != null)).execution_count = null | (.cells[].outputs[]? | select(.execution_count != null)).execution_count = null' ./file.ipynb |
| # Simple Generate Content | |
| curl "https://generativelanguage.googleapis.com/v1beta/models/gemini-flash-latest:generateContent?key=${GEMINI_API_KEY}" \ | |
| -H 'Content-Type: application/json' \ | |
| -X POST \ | |
| -d '{ | |
| "contents": [ | |
| { | |
| "parts": [ | |
| { | |
| "text": "Explain how AI works in one sentence" |
| """ | |
| Install dependencies: | |
| brew install portaudio | |
| pip install -U google-genai pyaudio | |
| Use headphones to avoid echo cancellation, then talk to Gemini. | |
| """ | |
| import asyncio |
Google has recently released Gemini 2.5 Flash Image, a powerful new model for image generation and editing, also known by its codename, Nano Banana. This model introduces state-of-the-art capabilities for creating and manipulating images, unlocking a wide range of new applications.
This guide provides a comprehensive walkthrough for developers looking to integrate Gemini 2.5 Flash Image aka Nano Banana into their applications using the Gemini Developer API.
This guide will cover:
- Using Nano Banana in AI Studio
- Project setup
Guide on how to use Nano Banana aka Gemini 2.5 Flash Image in JavaScript with the Google GenAI JS/TS SDK.
A detailed blog post can be found on TBD.
More resources:
- Get an API key from Google AI Studio.
- Nano Banana Gemini API docs
Guide on how to use Nano Banana aka Gemini 2.5 Flash Image in Python with the Google GenAI SDK.
A detailed blog post can be found on TBD.
More resources:
- Get an API key from Google AI Studio.
- Nano Banana Gemini API docs
| import { google } from "@ai-sdk/google"; | |
| import { z } from "zod"; | |
| import { generateText, generateObject } from "ai"; | |
| import "dotenv/config"; | |
| import puppeteer from "puppeteer"; | |
| import { ChartConfiguration } from "chart.js"; | |
| function createChartConfig({labels, data, label, type, colors,}: { | |
| labels: string[]; | |
| data: number[]; |
| Title | Market Research Agent with Gemini and the Vercel AI SDK |
|---|---|
| Description | Building apps with Gemini and the Vercel AI SDK |
The Vercel AI SDK is a powerful open-source library for building AI-powered applications, user interfaces, and agents in TypeScript.
Gemini models are accessible using the AI SDK by Vercel. This guide will help you get started with the AI SDK and Gemini.
For more information, see the following resources: