Documentation over SSH for AI coding agents
A self-hosted SSH server serving 28,000+ documentation pages
as searchable markdown. Your AI agent connects over SSH and uses standard
Unix tools — grep, find, cat —
to search and read docs with the same interface it uses for your code.
Add this to ~/.ssh/config to skip the port and user on every command:
Host docs.erfi.io User docs Port 2222 StrictHostKeyChecking no UserKnownHostsFile /dev/null LogLevel ERROR
Then all commands simplify to ssh docs.erfi.io ...
# OpenCode — saves tools + agent rules $ ssh docs.erfi.io tools > .opencode/tools/docs.ts $ ssh docs.erfi.io agents >> AGENTS.md
$ ssh docs.erfi.io setup | opencode
$ ssh docs.erfi.io "grep -rl 'RLS' /docs/supabase/" $ ssh docs.erfi.io "cat /docs/cloudflare/workers-ai.md" $ ssh docs.erfi.io "find /docs/vercel -name '*.md' | head -20"
ssh docs.erfi.io help # Usage and examples ssh docs.erfi.io sources # List doc sets with file counts ssh docs.erfi.io agents # Output AGENTS.md snippet ssh docs.erfi.io tools # Output OpenCode custom tools ssh docs.erfi.io setup # Interactive setup guide
Custom tools use a search → summary → targeted read workflow. Output capped at 16K chars (~4K tokens) with truncation pointers.
| Approach | Tokens | vs MCP |
|---|---|---|
| docs_search | ~480 | 98% smaller |
| docs_summary | ~200 | n/a |
| docs_grep | ~1,500 | 77% smaller |
| MCP search | ~30,000 | baseline |
Sources refreshed daily at 02:00 UTC. All docs under /docs/{source}/.
$ docker run -d -p 2222:2222 -p 8080:8080 ghcr.io/erfianugrah/docs-ssh:latest $ ssh -p 2222 docs@localhost help
See the source on GitHub for build instructions and production deployment.