Skip to content

AWS Bedrock Nova model produces different results based on line ending format #7364

@MaxRepin

Description

@MaxRepin

Checkboxes for prior research

Describe the bug

Description:

  • Using \n (Unix) line endings produces incorrect responses
  • Using \r\n (Windows) line endings produces correct responses
  • Same prompt content, only line ending format differs
  • Affects structured prompts with sections and rules

Impact:

  • Inconsistent behavior between environments
  • Forces developers to normalize line endings
  • Could affect other users with similar issues

Test Case:

  • Model: amazon.nova-lite-v1:0
  • Region: eu-west-2
  • Same prompt with \n vs \r\n produces different reasoning and responses

Regression Issue

  • Select this option if this issue appears to be a regression.

SDK version number

@aws-sdk/package-name@version, ...

Which JavaScript Runtime is this issue in?

Node.js

Details of the browser/Node.js/ReactNative version

@aws-sdk/[email protected]

Reproduction Steps

  • Model: amazon.nova-lite-v1:0
  • Region: eu-west-2

Observed Behavior

  • Same prompt with \n vs \r\n produces different reasoning and responses

Expected Behavior

Most modern systems normalize line endings. Same prompt with \n vs \r\n should produce identical reasoning and responses.

Possible Solution

normalize line endings

Additional Information/Context

No response

Metadata

Metadata

Assignees

Labels

bugThis issue is a bug.closed-for-stalenessp2This is a standard priority issueresponse-requestedWaiting on additional info and feedback. Will move to \"closing-soon\" in 7 days.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions