Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .env.example
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
API_KEY=
PIPELEX_INFERENCE_API_KEY=
PIPELEX_GATEWAY_API_KEY=
36 changes: 29 additions & 7 deletions .pipelex/inference/backends.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,14 @@
#
####################################################################################################

[pipelex_inference]
display_name = "⭐ Pipelex Inference"
enabled = true
endpoint = "https://inference.pipelex.com/v1"
api_key = "${PIPELEX_INFERENCE_API_KEY}"
[pipelex_gateway]
display_name = "⭐ Pipelex Gateway"
enabled = true # Enable after accepting terms via `pipelex init config`
api_key = "${PIPELEX_GATEWAY_API_KEY}"

[anthropic]
enabled = false
api_key = "${ANTHROPIC_API_KEY}"
claude_4_tokens_limit = 8192

[azure_openai]
display_name = "Azure OpenAI"
Expand Down Expand Up @@ -55,6 +53,11 @@ enabled = false
endpoint = "https://api.groq.com/openai/v1"
api_key = "${GROQ_API_KEY}"

[huggingface]
display_name = "Hugging Face"
enabled = false
api_key = "${HF_TOKEN}"

[mistral]
display_name = "Mistral AI"
enabled = false
Expand All @@ -69,9 +72,21 @@ display_name = "OpenAI"
enabled = false
api_key = "${OPENAI_API_KEY}"

[portkey]
display_name = "Portkey"
enabled = false
endpoint = "https://api.portkey.ai/v1"
api_key = "${PORTKEY_API_KEY}"

[scaleway]
display_name = "Scaleway"
enabled = false
endpoint = "${SCALEWAY_ENDPOINT}"
api_key = "${SCALEWAY_API_KEY}"

[vertexai]
display_name = "Google Vertex AI"
enabled = false
enabled = false # This is the only one we disable beacuse setting it up requires internet access just to get credentials so it fails in CI sandboxes
gcp_project_id = "${GCP_PROJECT_ID}"
gcp_location = "${GCP_LOCATION}"
gcp_credentials_file_path = "${GCP_CREDENTIALS_FILE_PATH}"
Expand All @@ -84,3 +99,10 @@ api_key = "${XAI_API_KEY}"

[internal] # software-only backend, runs internally, without AI
enabled = true

# Deprecated
[pipelex_inference]
display_name = "🛑 Legacy Pipelex Inference"
enabled = false
endpoint = "https://inference.pipelex.com/v1"
api_key = "${PIPELEX_INFERENCE_API_KEY}"
28 changes: 14 additions & 14 deletions .pipelex/inference/backends/anthropic.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,19 +39,11 @@ outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 0.25, output = 1.25 }

[claude-3-opus]
model_id = "claude-3-opus-20240229"
max_tokens = 4096
inputs = ["text", "images"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 15.0, output = 75.0 }

# --- Claude 3.7 Series --------------------------------------------------------
["claude-3.7-sonnet"]
model_id = "claude-3-7-sonnet-20250219"
max_tokens = 8192
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }
Expand All @@ -60,15 +52,15 @@ costs = { input = 3.0, output = 15.0 }
[claude-4-sonnet]
model_id = "claude-sonnet-4-20250514"
max_tokens = 64000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }

[claude-4-opus]
model_id = "claude-opus-4-20250514"
max_tokens = 32000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }
Expand All @@ -77,7 +69,7 @@ costs = { input = 3.0, output = 15.0 }
["claude-4.1-opus"]
model_id = "claude-opus-4-1-20250805"
max_tokens = 32000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }
Expand All @@ -86,15 +78,23 @@ costs = { input = 3.0, output = 15.0 }
["claude-4.5-sonnet"]
model_id = "claude-sonnet-4-5-20250929"
max_tokens = 64000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }

["claude-4.5-haiku"]
model_id = "claude-haiku-4-5-20251001"
max_tokens = 64000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 1.0, output = 5.0 }

["claude-4.5-opus"]
model_id = "claude-opus-4-5-20251101"
max_tokens = 64000
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 5.0, output = 25.0 }
98 changes: 91 additions & 7 deletions .pipelex/inference/backends/azure_openai.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@

[defaults]
model_type = "llm"
sdk = "azure_openai"
sdk = "azure_openai_responses"
prompting_target = "openai"
structure_method = "instructor/openai_tools"
structure_method = "instructor/openai_responses_tools"

################################################################################
# LANGUAGE MODELS
Expand Down Expand Up @@ -68,62 +68,146 @@ model_id = "o1-mini-2024-09-12"
inputs = ["text"]
outputs = ["text", "structured"]
costs = { input = 3.0, output = 12.0 }
constraints = ["temperature_must_be_1"]
valued_constraints = { fixed_temperature = 1 }

[o1]
model_id = "o1-2024-12-17"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 15.0, output = 60.0 }
constraints = ["temperature_must_be_1"]
valued_constraints = { fixed_temperature = 1 }

[o3-mini]
model_id = "o3-mini-2025-01-31"
inputs = ["text"]
outputs = ["text", "structured"]
costs = { input = 1.1, output = 4.4 }
constraints = ["temperature_must_be_1"]
valued_constraints = { fixed_temperature = 1 }

[o3]
model_id = "o3-2025-04-16"
inputs = ["text"]
outputs = ["text", "structured"]
costs = { input = 2, output = 8 }
constraints = ["temperature_must_be_1"]
valued_constraints = { fixed_temperature = 1 }

