mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-25 06:44:59 +00:00
Support weak_model=False
This commit is contained in:
parent
f81b62dfea
commit
4e50f0d095
4 changed files with 12 additions and 4 deletions
|
@ -123,7 +123,7 @@ def main():
|
|||
|
||||
assistant.append(line)
|
||||
|
||||
summarizer = ChatSummary(models.Model(models.DEFAULT_WEAK_MODEL_NAME))
|
||||
summarizer = ChatSummary(models.Model(models.DEFAULT_WEAK_MODEL_NAME, weak_model=False))
|
||||
summary = summarizer.summarize(messages[-40:])
|
||||
dump(summary)
|
||||
|
||||
|
|
|
@ -139,6 +139,9 @@ class Model:
|
|||
self.max_chat_history_tokens = 2 * 1024
|
||||
|
||||
self.configure_model_settings(model)
|
||||
if weak_model is False:
|
||||
self.weak_model_name = None
|
||||
else:
|
||||
self.get_weak_model(weak_model, require_model_info)
|
||||
|
||||
def configure_model_settings(self, model):
|
||||
|
@ -174,7 +177,7 @@ class Model:
|
|||
|
||||
self.weak_model = Model(
|
||||
self.weak_model_name,
|
||||
weak_model=self.weak_model_name,
|
||||
weak_model=False,
|
||||
require_model_info=require_model_info,
|
||||
)
|
||||
return self.weak_model
|
||||
|
|
|
@ -25,7 +25,7 @@ class GitRepo:
|
|||
self.models = [
|
||||
Model(
|
||||
DEFAULT_WEAK_MODEL_NAME,
|
||||
weak_model=DEFAULT_WEAK_MODEL_NAME,
|
||||
weak_model=False,
|
||||
require_model_info=False,
|
||||
)
|
||||
]
|
||||
|
|
|
@ -91,6 +91,11 @@ for more information on how to populate the above configuration values.
|
|||
If you can make an LLM accessible via an OpenAI compatible API,
|
||||
you can use `--openai-api-base` to connect to a different API endpoint.
|
||||
|
||||
You might need to use `--no-require-model-info` to tell aider to
|
||||
work with an unknown model that has no metadata available like
|
||||
context size, token costs, etc.
|
||||
Some minor functionality will be limited when using such models.
|
||||
|
||||
## Other LLMs
|
||||
|
||||
Aider uses the [litellm](https://docs.litellm.ai/docs/providers) package
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue