keen-code AGENTS.md

Project instructions for Keen Code, a command-line coding agent written in Go and powered by Firebase Genkit for its language-model interactions. They describe its tools, filesystem safeguards, testing, formatting, and commit conventions.

In plain words
What is it for?
Use them when changing the agent’s file tools, filesystem permissions, interactive terminal, language-model client, or Go code, and when preparing a commit.
Why use it?
They keep changes aligned with the project’s architecture and permission rules. They also provide repeatable checks for race conditions, dependencies, formatting, and commit contents.

Instructions file for CodexOpenCode

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/mochow13/keen-code/agents-md
Clone the repo
git clone --depth 1 https://github.com/mochow13/keen-code

Made for: Codex, OpenCode.

Per session 273 This file is loaded in full into every session.
When invoked 273 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00273 $0.00273
Opus 5 $0.00137 $0.00137
Sonnet 5 $0.00055 $0.00055
Haiku 4.5 $0.00027 $0.00027

Measured yesterday against content hash 97e8f02c070b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

keen-code AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

AGENTS.md · 25 lines

What it actually says

Keen Code

CLI-based coding agent powered by AI using Firebase Genkit for LLM interactions.

Important Guidelines

  • Minimal comments only when strictly necessary
  • Test critical paths, not aiming for 100% coverage
  • Always run go test -race ./... after finalising a change
  • Always run go mod tidy after each change
  • Always run gofmt on modified Go files before committing
  • Commit messages should be concise and focus on the key changes with bullet points
  • Commit messages should follow the feat(category): description format
  • Always check both tracked and untracked files for creating the commit message
  • Never add co-authors or made-with AI tags to the commit message

Architecture

  • internal/tools - LLM tools (read_file, write_file, edit_file, glob, grep, bash)
  • internal/filesystem - Guard for safe file access
  • internal/cli/repl - Interactive REPL UI
  • internal/llm - Genkit-based LLM client

Permission System

Guard checks paths before filesystem operations:

  • PermissionGranted - Allowed (working directory)
  • PermissionPending - User approval required (outside working dir)
  • PermissionDenied - Blocked (system paths, .gitignore files)
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 25 lines · 273 tokens per session scan A 97e8f02c070b

Subscribe to this mod's changes

keen-code AGENTS.md is an instructions file published in the GitHub repository mochow13/keen-code (60 stars, last pushed 2d ago), licensed MIT. It adds 273 tokens to every session, about $0.0014 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.