# --- GPT-5 Series -------------------------------------------------------------
[gpt-5-mini]
model_id = "gpt-5-mini-2025-08-07"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 0.25, output = 2.0 }
valued_constraints = { fixed_temperature = 1 }

[gpt-5-nano]
model_id = "gpt-5-nano-2025-08-07"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 0.05, output = 0.4 }
valued_constraints = { fixed_temperature = 1 }

[gpt-5-chat]
model_id = "gpt-5-chat-2025-08-07"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 1.25, output = 10.0 }
valued_constraints = { fixed_temperature = 1 }

[gpt-5]
model_id = "gpt-5-2025-08-07"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 1.25, output = 10.0 }
valued_constraints = { fixed_temperature = 1 }

# --- GPT-5.1 Series -------------------------------------------------------------
["gpt-5.1"]
model_id = "gpt-5.1-2025-11-13"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 1.25, output = 10.0 }
valued_constraints = { fixed_temperature = 1 }

["gpt-5.1-chat"]
model_id = "gpt-5.1-chat-2025-11-13"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 1.25, output = 10.0 }
valued_constraints = { fixed_temperature = 1 }

["gpt-5.1-codex"]
model_id = "gpt-5.1-codex-2025-11-13"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 1.25, output = 10.0 }
valued_constraints = { fixed_temperature = 1 }

# --- GPT-5.2 Series -------------------------------------------------------------
["gpt-5.2"]
model_id = "gpt-5.2-2025-12-11"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 1.75, output = 14.0 }

["gpt-5.2-chat"]
model_id = "gpt-5.2-chat-2025-12-11"
inputs = ["text", "images"]
outputs = ["text", "structured"]
costs = { input = 1.25, output = 10.0 }
valued_constraints = { fixed_temperature = 1 }

################################################################################
# IMAGE GENERATION MODELS
################################################################################

# --- OpenAI Image Generation --------------------------------------------------
[gpt-image-1]
sdk = "azure_rest_img_gen"
model_type = "img_gen"
model_id = "gpt-image-1-2025-04-15"
inputs = ["text"]
outputs = ["image"]
costs = { input = 0.04, output = 0.0 }
costs = { input = 10, output = 40 }

[gpt-image-1.rules]
prompt = "positive_only"
num_images = "gpt"
aspect_ratio = "gpt"
background = "gpt"
inference = "gpt"
safety_checker = "unavailable"
output_format = "gpt"

[gpt-image-1-mini]
sdk = "azure_rest_img_gen"
model_type = "img_gen"
model_id = "gpt-image-1-mini-2025-10-06"
inputs = ["text"]
outputs = ["image"]
costs = { input = 2.5, output = 8 }

[gpt-image-1-mini.rules]
prompt = "positive_only"
num_images = "gpt"
aspect_ratio = "gpt"
background = "gpt"
inference = "gpt"
safety_checker = "unavailable"
output_format = "gpt"

["gpt-image-1.5"]
sdk = "azure_rest_img_gen"
model_type = "img_gen"
model_id = "gpt-image-1.5-2025-12-16"
inputs = ["text"]
outputs = ["image"]
costs = { input = 8, output = 32 }

["gpt-image-1.5".rules]
prompt = "positive_only"
num_images = "gpt"
aspect_ratio = "gpt"
background = "gpt"
inference = "gpt"
safety_checker = "unavailable"
output_format = "gpt"
25 changes: 17 additions & 8 deletions .pipelex/inference/backends/bedrock.toml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ costs = { input = 3.0, output = 15.0 }
sdk = "bedrock_anthropic"
model_id = "us.anthropic.claude-3-7-sonnet-20250219-v1:0"
max_tokens = 8192
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }
Expand All @@ -69,7 +69,7 @@ costs = { input = 3.0, output = 15.0 }
sdk = "bedrock_anthropic"
model_id = "us.anthropic.claude-sonnet-4-20250514-v1:0"
max_tokens = 64000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }
Expand All @@ -78,7 +78,7 @@ costs = { input = 3.0, output = 15.0 }
sdk = "bedrock_anthropic"
model_id = "us.anthropic.claude-opus-4-20250514-v1:0"
max_tokens = 32000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }
Expand All @@ -87,25 +87,34 @@ costs = { input = 3.0, output = 15.0 }
sdk = "bedrock_anthropic"
model_id = "us.anthropic.claude-opus-4-1-20250805-v1:0"
max_tokens = 32000
inputs = ["text", "images"]
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }

["claude-4.5-sonnet"]
sdk = "bedrock_anthropic"
model_id = "us.anthropic.claude-sonnet-4-5-20250929-v1:0"
max_tokens = 8192
inputs = ["text", "images"]
max_tokens = 64000
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 3.0, output = 15.0 }

["claude-4.5-haiku"]
sdk = "bedrock_anthropic"
model_id = "us.anthropic.claude-haiku-4-5-20251001-v1:0"
max_tokens = 8192
inputs = ["text", "images"]
max_tokens = 64000
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 1.0, output = 5.0 }

["claude-4.5-opus"]
sdk = "bedrock_anthropic"
model_id = "global.anthropic.claude-opus-4-5-20251101-v1:0"
max_tokens = 64000
inputs = ["text", "images", "pdf"]
outputs = ["text", "structured"]
max_prompt_images = 100
costs = { input = 5.0, output = 25.0 }
Loading