chore: bump and switch LLM models per query complexity (CM-1051)#3944
Merged
chore: bump and switch LLM models per query complexity (CM-1051)#3944
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the LLM model selection strategy to reduce cost on simpler tasks and improve quality on complex workflows by introducing Claude Haiku 4.5 and moving several query types to Claude Sonnet 4.
Changes:
- Add
CLAUDE_HAIKU_4_5model type, including region mapping and pricing estimates. - Switch selected “simple/structured” query types to Haiku 4.5 and “complex/multi-step” query types to Sonnet 4.
- Update
LLM_SETTINGSto reflect the new per-query model choices.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
| services/libs/types/src/llm.ts | Adds Haiku 4.5 region/pricing and remaps multiple LlmQueryType settings to Haiku 4.5 or Sonnet 4. |
| services/libs/types/src/enums/llm.ts | Adds the CLAUDE_HAIKU_4_5 model enum value (Bedrock model ID). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
48f9522 to
0a0ad33
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Signed-off-by: Yeganathan S <63534555+skwowet@users.noreply.github.com>
Signed-off-by: Yeganathan S <63534555+skwowet@users.noreply.github.com>
Signed-off-by: Yeganathan S <63534555+skwowet@users.noreply.github.com>
0a0ad33 to
ec0aa27
Compare
joanagmaia
approved these changes
Mar 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Bump and switch LLM models per query complexity to optimize cost and response quality:
CLAUDE_HAIKU_4_5model type with region and pricing configuration.Note
Medium Risk
Changes which Bedrock Claude models (and token limits) are used for multiple production LLM query types, which can affect output quality/structure and downstream enrichment behavior. Low code risk but moderate product/data-risk if new model outputs differ from prior assumptions.
Overview
Updates LLM model routing and cost configuration. Adds
CLAUDE_HAIKU_4_5toLlmModelTypeand wires it intoLLM_MODEL_REGION_MAPandLLM_MODEL_PRICING_MAP.Rebalances models and token limits per query type. Several
LLM_SETTINGSentries move from Sonnet 3.5/V2 toCLAUDE_SONNET_4for more complex tasks, while simpler tasks (LinkedIn related profile matching, GitHub org matching, bot validation) switch toCLAUDE_HAIKU_4_5;max_tokensvalues are reduced from the prior very large defaults to tighter per-task limits (including loweringMEMBER_ENRICHMENTto65536).Written by Cursor Bugbot for commit 704be90. This will update automatically on new commits. Configure here.