Skip to content

feature: Port Proof of Concept Components#48

Draft
joeds13 wants to merge 31 commits intomainfrom
port-poc-components
Draft

feature: Port Proof of Concept Components#48
joeds13 wants to merge 31 commits intomainfrom
port-poc-components

Conversation

@joeds13
Copy link
Copy Markdown
Collaborator

@joeds13 joeds13 commented Apr 8, 2026

Description

Porting of the Proof of Concept Components into this templated NHS repo

Context

For alignment from the Proof of Concept to other Notify services

Type of changes

  • Refactoring (non-breaking change)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would change existing functionality)
  • Bug fix (non-breaking change which fixes an issue)

Checklist

  • I am familiar with the contributing guidelines
  • I have followed the code style of the project
  • I have added tests to cover my changes
  • I have updated the documentation accordingly
  • This PR is a result of pair or mob programming

Sensitive Information Declaration

To ensure the utmost confidentiality and protect your and others privacy, we kindly ask you to NOT including PII (Personal Identifiable Information) / PID (Personal Identifiable Data) or any other sensitive data in this PR (Pull Request) and the codebase changes. We will remove any PR that do contain any sensitive information. We really appreciate your cooperation in this matter.

  • I confirm that neither PII/PID nor sensitive data are included in this PR and the codebase changes.

@joeds13 joeds13 force-pushed the port-poc-components branch 2 times, most recently from 7c77114 to ad4c34c Compare April 9, 2026 08:54
@joeds13 joeds13 force-pushed the port-poc-components branch from 70c2905 to b6d0385 Compare April 10, 2026 09:02
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Ports the Admail proof-of-concept into this NHS Notify repo template, introducing the core application stack (frontend, backend API, and a Bedrock-backed Lambda) plus local dev orchestration and supporting tooling/config updates.

Changes:

  • Added a React frontend (Cognito login, upload + assessment UI, costing tool, history view) and an Express backend for S3 history/download endpoints.
  • Added the bedrock-prompt-messager Lambda (Bedrock Converse + S3 logging), plus local-server emulator and unit tests.
  • Updated repo/template configuration (workspaces, linting, Sonar, docs/readme, Docker Compose, Terraform component wiring), and added Playwright test scaffolding.

Reviewed changes

Copilot reviewed 112 out of 152 changed files in this pull request and generated 14 comments.

