Borrowing it
Nothing to install: this file belongs to shaharia-lab/goai. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/shaharia-lab/goai/main/CLAUDE.mdgit clone --depth 1 https://github.com/shaharia-lab/goaiWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/shaharia-lab/goai/claude-md)<a href="https://agentmods.dev/instructions/shaharia-lab/goai/claude-md"><img src="https://agentmods.dev/badge/instructions/shaharia-lab/goai/claude-md.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.01119 | $0.01119 |
| Opus 5 | $0.00560 | $0.00560 |
| Sonnet 5 | $0.00224 | $0.00224 |
| Haiku 4.5 | $0.00112 | $0.00112 |
Grade A, and why
goai CLAUDE.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 8d 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.
How it starts
The opening of the file, as written. The whole thing — 43 lines — stays where its author put it; the contents beside it link to each section on GitHub.
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Overview
GoAI provides a unified interface over multiple LLM providers, embeddings, vector storage, and a full Model Context Protocol (MCP) client/server implementation (module github.com/shaharia-lab/goai). It is a library — there is no main package; runnable usage lives in _examples/.
The root package (package goai) keeps its source files flat in the repository root, prefixed by concern (llm_*, mcp_*, embedding_*, vector_*, chat_history_*). Additional functionality is being organized into subpackages — place new self-contained subsystems in their own directory/package rather than adding to the root.
Commands
go build ./... # build
go test ./... # run all tests
go test ./... -covermode=atomic -coverprofile=coverage.out # tests with coverage (as CI runs them)
go test -run TestName ./... # run a single test by name
go run _examples/simple_chat.go # run an example
golangci-lint run # lint (CI uses super-linter with VALIDATE_GO)
There is no Makefile. CI (.github/workflows/CI.yaml) runs lint (super-linter), tests + Codecov, then a SonarCloud scan.
Architecture
The package follows a consistent facade + provider-interface pattern in every subsystem: a high-level struct wraps a provider interface, so implementations are swappable and injectable for testing.
- LLM (
llm.go,types.go):LLMRequest(facade) wraps theLLMProviderinterface (GetResponse/GetStreamingResponse). Providers:llm_provider_openai.go,llm_provider_anthropic.go,llm_provider_aws_bedrock.go,llm_provider_gemini.go, plusllm_provider_no_ops.go. Each provider has a matching thin client wrapper (e.g.llm_provider_openai_client.go) that isolates the vendor SDK for mocking. Streaming lives in separate*_streaming.gofiles.NewLLMRequestautomatically wraps the provider in aTracingLLMProvider(decorator pattern,tracing_llm_provider.go) unless already traced. Request options are functional options (WithMaxToken,WithTemperature, etc.) viaNewRequestConfig. - Tools (
tools_provider.go):ToolsProvidersupplies tools to LLM calls either from a local in-process[]Toollist or from an MCPClient— the two are mutually exclusive (adding one blocks the other).ExecuteTooltries local tools first, then falls back to the MCP client. - Embeddings (
embedding.go):EmbeddingServicewraps theEmbeddingProviderinterface; validates input and response. Bedrock provider inembedding_aws_bedrock_provider.go. - Vector storage (
vector_storage.go):VectorStoragefacade wrapsVectorStorageProvider. Postgres/pgvector implementation invector_storage_postgres.go; validation invector_validation.go.chunking.gosplits text for embedding. - Chat history (
chat_history_*.go):ChatHistoryStorageinterface with in-memory and SQLite implementations. - MCP (
mcp_*.go): a complete MCP implementation.- Client:
mcp_client.go(Client+Transportinterface) with two transports —mcp_client_sse.go(HTTP/SSE) andmcp_client_std.go(stdio). - Server:
mcp_server_base.go(BaseServerholds tools/resources/prompts, built withServerConfigOptions likeUseLogger) wrapped by a transport server —NewStdIOServer(mcp_server_stdio.go) orNewSSEServer(mcp_server_sse.go), each with aRun(ctx)loop. Wire protocol types are JSON-RPC 2.0 inmcp_types.go. Seemcp_doc.gofor an end-to-end server example.
- Client:
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.
- 8d ago First seen · 43 lines · 1,119 tokens per session scan A 766f9011fc3e
goai CLAUDE.md is an instructions file published in the GitHub repository shaharia-lab/goai (10 stars, last pushed 5d ago), licensed MIT. It adds 1,119 tokens to every session, about $0.0056 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-31.
Other instructions, from other repositories
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
codex AGENTS.md
AGENTS.md instructions for openai/codex, covering rust/codex-rs, the codex-core crate, code review rules, crate api surface and model visible context.
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, applying the notice (cutover) and fallback chain (never fail the build).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
spec-kit AGENTS.md
AGENTS.md instructions for github/spec-kit, covering agents.md, about spec kit and specify, quickstart — add a new integration in 5 steps, integration architecture and integrationmanifest — file tracking.