Extract HIGH-LEVEL software requirements from the source code below. Return a JSON array of requirements for the module "{{SectionTitle}}".

RULES:

  • Use “The CSCI shall…” syntax for every requirement.
  • Keep each requirement UNDER 200 characters.
  • Types: Capability, ExternalInterface, Performance, Safety, Security, DesignConstraint
  • QualificationMethod: Test, Analysis, Inspection, or Demonstration
  • Criticality: Essential, Desirable, or Optional
  • Focus on HIGH-LEVEL capabilities, not line-by-line implementation details.
  • A small file may only need 2-3 requirements. A complex module may need up to 8.
  • NEVER generate duplicate or overlapping requirements.
  • Every requirement must map to actual code behavior.
  • Return [] if no meaningful requirements can be extracted.

Generate IDs in the format REQ-{{IdPrefix}}-001, REQ-{{IdPrefix}}-002, etc.

Section: {{SectionTitle}} Description: {{ExistingBody}}

<source_code> {{SourceContext}} </source_code>

<output_format> Respond with ONLY a JSON object in this exact structure: { “requirements”: [ { “requirementId”: “REQ-XXX-001”, “body”: “The CSCI shall authenticate users via OAuth2 bearer tokens.”, “rationale”: “AuthController.Login() validates JWT tokens”, “type”: “Capability”, “qualificationMethod”: “Test”, “criticality”: “Essential”, “safetyLevel”: “QM” } ] } </output_format>