Show a summary per file
File Description
tests/playwright/tsconfig.json TS config for Playwright workspace
tests/playwright/playwright.config.ts Playwright runner + webServer config
tests/playwright/package.json Playwright workspace manifest/scripts
tests/playwright/login.spec.ts Basic login page test
tests/playwright/.gitignore Ignore Playwright artifacts
tests/.gitignore Ignore Playwright reports under tests
src/jekyll-devcontainer/src/.devcontainer/Dockerfile Devcontainer image label update
scripts/tests/lint.sh Lint helper script
scripts/tests/integration.sh Playwright install / integration script stub
scripts/githooks/check-file-format.sh EditorConfig formatting hook changes
scripts/githooks/check-english-usage.sh Vale hook: NUL-delimited file handling
scripts/config/vale/styles/config/vocabularies/words/accept.txt Vale vocab update (Admail)
scripts/config/sonar-scanner.properties Sonar sources/tests path updates
README.md Repo renamed + badges/links updated
project.code-workspace Workspace naming update
package.json Root workspaces updated; deps/overrides tweaks
Makefile Added dev docker-compose target
lambdas/example-lambda/tsconfig.json Removed example lambda scaffolding
lambdas/example-lambda/src/index.ts Removed example lambda handler
lambdas/example-lambda/src/tests/index.test.ts Removed example lambda tests
lambdas/example-lambda/package.json Removed example lambda package
lambdas/example-lambda/jest.config.ts Removed example lambda Jest config
lambdas/example-lambda/.gitignore Removed example lambda ignores
lambdas/example-lambda/.eslintignore Removed example lambda eslintignore
lambdas/bedrock-prompt-messager/tsconfig.json TS config for new Bedrock lambda
lambdas/bedrock-prompt-messager/src/types.d.ts Types for .txt prompt imports
lambdas/bedrock-prompt-messager/src/system_prompt.txt System prompt (base)
lambdas/bedrock-prompt-messager/src/system_prompt_extended.txt System prompt (extended advice)
lambdas/bedrock-prompt-messager/src/local-server.ts Local API Gateway emulator
lambdas/bedrock-prompt-messager/src/index.ts Lambda handler (request validation + service call)
lambdas/bedrock-prompt-messager/src/constants.ts Shared constants/CORS/errors/rating
lambdas/bedrock-prompt-messager/src/config.ts Env-based Bedrock config loader
lambdas/bedrock-prompt-messager/src/bedrock-service.ts Bedrock + guardrails + S3 logging implementation
lambdas/bedrock-prompt-messager/src/tests/index.test.ts Handler unit tests
lambdas/bedrock-prompt-messager/src/mocks/text-file.ts Jest mock for .txt imports
lambdas/bedrock-prompt-messager/README.md Lambda README placeholder
lambdas/bedrock-prompt-messager/package.json Lambda deps + build/test scripts
lambdas/bedrock-prompt-messager/jest.config.ts Jest config (txt mapper, modulePaths)
lambdas/bedrock-prompt-messager/docker/Dockerfile Runtime Lambda Dockerfile
lambdas/bedrock-prompt-messager/docker/dev.Dockerfile Dev container for lambda local server
lambdas/bedrock-prompt-messager/docker/dev-entrypoint.sh Watch build + node --watch runner
lambdas/bedrock-prompt-messager/build.sh esbuild bundle updates (es2022 + txt loader)
lambdas/bedrock-prompt-messager/.gitignore Lambda gitignore
lambdas/bedrock-prompt-messager/.dockerignore Lambda dockerignore
input-docs/NHS Synthetic Business Letters/NHS Synthetic Data Blood Test 2.docx Added synthetic input document
infrastructure/terraform/README Removed template Terraform readme
infrastructure/terraform/components/admail/README.md Added component README heading
infrastructure/terraform/components/admail/module_lambda_bedrock_messager.tf Points lambda module at new dist dir
infrastructure/terraform/components/admail/locals.tf Removed unused prompt filename local
infrastructure/terraform/components/admail/apprunner_service_frontend.tf AppRunner image tag renamed to frontend
infrastructure/terraform/components/admail/apprunner_service_backend.tf AppRunner image tag renamed to backend
eslint.config.mjs ESLint config updates + frontend-specific overrides
docs/user-guides/Perform_static_analysis.md Sonar org/project keys updated
docs/index.md Docs badge link updated
docs/_config.yml Docs description + GitHub repo link updated
docker-compose.yaml Local dev stack (frontend/backend/lambda)
containers/frontend/tsconfig.json Frontend TS config (allowJs)
containers/frontend/src/setupTests.js CRA-style Jest setup
containers/frontend/src/reportWebVitals.js CRA vitals helper
containers/frontend/src/Pages/History.js History page (S3 results browsing)
containers/frontend/src/Pages/FileUploadPage.js Upload page orchestrator
containers/frontend/src/index.js CRA entrypoint + AuthProvider
containers/frontend/src/index.css Base styles
containers/frontend/src/components/Shared.css Shared button styling
containers/frontend/src/components/Login.js Cognito login form
containers/frontend/src/components/Login.css Login styling
containers/frontend/src/components/Header.js Header/nav + logout
containers/frontend/src/components/Header.css Header styling
containers/frontend/src/components/FileUpload.js File input + DataURL extraction
containers/frontend/src/components/FileUpload.css File upload styling
containers/frontend/src/components/Costingtool.js Cost calculator component
containers/frontend/src/components/Costingtool.css Cost tool styling
containers/frontend/src/components/AuthContext.js Cognito auth context + token storage
containers/frontend/src/components/AIfeedback.js Renders assessment results + markdown
containers/frontend/src/components/AIfeedback.css Feedback styling
containers/frontend/src/App.js Router + auth gating
containers/frontend/src/App.css Layout styles
containers/frontend/src/api/BackendAPIClient.js Axios client + token refresh queue
containers/frontend/src/tests/components/Costingtool.test.js Frontend unit tests for costing tool
containers/frontend/README.md Frontend README placeholder
containers/frontend/public/robots.txt CRA robots file
containers/frontend/public/nhs-england-white.svg NHS logo asset
containers/frontend/public/manifest.json CRA manifest
containers/frontend/public/index.html CRA HTML shell + env-config include
containers/frontend/public/favicon.ico Favicon asset
containers/frontend/public/env-config.js Runtime env injection stub
containers/frontend/package.json Frontend deps/scripts (CRA)
containers/frontend/nginx.conf Nginx SPA config + caching
containers/frontend/entrypoint.sh Runtime env-config generation
containers/frontend/docker/Dockerfile Multi-stage build + Nginx runner
containers/frontend/docker/dev.Dockerfile Dev image for CRA server
containers/frontend/docker/dev-entrypoint.sh Dev server startup script
containers/frontend/build.sh Frontend build helper
containers/frontend/.gitignore Frontend gitignore
containers/frontend/.dockerignore Frontend dockerignore
containers/example-app/tsconfig.json Removed example container scaffold
containers/example-app/src/server.ts Removed example server
containers/example-app/src/tests/server.test.ts Removed example server tests
containers/example-app/package.json Removed example container package
containers/backend/tsconfig.json Backend TS config (baseUrl/paths)
containers/backend/src/server.ts Express server + CORS + auth middleware
containers/backend/src/s3-service.ts S3 pagination + getObject parsing
containers/backend/src/s3-router.ts /s3/history and /s3/download routes
containers/backend/src/constants.ts Backend constants
containers/backend/src/auth.ts Cognito JWT validation + middleware/404
containers/backend/src/auth-error.ts AuthError type
containers/backend/src/tests/s3-service.test.ts S3 service unit tests
containers/backend/README.md Backend README placeholder
containers/backend/package.json Backend deps/scripts
containers/backend/jest.config.ts Backend Jest config updates
containers/backend/docker/Dockerfile Backend runtime container
containers/backend/docker/dev.Dockerfile Backend dev container
containers/backend/docker/dev-entrypoint.sh Backend watch + node --watch runner
containers/backend/build.sh Backend build helper
containers/backend/.gitignore Backend gitignore
containers/backend/.dockerignore Backend dockerignore
AGENTS.md Agent guidance updated for containers + lambdas
.github/dependabot.yaml Dependabot config adjusted

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread scripts/githooks/check-file-format.sh
Comment thread containers/backend/src/server.ts Outdated
Comment thread lambdas/bedrock-prompt-messager/src/bedrock-service.ts
Comment thread lambdas/bedrock-prompt-messager/src/bedrock-service.ts
Comment thread tests/playwright/playwright.config.ts
Comment thread containers/frontend/src/components/AuthContext.js
Comment thread AGENTS.md Outdated
Comment thread lambdas/bedrock-prompt-messager/src/bedrock-service.ts
Comment thread containers/frontend/src/components/FileUpload.css Outdated
Comment thread containers/frontend/src/components/FileUpload.js Outdated
timireland and others added 2 commits April 21, 2026 13:29
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Tim Ireland <tim.ireland@hscic.gov.uk>
timireland and others added 4 commits April 23, 2026 15:08
Signed-off-by: Tim Ireland <tim.ireland@hscic.gov.uk>
Signed-off-by: Tim Ireland <tim.ireland@hscic.gov.uk>
- to supress expecteded failure logs which are actually expected in
  tests
@joeds13 joeds13 force-pushed the port-poc-components branch 2 times, most recently from d2adaf9 to d0cd3df Compare April 23, 2026 15:43
@joeds13 joeds13 force-pushed the port-poc-components branch from d0cd3df to 42cdeb2 Compare April 23, 2026 16:22
@joeds13 joeds13 force-pushed the port-poc-components branch 2 times, most recently from fbc50a3 to 83f9fc7 Compare April 27, 2026 13:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants