stringdb-link
AGENTS.md1 starsChanged 4 months agoMITView on GitHub
Shared repository instructions for agentic coding tools working in StringDB-Link. StringDB-Link is a Python FastAPI and MCP server for the STRING protein-protein interaction database. Primary areas: - stringdb_link/ - Python package, FastAPI routes, services, client, models, configuration, and MCP-facing code - tests/ - unit, API, and integration tests - docker/ - Dockerfile and Compose deployment files - docs/superpowers/plans/ - implementation plans for agentic workers - docs/superpowers/specs/ - design specs for agentic workers - Do not revert or overwrite changes you…
We split this AGENTS.md into the rules it gives an agent
18 rules. About 0 are common, 10 are distinctive, and 8 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈10
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 21
Use this file for shared repo-wide agent guidance.
- Distinctive: line 22
Keep CLAUDE.md lean and Claude-specific.
- Very specific: line 23
Prefer Makefile targets over ad hoc commands.
- Very specific: line 24
Use uv.lock as the dependency lock source of truth.
- Distinctive: line 28
Do not revert or overwrite changes you did not make unless explicitly asked.
- Distinctive: line 29
Keep edits scoped to the task and avoid unrelated refactors.
- Distinctive: line 30
Prefer existing code patterns over new abstractions.
- Very specific: line 31
Put tests under tests/; do not create alternate test roots.
- Distinctive: line 32
Use ASCII unless a file already requires non-ASCII content.
- Very specific: line 72
Use uv for dependency management.
- Very specific: line 73
Use modern Python typing: list[str], dict[str, int], str | None.
- Distinctive: line 76
Keep FastAPI route behavior covered by route tests and service behavior covered by unit tests.
- Very specific: line 137
Add a tool, update the README's ## Tools table: tests/unit/test_readme_tools.py asserts the table equals the registered tool surface …
- Very specific: line 139
Do not move operator or reference detail back into the README.
- Distinctive: line 154
Prefer cohesive splits: one module per responsibility, not random partitioning.
- Distinctive: line 155
Keep public facades stable across splits so call sites do not churn.
- Very specific: line 156
If an allowlisted file must grow, update .loc-allowlist explicitly and link the decomposition plan in the commit message.
- Distinctive: line 165
Treat failing checks as real issues unless you have clear evidence otherwise.
≈ “Common” is an estimate: at least 1 in 5 of the 36,368 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
AGENTS.md
Shared repository instructions for agentic coding tools working in StringDB-Link.
Project
StringDB-Link is a Python FastAPI and MCP server for the STRING protein-protein interaction database.
Primary areas:
stringdb_link/- Python package, FastAPI routes, services, client, models, configuration, and MCP-facing codetests/- unit, API, and integration testsdocker/- Dockerfile and Compose deployment filesdocs/superpowers/plans/- implementation plans for agentic workersdocs/superpowers/specs/- design specs for agentic workers
Source Of Truth
- Use this file for shared repo-wide agent guidance.
- Keep
CLAUDE.mdlean and Claude-specific; it should reference this file. - Prefer
Makefiletargets over ad hoc commands. - Use
uv.lockas the dependency lock source of truth.
Working Rules
- Do not revert or overwrite changes you did not make unless explicitly asked.
- Keep edits scoped to the task and avoid unrelated refactors.
- Prefer existing code patterns over new abstractions.
- Put tests under
tests/; do not create alternate test roots. - Use ASCII unless a file already requires non-ASCII content.
- Respect STRING API rate limits; do not bypass the existing client throttling.
- For MCP work, keep public hosted tools research-use scoped and avoid exposing destructive cache operations.
Commands
Required checks before claiming completion:
make ci-local
One-time local setup: make install, then uv run pre-commit install to install the
git hooks (Ruff, mypy, and the per-file line budget).
Useful focused commands:
make installmake lockmake formatmake lintmake lint-fixmake lint-locmake lint-readmemake typecheckmake typecheck-fastmake testmake test-fastmake test-unitmake test-integrationmake test-covmake precommitmake devmake mcp-servemake mcp-serve-httpmake docker-buildmake docker-upmake docker-down
Coding Standards
- Use
uvfor dependency management; do not use directpipinstalls. - Use modern Python typing:
list[str],dict[str, int],str | None. - Format and lint Python with Ruff.
- Type check with mypy strict targeting Python 3.12.
- Keep FastAPI route behavior covered by route tests and service behavior covered by unit tests.
Fleet Deploy Contract
The GeneFoundry fleet controller (strato_v6_docker_npm,
scripts/utils/deployment_preflight.py) deploys and validates
docker/docker-compose.npm.yml, and every service declared there must set
user: "<uid>:<gid>" numerically — this image's own value, read from
docker/Dockerfile (groupadd/useradd), never copied from a sibling
-link repo. The controller's runtime observer proves the effective uid
from /proc, so a symbolic USER app alone is not enough.
user must never appear in the Compose files listed in
container-release.json (docker/docker-compose.yml,
docker/docker-compose.prod.yml) — the shared release gate
(container_release.py validate-compose, ALLOWED_SERVICE_KEYS) forbids it
there. tests/unit/test_deploy_overlay_user.py guards both halves of this
contract, plus expose: ["8000"] in docker/docker-compose.npm.yml (needed
because ports: !reset [] publishes nothing, but the controller's
validate-deployed-overlay gate refuses a rendered model with no expose
entry naming the image's container port).
container-release.json declares deployed_compose_files
(docker/docker-compose.yml, docker/docker-compose.npm.yml — the exact set
Strato deploys, no docker-compose.prod.yml) so that gate checks the file
set the controller actually deploys, not the release-only compose_files.
container-release.yml and container-ci.yml both pin their shared
workflow at genefoundry-router v0.8.5
(31ea81cee5475fc3655c047c63a89739948f99a9) — both must move together,
since both validate container-release.json against the same
ReleaseConfig pydantic schema (extra="forbid"); bumping only one leaves
the other rejecting deployed_compose_files as an unknown field.
Release checklist this repo enforces (see tests/unit/test_version_single_source.py
and tests/api/test_health.py, which assert pyproject.toml's version is the
single source of truth for __version__):
- Bump
versioninpyproject.toml. uv lock(confirm the diff touches only this package's ownversionline).CHANGELOG.md: add## [x.y.z] - YYYY-MM-DD.CITATION.cff(generated bygenefoundry-router'smake citation-write— do not hand-edit beyond a release bump): updateversion:to match, anddate-released:to the release date (no test pins this repo'sdate-releasedto a literal or to the CHANGELOG, but keep it current).- Tag
vx.y.z, then approve thereleaseGitHub Environment gate:gh api repos/berntpopp/stringdb-link/actions/runs/<id>/pending_deployments(it can gate twice;status: waitingis the approval gate, not a slow build).
Documentation Discipline
README.md follows the GeneFoundry README Standard v1 and is machine-checked by
make lint-readme (scripts/check_readme.py, copied verbatim across the fleet). It is
the front door, not the manual: fixed section order, a 200-line hard ceiling, no
hand-typed counts or scores. Reference docs live in docs/:
docs/configuration.md- environment variables and request guardsdocs/deployment.md- transports, entry points, Docker, reverse proxydocs/architecture.md- module layout, REST-to-MCP generation, REST examplesdocs/data.md- STRING sources, caching, licence, citation
Add a tool, update the README's ## Tools table: tests/unit/test_readme_tools.py
asserts the table equals the registered tool surface exactly, and CI fails otherwise.
Do not move operator or reference detail back into the README; extend docs/ instead.
File Size Discipline
Hard cap: 600 lines per Python module in stringdb_link/, server.py, and
mcp_server.py. Enforced by make lint-loc and pre-commit. Tests are exempt.
Why: large modules concentrate complexity, slow type checking, and degrade LLM-assisted refactors because one edit risks unrelated behavior.
How:
- New files MUST stay under 600 lines.
- Existing oversized files are grandfathered in
.loc-allowlistwith their current line count as the ceiling. They may shrink but not grow. - Prefer cohesive splits: one module per responsibility, not random partitioning.
- Keep public facades stable across splits so call sites do not churn.
- If an allowlisted file must grow, update
.loc-allowlistexplicitly and link the decomposition plan in the commit message.
Testing Notes
make testis the fast default.make test-covruns coverage reports.make ci-localruns formatting, linting, line-budget checks, type checking, and tests.- Treat failing checks as real issues unless you have clear evidence otherwise.
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 28,693 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository9 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- ci-failure-triageSkill
- code-quality-reviewSkill
- dependency-cve-sweepSkill
- fastapi-route-changeSkill
- fleet-standard-adoptionSkill
- mcp-tool-changeSkill
- release-readinessSkill
- security-reviewSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

