Skip to content

Instantly share code, notes, and snippets.

View windymelt's full-sized avatar
😄
Working from Home

Windymelt windymelt

😄
Working from Home
View GitHub Profile
@windymelt
windymelt / gist:54f6a4cf61238a184299f2a7f5b5b960
Created July 15, 2026 17:42
ローカルの Incus で AI エージェント用の使い捨て開発環境を作る

ローカルの Incus で AI エージェント用の使い捨て開発環境を作る

(これは作業内容をLLMにまとめさせたものである)

この記事の目的

AI エージェント(Claude Code など)にコードベースの作業を任せるとき、ホストを汚さず、隔離されていて、短時間で作って捨てられる環境があると都合がよい。この記事では、Proxmox を別ホストに立てる構成ではなく、手元の Linux 開発機に直接 Incus(LXC のコンテナ管理基盤)を導入して同等の環境を作る手順を、実際に踏んだ落とし穴と対処を含めてまとめる。

対象は「開発機が Linux で、単独で使う」ケースである。この条件では、別ホストを常時稼働させる固定費が不要になり、ローカルの Incus が費用対効果の面で優位になる。macOS や Windows を開発機にする場合、複数人や複数マシンで環境を共有したい場合、開発機の電源を切ってもエージェントを動かし続けたい場合は、別ホスト構成のほうが向く。

@windymelt
windymelt / coder-battalion.md
Created July 6, 2026 11:14
WindymeltのSubagent構成
name CoderBattalion
description 三層エージェント編成の末端の実装部隊。上位(CoderBrigade)の指揮に忠実に実装を行う。テストや総合的な動作確認は行わない(EvaluatorBrigade が担う)。成果物の一部として必要なコード生成は行ってよいが、テストスイートや品質ゲートの実行はしない。プロジェクト非依存。\n\n<example>\nContext: CoderBrigade が分解したサブタスクを実装させたい。\nuser: "このファイルにこの変更を加えてください"\nassistant: "CoderBattalion を起動し、指示どおりに実装させます。"\n<commentary>\n分解済みサブタスクの忠実な実装は CoderBattalion に委譲する。\n</commentary>\n</example>
tools Read, Edit, Write, Bash, Glob, Grep, ToolSearch, Skill
model haiku
color cyan
memory project

あなたは三層エージェント編成の末端の実装部隊 CoderBattalion です。上位(CoderBrigade)から渡された計画・対象パス・スコープに忠実に従って実装します。あなたは配下を持たず、自身の手で実装するのが責務です。

package dev.capslock.gist.scalacli
object Greeting:
def hello(name: String): String = s"Hello, $name!"
import scala.math.BigInt
/** Common math utilities */
object MathUtils:
@annotation.tailrec
def gcd(a: BigInt, b: BigInt): BigInt =
if b == 0 then a.abs else gcd(b, a % b)
//////////////////////////////////////////////////////////////
// 1. Rational labels : p / q ------------------------------------------------
@windymelt
windymelt / 1.md
Last active May 14, 2025 16:29
Feedback for MCP server in Metals v1.5.3

Metals MCP Server Tools - Debug Report (Debugged with AI Agent)

1. Introduction

This report summarizes the results of an investigation into the behavior of tools provided by the Metals MCP server. The investigation was based on the information about MCP support found in the Metals release notes.

Test Environment:

  • JVM: OpenJDK 24
  • Metals Version: 1.5.3
@windymelt
windymelt / requiem.scala.sc
Created September 14, 2024 00:29
粛聖!! ロリ神レクイエム☆
// DSL
trait 監獄[Repr]:
def 入獄(罪人たち: Seq[(Int, 罪人[String])]): Unit
def 点呼(): Repr
trait 罪人[Repr]:
def 触る(): Repr
def 逮捕()(using 監獄[Repr]): Repr
def ごめんなさい(): Repr
import cats.effect.kernel.Resource
import cats.effect.IO
import cats.data.EitherT
trait Client {
def get(uri: String): IO[String]
}
val client: Resource[IO, Client] = Resource.pure(new {
def get(uri: String): IO[String] = IO.pure("result")
})
@windymelt
windymelt / vector.scala.sc
Created April 2, 2024 13:51
Vector APIを使った
//> using scala 3.4.0
//> using dep "com.outr::scribe::3.13.2"
// run via:
// scala-cli -J --add-modules -J jdk.incubator.vector -J -Xmx16G vector.scala.sc
import jdk.incubator.vector.*
import scribe._
def mult2a(arr: Array[Double]): Array[Double] = arr.map(_ * 1.618)
//> using scala 3.3.0
import java.awt.Desktop
import java.net.URI
if (Desktop.isDesktopSupported) {
Desktop.getDesktop.browse(new URI("https://scala-cli.virtuslab.org/"))
}
//> using scala 3.3.0
//> using dep org.http4s::http4s-ember-server:0.23.23
//> using dep org.http4s::http4s-dsl:0.23.23
import cats.effect._
import com.comcast.ip4s._
import org.http4s.HttpRoutes
import org.http4s._
import org.http4s.dsl.io._
import org.http4s.ember.server._