Repository: skypilot-org/skypilot
Pull request: [Docs] Fix inconsistent example in spot instance documentation
Fixes #3995



Problem statement:
[Docs] Inconsistent Example in Spot Instance Documentation
The documentation states that when one spot replica is available, SkyServe will provision an on-demand replica to meet the target number of replicas. However, the accompanying console output shows a scenario where there are 0 spot replicas available, which contradicts this explanation and could confuse users.

**Provided Console Output:**
```console
Services
NAME         VERSION  UPTIME  STATUS      REPLICAS  ENDPOINT
http-server  1        1m 17s  NO_REPLICA  0/4       54.227.229.217:30001

Service Replicas
SERVICE_NAME  ID  VERSION  ENDPOINT                   LAUNCHED    RESOURCES             STATUS         REGION
http-server   1   1        -                          1 min ago   1x GCP([Spot]vCPU=2)  PROVISIONING  us-east1
http-server   2   1        -                          1 min ago   1x GCP([Spot]vCPU=2)  PROVISIONING  us-central1
http-server   3   1        -                          1 mins ago  1x GCP(vCPU=2)        PROVISIONING  us-east1
http-server   4   1        -                          1 min ago   1x GCP(vCPU=2)        PROVISIONING  us-central1
```

**Original Text from Documentation:**
> "When the target number is 2 and only 1 spot replica is ready, SkyServe will provision 1 on-demand replica to meet the target number of replicas."

To enhance clarity, the explanation should be adjusted to accurately reflect the scenario where no spot replica is available, clearly showing that 2 on-demand replica is launched in response.

Hints from issue discussion:

Commit message: [Docs] Fix inconsistent example in spot instance documentation

Fixes #3995

Patch to review:
diff --git a/docs/source/serving/spot-policy.rst b/docs/source/serving/spot-policy.rst
index ff23b328705..1b812fea605 100644
--- a/docs/source/serving/spot-policy.rst
+++ b/docs/source/serving/spot-policy.rst
@@ -96,7 +96,7 @@ When the service is up, we can check the status of the service and the replicas
     http-server   3   1        -                          1 mins ago  1x GCP(vCPU=2)        PROVISIONING  us-east1     
     http-server   4   1        -                          1 min ago   1x GCP(vCPU=2)        PROVISIONING  us-central1
 
-When the required number of spot replicas are not available, SkyServe will provision the number of on-demand replicas needed to meet the target number of replicas. For example, when the target number is 2 and only 1 spot replica is ready, SkyServe will provision 1 on-demand replica to meet the target number of replicas. 
+When the required number of spot replicas are not available, SkyServe will provision the number of on-demand replicas needed to meet the target number of replicas. For example, when the target number is 2 and no spot replicas are ready, SkyServe will provision 2 on-demand replicas to meet the target number of replicas. 
 
 .. code-block:: console
 
@@ -157,4 +157,4 @@ Eventually, when the spot availability is back, SkyServe will automatically scal
     Service Replicas
     SERVICE_NAME  ID  VERSION  ENDPOINT                   LAUNCHED     RESOURCES             STATUS         REGION       
     http-server   2   1        http://34.68.226.193:8081  10 mins ago  1x GCP([Spot]vCPU=2)  READY          us-central1  
-    http-server   5   1        http://34.121.49.94:8081   1 min ago    1x GCP([Spot]vCPU=2)  READY          us-central1
\ No newline at end of file
+    http-server   5   1        http://34.121.49.94:8081   1 min ago    1x GCP([Spot]vCPU=2)  READY          us-central1


Code review comments:
diff_hunk: @@ -96,7 +96,7 @@ When the service is up, we can check the status of the service and the replicas
     http-server   3   1        -                          1 mins ago  1x GCP(vCPU=2)        PROVISIONING  us-east1     
     http-server   4   1        -                          1 min ago   1x GCP(vCPU=2)        PROVISIONING  us-central1
 
-When the required number of spot replicas are not available, SkyServe will provision the number of on-demand replicas needed to meet the target number of replicas. For example, when the target number is 2 and only 1 spot replica is ready, SkyServe will provision 1 on-demand replica to meet the target number of replicas. 
+When the required number of spot replicas are not available, SkyServe will provision the number of on-demand replicas needed to meet the target number of replicas. For example, when the target number is 2 and no spot replicas are ready, SkyServe will provision 2 on-demand replicas to meet the target number of replicas. 
path: docs/source/serving/spot-policy.rst
text: @user1:
```suggestion
When the required number of spot replicas are not available, SkyServe will provision on-demand replicas to meet the target number of replicas. For example, when the target number is 2 and no spot replicas are ready, SkyServe will provision 2 on-demand replicas to meet the target number of replicas. 
```