githits-cli AGENTS.md

Project instructions for GitHits, a service and command-line tool for searching code examples. They describe how an AI coding assistant should plan, design, test, and document changes.

In plain words
What is it for?
Use them when working on the GitHits backend, including architecture decisions, development planning, testing, dependency design, and code-example search.
Why use it?
They give the assistant consistent rules for maintainable code and prevent it from making unverified changes too quickly. They also explain when to consult more detailed project documentation.

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/githits-com/githits-cli/agents-md
Clone the repo
git clone --depth 1 https://github.com/githits-com/githits-cli

Made for: Codex, OpenCode.

Per session 3,113 This file is loaded in full into every session.
When invoked 3,113 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.03113 $0.03113
Opus 5 $0.01556 $0.01556
Sonnet 5 $0.00623 $0.00623
Haiku 4.5 $0.00311 $0.00311

Measured 2d ago against content hash 61087b577422, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

githits-cli 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 2d ago.

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.

AGENTS.md · 213 lines

How it starts

The opening of the file, as written. The whole thing — 213 lines — stays where its author put it; the contents beside it link to each section on GitHub.

githits Agent Instructions

GitHits companion for the backend - provides MCP server and command-line tools for code example search.

We strive to produce high quality code that can easily be maintained. Focus is on long term development speed, not on quick wins.

This document contains the most important instructions that need to be kept always in context.

General

  • Use very concise output and neutral tone
  • If unclear about anything or stuck, please stop and ask for clarification
  • Always verify assumptions
  • Don't jump into coding, plan and assess the impact first
  • Read more detailed documentation when needed
  • Remember your MCP tools and use them when needed

Architecture

Philosophy: "Create architecture that is performant and easy to test"

  • Focus on building structures that are performant and scalable
  • Build architecture that is easy to test
  • Isolate functionality into sensible small modules
  • Follow single responsibility principle
  • Prefer public helper modules to lots of private methods
  • Use dependency injection for external services (REST client, etc.)
  • Do not eagerly validate network/proxy/environment configuration while constructing command dependencies when the command has local-only or no-network paths. Defer validation until the first network operation and add regression tests for malformed env values on local paths.
  • For MCP/agent-facing tools, avoid coupled optional flags and default-true booleans. Design schemas for real agent calls, including empty strings, empty arrays, and explicit false values.
  • For MCP tool discovery, treat the tool name plus the first 80 description characters as a standalone selection surface. A verified Claude Desktop connector session exposed only that context during unguided tool selection; connector descriptions and MCP server instructions did not reach it. Lead with the natural user question and the tool's distinct job, treat 80 characters as a ceiling rather than a target, and keep registry counts/lists, argument mechanics, and follow-up routing after that boundary. Do not rely on neighboring tools for context. Add first-80 contract tests and run descriptor-only agent evals for description changes.
  • For GraphQL/API-backed tools, treat minimal data fetching as part of the tool contract. Before adding or changing selected fields, compare the query against every consumer (text, verbose, JSON, MCP, CLI, and internal callers), use conditional fields or separate queries for mode-specific data, and add tests that assert the wire variables/selections for compact and detailed modes.

Read the full file on GitHub · 213 lines

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. 2d ago First seen · 213 lines · 3,113 tokens per session scan A 61087b577422

Subscribe to this mod's changes

githits-cli AGENTS.md is an instructions file published in the GitHub repository githits-com/githits-cli (87 stars, last pushed 3d ago), licensed Apache-2.0. It adds 3,113 tokens to every session, about $0.0156 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.