bedrock-claude-chat icon indicating copy to clipboard operation
bedrock-claude-chat copied to clipboard

[BUG] Chat History Defaults to Spanish Despite English Language Selected

Open marcwojcik opened this issue 1 year ago • 4 comments
trafficstars

Describe the bug

The Bedrock-Claude-Chat application is displaying the chat history in Spanish, despite the user selecting a different language (e.g., English) in the Menu settings.

To Reproduce

Open a new chat and the history will always come up default to Spanish.

Screenshots

2024-04-11_17-20-55

Additional context

Add any other context about the problem here.

marcwojcik avatar Apr 11 '24 21:04 marcwojcik

Possible solution

Pass language explicitly to:

  • GET /conversation/{conversation_id}/proposed-title endpoint
  • propose_conversation_title

statefb avatar Apr 16 '24 03:04 statefb

PR merged but leave the issue still open because enough evidence was not provided on #247. Please leave your comment below if you have still same issue.

statefb avatar Apr 17 '24 06:04 statefb

I got this error, even though my backend had the update (ie "- Title must be in the same language as the conversation.")

Maybe interpolate a preferred/default language in the parameter for the prompt string? ie

def propose_conversation_title(
    user_id: str,
    conversation_id: str,
    language: str,
    model: Literal[
        "claude-instant-v1",
        "claude-v2",
        "claude-v3-opus",
        "claude-v3-sonnet",
        "claude-v3-haiku",
    ] = "claude-v3-haiku",
) -> str:
    PROMPT = f"""Reading the conversation above, what is the appropriate title for the conversation? When answering the title, please follow the rules below:
<rules>
- Title must be in {language}.
- Title length must be from 15 to 20 characters.
- Prefer more specific title than general. Your title should always be distinct from others.
- Return the conversation title only. DO NOT include any strings other than the title.
</rules>
"""

josephedward avatar Apr 29 '24 19:04 josephedward

@josephedward I believe your proposal is one of the simplest and effective ways to address the root cause. It would be greatly appreciated if you could take the trouble to create a Pull Request. Thank you!

statefb avatar May 02 '24 11:05 statefb