@@ -13,8 +13,7 @@ more details below in Usage section.
13
13
14
14
## Base Interface
15
15
The package exposes two simple interfaces for communicating with LLMs (In the future, we
16
- will expand the interface to support more tasks like embeddings, list models, edits, etc.
17
- and we will add a standardized for LLMs param like max_tokens, temperature, etc.):
16
+ will expand the interface to support more tasks like list models, edits, etc.):
18
17
``` python
19
18
from abc import ABC , abstractmethod
20
19
from dataclasses import dataclass, field
@@ -47,7 +46,7 @@ class BaseLLMAPIClient(BaseLLMClient, ABC):
47
46
48
47
@abstractmethod
49
48
async def text_completion (self , prompt : str , model : Optional[str ] = None , max_tokens : int | None = None ,
50
- temperature : Optional[float ] = None , ** kwargs ) -> list[str ]:
49
+ temperature : Optional[float ] = None , top_p : Optional[ float ] = None , ** kwargs ) -> list[str ]:
51
50
raise NotImplementedError ()
52
51
53
52
async def embedding (self , text : str , model : Optional[str ] = None , ** kwargs ) -> list[float ]:
@@ -200,6 +199,7 @@ Contributions are welcome! Please check out the todos below, and feel free to op
200
199
- [x] Convert common models parameter
201
200
- [x] temperature
202
201
- [x] max_tokens
202
+ - [x] top_p
203
203
- [ ] more
204
204
205
205
### Development
0 commit comments