@shiftleftpt/sbd-toe-mcp 0.1.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.
Files changed (93) hide show
  1. package/.env.example +35 -0
  2. package/LICENSE +201 -0
  3. package/README.md +323 -0
  4. package/data/publish/algolia_docs_records.json +148847 -0
  5. package/data/publish/algolia_docs_records_enriched.json +194004 -0
  6. package/data/publish/algolia_entities_records.json +74715 -0
  7. package/data/publish/algolia_entities_records_enriched.json +177587 -0
  8. package/data/publish/algolia_index_settings.json +102 -0
  9. package/data/publish/sbd-toe-index-compact.json +111 -0
  10. package/data/reports/run_manifest.json +10 -0
  11. package/dist/backend/semantic-index-gateway.d.ts +25 -0
  12. package/dist/backend/semantic-index-gateway.js +555 -0
  13. package/dist/backend/semantic-index-gateway.js.map +1 -0
  14. package/dist/backend/semantic-index-gateway.test.d.ts +1 -0
  15. package/dist/backend/semantic-index-gateway.test.js +384 -0
  16. package/dist/backend/semantic-index-gateway.test.js.map +1 -0
  17. package/dist/bootstrap/checkout-backend.d.ts +31 -0
  18. package/dist/bootstrap/checkout-backend.js +136 -0
  19. package/dist/bootstrap/checkout-backend.js.map +1 -0
  20. package/dist/bootstrap/checkout-backend.test.d.ts +1 -0
  21. package/dist/bootstrap/checkout-backend.test.js +158 -0
  22. package/dist/bootstrap/checkout-backend.test.js.map +1 -0
  23. package/dist/bootstrap/release-checkout.d.ts +8 -0
  24. package/dist/bootstrap/release-checkout.js +168 -0
  25. package/dist/bootstrap/release-checkout.js.map +1 -0
  26. package/dist/bootstrap/release-checkout.test.d.ts +1 -0
  27. package/dist/bootstrap/release-checkout.test.js +137 -0
  28. package/dist/bootstrap/release-checkout.test.js.map +1 -0
  29. package/dist/config.d.ts +4 -0
  30. package/dist/config.js +81 -0
  31. package/dist/config.js.map +1 -0
  32. package/dist/index.d.ts +2 -0
  33. package/dist/index.js +1063 -0
  34. package/dist/index.js.map +1 -0
  35. package/dist/orchestrator/ask-manual.d.ts +13 -0
  36. package/dist/orchestrator/ask-manual.js +202 -0
  37. package/dist/orchestrator/ask-manual.js.map +1 -0
  38. package/dist/prompt/build-answer-prompt.d.ts +2 -0
  39. package/dist/prompt/build-answer-prompt.js +51 -0
  40. package/dist/prompt/build-answer-prompt.js.map +1 -0
  41. package/dist/prompt/system-prompt.d.ts +1 -0
  42. package/dist/prompt/system-prompt.js +94 -0
  43. package/dist/prompt/system-prompt.js.map +1 -0
  44. package/dist/resources/sbd-toe-resources.d.ts +18 -0
  45. package/dist/resources/sbd-toe-resources.js +164 -0
  46. package/dist/resources/sbd-toe-resources.js.map +1 -0
  47. package/dist/resources/sbd-toe-resources.test.d.ts +1 -0
  48. package/dist/resources/sbd-toe-resources.test.js +134 -0
  49. package/dist/resources/sbd-toe-resources.test.js.map +1 -0
  50. package/dist/test-utils.d.ts +153 -0
  51. package/dist/test-utils.js +176 -0
  52. package/dist/test-utils.js.map +1 -0
  53. package/dist/tools/generate-document.d.ts +22 -0
  54. package/dist/tools/generate-document.js +392 -0
  55. package/dist/tools/generate-document.js.map +1 -0
  56. package/dist/tools/generate-document.test.d.ts +1 -0
  57. package/dist/tools/generate-document.test.js +189 -0
  58. package/dist/tools/generate-document.test.js.map +1 -0
  59. package/dist/tools/map-review-scope.d.ts +20 -0
  60. package/dist/tools/map-review-scope.js +299 -0
  61. package/dist/tools/map-review-scope.js.map +1 -0
  62. package/dist/tools/map-review-scope.test.d.ts +1 -0
  63. package/dist/tools/map-review-scope.test.js +204 -0
  64. package/dist/tools/map-review-scope.test.js.map +1 -0
  65. package/dist/tools/plan-repo-governance.d.ts +41 -0
  66. package/dist/tools/plan-repo-governance.js +509 -0
  67. package/dist/tools/plan-repo-governance.js.map +1 -0
  68. package/dist/tools/plan-repo-governance.test.d.ts +1 -0
  69. package/dist/tools/plan-repo-governance.test.js +237 -0
  70. package/dist/tools/plan-repo-governance.test.js.map +1 -0
  71. package/dist/tools/structured-tools.d.ts +5 -0
  72. package/dist/tools/structured-tools.js +310 -0
  73. package/dist/tools/structured-tools.js.map +1 -0
  74. package/dist/tools/structured-tools.test.d.ts +1 -0
  75. package/dist/tools/structured-tools.test.js +459 -0
  76. package/dist/tools/structured-tools.test.js.map +1 -0
  77. package/dist/types.d.ts +160 -0
  78. package/dist/types.js +2 -0
  79. package/dist/types.js.map +1 -0
  80. package/dist/upstream/backend-contract.d.ts +3 -0
  81. package/dist/upstream/backend-contract.js +37 -0
  82. package/dist/upstream/backend-contract.js.map +1 -0
  83. package/dist/validators/ai-disclosure.d.ts +39 -0
  84. package/dist/validators/ai-disclosure.js +183 -0
  85. package/dist/validators/ai-disclosure.js.map +1 -0
  86. package/dist/validators/ai-disclosure.test.d.ts +1 -0
  87. package/dist/validators/ai-disclosure.test.js +244 -0
  88. package/dist/validators/ai-disclosure.test.js.map +1 -0
  89. package/examples/claude-desktop.json +8 -0
  90. package/examples/vscode.mcp.json +9 -0
  91. package/package.json +50 -0
  92. package/prompts/sbd-toe-chat-system.md +71 -0
  93. package/smithery.yaml +44 -0
@@ -0,0 +1,71 @@
1
+ You are an assistant for the **Security by Design - Theory of Everything (SbD-ToE)** documentation.
2
+
3
+ Answer questions using **only the retrieved SbD-ToE documentation context provided by this MCP server**.
4
+
5
+ Rules:
6
+
7
+ - Use only information present in the retrieved SbD-ToE context.
8
+ - If the answer cannot be found, say that the information is not available.
9
+ - Provide concise and technically precise answers.
10
+ - When possible reference the relevant chapter or section and provide the documentation link if it exists in the retrieved context.
11
+ - The base url for the manual is {{SITE_BASE_URL}}; the manual base slug is {{MANUAL_BASE_URL}}; cross check is {{CROSS_CHECK_BASE_URL}}.
12
+ - If a canonical URL is not available in the retrieved context, do not invent section anchors. Prefer page-level URLs only when they are deterministic.
13
+
14
+ ---
15
+
16
+ ## Index usage
17
+
18
+ The retrieved context comes from two semantic indices/snapshots with different purposes.
19
+
20
+ **{{DOCS_INDEX}}**
21
+ Primary documentation source containing extracted content from the SbD-ToE manual.
22
+ Use it as the main source for conceptual, operational and technical answers.
23
+
24
+ **{{ENTITIES_INDEX}}**
25
+ Contains structured concepts such as roles, phases, practices, artifacts and policies.
26
+ Use it to clarify relationships and structure answers.
27
+
28
+ ---
29
+
30
+ ## Understanding the manual
31
+
32
+ The SbD-ToE manual is structured by chapters and document layers.
33
+
34
+ Typical sections include:
35
+
36
+ **Intro**
37
+ Conceptual explanation of practices.
38
+
39
+ **Lifecycle**
40
+ Operational guidance describing who performs actions, in which SDLC phase, and which artifacts must exist.
41
+
42
+ **Technical complement**
43
+ Implementation details, examples and tooling.
44
+
45
+ **Policies**
46
+ Organizational governance and required security policies.
47
+
48
+ ---
49
+
50
+ ## Risk model
51
+
52
+ Applications are classified by risk:
53
+
54
+ L1 - low risk
55
+ L2 - medium risk
56
+ L3 - critical
57
+
58
+ These represent application risk, not maturity.
59
+
60
+ Practices are applied proportionally to risk.
61
+
62
+ ---
63
+
64
+ ## Answer style
65
+
66
+ When possible structure answers as:
67
+
68
+ Role
69
+ Phase
70
+ Action
71
+ Artifact
package/smithery.yaml ADDED
@@ -0,0 +1,44 @@
1
+ # smithery.yaml — Smithery MCP registry configuration
2
+ # https://smithery.ai
3
+ name: sbd-toe-mcp
4
+ description: "MCP server for SbD-ToE security manual — structured tools for Claude, GitHub Copilot and other MCP clients"
5
+ license: Apache-2.0
6
+ homepage: "https://github.com/Shiftleftpt/sbd-toe-mcp-poc#readme"
7
+
8
+ startCommand:
9
+ type: stdio
10
+ configSchema:
11
+ type: object
12
+ properties:
13
+ DEBUG_MODE:
14
+ type: string
15
+ default: "false"
16
+ description: "Enable debug logging (true/false)"
17
+ MAX_CONTEXT_RECORDS:
18
+ type: string
19
+ default: "8"
20
+ description: "Maximum number of records returned per query (integer ≥ 1)"
21
+ SITE_BASE_URL:
22
+ type: string
23
+ default: "https://www.securitybydesign.dev/"
24
+ description: "Base URL for the SbD-ToE website (optional override)"
25
+ MANUAL_BASE_URL:
26
+ type: string
27
+ default: "https://www.securitybydesign.dev/sbd-toe/sbd-manual/"
28
+ description: "Base URL for the SbD-ToE manual (optional override)"
29
+ CROSS_CHECK_BASE_URL:
30
+ type: string
31
+ default: "https://www.securitybydesign.dev/sbd-toe/cross-check-normativo/"
32
+ description: "Base URL for normative cross-check (optional override)"
33
+ SBD_TOE_APP_ROOT:
34
+ type: string
35
+ description: "Override the app root path (advanced — leave empty for auto-detection)"
36
+ additionalProperties: false
37
+ commandFunction: |-
38
+ (config) => ({
39
+ command: "npx",
40
+ args: ["-y", "@shiftleftpt/sbd-toe-mcp"],
41
+ env: Object.fromEntries(
42
+ Object.entries(config).filter(([_, v]) => v !== undefined && v !== "")
43
+ )
44
+ })