mirror of
https://github.com/fauxpilot/fauxpilot.git
synced 2025-07-16 10:03:25 -07:00
Rewrite API to FastAPI, separate API from CodeGen, remove dev settings
This commit is contained in:
parent
6b69437b7e
commit
8895b74238
9 changed files with 942 additions and 262 deletions
23
copilot_proxy/models.py
Normal file
23
copilot_proxy/models.py
Normal file
|
@ -0,0 +1,23 @@
|
|||
from typing import Optional, Union
|
||||
|
||||
from pydantic import BaseModel
|
||||
|
||||
|
||||
class OpenAIinput(BaseModel):
|
||||
model: str
|
||||
prompt: Optional[str]
|
||||
suffix: Optional[str]
|
||||
max_tokens: Optional[int] = 16
|
||||
temperature: Optional[float] = 0.6
|
||||
top_p: Optional[float] = 1.0
|
||||
n: Optional[int] = 1
|
||||
stream: Optional[bool]
|
||||
logprobs: Optional[int] = None
|
||||
echo: Optional[bool]
|
||||
stop: Optional[Union[str, list]]
|
||||
presence_penalty: Optional[float] = 0
|
||||
frequency_penalty: Optional[float] = 1
|
||||
best_of: Optional[int] = 1
|
||||
logit_bias: Optional[dict]
|
||||
user: Optional[str]
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue