mirror of
https://github.com/FoundationAgents/MetaGPT.git
synced 2026-06-11 15:15:18 +02:00
feat: + kwargs
This commit is contained in:
parent
e316fe4d60
commit
c513712928
1 changed files with 2 additions and 2 deletions
|
|
@ -223,7 +223,7 @@ class OpenAIGPTAPI(BaseGPTAPI, RateLimiter):
|
|||
return CONFIG.max_tokens_rsp
|
||||
return get_max_completion_tokens(messages, self.model, CONFIG.max_tokens_rsp)
|
||||
|
||||
async def get_summary(self, text: str, max_words=200, keep_language: bool = False):
|
||||
async def get_summary(self, text: str, max_words=200, keep_language: bool = False, **kwargs):
|
||||
max_token_count = DEFAULT_MAX_TOKENS
|
||||
max_count = 100
|
||||
text_length = len(text)
|
||||
|
|
@ -262,7 +262,7 @@ class OpenAIGPTAPI(BaseGPTAPI, RateLimiter):
|
|||
logger.debug(f"summary rsp: {response}")
|
||||
return response
|
||||
|
||||
async def get_context_title(self, text: str, max_words=5) -> str:
|
||||
async def get_context_title(self, text: str, max_words=5, **kwargs) -> str:
|
||||
"""Generate text title"""
|
||||
summary = await self.get_summary(text, max_words=500)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue