@hdwebsoft/hdcode-ai-darwin-x64 0.0.7 → 0.0.8

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.
Files changed (54) hide show
  1. package/bin/hdcode +0 -0
  2. package/bin/index.js.map +1 -1
  3. package/bin/worker.js.map +1 -1
  4. package/package.json +1 -1
  5. package/resources/agents/finder.md +1 -1
  6. package/resources/agents/mermaid.md +1 -1
  7. package/resources/skills/hd-code-review/CODING_STANDARDS.md +14 -114
  8. package/resources/skills/hd-code-review/REVIEW_STANDARDS.md +76 -0
  9. package/resources/skills/hd-code-review/SKILL.md +314 -90
  10. package/resources/skills/hd-code-review/reference/review-checklist.md +104 -101
  11. package/resources/skills/hd-code-review/reference/stacks/apex.md +49 -0
  12. package/resources/skills/hd-code-review/reference/stacks/aura.md +39 -0
  13. package/resources/skills/hd-code-review/reference/stacks/cakephp.md +50 -0
  14. package/resources/skills/hd-code-review/reference/stacks/django.md +53 -0
  15. package/resources/skills/hd-code-review/reference/stacks/dotnet.md +52 -0
  16. package/resources/skills/hd-code-review/reference/stacks/expo.md +39 -0
  17. package/resources/skills/hd-code-review/reference/stacks/flutter.md +48 -0
  18. package/resources/skills/hd-code-review/reference/stacks/go.md +51 -0
  19. package/resources/skills/hd-code-review/reference/stacks/laravel.md +56 -0
  20. package/resources/skills/hd-code-review/reference/stacks/lwc.md +49 -0
  21. package/resources/skills/hd-code-review/reference/stacks/nodejs.md +51 -0
  22. package/resources/skills/hd-code-review/reference/stacks/php.md +52 -0
  23. package/resources/skills/hd-code-review/reference/stacks/python.md +50 -0
  24. package/resources/skills/hd-code-review/reference/stacks/react.md +51 -0
  25. package/resources/skills/hd-code-review/reference/stacks/reactnative.md +54 -0
  26. package/resources/skills/hd-code-review/reference/stacks/scala.md +48 -0
  27. package/resources/skills/hd-code-review/reference/stacks/visualforce.md +38 -0
  28. package/resources/skills/hd-code-review/reference/stacks/vuejs.md +52 -0
  29. package/resources/skills/hd-code-review/reference/stacks/wordpress.md +54 -0
  30. package/resources/skills/hd-daily-goals/SKILL.md +41 -9
  31. package/resources/skills/hd-daily-goals/reference/ticket-autofill.md +104 -0
  32. package/resources/skills/hd-daily-goals/reference/validation-rules.md +13 -0
  33. package/resources/skills/hd-daily-report/SKILL.md +70 -14
  34. package/resources/skills/hd-daily-report/reference/sample-report-qc.md +44 -0
  35. package/resources/skills/hd-daily-report/reference/sample-report.md +18 -15
  36. package/resources/skills/hd-daily-report/reference/validation-rules.md +28 -7
  37. package/resources/skills/hd-daily-viewer/SKILL.md +222 -0
  38. package/resources/skills/hd-docs-init/SKILL.md +33 -0
  39. package/resources/skills/hd-docs-parse/SKILL.md +2 -0
  40. package/resources/skills/hd-docs-parse/scripts/parse_document.py +6 -0
  41. package/resources/skills/hd-docs-sync/SKILL.md +65 -3
  42. package/resources/skills/hd-docs-sync/reference/doc-mapping.md +1 -0
  43. package/resources/skills/hd-help/SKILL.md +24 -0
  44. package/resources/skills/hd-help/reference/skill-map.md +122 -7
  45. package/resources/skills/hd-iso/SKILL.md +409 -0
  46. package/resources/skills/hd-iso/reference/iso-27001-requirements.md +166 -0
  47. package/resources/skills/hd-iso/reference/iso-9001-requirements.md +91 -0
  48. package/resources/skills/hd-iso/reference/role-profiles.md +115 -0
  49. package/resources/skills/hd-iso-ready/SKILL.md +146 -0
  50. package/resources/skills/hd-iso-sync/SKILL.md +217 -0
  51. package/resources/skills/hd-iso-sync/reference/frontmatter-schema.md +89 -0
  52. package/resources/skills/hd-iso-verify/SKILL.md +294 -0
  53. package/resources/skills/hd-issue-resolution/SKILL.md +20 -0
  54. package/resources/skills/hd-task/SKILL.md +12 -0
