mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2025-04-25 07:07:32 -04:00
feat: support switch model (#5575)
* feat: ai settings page * chore: intergate client api * chore: replace open ai calls * chore: disable gen image from ai * chore: clippy * chore: remove learn about ai * chore: fix wanrings * chore: fix restart button title * chore: remove await * chore: remove loading indicator --------- Co-authored-by: nathan <nathan@appflowy.io> Co-authored-by: Lucas.Xu <lucas.xu@appflowy.io>
This commit is contained in:
parent
40312f4260
commit
54c9d12171
78 changed files with 1383 additions and 499 deletions
|
@ -205,3 +205,32 @@ impl From<RepeatedRelatedQuestion> for RepeatedRelatedQuestionPB {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Default, ProtoBuf, Clone, Debug)]
|
||||
pub struct CompleteTextPB {
|
||||
#[pb(index = 1)]
|
||||
pub text: String,
|
||||
|
||||
#[pb(index = 2)]
|
||||
pub completion_type: CompletionTypePB,
|
||||
|
||||
#[pb(index = 3)]
|
||||
pub stream_port: i64,
|
||||
}
|
||||
|
||||
#[derive(Default, ProtoBuf, Clone, Debug)]
|
||||
pub struct CompleteTextTaskPB {
|
||||
#[pb(index = 1)]
|
||||
pub task_id: String,
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, ProtoBuf_Enum, Default)]
|
||||
pub enum CompletionTypePB {
|
||||
UnknownCompletionType = 0,
|
||||
#[default]
|
||||
ImproveWriting = 1,
|
||||
SpellingAndGrammar = 2,
|
||||
MakeShorter = 3,
|
||||
MakeLonger = 4,
|
||||
ContinueWriting = 5,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue