code-quality-architecture
Skill345 starsChanged 35 days agoApache-2.0View on GitHub
Use for the cross-cutting design pass on a PR — module boundaries, dependency direction, API surface, and build/test/CI hygiene — across clickhouse-sink-connector's Java modules (sink-connector, sink-connector-lightweight), its Python tools (sink-connector/python), and its Go client (sink-connector-client). Run after the per-language deep checklist, as the last pass in pr-self-review.
2 other projects use a version of this.
Adopted by
Most recently taken up by
- hyperdreamer/pi-webuitheir own version, first seen Nov 8, 2026
- jmfederico/pi-webtheir own version, first seen Oct 8, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 2
- jmfederico/pi-web★ 931same name
- hyperdreamer/pi-webui★ 9same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository17 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- clickhouse-sink-reviewSkill
- code-quality-bashSkill
- code-quality-goSkill
- code-quality-jvmSkill
- code-quality-pythonSkill
- code-quality-sqlSkill
- code-reuse-firstSkill
- code-reuse-reviewSkill
- design-note-debtSkill
- destructive-operation-safetySkill
- mandatory-code-change-validationSkill
- pr-self-reviewSkill
- repro-harness-negative-proofSkill
- sink-connector-mysql-source-of-truthSkill
The file
Files
Architecture & Cross-Language Quality
Overview
Language-specific style lives in code-quality-jvm, code-quality-python,
code-quality-go, code-quality-bash, and code-quality-sql. This skill
is the layer above: does the change fit the module it lives in, does it
leak across a boundary it shouldn't, and does the project's build/test
machinery actually exercise it.
Language Skill Router
| Language | Skill | Primary module(s) in this repo |
| Java | code-quality-jvm | sink-connector, sink-connector-lightweight |
| Python | code-quality-python | sink-connector/python (db_compare, ch_sink_tools, etc.) |
| Go | code-quality-go | sink-connector-client |
| Bash | code-quality-bash | build/CI helper scripts |
| SQL | code-quality-sql | embedded queries, DDL, migrations, test fixtures |
When to Use
- The design/architecture pass at the end of a multi-language PR
- A user asks for "worldclass" structure, module boundaries, or API design
- Reviewing whether a new dependency or module split is justified
Core Principles (portable across languages)
- Dependency direction matches the module graph.
sink-connector-client(Go) should not reach back into JVM-only concerns;sink-connector/pythontooling should depend on stable interfaces (CLI, file formats, DB schemas) rather than reaching into JVM internals. - Single Responsibility at the module and class/package level. A module that mixes CDC-engine concerns with verification-tooling concerns is a sign the split is wrong, not that more branches are needed.
- Program to interfaces, not implementations, at module boundaries especially — a consumer of the offset store or the schema cache should depend on an interface/contract, not a concrete class, so the implementation can change without rippling outward.
- Explicit dependencies, pinned builds. Lockfiles/pinned versions committed for every language toolchain in use; don't let an unpinned transitive dependency change behavior silently between builds.
- Build/test/CI as a gate, not a suggestion. A change that builds
locally but isn't exercised by
mvn -o test(offline, perAGENTS.md), the Python test suite, or the Go module's tests is unverified, not verified-by-absence-of-complaint. - Spec-first still applies at the architecture level — a module
boundary change (new module, new package, new public interface) is
itself a design decision that belongs in
specs/before the code, per the Smart Ralph Protocol.
Review Checklist (architecture pass)
- New dependency added — is it justified over stdlib / an existing
in-repo utility? (See
code-reuse-first.) Is it pinned? - New public API/interface — is it the minimum surface needed, or does it expose internals that should stay package-private/internal?
- Module boundary crossed — does a change in one module (e.g.
sink-connector) require a change in another (sink-connector-client,sink-connector-lightweight) to stay consistent? If so, is that captured by a shared spec rather than duplicated knowledge? - Test pyramid shape — does the change add a unit test at the right level, or only a slow end-to-end test that will be the only thing that ever catches a regression here?
- CI gates —
scripts/review_gates.pyenforces four baseline gates in CI (destructive, merge-stop, license, hygiene); this pass checks what those gates can't: whether the design itself is sound.
Anti-Patterns
God modules that mix CDC-engine, verification-tooling, and CLI concerns · circular dependencies between modules · concrete-type APIs where an interface would do · unpinned dependencies · a module boundary that exists only because of how the code grew, not because of any real separation of concerns.
Sources
General SOLID/clean-architecture principles · this project's own
AGENTS.md (module shape, build rules) and specs/SMART_RALPH_PROTOCOL.md
(spec-first discipline).
Cross-References
pr-self-review, mandatory-code-change-validation, code-reuse-first,
code-reuse-review.
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.

