Compare commits
4 Commits
f1f1e42e7e
...
a8ce6102d2
Author | SHA1 | Date | |
---|---|---|---|
a8ce6102d2 | |||
236d1c0a10 | |||
7a35029a18 | |||
7a73a1e3fc |
|
@ -387,6 +387,9 @@ def run_ollama_and_get_yes_or_no(cwd, initial_texts: list[str]) -> bool:
|
||||||
|
|
||||||
|
|
||||||
def verify_solution(repository_path: Path, issue_content: str) -> bool:
|
def verify_solution(repository_path: Path, issue_content: str) -> bool:
|
||||||
|
if not EVALUATOR_MODEL:
|
||||||
|
return True
|
||||||
|
|
||||||
summary = run_ollama(
|
summary = run_ollama(
|
||||||
repository_path,
|
repository_path,
|
||||||
[
|
[
|
||||||
|
@ -472,10 +475,6 @@ def solve_issue_in_repository(
|
||||||
if not resolution.success:
|
if not resolution.success:
|
||||||
return resolution
|
return resolution
|
||||||
|
|
||||||
if not EVALUATOR_MODEL:
|
|
||||||
logger.info('No evaluator model specified, skipping evaluation')
|
|
||||||
return resolution
|
|
||||||
|
|
||||||
# Verify whether this is a satisfactory solution
|
# Verify whether this is a satisfactory solution
|
||||||
if verify_solution(repository_path, issue_content):
|
if verify_solution(repository_path, issue_content):
|
||||||
return resolution
|
return resolution
|
||||||
|
|
|
@ -45,6 +45,16 @@ def parse_args():
|
||||||
default=300,
|
default=300,
|
||||||
help='Interval in seconds between checks in daemon mode (default: 300)',
|
help='Interval in seconds between checks in daemon mode (default: 300)',
|
||||||
)
|
)
|
||||||
|
parser.add_argument(
|
||||||
|
'--aider-model',
|
||||||
|
help='Model to use for generating code (overrides default)',
|
||||||
|
default=None,
|
||||||
|
)
|
||||||
|
parser.add_argument(
|
||||||
|
'--evaluator-model',
|
||||||
|
help='Model to use for evaluating code (overrides default)',
|
||||||
|
default=None,
|
||||||
|
)
|
||||||
return parser.parse_args()
|
return parser.parse_args()
|
||||||
|
|
||||||
|
|
||||||
|
@ -52,6 +62,14 @@ def main():
|
||||||
logging.basicConfig(level='INFO')
|
logging.basicConfig(level='INFO')
|
||||||
args = parse_args()
|
args = parse_args()
|
||||||
|
|
||||||
|
# Override default models if provided
|
||||||
|
import aider_gitea as core
|
||||||
|
|
||||||
|
if args.aider_model:
|
||||||
|
core.CODE_MODEL = args.aider_model
|
||||||
|
if args.evaluator_model:
|
||||||
|
core.EVALUATOR_MODEL = args.evaluator_model
|
||||||
|
|
||||||
seen_issues_db = SeenIssuesDB()
|
seen_issues_db = SeenIssuesDB()
|
||||||
client = GiteaClient(args.gitea_url, secrets.gitea_token())
|
client = GiteaClient(args.gitea_url, secrets.gitea_token())
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user