Compare commits
2 Commits
7da687ab3f
...
3e5b88a736
Author | SHA1 | Date | |
---|---|---|---|
3e5b88a736 | |||
95b38b506e |
|
@ -158,16 +158,19 @@ AIDER_LINT = bash_cmd(
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
LLM_MESSAGE_FORMAT = (
|
LLM_MESSAGE_FORMAT = """{issue}
|
||||||
"""{issue}\nGo ahead with the changes you deem appropriate without waiting for explicit approval."""
|
|
||||||
)
|
Go ahead with the changes you deem appropriate without waiting for explicit approval.
|
||||||
|
|
||||||
|
Do not draft changes beforehand; produce changes only once prompted for a specific file.
|
||||||
|
"""
|
||||||
|
|
||||||
CODE_MODEL = None
|
CODE_MODEL = None
|
||||||
EVALUATOR_MODEL = 'ollama/gemma3:27b'
|
EVALUATOR_MODEL = 'ollama/gemma3:27b'
|
||||||
|
|
||||||
MODEL_EDIT_MODES = {
|
MODEL_EDIT_MODES = {
|
||||||
'ollama/qwen3:32b': 'diff',
|
'ollama/qwen3:32b': 'diff',
|
||||||
'ollama/hf.co/unsloth/Qwen3-30B-A3B-GGUF:Q4_K_M': 'whole',
|
'ollama/hf.co/unsloth/Qwen3-30B-A3B-GGUF:Q4_K_M': 'diff-fenced',
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -186,6 +189,7 @@ def create_aider_command(issue: str) -> list[str]:
|
||||||
'--auto-test',
|
'--auto-test',
|
||||||
'--no-auto-lint',
|
'--no-auto-lint',
|
||||||
'--yes',
|
'--yes',
|
||||||
|
'--disable-playwright',
|
||||||
'--timeout',
|
'--timeout',
|
||||||
str(10_000),
|
str(10_000),
|
||||||
]
|
]
|
||||||
|
@ -360,6 +364,9 @@ def issue_solution_round(repository_path, issue_content):
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
def remove_thinking_tokens(text: str) -> str:
|
||||||
|
text = re.sub('^<think>.*?</think>', '', text, flags=re.MULTILINE)
|
||||||
|
return text.strip()
|
||||||
|
|
||||||
def run_ollama(cwd: Path, texts: list[str]) -> str:
|
def run_ollama(cwd: Path, texts: list[str]) -> str:
|
||||||
cmd = ['ollama', 'run', EVALUATOR_MODEL.removeprefix('ollama/')]
|
cmd = ['ollama', 'run', EVALUATOR_MODEL.removeprefix('ollama/')]
|
||||||
|
@ -373,6 +380,7 @@ def run_ollama(cwd: Path, texts: list[str]) -> str:
|
||||||
text=True,
|
text=True,
|
||||||
)
|
)
|
||||||
stdout, stderr = process.communicate('\n'.join(texts))
|
stdout, stderr = process.communicate('\n'.join(texts))
|
||||||
|
stdout = remove_thinking_tokens(stdout)
|
||||||
print(stdout)
|
print(stdout)
|
||||||
return stdout
|
return stdout
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user