@@ -0,0 +1,166 @@
1
+ # ISO 27001:2022 Requirements
2
+
3
+ Used by `hd-iso gap` to check document coverage against mandatory clauses and Annex A controls.
4
+
5
+ > **Source & Disclaimer**
6
+ > Clause IDs, titles, and structure are based on BSI Group training materials ([bsigroup.com](https://www.bsigroup.com)) and publicly available ISO guidance. Descriptions are summaries — not verbatim from the official ISO document. For formal audit submissions, reference the purchased official standard from ISO or BSI.
7
+ > Last reviewed: 2026-03-05 | Standard version: ISO/IEC 27001:2022
8
+
9
+ ## Column Guide
10
+
11
+ | Column | Source | Notes |
12
+ |--------|--------|-------|
13
+ | `Clause` | Official standard | Normative clause ID |
14
+ | `Title` | Official standard | Normative clause title |
15
+ | `Type` | Official standard | `mandatory` (clauses 4–10) or `control` (Annex A) |
16
+ | `Description` | BSI training summary | Brief summary — not official text |
17
+ | `Shall` | **Official PDF** | Key normative "shall" statements. **Populate from purchased ISO/IEC 27001:2022 PDF** using `/hd-docs-parse`. Leave empty until official text is available. |
18
+
19
+ When `Shall` is populated, `hd-iso-verify` uses it as the authoritative source for clause-specific checks.
20
+
21
+ ---
22
+
23
+ ## Mandatory Clauses (Clauses 4–10)
24
+
25
+ | Clause | Title | Type | Description |
26
+ |--------|-------|------|-------------|
27
+ | 4.1 | Understanding the organization and its context | mandatory | Internal/external issues affecting ISMS |
28
+ | 4.2 | Understanding needs of interested parties | mandatory | Requirements of stakeholders |
29
+ | 4.3 | Determining scope of ISMS | mandatory | Boundaries and applicability |
30
+ | 4.4 | ISMS | mandatory | Establish, implement, maintain, improve ISMS |
31
+ | 5.1 | Leadership and commitment | mandatory | Top management demonstration |
32
+ | 5.2 | Policy | mandatory | Information security policy |
33
+ | 5.3 | Roles, responsibilities, authorities | mandatory | Assigned and communicated |
34
+ | 6.1 | Actions to address risks and opportunities | mandatory | Risk treatment including 6.1.2 risk assessment, 6.1.3 risk treatment |
35
+ | 6.2 | Information security objectives | mandatory | Measurable security objectives |
36
+ | 6.3 | Planning of changes | mandatory | Changes to ISMS performed in controlled manner |
37
+ | 7.1 | Resources | mandatory | Provide necessary resources |
38
+ | 7.2 | Competence | mandatory | Competence of relevant persons |
39
+ | 7.3 | Awareness | mandatory | Awareness of security policy and roles |
40
+ | 7.4 | Communication | mandatory | Internal and external communication |
41
+ | 7.5 | Documented information | mandatory | Create, update, control documented information |
42
+ | 8.1 | Operational planning and control | mandatory | Plan, implement, control processes |
43
+ | 8.2 | Information security risk assessment | mandatory | Perform at planned intervals or on change |
44
+ | 8.3 | Information security risk treatment | mandatory | Implement risk treatment plan |
45
+ | 9.1 | Monitoring, measurement, analysis, evaluation | mandatory | Evaluate performance and effectiveness |
46
+ | 9.2 | Internal audit | mandatory | Conduct at planned intervals |
47
+ | 9.3 | Management review | mandatory | Top management review at planned intervals |
48
+ | 10.1 | Continual improvement | mandatory | Continuously improve ISMS |
49
+ | 10.2 | Nonconformity and corrective action | mandatory | React, take action, review effectiveness |
50
+
51
+ ---
52
+
53
+ ## Annex A Controls (ISO 27001:2022)
54
+
55
+ ### A.5 — Organizational Controls (37 controls)
56
+
57
+ | Clause | Title | Type | Description |
58
+ |--------|-------|------|-------------|
59
+ | A.5.1 | Policies for information security | control | Define, approve, publish, review policies |
60
+ | A.5.2 | Information security roles and responsibilities | control | Allocate responsibilities |
61
+ | A.5.3 | Segregation of duties | control | Separate conflicting duties |
62
+ | A.5.4 | Management responsibilities | control | Require adherence to policy |
63
+ | A.5.5 | Contact with authorities | control | Maintain contacts with authorities |
64
+ | A.5.6 | Contact with special interest groups | control | Maintain contacts with special interest groups |
65
+ | A.5.7 | Threat intelligence | control | Collect and analyze threats |
66
+ | A.5.8 | Information security in project management | control | Address security in project management |
67
+ | A.5.9 | Inventory of information and other associated assets | control | Maintain asset inventory |
68
+ | A.5.10 | Acceptable use of information and assets | control | Rules for acceptable use |
69
+ | A.5.11 | Return of assets | control | Return assets upon termination/change |
70
+ | A.5.12 | Classification of information | control | Classify information by requirements |
71
+ | A.5.13 | Labelling of information | control | Label information per classification |
72
+ | A.5.14 | Information transfer | control | Rules for transferring information |
73
+ | A.5.15 | Access control | control | Establish and implement access policy |
74
+ | A.5.16 | Identity management | control | Manage full identity lifecycle |
75
+ | A.5.17 | Authentication information | control | Manage allocation/use of authentication info |
76
+ | A.5.18 | Access rights | control | Provision, review, remove access rights |
77
+ | A.5.19 | Information security in supplier relationships | control | Manage supplier security risks |
78
+ | A.5.20 | Addressing security within supplier agreements | control | Establish security requirements with suppliers |
79
+ | A.5.21 | Managing ICT supply chain security | control | Manage ICT supply chain risks |
80
+ | A.5.22 | Monitoring, review and change management of supplier services | control | Monitor and review supplier services |
81
+ | A.5.23 | Information security for use of cloud services | control | Manage cloud service security |
82
+ | A.5.24 | Information security incident management planning | control | Plan and prepare for incident management |
83
+ | A.5.25 | Assessment and decision on IS events | control | Assess events and decide if incidents |
84
+ | A.5.26 | Response to information security incidents | control | Respond to incidents |
85
+ | A.5.27 | Learning from IS incidents | control | Use knowledge gained from incidents |
86
+ | A.5.28 | Collection of evidence | control | Establish procedures for evidence |
87
+ | A.5.29 | IS during disruption | control | Plan security during disruption |
88
+ | A.5.30 | ICT readiness for business continuity | control | Plan ICT continuity |
89
+ | A.5.31 | Legal, statutory, regulatory and contractual requirements | control | Identify and comply with requirements |
90
+ | A.5.32 | Intellectual property rights | control | Protect intellectual property |
91
+ | A.5.33 | Protection of records | control | Protect records from loss, destruction, falsification |
92
+ | A.5.34 | Privacy and protection of PII | control | Protect PII per applicable requirements |
93
+ | A.5.35 | Independent review of IS | control | Independent review at planned intervals |
94
+ | A.5.36 | Compliance with policies and standards | control | Regular review of compliance |
95
+ | A.5.37 | Documented operating procedures | control | Maintain operating procedures |
96
+
97
+ ### A.6 — People Controls (8 controls)
98
+
99
+ | Clause | Title | Type | Description |
100
+ |--------|-------|------|-------------|
101
+ | A.6.1 | Screening | control | Background verification of candidates |
102
+ | A.6.2 | Terms and conditions of employment | control | Security responsibilities in contracts |
103
+ | A.6.3 | Information security awareness, education and training | control | Security training program |
104
+ | A.6.4 | Disciplinary process | control | Formal process for security violations |
105
+ | A.6.5 | Responsibilities after termination/change | control | Security responsibilities post-employment |
106
+ | A.6.6 | Confidentiality or non-disclosure agreements | control | NDAs for security |
107
+ | A.6.7 | Remote working | control | Security for remote workers |
108
+ | A.6.8 | IS event reporting | control | Report security events |
109
+
110
+ ### A.7 — Physical Controls (14 controls)
111
+
112
+ | Clause | Title | Type | Description |
113
+ |--------|-------|------|-------------|
114
+ | A.7.1 | Physical security perimeters | control | Define and use security perimeters |
115
+ | A.7.2 | Physical entry | control | Protect secure areas by entry controls |
116
+ | A.7.3 | Securing offices, rooms and facilities | control | Physical security for offices/rooms |
117
+ | A.7.4 | Physical security monitoring | control | Monitor premises for unauthorized access |
118
+ | A.7.5 | Protecting against physical and environmental threats | control | Protect against disasters |
119
+ | A.7.6 | Working in secure areas | control | Secure area procedures |
120
+ | A.7.7 | Clear desk and clear screen | control | Policies for clear desk/screen |
121
+ | A.7.8 | Equipment siting and protection | control | Site and protect equipment |
122
+ | A.7.9 | Security of assets off-premises | control | Protect off-site assets |
123
+ | A.7.10 | Storage media | control | Manage storage media lifecycle |
124
+ | A.7.11 | Supporting utilities | control | Protect from utility failures |
125
+ | A.7.12 | Cabling security | control | Protect power and telecom cabling |
126
+ | A.7.13 | Equipment maintenance | control | Maintain equipment correctly |
127
+ | A.7.14 | Secure disposal or re-use of equipment | control | Verify data deletion before disposal |
128
+
129
+ ### A.8 — Technological Controls (34 controls)
130
+
131
+ | Clause | Title | Type | Description |
132
+ |--------|-------|------|-------------|
133
+ | A.8.1 | User endpoint devices | control | Protect user endpoint devices |
134
+ | A.8.2 | Privileged access rights | control | Restrict and manage privileged access |
135
+ | A.8.3 | Information access restriction | control | Restrict access per policy |
136
+ | A.8.4 | Access to source code | control | Restrict source code access |
137
+ | A.8.5 | Secure authentication | control | Implement secure authentication |
138
+ | A.8.6 | Capacity management | control | Monitor and manage capacity |
139
+ | A.8.7 | Protection against malware | control | Malware protection |
140
+ | A.8.8 | Management of technical vulnerabilities | control | Vulnerability management |
141
+ | A.8.9 | Configuration management | control | Manage configurations securely |
142
+ | A.8.10 | Information deletion | control | Delete information when no longer needed |
143
+ | A.8.11 | Data masking | control | Mask data per policy |
144
+ | A.8.12 | Data leakage prevention | control | Prevent data leakage |
145
+ | A.8.13 | Information backup | control | Backup and test recovery |
146
+ | A.8.14 | Redundancy of information processing facilities | control | Sufficient redundancy |
147
+ | A.8.15 | Logging | control | Produce, store, protect logs |
148
+ | A.8.16 | Monitoring activities | control | Monitor networks, systems, applications |
149
+ | A.8.17 | Clock synchronisation | control | Synchronize clocks |
150
+ | A.8.18 | Use of privileged utility programs | control | Control privileged utilities |
151
+ | A.8.19 | Installation of software on operational systems | control | Control software installation |
152
+ | A.8.20 | Networks security | control | Manage and control networks |
153
+ | A.8.21 | Security of network services | control | Identify and address network service security |
154
+ | A.8.22 | Segregation of networks | control | Segregate networks |
155
+ | A.8.23 | Web filtering | control | Manage access to external websites |
156
+ | A.8.24 | Use of cryptography | control | Implement cryptography policy |
157
+ | A.8.25 | Secure development life cycle | control | Establish secure development rules |
158
+ | A.8.26 | Application security requirements | control | Specify application security requirements |
159
+ | A.8.27 | Secure system architecture and engineering principles | control | Apply secure engineering principles |
160
+ | A.8.28 | Secure coding | control | Apply secure coding practices |
161
+ | A.8.29 | Security testing in development and acceptance | control | Security testing in SDLC |
162
+ | A.8.30 | Outsourced development | control | Supervise outsourced development |
163
+ | A.8.31 | Separation of development, test and production | control | Separate environments |
164
+ | A.8.32 | Change management | control | Control changes to systems |
165
+ | A.8.33 | Test information | control | Protect test information |
166
+ | A.8.34 | Protection of IS during audit testing | control | Protect systems during audit |
@@ -0,0 +1,91 @@
1
+ # ISO 9001:2015 Requirements
2
+
3
+ Used by `hd-iso gap` to check document coverage against mandatory clauses.
4
+
5
+ > **Source & Disclaimer**
6
+ > Clause IDs, titles, and structure are based on BSI Group training materials ([bsigroup.com](https://www.bsigroup.com)) and publicly available ISO guidance. Descriptions are summaries — not verbatim from the official ISO document. For formal audit submissions, reference the purchased official standard from ISO or BSI.
7
+ > Last reviewed: 2026-03-05 | Standard version: ISO 9001:2015
8
+
9
+ ## Column Guide
10
+
11
+ | Column | Source | Notes |
12
+ |--------|--------|-------|
13
+ | `Clause` | Official standard | Normative clause ID |
14
+ | `Title` | Official standard | Normative clause title |
15
+ | `Type` | Official standard | `mandatory` |
16
+ | `Description` | BSI training summary | Brief summary — not official text |
17
+ | `Shall` | **Official PDF** | Key normative "shall" statements. **Populate from purchased ISO 9001:2015 PDF** using `/hd-docs-parse`. Leave empty until official text is available. |
18
+
19
+ When `Shall` is populated, `hd-iso-verify` uses it as the authoritative source for clause-specific checks.
20
+
21
+ ---
22
+
23
+ ## Mandatory Clauses
24
+
25
+ | Clause | Title | Type | Description |
26
+ |--------|-------|------|-------------|
27
+ | 4.1 | Understanding the organization and its context | mandatory | Internal/external issues affecting QMS |
28
+ | 4.2 | Understanding needs of interested parties | mandatory | Requirements of relevant stakeholders |
29
+ | 4.3 | Determining scope of QMS | mandatory | Boundaries, applicability, justification for exclusions |
30
+ | 4.4 | QMS and its processes | mandatory | Establish, implement, maintain, improve QMS processes |
31
+ | 5.1 | Leadership and commitment | mandatory | Top management accountability for QMS |
32
+ | 5.2 | Policy | mandatory | Quality policy established, communicated, maintained |
33
+ | 5.3 | Roles, responsibilities and authorities | mandatory | Assigned, communicated, understood |
34
+ | 6.1 | Actions to address risks and opportunities | mandatory | Determine risks/opportunities, plan actions |
35
+ | 6.2 | Quality objectives and planning | mandatory | Measurable quality objectives and plans to achieve |
36
+ | 6.3 | Planning of changes | mandatory | Changes made in controlled manner |
37
+ | 7.1 | Resources | mandatory | Provide resources: people, infrastructure, environment, monitoring/measuring, knowledge |
38
+ | 7.2 | Competence | mandatory | Ensure competence of people affecting quality |
39
+ | 7.3 | Awareness | mandatory | Aware of policy, objectives, contribution, nonconformity implications |
40
+ | 7.4 | Communication | mandatory | Determine internal/external communication on QMS |
41
+ | 7.5 | Documented information | mandatory | Create, update, control documented information |
42
+ | 8.1 | Operational planning and control | mandatory | Plan, implement, control processes for products/services |
43
+ | 8.2 | Requirements for products and services | mandatory | Customer communication, review of requirements, changes |
44
+ | 8.3 | Design and development | mandatory | Design/development process (if applicable) |
45
+ | 8.4 | Control of externally provided processes, products and services | mandatory | Supplier/subcontractor control |
46
+ | 8.5 | Production and service provision | mandatory | Controlled conditions, identification, preservation, post-delivery |
47
+ | 8.6 | Release of products and services | mandatory | Verify requirements met before release |
48
+ | 8.7 | Control of nonconforming outputs | mandatory | Identify and control nonconforming outputs |
49
+ | 9.1 | Monitoring, measurement, analysis and evaluation | mandatory | What, how, when to monitor and analyze |
50
+ | 9.2 | Internal audit | mandatory | Conduct at planned intervals, audit program |
51
+ | 9.3 | Management review | mandatory | Top management review: inputs, outputs, decisions |
52
+ | 10.1 | Continual improvement | mandatory | Determine opportunities, take actions |
53
+ | 10.2 | Nonconformity and corrective action | mandatory | React, root cause, review effectiveness, update risks |
54
+ | 10.3 | Continual improvement (general) | mandatory | Improve QMS suitability, adequacy, effectiveness |
55
+
56
+ ## Common Document Types by Clause
57
+
58
+ | Clause | Typical Doc Type | Example Title |
59
+ |--------|-----------------|---------------|
60
+ | 4.1–4.4 | policy + procedure | QMS Scope Document, Context Analysis |
61
+ | 5.1–5.3 | policy | Quality Policy, Roles & Responsibilities Matrix |
62
+ | 6.1–6.3 | procedure + record | Risk Register, Objectives Tracker |
63
+ | 7.1–7.5 | procedure + record | Training Records, Document Control Procedure |
64
+ | 8.1–8.7 | procedure + record | Production Procedure, NCR Log, Supplier Evaluation |
65
+ | 9.1–9.3 | procedure + record | Internal Audit Schedule, Management Review Minutes |
66
+ | 10.1–10.3 | procedure + record | Corrective Action Procedure, Improvement Log |
67
+
68
+ ## Mandatory Documented Information (ISO 9001:2015)
69
+
70
+ Documents that MUST exist as formal records:
71
+
72
+ | Item | Clause | Description |
73
+ |------|--------|-------------|
74
+ | Scope of QMS | 4.3 | Documented scope with justification for exclusions |
75
+ | Quality policy | 5.2 | Approved policy document |
76
+ | Quality objectives | 6.2 | Measurable objectives with plans |
77
+ | Operational planning and control | 8.1 | Evidence of processes controlled |
78
+ | Design and development inputs | 8.3.3 | If applicable |
79
+ | Design and development outputs | 8.3.5 | If applicable |
80
+ | Design and development changes | 8.3.6 | If applicable |
81
+ | External provider control criteria | 8.4.1 | Supplier evaluation criteria |
82
+ | Characteristics of products/services | 8.5.1 | Work instructions / specifications |
83
+ | Traceability records | 8.5.2 | Where required |
84
+ | Customer/external property records | 8.5.3 | If applicable |
85
+ | Change control records | 8.5.6 | Changes to production/service |
86
+ | Release authorization records | 8.6 | Evidence products/services meet requirements |
87
+ | Nonconforming outputs | 8.7.2 | NCR records |
88
+ | Monitoring/measurement results | 9.1.1 | Evidence of performance evaluation |
89
+ | Internal audit program and results | 9.2.2 | Audit schedule, reports, findings |
90
+ | Management review results | 9.3.3 | Meeting minutes with decisions |
91
+ | Nonconformities and corrective actions | 10.2.2 | CAR records |
@@ -0,0 +1,115 @@
1
+ # Role Profiles for ISO Onboarding
2
+
3
+ Used by `hd-iso onboard` to filter relevant documents per role.
4
+ Maps each role to the ISO clauses and doc_types most relevant to them.
5
+
6
+ ## Role Definitions
7
+
8
+ ### `developer`
9
+ Software engineers, DevOps engineers, tech leads.
10
+
11
+ **Relevant ISO 27001 clauses:**
12
+ - A.8.1–A.8.5 (endpoint devices, privileged access, access restriction, source code, authentication)
13
+ - A.8.8 (vulnerability management)
14
+ - A.8.9 (configuration management)
15
+ - A.8.13 (backup)
16
+ - A.8.15–A.8.16 (logging, monitoring)
17
+ - A.8.19 (software installation)
18
+ - A.8.20–A.8.22 (network security, segregation)
19
+ - A.8.24 (cryptography)
20
+ - A.8.25–A.8.34 (secure SDLC — all development controls)
21
+ - A.5.15, A.5.18 (access control, access rights)
22
+ - A.6.7 (remote working)
23
+ - A.6.8 (event reporting)
24
+
25
+ **Relevant ISO 9001 clauses:**
26
+ - 8.1 (operational planning)
27
+ - 8.3 (design and development)
28
+ - 8.5 (production/service provision)
29
+ - 10.2 (nonconformity and corrective action)
30
+
31
+ ---
32
+
33
+ ### `qa`
34
+ Quality assurance engineers, testers, QA managers.
35
+
36
+ **Relevant ISO 27001 clauses:**
37
+ - A.8.29 (security testing in development and acceptance)
38
+ - A.8.33 (test information)
39
+ - A.5.12, A.5.13 (classification and labelling)
40
+ - A.5.36 (compliance with policies)
41
+
42
+ **Relevant ISO 9001 clauses:**
43
+ - 8.5 (production and service provision)
44
+ - 8.6 (release of products and services)
45
+ - 8.7 (control of nonconforming outputs)
46
+ - 9.1 (monitoring, measurement, analysis and evaluation)
47
+ - 10.2 (nonconformity and corrective action)
48
+ - 7.2 (competence)
49
+
50
+ ---
51
+
52
+ ### `manager`
53
+ Team leads, department heads, project managers, product owners.
54
+
55
+ **Relevant ISO 27001 clauses:**
56
+ - 4.1–4.4 (context, scope, ISMS)
57
+ - 5.1–5.3 (leadership, policy, roles)
58
+ - 6.1–6.3 (risk, objectives, change planning)
59
+ - 7.1–7.5 (resources, competence, awareness, communication, documented information)
60
+ - 9.1–9.3 (monitoring, internal audit, management review)
61
+ - 10.1–10.2 (continual improvement, corrective action)
62
+ - A.5.1–A.5.4 (policies, roles, segregation, management responsibilities)
63
+ - A.5.19–A.5.22 (supplier/cloud management)
64
+
65
+ **Relevant ISO 9001 clauses:**
66
+ - 5.1–5.3 (leadership)
67
+ - 6.1–6.3 (planning)
68
+ - 9.3 (management review)
69
+ - 10.1–10.3 (improvement)
70
+
71
+ ---
72
+
73
+ ### `security`
74
+ CISO, security engineers, information security officers.
75
+
76
+ **Relevant ISO 27001 clauses:**
77
+ - All A.5–A.8 controls (full Annex A)
78
+ - All mandatory clauses 4–10
79
+ - Special focus: 6.1 (risk assessment), 8.2–8.3 (risk treatment)
80
+
81
+ **Relevant ISO 9001 clauses:**
82
+ - 6.1 (risks and opportunities)
83
+ - 9.1 (monitoring and measurement)
84
+ - 10.2 (corrective action)
85
+
86
+ ---
87
+
88
+ ### `new-hire`
89
+ All new employees regardless of role. Company-wide awareness only.
90
+
91
+ **Filter**: docs where `roles` contains `all` AND `doc_type` is `policy`
92
+
93
+ **Relevant clauses (awareness level):**
94
+ - A.5.1 (security policy)
95
+ - A.5.10 (acceptable use)
96
+ - A.6.3 (security awareness training)
97
+ - A.6.6 (NDAs and confidentiality)
98
+ - A.6.8 (incident reporting)
99
+ - 5.2 (quality policy)
100
+ - 7.3 (awareness)
101
+
102
+ ---
103
+
104
+ ## Role Hierarchy
105
+
106
+ For onboarding output, apply roles additively:
107
+ - A `manager` who is also a developer → run both profiles, deduplicate docs
108
+ - A `security` person → gets all controls (superset of all other roles)
109
+
110
+ ## Adding Custom Roles
111
+
112
+ To add a company-specific role (e.g. `hr`, `finance`, `ops`):
113
+ 1. Add a new section here following the same format
114
+ 2. Map to relevant ISO clauses
115
+ 3. `hd-iso onboard --role hr` will pick it up automatically
@@ -0,0 +1,146 @@
1
+ ---
2
+ name: hd-iso-ready
3
+ description: "ISO certification readiness assessment. Aggregates gap coverage, document quality, mandatory records, and open NCRs into a weighted readiness score. Use when: checking audit readiness, getting a compliance health summary, pre-audit review, 'are we ISO ready?', 'hd-iso-ready', 'certification readiness check'."
4
+ license: proprietary
5
+ metadata:
6
+ version: "1.0.0"
7
+ copyright: "© HDWEBSOFT. All rights reserved."
8
+ ---
9
+
10
+ # ISO Certification Readiness Report
11
+
12
+ > **[IMPORTANT]** Advisory only — compliance decisions and auditor submissions are owned by humans. Run `hd-iso-sync` first to ensure local docs are current.
13
+
14
+ ## Invocation
15
+
16
+ ```
17
+ /hd-iso-ready [--standard 9001|27001] Full readiness assessment (default: both)
18
+ /hd-iso-ready --standard 27001 --brief Executive summary only
19
+ ```
20
+
21
+ ---
22
+
23
+ ## Pipeline
24
+
25
+ | Step | Action | Weight |
26
+ |------|--------|--------|
27
+ | 1. Gap | Clause coverage: covered / total mandatory | 30% |
28
+ | 2. Quality | Doc quality audit: compliant vs partial vs non-compliant | 35% |
29
+ | 3. Records | Mandatory records existence check | 25% |
30
+ | 4. NCRs | Open NCRs: major -10%/ea (max -30%), minor -3%/ea (max -9%) | penalty |
31
+ | 5. Report | Weighted score → grade → save report | — |
32
+
33
+ Prerequisite: `docs/iso/` populated. Reference files at `skills/hd-iso/reference/`. Missing `docs/iso/ncr/` → assume 0 NCRs.
34
+
35
+ ---
36
+
37
+ ## Step 1 — Gap Check (Clause Coverage)
38
+
39
+ Check if mandatory clauses have a doc tagged in `docs/iso/` frontmatter. Annex A controls excluded from scoring.
40
+
41
+ ```
42
+ 📋 Clause Coverage
43
+ ✅ Covered: 18/21 mandatory clauses
44
+ ❌ Missing: 3 clauses — 8.2, 9.2, 10.2
45
+ Score: 86%
46
+ ```
47
+
48
+ ---
49
+
50
+ ## Step 2 — Document Quality
51
+
52
+ For all docs tagged with the standard: apply the hd-iso-verify universal checklist (U1 scope, U2 owner, U3 process, U4 evidence, U5 review). Grade each: ✅ (≥80%) / 🟡 (50–79%) / 🔴 (<50%). Score: (✅×1 + 🟡×0.6) / total.
53
+
54
+ ```
55
+ 📄 Document Quality
56
+ 🟢 Compliant: 6 docs
57
+ 🟡 Review needed: 8 docs
58
+ 🔴 Non-compliant: 3 docs
59
+ Score: 61%
60
+ ```
61
+
62
+ ---
63
+
64
+ ## Step 3 — Mandatory Records
65
+
66
+ Search `docs/iso/` for each mandatory record (from reference "Mandatory Documented Information" list). Grade: ✅ present | ⚠️ wrong doc_type | ❌ missing. Wrong-type counts as 0.5 in score.
67
+
68
+ ```
69
+ 📁 Mandatory Records
70
+ ✅ Present: 10/13
71
+ ⚠️ Wrong type: 1
72
+ ❌ Missing: 2
73
+ Score: 81%
74
+ ```
75
+
76
+ ---
77
+
78
+ ## Step 4 — Open NCRs
79
+
80
+ Scan `docs/iso/ncr/*.md` for status: open or in-progress. Count by severity and apply penalty.
81
+
82
+ ```
83
+ ⚠️ Open NCRs
84
+ 3 open (1 major, 2 minor)
85
+ Penalty: -13%
86
+ ```
87
+
88
+ ---
89
+
90
+ ## Step 5 — Compile Report
91
+
92
+ ```
93
+ weighted_score = (gap × 0.30) + (quality × 0.35) + (records × 0.25) - ncr_penalty
94
+ ```
95
+
96
+ ### Readiness Grade
97
+
98
+ | Score | Grade |
99
+ |-------|-------|
100
+ | ≥85%, no major NCRs, no ❌ mandatory records | 🟢 READY |
101
+ | 65–84% OR 1+ major NCR | 🟡 PARTIALLY READY |
102
+ | <65% OR missing mandatory records OR 2+ major NCRs | 🔴 NOT READY |
103
+
104
+ **Critical blockers** (shown regardless of score): any ❌ mandatory clause, any open major NCR, any ❌ mandatory record.
105
+
106
+ ---
107
+
108
+ ## Output Format
109
+
110
+ ```
111
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
112
+ ISO 27001:2022 Certification Readiness Report
113
+ Generated: 2026-03-05 | Docs synced: 2026-03-04
114
+
115
+ OVERALL: 🟡 PARTIALLY READY (72%)
116
+
117
+ 📋 Clause Coverage: 18/21 Score: 86%
118
+ 📄 Document Quality: 6✅ 8🟡 3🔴 Score: 61%
119
+ 📁 Mandatory Records: 10/13 Score: 81%
120
+ ⚠️ Open NCRs: 3 open (1 major, 2 minor) Penalty: -13%
121
+
122
+ Readiness Breakdown:
123
+ Gap (30%): 86% → 25.8
124
+ Quality (35%): 61% → 21.4
125
+ Records (25%): 81% → 20.3
126
+ NCR penalty: -13%
127
+ ────────────────────
128
+ Score: 72% → 🟡 PARTIALLY READY
129
+
130
+ Critical blockers:
131
+ 1. ❌ Clause 9.2 — no internal audit procedure found
132
+ 2. ❌ NCR-002 (major): Incident response procedure non-compliant
133
+ 3. ❌ Management review records missing (tagged clause 9.3.3)
134
+
135
+ Next steps:
136
+ /hd-iso gap --standard 27001 → detail on missing clauses
137
+ /hd-iso-verify --standard 27001 → detail on non-compliant docs
138
+ /hd-iso records --standard 27001 → detail on missing records
139
+ /hd-iso ncr list --status open → address open NCRs
140
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
141
+ Report saved: reports/readiness-27001-20260305.md
142
+ ```
143
+
144
+ **Brief mode**: OVERALL grade + 4-section scores + critical blockers + next steps only.
145
+
146
+ Report filename: `reports/readiness-<standard>-<YYYYMMDD>.md` (both standards: `readiness-both-<YYYYMMDD>.md`). Create `reports/` if missing.