@webex/helper-image 3.12.0-webex-services-ready.4 → 3.13.0

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.
@@ -0,0 +1,328 @@
1
+ {
2
+ "manifest_version": 1,
3
+ "repository": {
4
+ "name": "@webex/helper-image",
5
+ "purpose": "A Webex JavaScript SDK helper package that reads EXIF orientation onto image files, resolves their MIME type, and measures and thumbnails them through separate Node and browser implementations.",
6
+ "category": "cat2-legacy",
7
+ "primary_languages": [
8
+ "javascript"
9
+ ]
10
+ },
11
+ "topology": "Single-repo",
12
+ "commands": {
13
+ "install": {
14
+ "command": "yarn install",
15
+ "source_file": "package.json",
16
+ "role": "install",
17
+ "verified_at": "2026-09-28T13:42:25Z"
18
+ },
19
+ "compile": "[NEEDS HUMAN INPUT] -- no standalone compile step exists: the sources are JavaScript transpiled by Babel as part of build:src, and package.json declares no typecheck or compile-only target.",
20
+ "build": {
21
+ "command": "yarn workspace @webex/helper-image build",
22
+ "source_file": "package.json",
23
+ "role": "package",
24
+ "verified_at": "2026-09-28T13:42:25Z"
25
+ },
26
+ "unit-test": {
27
+ "command": "yarn workspace @webex/helper-image test:unit",
28
+ "source_file": "package.json",
29
+ "role": "unit-test",
30
+ "verified_at": "2026-09-28T13:42:25Z"
31
+ },
32
+ "browser-test": {
33
+ "command": "yarn workspace @webex/helper-image test:browser",
34
+ "source_file": "package.json",
35
+ "role": "other",
36
+ "verified_at": "2026-09-28T13:42:25Z"
37
+ },
38
+ "lint": {
39
+ "command": "yarn workspace @webex/helper-image test:style",
40
+ "source_file": "package.json",
41
+ "role": "lint",
42
+ "verified_at": "2026-09-28T13:42:25Z"
43
+ },
44
+ "deploy": {
45
+ "command": "yarn workspace @webex/helper-image deploy:npm",
46
+ "source_file": "package.json",
47
+ "role": "deploy",
48
+ "verified_at": "2026-09-28T13:42:25Z"
49
+ },
50
+ "test": {
51
+ "command": "yarn workspace @webex/helper-image test",
52
+ "source_file": "package.json",
53
+ "role": "other",
54
+ "verified_at": "2026-09-28T13:42:25Z"
55
+ }
56
+ },
57
+ "toolchain": [
58
+ {
59
+ "name": "node",
60
+ "version": ">=18",
61
+ "origin": "repo-config",
62
+ "source_file": "package.json"
63
+ }
64
+ ],
65
+ "tests": {
66
+ "unit": {
67
+ "command_ref": "unit-test",
68
+ "dir": "test/unit/spec",
69
+ "framework": "Mocha with chai assertions via @webex/test-helper-chai and Sinon stubs, executed by @webex/legacy-tools. The same spec directory also runs under Karma in a real browser through the browser-test command, which is the only way the browserOnly cases in test/unit/spec/index.js execute; Chrome and Firefox are that runner's defaults and it also needs the fixture server that serves the test image. There is no separate integration or end-to-end suite in this package."
70
+ }
71
+ },
72
+ "quality_gates": {
73
+ "code_coverage": {
74
+ "origin": "none",
75
+ "declared_by": "rarajes2@cisco.com"
76
+ }
77
+ },
78
+ "modules": [
79
+ {
80
+ "path": "src/",
81
+ "coverage_status": "Partial",
82
+ "coverage_evidence": "Canonical spec generated from the complete committed source and its unit suite. The public surface, dual-runtime split, invariants and failure modes are backed by file evidence. No characterization baseline exists yet: the only suite is test/unit/spec/index.js, whose readExifData cases are disabled with xdescribe, so the EXIF parsing path is unpinned and a characterization baseline is required before risky modification.",
83
+ "canonical_spec": "src/docs/README.md",
84
+ "contracts": {
85
+ "provides": [
86
+ "helper-image-package-api",
87
+ "image-thumbnail-png"
88
+ ],
89
+ "requires": [
90
+ "http-core-detect",
91
+ "exifr-parse",
92
+ "graphicsmagick-cli",
93
+ "browser-image-apis"
94
+ ]
95
+ },
96
+ "last_assessed": "2026-09-28",
97
+ "section_profile": {
98
+ "has_ui": false,
99
+ "crosses_service_boundaries": false,
100
+ "enforces_domain_rules": true,
101
+ "is_concurrent_async": true,
102
+ "owns_persistence": false,
103
+ "returns_caller_errors": true,
104
+ "has_design_tradeoff": true,
105
+ "stateful_transitions": false,
106
+ "exposes_wire_protocol": true,
107
+ "ui_multi_screen": false,
108
+ "large_data_model": false,
109
+ "has_tiers": false,
110
+ "module_specific_conventions": true,
111
+ "published_package": true,
112
+ "embedded_in_host": false,
113
+ "holds_client_state": false,
114
+ "resolved_by": "claude-opus-5",
115
+ "resolved_at": "2026-09-28T13:42:25Z",
116
+ "has_submodules": false,
117
+ "has_submodules_computed_by": "scripts/module_tree.py",
118
+ "has_submodules_computed_at": "2026-09-28T13:45:06Z"
119
+ }
120
+ }
121
+ ],
122
+ "contract_catalog": {
123
+ "index_path": "docs/architecture.md",
124
+ "definitions": {
125
+ "helper-image-package-api": {
126
+ "kind": "sdk",
127
+ "publication": "published",
128
+ "source_kind": "repository-path",
129
+ "source": "package.json",
130
+ "summary": "Published package export surface. package.json declares the entry points (main, devMain) and the browser field that substitutes the browser implementation of processImage; src/index.js declares the four exported functions updateImageOrientation, readExifData, processImage and detectFileType. The package ships no .d.ts or API report, so these two declarations together are the ecosystem-native contract."
131
+ },
132
+ "image-thumbnail-png": {
133
+ "kind": "file",
134
+ "publication": "published",
135
+ "source_kind": "repository-path",
136
+ "source": "src/process-image.js",
137
+ "summary": "The [thumbnail, fileDimensions, thumbnailDimensions] triple returned by processImage, whose thumbnail is PNG-encoded in both runtimes and whose orientation semantics follow EXIF values 1 through 8."
138
+ },
139
+ "http-core-detect": {
140
+ "kind": "sdk",
141
+ "publication": "internal",
142
+ "source_kind": "external",
143
+ "source": "@webex/http-core package export: detect",
144
+ "summary": "Magic-byte MIME sniffing used by detectFileType when a file carries neither type nor mimeType. Runs locally with no network call and rejects anything that is not a Blob, ArrayBuffer or Uint8Array."
145
+ },
146
+ "exifr-parse": {
147
+ "kind": "sdk",
148
+ "publication": "internal",
149
+ "source_kind": "external",
150
+ "source": "exifr/dist/lite.umd package export: parse",
151
+ "summary": "EXIF tag reader used by readExifData to obtain Orientation, ExifImageHeight and ExifImageWidth from JPEG bytes."
152
+ },
153
+ "graphicsmagick-cli": {
154
+ "kind": "cli",
155
+ "publication": "internal",
156
+ "source_kind": "external",
157
+ "source": "gm npm package invoking the host GraphicsMagick or ImageMagick binary",
158
+ "summary": "Host image toolchain the Node implementation shells out to for size measurement and thumbnail generation. Its absence is detected through an EPIPE error string and degrades to an undefined result rather than a rejection."
159
+ },
160
+ "browser-image-apis": {
161
+ "kind": "sdk",
162
+ "publication": "internal",
163
+ "source_kind": "external",
164
+ "source": "DOM platform APIs: FileReader, Blob, URL.createObjectURL, Image, HTMLCanvasElement, atob",
165
+ "summary": "Browser platform surface the browser implementation and updateImageOrientation depend on for byte reading, decoding, canvas rasterization and base64 conversion."
166
+ }
167
+ }
168
+ },
169
+ "spec_source_policy": {
170
+ "mode": "keep-separate",
171
+ "decided_by": "rarajes2@cisco.com",
172
+ "decided_at": "2026-09-28T13:42:25Z",
173
+ "decision_record": ".generated/sdd/bootstrap-questionnaire.md"
174
+ },
175
+ "spec_sources": [
176
+ {
177
+ "path": "README.md",
178
+ "scope": "repo",
179
+ "role": "reference-only",
180
+ "canonical": false,
181
+ "use_by_agents": "context-only",
182
+ "post_migration_action": "retain",
183
+ "deletion_status": "not-applicable",
184
+ "notes": "Consumer-facing npm README in standard-readme form. Left byte-for-byte unchanged under keep-separate and used as context only. It documents updateImageOrientation, readExifData and orient, omits processImage and detectFileType, and presents the module-internal orient as if it were a package export; the canonical module spec states the real boundary."
185
+ }
186
+ ],
187
+ "spec_policy": {
188
+ "require_what_and_why": true,
189
+ "require_provenance": true,
190
+ "protected_specs": [
191
+ "src/docs/README.md"
192
+ ]
193
+ },
194
+ "validation": {
195
+ "generator_runtime": "claude-opus-5",
196
+ "generator_model": "claude-opus-5",
197
+ "generator_runtime_source": "invocation-input",
198
+ "minimum_independence": "different-runtime",
199
+ "blocking_severities": [
200
+ "Blocking"
201
+ ],
202
+ "validator_runtime": "current-session",
203
+ "validator_runtime_source": "invocation-input",
204
+ "runtime_fallback_tier": "different-runtime"
205
+ },
206
+ "layout": {
207
+ "sdd_root": ".sdd",
208
+ "docs_root": "docs",
209
+ "agent_entry_path": "AGENTS.md",
210
+ "standing_docs_root": "docs",
211
+ "spec_index_path": "docs/specs/README.md",
212
+ "module_docs_strategy": "source-local",
213
+ "module_docs_relative_path": "docs/README.md",
214
+ "module_docs_decision": {
215
+ "basis": "repo-standards-default",
216
+ "reason": "The package holds no module-local documentation folder or competing docs convention, so the source-local default resolves without collision: the single module at src/ takes src/docs/README.md.",
217
+ "decided_by": "claude-opus-5",
218
+ "decided_at": "2026-09-28T13:42:25Z"
219
+ },
220
+ "repo_context_decision": {
221
+ "path": ".repo-context.json",
222
+ "schema_path": "schemas/repo-context.schema.json",
223
+ "action": "create",
224
+ "schema_action": "create",
225
+ "reason": "Neither target exists in the package. The schemas/ directory is present but empty, so both the context and its schema are created from the Repo Standards snapshot rather than reused.",
226
+ "decided_by": "claude-opus-5",
227
+ "decided_at": "2026-09-28T13:42:25Z"
228
+ },
229
+ "artifact_decisions": [
230
+ {
231
+ "path": "docs/service.md",
232
+ "action": "omit",
233
+ "reason": "Not a deployable service. package.json publishes a library to npm and its only release command is deploy:npm; there is no runtime, deployment descriptor or service entry point.",
234
+ "decided_by": "claude-opus-5",
235
+ "decided_at": "2026-09-28T13:42:25Z"
236
+ },
237
+ {
238
+ "path": "mkdocs.yml",
239
+ "action": "omit",
240
+ "reason": "Absent and not selected. The package publishes no documentation site; API reference for the SDK is generated at the workspace level, and no package in the workspace carries an mkdocs configuration.",
241
+ "decided_by": "claude-opus-5",
242
+ "decided_at": "2026-09-28T13:42:25Z"
243
+ },
244
+ {
245
+ "path": "api-specs/openapi.yaml",
246
+ "action": "omit",
247
+ "reason": "Absent and not applicable. The published surface is an ecosystem-native JavaScript package export surface declared in src/index.js and package.json; the package owns no HTTP route and makes no network call.",
248
+ "decided_by": "claude-opus-5",
249
+ "decided_at": "2026-09-28T13:42:25Z"
250
+ },
251
+ {
252
+ "path": "SECURITY.md",
253
+ "action": "omit",
254
+ "reason": "Absent and not selected. Security reporting is owned at the workspace level, not per package; no @webex/helper-* package carries a package-level security policy.",
255
+ "decided_by": "claude-opus-5",
256
+ "decided_at": "2026-09-28T13:42:25Z"
257
+ },
258
+ {
259
+ "path": "CONTRIBUTING.md",
260
+ "action": "omit",
261
+ "reason": "Absent and not selected. README.md already links contributors to the workspace-level CONTRIBUTING guide, so a package-level copy would create a second authority.",
262
+ "decided_by": "claude-opus-5",
263
+ "decided_at": "2026-09-28T13:42:25Z"
264
+ },
265
+ {
266
+ "path": "CHANGELOG.md",
267
+ "action": "omit",
268
+ "reason": "Absent and not selected. Release notes and version bumps are produced at the workspace level rather than per package; the package declares no changelog tooling.",
269
+ "decided_by": "claude-opus-5",
270
+ "decided_at": "2026-09-28T13:42:25Z"
271
+ },
272
+ {
273
+ "path": "CTO_CHECKLIST.yml",
274
+ "action": "omit",
275
+ "reason": "Absent and not selected. The checklist pair applies to a deployable service, and this package is a published library with no deployment surface.",
276
+ "decided_by": "claude-opus-5",
277
+ "decided_at": "2026-09-28T13:42:25Z"
278
+ },
279
+ {
280
+ "path": "schemas/cto-checklist.schema.json",
281
+ "action": "omit",
282
+ "reason": "Absent and not selected. It is selected only together with CTO_CHECKLIST.yml, which is omitted for this non-deployable library.",
283
+ "decided_by": "claude-opus-5",
284
+ "decided_at": "2026-09-28T13:42:25Z"
285
+ }
286
+ ],
287
+ "template_roots": {
288
+ "canonical": ".sdd/templates/repo-standards"
289
+ },
290
+ "repo_skills_root": ".sdd/skills",
291
+ "contract_index_path": "docs/architecture.md"
292
+ },
293
+ "coverage_ratchet": {
294
+ "enabled": true
295
+ },
296
+ "substrate": {
297
+ "source": "WebexTools/repo-standards",
298
+ "consumed": [
299
+ "lint config inherited from @webex/eslint-config-legacy via .eslintrc.js",
300
+ "Babel config inherited from @webex/babel-config-legacy via babel.config.js",
301
+ "Jest config inherited from @webex/jest-config-legacy via jest.config.js",
302
+ "build and test runner provided by @webex/legacy-tools via package.json scripts",
303
+ "consumer-facing README.md retained unchanged as reference-only"
304
+ ],
305
+ "compliance_tier": "legacy"
306
+ },
307
+ "section_profiles": {
308
+ "repo": {
309
+ "owns_datastore": false,
310
+ "holds_client_state": false,
311
+ "components_interact": false,
312
+ "domain_data_across_components": false,
313
+ "caches_data": false,
314
+ "observability_convention": true,
315
+ "deploys_to_infra": false,
316
+ "shared_base_libs": true,
317
+ "is_monorepo": false,
318
+ "multi_platform": true,
319
+ "published_package": true,
320
+ "embedded_in_host": false,
321
+ "cross_repo_deps_material": true,
322
+ "security_arch_warranted": false,
323
+ "exposes_commands_or_artifacts": false
324
+ },
325
+ "resolved_by": "claude-opus-5",
326
+ "resolved_at": "2026-09-28T13:42:25Z"
327
+ }
328
+ }
package/AGENTS.md ADDED
@@ -0,0 +1,218 @@
1
+ <!-- sdd-generated-metadata
2
+ doc_kind: agent-entry
3
+ generated_from: agents@0.3.0
4
+ generated_by: claude-opus-5
5
+ approved_by: rarajes2@cisco.com
6
+ updated_at: 2026-09-28T14:57:53Z
7
+ validation_status: pass-with-warnings
8
+ -->
9
+
10
+ # AI Agent Instructions
11
+
12
+ Instructions for AI coding assistants working in `@webex/helper-image`, a published Webex JavaScript
13
+ SDK helper package that reads EXIF orientation onto image files, resolves their MIME type, and
14
+ measures and thumbnails them through separate Node and browser implementations.
15
+
16
+ ## Working Method
17
+
18
+ - Read the relevant repository files before editing. Do not edit blind.
19
+ - Understand the task and affected surfaces before writing code.
20
+ - Prefer focused edits over rewriting whole files.
21
+ - Do not invent commands, paths, exports, or behavior. Verify them from repository-local source.
22
+ - Test or validate before declaring done.
23
+ - Keep output concise. If something is uncertain, say so instead of guessing.
24
+
25
+ ## Canonical Repository Documentation
26
+
27
+ Before changing code or documentation, start with:
28
+
29
+ - `docs/index.md` for repository documentation navigation;
30
+ - `docs/architecture.md` for repository boundaries and interactions;
31
+ - `docs/specs/README.md` for the manifest-backed module and contract registry;
32
+ - the affected module's manifest-routed specification, which for this package is the single module at `src/docs/README.md`; and
33
+ - `docs/adr/index.md` plus applicable concrete ADRs for durable decisions.
34
+
35
+ Follow `.sdd/manifest.json` for each contract's publication state and canonical source. Published
36
+ repository-owned HTTP APIs use their linked OpenAPI document; internal HTTP surfaces may link route
37
+ code, and published SDKs use their ecosystem-native API artifact. The manifest remains authoritative
38
+ for canonical paths and artifact decisions.
39
+
40
+ This package owns no HTTP surface. Its published contract is the package export surface declared in
41
+ `package.json` and `src/index.js`.
42
+
43
+ `README.md` is the consumer-facing npm readme. It is reference-only context, not a specification, and
44
+ it is incomplete: it documents `updateImageOrientation`, `readExifData` and `orient` while omitting
45
+ `processImage` and `detectFileType`, and it presents `orient` as though it were a package export.
46
+ `src/docs/README.md` states the real boundary.
47
+
48
+ ## 1. Commands (Run First)
49
+
50
+ Use only documented commands. Do not invent alternatives when a command is missing.
51
+
52
+ | Task | Command |
53
+ | ---------------------- | --------------------------------------------------- |
54
+ | Install dependencies | `yarn install` |
55
+ | Start dev environment | Not applicable — this package is a library with no runnable entry point |
56
+ | Run tests | `yarn workspace @webex/helper-image test:unit` |
57
+ | Run linters | `yarn workspace @webex/helper-image test:style` |
58
+ | Build/release artifact | `yarn workspace @webex/helper-image build` |
59
+ | Format code | No dedicated command; formatting is enforced through the lint command above |
60
+
61
+ Browser-runner variant of the same unit specs: `yarn workspace @webex/helper-image test:browser`.
62
+
63
+ Do not run the package's aggregate `test` script, `yarn workspace @webex/helper-image test`. It chains
64
+ `yarn test:integration`, which `package.json` does not define, so it fails before reaching the browser
65
+ tier. Run the tiers individually.
66
+
67
+ If a required command is unknown, stop and ask for the exact command.
68
+
69
+ ## 2. Agent Persona and Scope
70
+
71
+ You are the `@webex/web-client` engineering assistant for `@webex/helper-image`.
72
+
73
+ Primary outcomes:
74
+
75
+ - Deliver production-safe changes with passing tests.
76
+ - Preserve existing behavior unless a change request explicitly requires a behavior change.
77
+ - Keep docs and configuration aligned with code changes.
78
+
79
+ Definition of done:
80
+
81
+ 1. Requested change is implemented.
82
+ 2. Relevant tests/lint/build checks pass locally.
83
+ 3. Updated docs/config cover new behavior.
84
+ 4. PR summary includes risks and rollback notes.
85
+
86
+ ## 3. Repository Knowledge
87
+
88
+ ### Tech Stack
89
+
90
+ Document concrete versions so assistants choose compatible APIs.
91
+
92
+ | Area | Tooling | Version |
93
+ | ---------------- | ----------------------------------------------------------- | ----------- |
94
+ | Language runtime | Node, plus browser targets built from the same sources | `>=18` |
95
+ | Build tool | `@webex/legacy-tools` (`webex-legacy-tools build`) over Babel via `@webex/babel-config-legacy` | workspace |
96
+ | Test framework | Mocha with `@webex/test-helper-chai` assertions and Sinon; Karma for the browser runner | `sinon ^9.2.4` |
97
+ | Lint/format | ESLint with `@webex/eslint-config-legacy`, Prettier | `eslint ^8.24.0`, `prettier ^2.7.1` |
98
+
99
+ Node's floor is declared in `package.json`. Yarn workspaces resolve the `workspace:*` dependencies,
100
+ and the Yarn version is pinned by the enclosing workspace rather than by this package.
101
+
102
+ ### Project Map
103
+
104
+ - `src/`: the only module. Public entry plus EXIF orientation, MIME detection, and image
105
+ measurement/thumbnailing. Specified in `src/docs/README.md`.
106
+ - `src/index.js`: the package export surface and the EXIF orientation functions.
107
+ - `src/process-image.js` and `src/process-image.browser.js`: the two implementations of
108
+ `processImage`, selected by the `browser` field in `package.json`.
109
+ - `test/unit/spec/index.js`: the whole unit suite, run by both the Mocha and Karma runners.
110
+ - `docs/`: generated standing documentation. `.sdd/`: manifest and the templates symlink.
111
+
112
+ ### Critical Constraints
113
+
114
+ - `processImage` has two implementations with genuinely different behavior. A change to one is not a
115
+ change to the package unless the other is updated to match, and the differences are catalogued in
116
+ `src/docs/README.md`.
117
+ - `readExifData` mutates the `file` object it is given and returns the buffer unchanged. Callers in
118
+ the wider SDK depend on that side effect, so the mutation is the contract, not an implementation
119
+ detail.
120
+ - The export surface is published to npm. Renaming, removing, or changing the shape of any export in
121
+ `src/index.js` is a breaking change for external consumers.
122
+ - The Node implementation depends on a GraphicsMagick or ImageMagick binary on the host and
123
+ deliberately degrades to an undefined result when it is absent. Do not convert that degradation
124
+ into a rejection without treating it as a breaking change.
125
+
126
+ ## 4. Testing Workflow
127
+
128
+ Run checks in this order:
129
+
130
+ 1. `yarn workspace @webex/helper-image test:unit`
131
+ 2. `yarn workspace @webex/helper-image test:style`
132
+ 3. `yarn workspace @webex/helper-image test:browser` — the browser runner for the same specs; it is
133
+ the only tier that executes the `browserOnly` cases
134
+
135
+ Testing rules:
136
+
137
+ - Add or update tests for every behavior change.
138
+ - Cover failure paths and edge cases, not only happy paths.
139
+ - Do not remove tests to make CI pass.
140
+ - The `readExifData` cases in `test/unit/spec/index.js` are disabled with `xdescribe`, so the EXIF
141
+ parsing path is currently unpinned. Treat any change to it as unguarded and add coverage rather
142
+ than relying on the existing suite.
143
+
144
+ ## 5. Code Style and Patterns
145
+
146
+ Coding expectations:
147
+
148
+ - Follow repository style rules and static analysis output.
149
+ - Prefer small, composable functions over large procedural blocks.
150
+ - Make error handling explicit at system boundaries.
151
+ - Keep public interfaces stable unless a breaking change is requested.
152
+ - Before adding a literal path, filename, command, workflow identifier, status,
153
+ or other policy value, search the repository for exact and semantically
154
+ equivalent uses. When repeated production values represent one shared
155
+ contract, move them to the narrowest owning shared module or catalog as one
156
+ canonical named constant, enum, or type and update consumers. Keep incidental
157
+ similarities, one-off implementation details, and independent test fixtures
158
+ local.
159
+ - Do not import a default, named, object, or namespace binding and immediately
160
+ re-export it. Consumers should import from the owning module; package barrels
161
+ should use direct named re-exports.
162
+ - Do not write inline runtime `typeof` checks outside descriptively named guard
163
+ implementations. Import and reuse the owning guard instead; TypeScript
164
+ type-position `typeof` queries remain allowed.
165
+ - Take a `logger` as a parameter rather than importing one. Every function in this package that
166
+ logs receives the logger from its caller, which is what lets the SDK route package logs through
167
+ the host client's logger.
168
+
169
+ Pattern example:
170
+
171
+ ```text
172
+ Preferred:
173
+ - Validate external input close to the boundary.
174
+ - Return typed/structured results.
175
+ - Include actionable error messages.
176
+
177
+ Avoid:
178
+ - Passing unvalidated payloads deep into the system.
179
+ - Swallowing exceptions or returning ambiguous null values.
180
+ ```
181
+
182
+ ## 6. Git Workflow
183
+
184
+ - Branch naming: `[feature|fix|chore]/[short-description]`
185
+ - Commit format: conventional commits (`feat:`, `fix:`, `docs:`, `refactor:`, `test:`, `chore:`)
186
+ - Keep commits focused and reversible.
187
+ - Rebase on the target branch before opening PR.
188
+
189
+ PR checklist:
190
+
191
+ - What changed and why.
192
+ - Tests run and results.
193
+ - Risk/impact areas.
194
+ - Rollback approach.
195
+
196
+ ## 7. Boundaries and Escalation
197
+
198
+ ### Always
199
+
200
+ - Prefer existing patterns over introducing new architecture.
201
+ - Keep changes minimal for the requested scope.
202
+ - Call out assumptions and unknowns explicitly.
203
+
204
+ ### Ask First
205
+
206
+ - Adding new dependencies or external services.
207
+ - Large refactors or schema migrations.
208
+ - Security-sensitive changes (auth, encryption, secrets handling).
209
+ - Any destructive data or infrastructure operation.
210
+ - Changing any export in `src/index.js`, or changing one `processImage` implementation without the
211
+ other. Both are consumer-visible.
212
+
213
+ ### Never
214
+
215
+ - Commit secrets, keys, or credentials.
216
+ - Bypass required checks by disabling tests or linters.
217
+ - Rewrite history on shared branches.
218
+ - Change unrelated files "while here" without clear need.
@@ -0,0 +1,34 @@
1
+ <!-- sdd-generated-metadata
2
+ doc_kind: standing-doc
3
+ generated_from: adr-index@0.3.0
4
+ generated_by: claude-opus-5
5
+ approved_by: rarajes2@cisco.com
6
+ updated_at: 2026-09-28T14:57:53Z
7
+ validation_status: pass-with-warnings
8
+ -->
9
+
10
+ # Architectural decision records
11
+
12
+ Numbered, append-only records of structural decisions affecting this repository
13
+ and its documentation. Add a concrete ADR (for example, `0042-cache-policy.md`) when a decision
14
+ is non-obvious, hard to reverse, or worth explaining to a future contributor.
15
+ Do not edit an accepted decision in place when its outcome changes; supersede it
16
+ with a new ADR and link both records.
17
+
18
+ ## Index
19
+
20
+ No architectural decisions are registered yet. Replace this sentence with links to concrete,
21
+ accepted ADRs as decisions are recorded.
22
+
23
+ Two standing design choices in this package are candidates for the first ADRs, because both are
24
+ consumer-visible and neither carries a recorded rationale in the code: the split of `processImage`
25
+ into separate Node and browser implementations selected by the `browser` field in `package.json`,
26
+ and the decision that a missing host image toolchain degrades to an undefined result rather than a
27
+ rejection. Both are described with evidence in [`../../src/docs/README.md`](../../src/docs/README.md)
28
+ under `Key design trade-off`; neither has been ratified as a decision record.
29
+
30
+ Add new entries as ADRs are accepted. Keep this list in numeric order.
31
+
32
+ Each ADR should state its context, decision, alternatives, consequences, and
33
+ the condition that would cause the team to revisit it. Record the deciders,
34
+ any superseded decision, and the constraint future changes must preserve.