Update zed_llm_client
to v0.8.1 (#30433)
This PR updates the `zed_llm_client` crate to v0.8.1. The name of `Plan::Free` changed to `Plan::ZedFree` in this version. Release Notes: - N/A
This commit is contained in:
parent
000077facf
commit
f29c6e5661
10 changed files with 16 additions and 16 deletions
|
@ -75,7 +75,7 @@ impl Default for DebugAccountState {
|
|||
Self {
|
||||
enabled: false,
|
||||
trial_expired: false,
|
||||
plan: Plan::Free,
|
||||
plan: Plan::ZedFree,
|
||||
custom_prompt_usage: RequestUsage {
|
||||
limit: UsageLimit::Unlimited,
|
||||
amount: 0,
|
||||
|
|
|
@ -1085,11 +1085,11 @@ impl MessageEditor {
|
|||
let plan = user_store
|
||||
.current_plan()
|
||||
.map(|plan| match plan {
|
||||
Plan::Free => zed_llm_client::Plan::Free,
|
||||
Plan::Free => zed_llm_client::Plan::ZedFree,
|
||||
Plan::ZedPro => zed_llm_client::Plan::ZedPro,
|
||||
Plan::ZedProTrial => zed_llm_client::Plan::ZedProTrial,
|
||||
})
|
||||
.unwrap_or(zed_llm_client::Plan::Free);
|
||||
.unwrap_or(zed_llm_client::Plan::ZedFree);
|
||||
let usage = self.thread.read(cx).last_usage().or_else(|| {
|
||||
maybe!({
|
||||
let amount = user_store.model_request_usage_amount()?;
|
||||
|
|
|
@ -39,7 +39,7 @@ impl RenderOnce for UsageCallout {
|
|||
|
||||
let (title, message, button_text, url) = if is_limit_reached {
|
||||
match self.plan {
|
||||
Plan::Free => (
|
||||
Plan::ZedFree => (
|
||||
"Out of free prompts",
|
||||
"Upgrade to continue, wait for the next reset, or switch to API key."
|
||||
.to_string(),
|
||||
|
@ -61,7 +61,7 @@ impl RenderOnce for UsageCallout {
|
|||
}
|
||||
} else {
|
||||
match self.plan {
|
||||
Plan::Free => (
|
||||
Plan::ZedFree => (
|
||||
"Reaching free plan limit soon",
|
||||
format!(
|
||||
"{remaining} remaining - Upgrade to increase limit, or switch providers",
|
||||
|
@ -120,7 +120,7 @@ impl Component for UsageCallout {
|
|||
single_example(
|
||||
"Approaching limit (90%)",
|
||||
UsageCallout::new(
|
||||
Plan::Free,
|
||||
Plan::ZedFree,
|
||||
RequestUsage {
|
||||
limit: UsageLimit::Limited(50),
|
||||
amount: 45, // 90% of limit
|
||||
|
@ -131,7 +131,7 @@ impl Component for UsageCallout {
|
|||
single_example(
|
||||
"Limit reached (100%)",
|
||||
UsageCallout::new(
|
||||
Plan::Free,
|
||||
Plan::ZedFree,
|
||||
RequestUsage {
|
||||
limit: UsageLimit::Limited(50),
|
||||
amount: 50, // 100% of limit
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue