Skip to content

Build AI methods with your coding agent, then run them anywhere: as an MCP for chatbots, as a webapp for people, or via API for your software.

Add claude-opus-4-7 model with breaking change support

Louis Choquelcdabd29a8e05
diff --git a/.pipelex-dev/test_profiles.toml b/.pipelex-dev/test_profiles.toml
index c2cf468ea..18f588987 100644
--- a/.pipelex-dev/test_profiles.toml
+++ b/.pipelex-dev/test_profiles.toml
@@ -67,6 +67,7 @@ anthropic = [
"claude-4.5-sonnet",
"claude-4.5-opus",
"claude-4.6-opus",
+ "claude-4.7-opus",
]
# --- DeepSeek Models ---
diff --git a/.pipelex/inference/backends/anthropic.toml b/.pipelex/inference/backends/anthropic.toml
index 145ba192f..88b6d412d 100644
--- a/.pipelex/inference/backends/anthropic.toml
+++ b/.pipelex/inference/backends/anthropic.toml
@@ -109,3 +109,14 @@ outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 5.0, output = 25.0 }
thinking_mode = "adaptive"
+
+# --- Claude 4.7 Series --------------------------------------------------------
+["claude-4.7-opus"]
+model_id = "claude-opus-4-7"
+max_tokens = 128000
+inputs = ["text", "images", "pdf"]
+outputs = ["text", "structured"]
+max_prompt_images = 100
+costs = { input = 5.0, output = 25.0 }
+thinking_mode = "adaptive"
+listed_constraints = ["temperature_unsupported"]
diff --git a/.pipelex/inference/backends/bedrock.toml b/.pipelex/inference/backends/bedrock.toml
index c8f67e65e..6b263ea5c 100644
--- a/.pipelex/inference/backends/bedrock.toml
+++ b/.pipelex/inference/backends/bedrock.toml
@@ -134,3 +134,15 @@ outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 5.0, output = 25.0 }
thinking_mode = "adaptive"
+
+# --- Claude 4.7 Series --------------------------------------------------------
+["claude-4.7-opus"]
+sdk = "bedrock_anthropic"
+model_id = "global.anthropic.claude-opus-4-7-v1"
+max_tokens = 128000
+inputs = ["text", "images", "pdf"]
+outputs = ["text", "structured"]
+max_prompt_images = 100
+costs = { input = 5.0, output = 25.0 }
+thinking_mode = "adaptive"
+listed_constraints = ["temperature_unsupported"]
diff --git a/pipelex/cogt/llm/llm_job_components.py b/pipelex/cogt/llm/llm_job_components.py
index 8950766dc..3600ee096 100644
--- a/pipelex/cogt/llm/llm_job_components.py
+++ b/pipelex/cogt/llm/llm_job_components.py
@@ -11,6 +11,7 @@ class ReasoningEffort(StrEnum):
LOW = "low"
MEDIUM = "medium"
HIGH = "high"
+ XHIGH = "xhigh"
MAX = "max"
diff --git a/pipelex/cogt/model_backends/constraints.py b/pipelex/cogt/model_backends/constraints.py
index e672583af..f8f75b7a2 100644
--- a/pipelex/cogt/model_backends/constraints.py
+++ b/pipelex/cogt/model_backends/constraints.py
@@ -3,6 +3,7 @@ from pipelex.types import StrEnum
class ListedConstraint(StrEnum):
TEMPERATURE_MUST_BE_MULTIPLIED_BY_2 = "temperature_must_be_multiplied_by_2"
+ TEMPERATURE_UNSUPPORTED = "temperature_unsupported"
MAX_TOKENS_MUST_BE_HIGH_ENOUGH = "max_tokens_must_be_high_enough"
diff --git a/pipelex/kit/configs/inference/backends/anthropic.toml b/pipelex/kit/configs/inference/backends/anthropic.toml
index 145ba192f..88b6d412d 100644
--- a/pipelex/kit/configs/inference/backends/anthropic.toml
+++ b/pipelex/kit/configs/inference/backends/anthropic.toml
@@ -109,3 +109,14 @@ outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 5.0, output = 25.0 }
thinking_mode = "adaptive"
+
+# --- Claude 4.7 Series --------------------------------------------------------
+["claude-4.7-opus"]
+model_id = "claude-opus-4-7"
+max_tokens = 128000
+inputs = ["text", "images", "pdf"]
+outputs = ["text", "structured"]
+max_prompt_images = 100
+costs = { input = 5.0, output = 25.0 }
+thinking_mode = "adaptive"
+listed_constraints = ["temperature_unsupported"]
diff --git a/pipelex/kit/configs/inference/backends/bedrock.toml b/pipelex/kit/configs/inference/backends/bedrock.toml
index c8f67e65e..6b263ea5c 100644
--- a/pipelex/kit/configs/inference/backends/bedrock.toml
+++ b/pipelex/kit/configs/inference/backends/bedrock.toml
@@ -134,3 +134,15 @@ outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 5.0, output = 25.0 }
thinking_mode = "adaptive"
+
+# --- Claude 4.7 Series --------------------------------------------------------
+["claude-4.7-opus"]
+sdk = "bedrock_anthropic"
+model_id = "global.anthropic.claude-opus-4-7-v1"
+max_tokens = 128000
+inputs = ["text", "images", "pdf"]
+outputs = ["text", "structured"]
+max_prompt_images = 100
+costs = { input = 5.0, output = 25.0 }
+thinking_mode = "adaptive"
+listed_constraints = ["temperature_unsupported"]
diff --git a/pipelex/kit/configs/inference/backends/pipelex_gateway_models.md b/pipelex/kit/configs/inference/backends/pipelex_gateway_models.md
index eb436dcad..bbf7aef88 100644
--- a/pipelex/kit/configs/inference/backends/pipelex_gateway_models.md
+++ b/pipelex/kit/configs/inference/backends/pipelex_gateway_models.md
@@ -21,14 +21,6 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
</thead>
<tbody>
<tr>
-<td>claude-3.7-sonnet</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
-</tr>
-<tr>
<td>claude-4-opus</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
@@ -85,23 +77,15 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
</tr>
<tr>
-<td>deepseek-v3.1</td>
+<td>claude-4.6-sonnet</td>
+<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">❌</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">❌</td>
-<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
-</tr>
-<tr>
-<td>deepseek-v3.2</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">❌</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">❌</td>
<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
</tr>
<tr>
-<td>deepseek-v3.2-speciale</td>
+<td>deepseek-v3.2</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">❌</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">❌</td>
@@ -512,12 +496,6 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
</thead>
<tbody>
<tr>
-<td>flux-2-pro</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
-<td style="text-align:center;background-color:rgba(76,175,80,0.15)">✅</td>
-</tr>
-<tr>
<td>gpt-image-1</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
<td style="text-align:center;background-color:rgba(33,150,243,0.15)">✅</td>
@@ -558,6 +536,6 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
> **AUTO-GENERATED FILE** - Do not edit manually.
-> Last updated: 2026-03-21T13:07:30Z
+> Last updated: 2026-04-14T09:23:56Z
>
> Run `pipelex-dev update-gateway-models` or `make ugm` to regenerate.
\ No newline at end of file
diff --git a/pipelex/kit/configs/inference/backends/pipelex_gateway_models_plain.md b/pipelex/kit/configs/inference/backends/pipelex_gateway_models_plain.md
index 576697ea7..42a5a369c 100644
--- a/pipelex/kit/configs/inference/backends/pipelex_gateway_models_plain.md
+++ b/pipelex/kit/configs/inference/backends/pipelex_gateway_models_plain.md
@@ -7,9 +7,6 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
## Language Models (LLM)
-- **claude-3.7-sonnet**
- - inputs: text, images, pdf
- - outputs: text, structured
- **claude-4-opus**
- inputs: text, images, pdf
- outputs: text, structured
@@ -31,15 +28,12 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
- **claude-4.6-opus**
- inputs: text, images, pdf
- outputs: text, structured
-- **deepseek-v3.1**
- - inputs: text
+- **claude-4.6-sonnet**
+ - inputs: text, images, pdf
- outputs: text, structured
- **deepseek-v3.2**
- inputs: text
- outputs: text, structured
-- **deepseek-v3.2-speciale**
- - inputs: text
- - outputs: text, structured
- **gemini-2.5-flash**
- inputs: text, images, pdf
- outputs: text, structured
@@ -184,9 +178,6 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
## Image Generation Models
-- **flux-2-pro**
- - inputs: text, images
- - outputs: image
- **gpt-image-1**
- inputs: text, images
- outputs: image
@@ -208,6 +199,6 @@ For configuration details, see the [documentation](https://docs.pipelex.com/late
> **AUTO-GENERATED FILE** - Do not edit manually.
-> Last updated: 2026-03-21T13:07:30Z
+> Last updated: 2026-04-14T09:23:56Z
>
> Run `pipelex-dev update-gateway-models` or `make ugm` to regenerate.
\ No newline at end of file
diff --git a/pipelex/pipelex.toml b/pipelex/pipelex.toml
index e64f64ce5..f9f74d391 100644
--- a/pipelex/pipelex.toml
+++ b/pipelex/pipelex.toml
@@ -151,6 +151,7 @@ minimal = "minimal"
low = "low"
medium = "medium"
high = "high"
+xhigh = "xhigh"
max = "xhigh"
[cogt.llm_config.anthropic_config]
@@ -162,6 +163,7 @@ minimal = "low"
low = "low"
medium = "medium"
high = "high"
+xhigh = "xhigh"
max = "max"
[cogt.llm_config.google_config.effort_to_level_map]
@@ -170,6 +172,7 @@ minimal = "low"
low = "low"
medium = "medium"
high = "high"
+xhigh = "high"
max = "high"
[cogt.llm_config.mistral_config.effort_to_level_map]
@@ -178,6 +181,7 @@ minimal = "reasoning"
low = "reasoning"
medium = "reasoning"
high = "reasoning"
+xhigh = "reasoning"
max = "reasoning"
[cogt.llm_config.llm_job_config]
@@ -189,6 +193,7 @@ minimal = 512
low = 1024
medium = 5000
high = 16384
+xhigh = 32768
max = 65536
[cogt.llm_config.effort_to_budget_maps.gemini]
@@ -197,6 +202,7 @@ minimal = 512
low = 1024
medium = 5000
high = 16384
+xhigh = 32768
max = 65536
[cogt.llm_config.generic_templates]
diff --git a/pipelex/plugins/anthropic/anthropic_config.py b/pipelex/plugins/anthropic/anthropic_config.py
index 95631e12c..1e7a4ab97 100644
--- a/pipelex/plugins/anthropic/anthropic_config.py
+++ b/pipelex/plugins/anthropic/anthropic_config.py
@@ -10,6 +10,7 @@ class AnthropicEffortLevel(StrEnum):
LOW = "low"
MEDIUM = "medium"
HIGH = "high"
+ XHIGH = "xhigh"
MAX = "max"
diff --git a/pipelex/plugins/anthropic/anthropic_llm_worker.py b/pipelex/plugins/anthropic/anthropic_llm_worker.py
index 47c9c1fe3..f221a8276 100644
--- a/pipelex/plugins/anthropic/anthropic_llm_worker.py
+++ b/pipelex/plugins/anthropic/anthropic_llm_worker.py
@@ -16,6 +16,7 @@ from pipelex.cogt.llm.llm_utils import (
)
from pipelex.cogt.llm.llm_worker_internal_abstract import LLMWorkerInternalAbstract
from pipelex.cogt.llm.thinking_mode import ThinkingMode
+from pipelex.cogt.model_backends.constraints import ListedConstraint
from pipelex.cogt.model_backends.model_spec import InferenceModelSpec
from pipelex.config import get_config
from pipelex.plugins.anthropic.anthropic_exceptions import (
@@ -193,7 +194,13 @@ class AnthropicLLMWorker(LLMWorkerInternalAbstract):
) -> _ThinkingParams:
"""Build thinking params when reasoning_budget is specified."""
match thinking_mode:
- case ThinkingMode.ADAPTIVE | ThinkingMode.MANUAL:
+ case ThinkingMode.ADAPTIVE:
+ msg = (
+ f"Model '{self.inference_model.desc}' uses adaptive thinking which does not support reasoning_budget. "
+ f"Use reasoning_effort instead (e.g. reasoning_effort='high')"
+ )
+ raise LLMCapabilityError(msg)
+ case ThinkingMode.MANUAL:
safe_budget = min(budget, max_tokens - 1)
log.verbose(f"Anthropic thinking with explicit budget_tokens={safe_budget}")
thinking_config: ThinkingConfigParam = {"type": "enabled", "budget_tokens": safe_budget}
@@ -221,11 +228,12 @@ class AnthropicLLMWorker(LLMWorkerInternalAbstract):
try:
# Use streaming internally to avoid SDK long-request protection
+ temperature_unsupported = ListedConstraint.TEMPERATURE_UNSUPPORTED in self.inference_model.listed_constraints
async with self.anthropic_async_client.messages.stream(
messages=[message],
system=llm_job.llm_prompt.system_text or omit,
model=self.inference_model.model_id,
- temperature=omit if thinking_params.suppress_temperature else job_params.temperature,
+ temperature=omit if (thinking_params.suppress_temperature or temperature_unsupported) else job_params.temperature,
max_tokens=max_tokens,
thinking=thinking_params.thinking or omit,
output_config=thinking_params.output_config or omit,
@@ -294,13 +302,14 @@ class AnthropicLLMWorker(LLMWorkerInternalAbstract):
requested_max_tokens = job_params.max_tokens or self.default_max_tokens
effective_max_tokens = min(requested_max_tokens, safe_max_tokens)
+ temperature_unsupported = ListedConstraint.TEMPERATURE_UNSUPPORTED in self.inference_model.listed_constraints
try:
result_object, completion = await self.instructor_for_objects.chat.completions.create_with_completion(
messages=messages,
response_model=schema,
max_retries=llm_job.job_config.max_retries,
model=self.inference_model.model_id,
- temperature=job_params.temperature,
+ temperature=omit if temperature_unsupported else job_params.temperature,
max_tokens=effective_max_tokens,
timeout=float(timeout_seconds), # Explicit timeout disables SDK's long-request protection
)