+
+
+ 2 · DEPLOYMENTS
+
+
- {deployments.length === 0 && (
-
- No deployments added yet.
-
- )}
-
- {deployments.map((dep, idx) => (
-
- {strategy === "priority-failover" && (
-
- #{dep.priority}
-
- )}
-
- {dep.model_name}
- {dep.litellm_provider ? ` (${dep.litellm_provider})` : ""}
-
- {strategy === "weighted" && (
-
updateDeploymentWeight(idx, val)}
- addonAfter="%"
- style={{ width: 100 }}
+ {/* Add selector */}
+ {showAddSelector && (
+
+
+
+ setSelectedDeployment(dep)}
/>
- )}
+
+
}
- onClick={() => removeDeployment(idx)}
- />
+ onClick={() => { setShowAddSelector(false); setSelectedDeployment(null); }}
+ >
+ Cancel
+
- ))}
+
+ )}
+
+ {/* Pipeline visualization */}
+ {deployments.length > 0 && (
+
+ {deployments.map((dep, idx) => {
+ const color = getProviderColor(dep.provider);
+ return (
+
+ {idx > 0 && (
+ →
+ )}
+
+ {idx + 1}
+ {dep.provider !== "-" ? dep.provider.split(" ")[0] : dep.model_name}
+
+
+ );
+ })}
+
+ )}
+
+ {/* Deployment cards */}
+ {deployments.length === 0 && !showAddSelector && (
+
+ No deployments yet. Click + Add to get started.
+
+ )}
+
+
+ {deployments.map((dep, idx) => {
+ const color = getProviderColor(dep.provider);
+ return (
+
+
toggleEnabled(idx)}
+ />
+
+ {idx + 1}
+
+ {/* Provider icon */}
+
+ {getProviderInitial(dep.provider)}
+
+ {/* Name */}
+
+
+ {dep.provider}
+
+
+ / {dep.model_name}
+
+
+ {/* Weight (only for weighted) */}
+ {strategy === "weighted" && (
+ updateWeight(idx, val)}
+ addonAfter="%"
+ style={{ width: 90 }}
+ />
+ )}
+ {/* Reorder */}
+
+
+
+
+ {/* Delete */}
+
+
+ );
+ })}
+
+
+
+ {/* Section 3: Logical Model Name */}
+
+
+ 3 · LOGICAL MODEL NAME
+
+
+ What callers use to invoke this group
+
+
+
+ setLogicalName(e.target.value)}
+ placeholder="prod-model"
+ className="flex-1 border-none outline-none text-sm font-mono text-gray-800 bg-transparent"
+ />
-
-
-
-
-
-
-
-
-
-
+ {/* Code snippet */}
+
+
-
-
-
+ {isEditing ? "Update Routing Group" : "Save Routing Group"}
+
+