@srobroek/pi-architecture 0.0.0-stage → 0.11.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md ADDED
@@ -0,0 +1,127 @@
1
+ ## architecture [0.11.1](https://github.com/srobroek/harness-plugins/compare/architecture--v0.11.0...architecture--v0.11.1) (2026-11-23)
2
+
3
+ ### Bug Fixes
4
+
5
+ * **whats-new:** grant MCP tools to the whats-new research agent ([8ae7fe0](https://github.com/srobroek/harness-plugins/commit/8ae7fe05c65e2df2f53ebf944c8f9bd5b7625cf9))
6
+
7
+ ## architecture [0.11.0](https://github.com/srobroek/harness-plugins/compare/architecture--v0.10.0...architecture--v0.11.0) (2026-11-23)
8
+
9
+ ### Features
10
+
11
+ * **agent-plugins:** complete pi agent prompts ([bd49ec4](https://github.com/srobroek/harness-plugins/commit/bd49ec4a310c315702f2ce63789cda4cf345760d))
12
+
13
+ ## architecture [0.10.0](https://github.com/srobroek/harness-plugins/compare/architecture--v0.9.1...architecture--v0.10.0) (2026-11-23)
14
+
15
+ ### Features
16
+
17
+ * **agent-reviewer:** ship agent-only plugins to OMP ([4651445](https://github.com/srobroek/harness-plugins/commit/4651445bd2b5ce547a1bf781c7049acf4f894019))
18
+
19
+ ## architecture [0.9.1](https://github.com/srobroek/harness-plugins/compare/architecture--v0.9.0...architecture--v0.9.1) (2026-11-23)
20
+
21
+ ### Bug Fixes
22
+
23
+ * make every plugin agent's OMP form correct ([96b7bfe](https://github.com/srobroek/harness-plugins/commit/96b7bfea3c35017b34a28f59e81fb059f6c68a24))
24
+
25
+ ## architecture [0.9.0](https://github.com/srobroek/harness-plugins/compare/architecture--v0.8.1...architecture--v0.9.0) (2026-11-22)
26
+
27
+ ### Features
28
+
29
+ * **delivery:** ship the orchestrator agent ([#121](https://github.com/srobroek/harness-plugins/issues/121)) ([53f33c0](https://github.com/srobroek/harness-plugins/commit/53f33c016315732220a7c87066267931ee87f514))
30
+
31
+ ## architecture [0.8.1](https://github.com/srobroek/harness-plugins/compare/architecture--v0.8.0...architecture--v0.8.1) (2026-11-21)
32
+
33
+ ### Bug Fixes
34
+
35
+ * **code-challenge:** close dogfood friction in skill, schema and validation ([043a8b3](https://github.com/srobroek/harness-plugins/commit/043a8b39057ec8fca54d09adebb0532c2154e330))
36
+
37
+ ## architecture [0.8.0](https://github.com/srobroek/harness-plugins/compare/architecture--v0.7.0...architecture--v0.8.0) (2026-11-21)
38
+
39
+ ### Features
40
+
41
+ * **architecture:** give the architect the read-only shell ([0dc1a97](https://github.com/srobroek/harness-plugins/commit/0dc1a9782229c62b254e96bd5624110ff43ad51c))
42
+
43
+ ### Bug Fixes
44
+
45
+ * **architecture:** rebuild with the hardened read-only shell rules ([1d623b8](https://github.com/srobroek/harness-plugins/commit/1d623b88696750f9a4bdacea61feaf45d1f4ed39))
46
+
47
+ # Changelog
48
+
49
+ ## [0.7.0](https://github.com/srobroek/opencode-plugins/compare/architecture--v0.6.0...architecture--v0.7.0) (2026-11-20)
50
+
51
+
52
+ ### Features
53
+
54
+ * **agents:** follow lang skills and the repo engineering doc, report departures ([#267](https://github.com/srobroek/opencode-plugins/issues/267)) ([2c15755](https://github.com/srobroek/opencode-plugins/commit/2c15755d62faed398c8f3ce4747a61d1c92ff00c))
55
+ * **architecture:** allow the aws-guidance skill to architect ([7cbfa12](https://github.com/srobroek/opencode-plugins/commit/7cbfa12f297118f9704e521225cb2c593154030e))
56
+ * **architecture:** allow toolchain skills ([0055f1c](https://github.com/srobroek/opencode-plugins/commit/0055f1c14530c56aee695f212816e2f9bc62d2f4))
57
+ * **architecture:** carry coding-core standards in the architect prompt ([7155a6b](https://github.com/srobroek/opencode-plugins/commit/7155a6bfbe84b7663814329ed8bea1512b19aa23))
58
+ * plugin scan fixes, wider agent access and the plugin-audit plugin ([9c71525](https://github.com/srobroek/opencode-plugins/commit/9c7152559776aaf80cfed9626d78bafdd845fa9a))
59
+ * **plugin-audit:** add plugin_audit_scan tool and plugin-audit skill ([d400433](https://github.com/srobroek/opencode-plugins/commit/d4004330e9a922d8e832b6f3266502141eaea4a3))
60
+
61
+
62
+ ### Refactors
63
+
64
+ * **lib:** one MCP tool grant table for the tools option ([f8cc1d8](https://github.com/srobroek/opencode-plugins/commit/f8cc1d817d62b211b712d1889200f7c91f049c89))
65
+
66
+ ## [0.6.0](https://github.com/srobroek/opencode-plugins/compare/architecture--v0.5.0...architecture--v0.6.0) (2026-11-19)
67
+
68
+
69
+ ### Features
70
+
71
+ * beads, speckit and journeys in Claude Code; translated subagents instead of raw OpenCode agents ([e5fcc23](https://github.com/srobroek/opencode-plugins/commit/e5fcc2338e0846cbebc3370f65826cf2edf137bc))
72
+ * **modes:** debug, refactor and concept agents ([6369b8a](https://github.com/srobroek/opencode-plugins/commit/6369b8ae6c4ca35c664f094b60c28d356cc13298))
73
+ * **safety:** secret_store tool stores a generated or command-issued secret without a shell ([d84a1d2](https://github.com/srobroek/opencode-plugins/commit/d84a1d22b0ff6e72f327fb185c512b2296a80a1e))
74
+
75
+ ## [0.5.0](https://github.com/srobroek/opencode-plugins/compare/architecture--v0.4.0...architecture--v0.5.0) (2026-11-13)
76
+
77
+
78
+ ### Features
79
+
80
+ * **agents:** a tools option that lets read-only and coding agents call allowed MCP tools ([70558c3](https://github.com/srobroek/opencode-plugins/commit/70558c30dc450faec7e6012cdb0f678f1ecd7f01))
81
+
82
+ ## [0.4.0](https://github.com/srobroek/opencode-plugins/compare/architecture--v0.3.0...architecture--v0.4.0) (2026-11-12)
83
+
84
+
85
+ ### Features
86
+
87
+ * **quality:** research-first engineering standards and per-language library standards for every coding agent ([09e8d46](https://github.com/srobroek/opencode-plugins/commit/09e8d461bb2b7654788a588ef6932929ff564d28))
88
+
89
+ ## [0.3.0](https://github.com/srobroek/opencode-plugins/compare/architecture--v0.2.1...architecture--v0.3.0) (2026-11-11)
90
+
91
+
92
+ ### Features
93
+
94
+ * cap every shipped agent with a step limit ([#123](https://github.com/srobroek/opencode-plugins/issues/123)) ([7b3b60f](https://github.com/srobroek/opencode-plugins/commit/7b3b60f84ac4aabcf8d5d649042e26054f79b0f4))
95
+
96
+ ## [0.2.1](https://github.com/srobroek/opencode-plugins/compare/architecture--v0.2.0...architecture--v0.2.1) (2026-10-27)
97
+
98
+
99
+ ### Bug Fixes
100
+
101
+ * **lib:** keep a shipped agent hidden when the host prefills hidden: false ([6156c94](https://github.com/srobroek/opencode-plugins/commit/6156c946f8a5265ff5498bb4062a9d822bbd0555))
102
+
103
+
104
+ ### Performance
105
+
106
+ * **architecture:** drop Code Mode and allow skills by family ([83f757a](https://github.com/srobroek/opencode-plugins/commit/83f757a1a830697ca8010814b49b0af28bf840bb))
107
+ * **architecture:** trigger the router on mapping components and monorepo layout ([fdc250e](https://github.com/srobroek/opencode-plugins/commit/fdc250e3cfcae6607e9d80e5a06d6bb5a1d008e9))
108
+
109
+ ## [0.2.0](https://github.com/srobroek/opencode-plugins/compare/architecture--v0.1.0...architecture--v0.2.0) (2026-10-27)
110
+
111
+
112
+ ### Features
113
+
114
+ * **architecture:** add architecture skills and read-only architect agent ([5e46e6e](https://github.com/srobroek/opencode-plugins/commit/5e46e6e8ea2ecb27e1c1def7db9ba0c3f7a5c4a7))
115
+ * **architecture:** declare the architect model role ([b2dc547](https://github.com/srobroek/opencode-plugins/commit/b2dc5472127b214e0c5d29fcbea653366e3ae2c8))
116
+ * **lib:** carry steps and the model-role header from shipped agent files ([7538ab1](https://github.com/srobroek/opencode-plugins/commit/7538ab1a05b3071564defb2ab11ce356245c3890))
117
+ * **lib:** honour metadata opencode/autoinvoke in shipped SKILL.md files ([881e7df](https://github.com/srobroek/opencode-plugins/commit/881e7df220095d0155b07437e733fdb795d9279b))
118
+ * **lib:** shared review core composed into agents at build time ([d79c79b](https://github.com/srobroek/opencode-plugins/commit/d79c79b48ba09d5770c7586799f856237f3b00af))
119
+ * **model-roles:** tiers derived from the catalog, reviewer tier and one-time classification ([4265016](https://github.com/srobroek/opencode-plugins/commit/42650166140c1fada15bda5066d235fdf5fce327))
120
+
121
+
122
+ ### Performance
123
+
124
+ * **architecture:** route the three architecture skills through one architecture-guide listing entry ([44a463b](https://github.com/srobroek/opencode-plugins/commit/44a463b774d7ed64009869ea7b39d249fde9dfe0))
125
+ * give shipped subagents tool allowlists ([014fffb](https://github.com/srobroek/opencode-plugins/commit/014fffb403fd1363f494af84c63bf93074af6d20))
126
+ * keep shipped agent descriptions under 150 characters ([7023675](https://github.com/srobroek/opencode-plugins/commit/70236752520b0fd02b872ec61510ec1388028778))
127
+ * shorten skill descriptions and hide pure reference skills from the listing ([51841bd](https://github.com/srobroek/opencode-plugins/commit/51841bd68ae7fe809711430fe3430b75b63e81c0))
package/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
package/README.md CHANGED
@@ -1,3 +1,59 @@
1
- # Temporary Holding Version
1
+ # architecture
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Architecture guidance as skills, plus a read-only `architect` subagent.
4
+
5
+ Only `architecture-guide` is listed to the model in OpenCode: it is a router whose body maps each
6
+ situation to the skills below, which set `opencode/autoinvoke: false` and load by id. One listing
7
+ entry instead of one per skill keeps the per-request skills listing short. Claude Code ignores that metadata, so there every skill is listed and triggers directly.
8
+
9
+ | Skill | When |
10
+ | --- | --- |
11
+ | `architecture-top-level` | Choosing or changing top-level directories: `apps/`, `services/`, `functions/`, `workers/`, `libs/`, `packages/`, `schemas/`, `data/`, `infrastructure/`, `tools/`, ... |
12
+ | `architecture-ownership` | Placing libs by architectural role, owner-local assets and data, schemas, generated clients, UI primitives and product agents |
13
+ | `architecture-repositories` | Single-language repository, polyglot monorepo or several repositories; layout by deployable with native workspaces per language, shared contracts with generated clients, task runners and build tools, CI selection, ownership and per-component releases |
14
+ | `architecture-docs-files` | Inferring architecture or stack, or creating durable project knowledge under `docs/` |
15
+
16
+ On omp these were rules the host attached by description. Here they are skills the
17
+ model loads when the description matches; the text is unchanged apart from
18
+ references, which now name the skill (`architecture-docs-files` points at the
19
+ `quality-code-design` skill from the quality plugin).
20
+
21
+ ## Agent
22
+
23
+ `architect` (mode `subagent`, steps 80) designs systems, modules and APIs and turns a hard
24
+ change into an ordered implementation plan. It starts its reply with
25
+ `VERDICT: DESIGNED|PARTIAL|BLOCKED`. Its permissions are an allowlist: every tool
26
+ is denied except read, grep, glob, the `lsp_*` tools, webfetch, websearch, `subagent`
27
+ for `explore`, and the `architecture-*`, `lang-*` and `quality-*` skill families, so
28
+ `edit`, `shell`, Code Mode and other skills are not in its requests. Rules are added after any you configure for an agent
29
+ with the same id, so the read-only boundary holds.
30
+
31
+ The agent was converted from omp with `scripts/convert-agent.ts`. The omp
32
+ `ast_grep`, `lsp` and `find` tools became `grep`, `glob`, an LSP tool when one is
33
+ available, and `explore` in place of `scout`. Spawning `explore` from `architect`
34
+ running as a subagent needs `experimental.subagent_depth` of 2 or more.
35
+
36
+ The agent pins no model. It declares the `strong` model tier through the
37
+ `x-opencode-model-role` request header, so with the model-roles plugin the
38
+ `strong` tier picks its model. Without it the agent inherits the caller's model;
39
+ set `agent.architect.model` in your config to pin one.
40
+
41
+ ## Install
42
+
43
+ ```sh
44
+ opencode plugin add 'github:srobroek/harness-plugins::path:plugins/architecture/opencode'
45
+ ```
46
+ OMP installs the agent and skills from the generated OMP directory:
47
+
48
+ ```sh
49
+ omp plugin install /path/to/harness-plugins/plugins/architecture/omp
50
+ ```
51
+
52
+ Claude Code install the skills, not the agent, from this repository's
53
+ marketplace:
54
+
55
+ ```sh
56
+ claude plugin marketplace add srobroek/harness-plugins
57
+ claude plugin install architecture@harness-plugins
58
+
59
+ ```
@@ -0,0 +1,32 @@
1
+ ---
2
+ name: architect
3
+ description: "Read-only architect for software, system, module, and API design and complex plans. Spawn before nontrivial structural work."
4
+ tools: read, grep, find, ls, subagent
5
+ allowedAgents: scout
6
+ allowNestedSubagents: true
7
+ skills: architecture-guide, architecture-top-level, architecture-ownership, architecture-docs-files, quality-code-design, lang-go, lang-python, lang-rust, lang-typescript, toolchain-guide, aws-guidance
8
+ inheritProjectContext: true
9
+ inheritSkills: true
10
+ ---
11
+
12
+ You are a read-only software architect. Design systems, modules, and APIs, and turn hard changes into implementation plans another agent executes. Investigate and propose; never edit, build, or commit.
13
+
14
+ ## Task
15
+
16
+ 1. Read the brief, constraints, and known paths. Restate the problem in one or two lines.
17
+ 2. Map existing structure before proposing any. Read touched modules, callers, and contracts. Use `grep` and `find` for lookup and discovery. For recon spanning several files or when behavior location is unknown, use `subagent` to ask `scout` when delegation is authorized.
18
+ 3. Name the seams, data shapes, and invariants each boundary protects.
19
+ 4. Design against repository conventions. Consider 2-3 candidates only when the choice is not forced; compare coupling, blast radius, migration cost, reversibility, and failure modes.
20
+ 5. Recommend one design, its tradeoff, reversal condition, ordered implementation steps, and observable checks.
21
+ 6. Cite structural claims with paths and lines. Return unresolved questions with the fact that would resolve them.
22
+
23
+ Pi supplies skills listed in agent frontmatter automatically; do not try to call a skill tool.
24
+
25
+ ## Rules
26
+
27
+ - No edits, writes, builds, tests, migration, or commits.
28
+ - Do not plan Beads graphs or UI behavior.
29
+
30
+ ## Output
31
+
32
+ Begin with `VERDICT: DESIGNED|PARTIAL|BLOCKED`. Include a concise problem restatement, current structure and contracts, candidates only when needed, recommendation, ordered plan, and open questions only when unresolved. Cap at 250 words, or 400 when candidates or open questions are needed.
package/package.json CHANGED
@@ -1,6 +1,35 @@
1
1
  {
2
2
  "name": "@srobroek/pi-architecture",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.11.1",
4
+ "description": "Architecture skills: capability-first top-level layout, ownership boundaries, and durable docs/ project knowledge.",
5
+ "keywords": [
6
+ "pi-package"
7
+ ],
8
+ "license": "Apache-2.0",
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "git+https://github.com/srobroek/harness-plugins.git",
12
+ "directory": "plugins/architecture/pi"
13
+ },
14
+ "files": [
15
+ "CHANGELOG.md",
16
+ "LICENSE",
17
+ "README.md",
18
+ "agents",
19
+ "skills"
20
+ ],
21
+ "publishConfig": {
22
+ "access": "public",
23
+ "provenance": true
24
+ },
25
+ "pi": {
26
+ "skills": [
27
+ "./skills"
28
+ ],
29
+ "subagents": {
30
+ "agents": [
31
+ "./agents"
32
+ ]
33
+ }
34
+ }
35
+ }
@@ -0,0 +1,23 @@
1
+ ---
2
+ name: architecture-docs-files
3
+ description: Use when inferring a project's architecture or stack, or when creating durable project knowledge files under docs/.
4
+ metadata:
5
+ opencode/autoinvoke: false
6
+ ---
7
+
8
+ Store durable project knowledge under `docs/` and read those files before
9
+ inferring architecture or stack from generated files.
10
+
11
+ Preferred files:
12
+
13
+ - `docs/architecture.md` for system shape, boundaries, runtime topology, and important flows.
14
+ - `docs/stack.md` for languages, package managers, frameworks, infrastructure, data stores, and quality tools.
15
+ - For durable architectural decisions, follow the `quality-code-design` skill's `references/lifecycle.md` (Durable decisions), which says when to record one and where.
16
+ - `docs/engineering.md` for the agent-readable engineering doc, linked from `AGENTS.md` and read before work in the repo. Sections: stack (languages, toolchain versions, frameworks, key libraries and why; link `docs/stack.md` instead of copying it when that file exists), layout and dependency direction, standards and approved departures with reasons, and how to build, test and lint, plus repo conventions and local workflows.
17
+ - Keep it current: a change that alters the stack (a new or removed dependency, a toolchain bump, a new crate or module, a new tool or a departure) updates it in the same PR, and a reviewer treats a stale doc as a finding. The `quality-code-policy` skill states the rule.
18
+ - `docs/operations.md` for deployment, hosting, secrets, monitoring, and runbooks.
19
+ - `docs/product.md` for user, domain, and product behavior that is not already owned by a spec.
20
+
21
+ When one of these files is missing and the task needs the information, create
22
+ the smallest useful file instead of embedding the knowledge in agent context
23
+ files.
@@ -0,0 +1,17 @@
1
+ ---
2
+ name: architecture-guide
3
+ description: "Load for a project's architecture or stack: map components, plan top-level dirs or monorepo layout, write docs/ files."
4
+ ---
5
+
6
+ # Architecture guide
7
+
8
+ This guide only routes. Before you answer or act, load the matching skill with the skill
9
+ tool, by id, in this same turn, and every other row the task spans. Answer from the loaded
10
+ skill, not from this table.
11
+
12
+ | Situation | Load skill |
13
+ | --- | --- |
14
+ | Inferring a project's architecture or stack, or creating durable knowledge files under `docs/` | `architecture-docs-files` |
15
+ | Choosing or changing top-level directories or a capability-first layout | `architecture-top-level` |
16
+ | Choosing single-language, polyglot monorepo or several repositories; laying out, building, releasing or running CI for a repository with several languages | `architecture-repositories` |
17
+ | Placing libs, owner-local assets, data, schemas, generated clients or UI primitives | `architecture-ownership` |
@@ -0,0 +1,44 @@
1
+ ---
2
+ name: architecture-ownership
3
+ description: Use when placing libs, owner-local assets, data, schemas, generated clients or UI primitives in an ownership layout.
4
+ metadata:
5
+ opencode/autoinvoke: false
6
+ ---
7
+
8
+ Keep `libs/` organized by architectural role: `domain`, `application`,
9
+ `adapters`, `config`, `testing`, `ui`, and `types`.
10
+
11
+ `libs/domain` is pure domain logic. It must not import network, database,
12
+ filesystem, framework, or cloud SDK dependencies.
13
+
14
+ Keep components local to an app. Move shared primitives and design-system code
15
+ to `libs/ui` when a shared library reduces present total complexity; consumer
16
+ count alone decides nothing. Shared UI code
17
+ should be more stable than app-local components: use typed props, documented
18
+ variants, and reusable accessibility behavior.
19
+
20
+ Use owner-local folders for owned assets:
21
+
22
+ - service data under `services/*/data`
23
+ - service contracts under `services/*/contracts`
24
+ - prompts and evals under the owning service or library
25
+
26
+ Use root `schemas/` only for shared or public contracts. Generated clients live
27
+ with consumers or in independently versioned packages.
28
+
29
+ AI/product agents are owned by services or libraries. Do not create a root
30
+ `agents/` directory for product code.
31
+
32
+ ## Data assets
33
+
34
+ Use this for data ownership, database assets, migrations, queries, seeds,
35
+ fixtures, datasets, pipelines, notebooks, warehouses, and analytics material.
36
+
37
+ Use root `data/` only for shared assets where no single owner exists. Otherwise
38
+ keep data with its owning app, service, worker, or library.
39
+
40
+ Database-specific assets live under the owner's `data/database/` folder, one
41
+ folder per asset kind.
42
+
43
+ Keep notebooks and exploratory data close to the owning domain unless the
44
+ project deliberately maintains a shared data science workspace.
@@ -0,0 +1,99 @@
1
+ ---
2
+ name: architecture-repositories
3
+ description: Use when choosing single-language, polyglot monorepo or polyrepo, or laying out a repository with several languages.
4
+ metadata:
5
+ opencode/autoinvoke: false
6
+ ---
7
+
8
+ # Single-language, polyglot and multi-repository layouts
9
+
10
+ Checked 2026-11-12. Directory names follow `architecture-top-level`; contract and generated-client placement follows `architecture-ownership`.
11
+
12
+ ## Choose the boundary
13
+
14
+ Repository, workspace, deployment and release boundaries are separate decisions. Draw each by deployment, ownership and access, not by language.
15
+
16
+ | Criterion | One language, one repository | Polyglot monorepo | Several repositories |
17
+ | --- | --- | --- | --- |
18
+ | Deployables and cadence | One product or one ecosystem | Independent deployables that keep their own release cadence | Strong operational or release autonomy |
19
+ | Contracts and atomic change | Native package interfaces | Contract and consumer changes land in one pull request | Published contracts that rarely change |
20
+ | Ownership | One small, cohesive team | Shared governance with ownership per directory | Autonomous teams with little coordination |
21
+ | CI and tooling cost | Lowest | Needs selective jobs and caching as coupling grows | Smaller pipelines, but platform setup repeated in each repository |
22
+ | Access control | One trust level | Everyone may read everything | Source visibility must differ |
23
+ | Cross-cutting change | Easy | Atomic in source; deployment still rolls out per service | Coordinated pull requests and staged compatibility |
24
+
25
+ Default for a TypeScript web app with Python Lambda functions that share contracts and owners: one polyglot monorepo, laid out by deployable, with native workspaces per language and an independent deploy pipeline per deployable. Choose separate repositories when source access or team autonomy requires it.
26
+
27
+ ## Lay out by deployable
28
+
29
+ ```text
30
+ apps/web/ TypeScript (bun workspace member)
31
+ functions/aws-lambda/orders/ Python (uv project or workspace member)
32
+ functions/aws-lambda/billing/
33
+ services/api/ long-lived backend deployable
34
+ libs/ internal shared code by role, per language
35
+ packages/api-ts/ packages/api-python/ generated clients, when versioned independently
36
+ schemas/ shared contracts: OpenAPI, protobuf (buf.yaml), JSON Schema
37
+ infrastructure/<stack>/ shared CDK or Terraform; deployable-specific IaC stays with the deployable
38
+ tools/ scripts/ docs/
39
+ ```
40
+
41
+ - Organize by deployable, never by a top-level `typescript/` and `python/` split.
42
+ - Each language keeps its native workspace: bun (or pnpm, not both) for JavaScript, uv for Python, a Cargo workspace for Rust; bun, uv and Cargo select members by glob. Go starts with one module; a `go.work` file, which lists module directories with `use`, is for local development across several modules, and CI checks each module with `GOWORK=off`.
43
+ - Keep one authoritative lockfile per dependency-resolution domain and install it frozen in CI. A uv workspace resolves all members together; give a Lambda function its own project and `uv.lock` when its dependencies conflict with the others or must stay minimal.
44
+ - Package each Lambda function from its own dependency closure (ZIP or image), never from the shared development environment. Build native wheels for the Lambda architecture, and test the packaged artifact on its own: a workspace does not stop one member from importing another member's undeclared dependency.
45
+ - Build container images with a per-service context; use named or pruned contexts when a service needs a shared package or the root lockfile.
46
+ - Format and lint with each language's own tools (Biome or ESLint, Ruff and a type checker, `gofmt`, rustfmt and Clippy, `terraform fmt`). One shared `prek` or pre-commit config routes hooks by file type; `.editorconfig` covers whitespace.
47
+
48
+ ## Share contracts, not code
49
+
50
+ - Keep the contract source in `schemas/` (or the owning service's `contracts/`): OpenAPI for HTTP, protobuf with Buf v2 configuration for RPC, JSON Schema for events and files. One authoritative contract per interface; do not maintain the same model in three languages by hand. The API style choice is in `toolchain-api`.
51
+ - Generate a native client per language into its consumer or a versioned package. Pin generator versions and options. Commit the output; in CI, regenerate and fail when `git diff --exit-code` reports changes or `git status --porcelain -- <generated dirs>` shows new files. Never hand-edit generated files.
52
+ - A contract change selects every consumer's checks.
53
+ - Never import across language or package boundaries through relative paths or path hacks.
54
+
55
+ ## Run tasks and builds
56
+
57
+ | Need | Default | Graduate to | Notes |
58
+ | --- | --- | --- | --- |
59
+ | Tool versions and one task entrypoint | `mise` (monorepo tasks with explicit config roots) or `just` / Task over native commands | - | `mise` artifact caching is experimental; do not treat it as a build cache |
60
+ | Cross-language task graph with caching | - | moon 2 (Bun, Node, Go and Rust fully integrated; Python partial) or Nx 24 with the community Python and Go plugins | Validate the Python integration before relying on it |
61
+ | JavaScript-heavy repository | Turborepo 2 | - | It discovers `package.json` workspaces only; non-JS tasks are wrapped, not modelled |
62
+ | Python-heavy repository with fine-grained packaging | - | Pants 2 (dependency inference, hermetic runs, Lambda packaging) | Check JS and framework support before adopting it |
63
+ | Hermetic builds and remote execution at scale | - | Bazel 9 with `rules_python`, `rules_go`, `rules_js`; Buck2 | Pays off only with dedicated build engineering; pin rules and toolchains |
64
+
65
+ Keep one thin orchestration entrypoint. Do not rebuild every ecosystem's dependency handling inside another language's tool.
66
+
67
+ ## CI, ownership and releases
68
+
69
+ - Select jobs by what changed: start with path filters (`dorny/paths-filter`, which supports matrices and `merge_group`), and move to moon or Nx affected graphs when shared libraries make path filters fragile. Inputs include contracts, shared libraries, lockfiles and CI configuration, not only the changed directory.
70
+ - Always start the required workflow. Run language or component jobs conditionally, then finish with an always-running gate job that fails on any failed or skipped-by-mistake job. Path-filtering a required workflow out leaves its check pending, and merge queues need the `merge_group` trigger.
71
+ - Cache downloads separately from build outputs. Key build caches on sources, contracts, lockfiles, toolchain versions and flags; untrusted pull requests never write to shared caches.
72
+ - CODEOWNERS per deployable, plus `schemas/`, `infrastructure/` and CI configuration. Ownership routes review; it does not hide source.
73
+ - Release each deployable or package on its own with release-please manifest mode (a release type per path, component-prefixed tags). Link versions only for components that ship together on purpose. Changesets is npm-oriented and needs adapters for Python or Go; `semantic-release-monorepo` is a community extension to validate before use. Deploying stays a separate pipeline step.
74
+
75
+ ## Avoid
76
+
77
+ - Copying models or helpers between languages instead of generating from one contract.
78
+ - One giant CI job that builds and tests every language on every change.
79
+ - Generated code without a drift check, or with unpinned generators.
80
+ - Forcing incompatible Lambda functions into one Python resolution.
81
+ - One language's tool orchestrating everything badly.
82
+
83
+ ## Sources
84
+
85
+ - Bun workspaces: https://bun.sh/docs/pm/workspaces
86
+ - uv workspaces: https://docs.astral.sh/uv/concepts/projects/workspaces/
87
+ - Go workspaces: https://go.dev/doc/tutorial/workspaces
88
+ - Cargo workspaces: https://doc.rust-lang.org/cargo/reference/workspaces.html
89
+ - Buf v2 configuration: https://buf.build/docs/configuration/v2/buf-yaml/
90
+ - Lambda Python packaging: https://docs.aws.amazon.com/lambda/latest/dg/python-package.html
91
+ - Docker build contexts: https://docs.docker.com/build/building/context/
92
+ - mise monorepo tasks: https://mise.jdx.dev/tasks/monorepo.html
93
+ - moon: https://moonrepo.dev/docs
94
+ - Nx affected: https://nx.dev/docs/features/ci-features/affected
95
+ - Turborepo repository structure: https://turborepo.com/docs/crafting-your-repository/structuring-a-repository
96
+ - Pants: https://www.pantsbuild.org/stable/docs/introduction/welcome-to-pants
97
+ - Bazel: https://bazel.build/about/intro
98
+ - GitHub required checks with path filters: https://docs.github.com/en/pull-requests/how-tos/merge-and-close-pull-requests/troubleshooting-required-status-checks
99
+ - release-please manifest mode: https://github.com/googleapis/release-please/blob/main/docs/manifest-releaser.md
@@ -0,0 +1,27 @@
1
+ ---
2
+ name: architecture-top-level
3
+ description: Use when choosing or changing a repository's top-level directories or its capability-first layout.
4
+ metadata:
5
+ opencode/autoinvoke: false
6
+ ---
7
+
8
+ Prefer these top-level directories when the project shape needs them:
9
+
10
+ - `apps/` for user-facing surfaces: web, admin, mobile, desktop, marketing, and docs.
11
+ - `services/` for long-lived backend deployables: API, GraphQL, RPC, webhooks, auth, billing, and notifications.
12
+ - `functions/` for serverless handlers, nested by platform such as `aws-lambda` or `cloudflare`.
13
+ - `workers/` for background jobs, queues, schedulers, and consumers, nested by platform.
14
+ - `libs/` for internal shared code by architectural role.
15
+ - `packages/` only for externally published or independently versioned packages.
16
+ - `schemas/` for shared or public contracts.
17
+ - `data/` for shared data assets where no single owner exists.
18
+ - `infrastructure/` for shared platform and IaC.
19
+ - `tools/` for maintained CLIs, generators, MCP implementations, and reusable developer tooling.
20
+ - `scripts/` for thin automation.
21
+ - `docs/`, `specs/`, `tests/`, `assets/`, and `archive/` for cross-cutting project material.
22
+
23
+ Keep non-shared deployment configuration with the owning deployable rather than
24
+ in root `infrastructure/`.
25
+
26
+ Keep generated outputs and caches out of source unless the project explicitly
27
+ tracks them.