-
Notifications
You must be signed in to change notification settings - Fork 4
Goose agent loop #22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Goose agent loop #22
Conversation
…/goose * 'main' of https://github.com/block/ai-migrate: implement support for response_format (#21)
src/ai_migrate/migrate.py
Outdated
| for i in range(goose.max_retries): | ||
| log(f"Running migration attempt {i + 1} with Goose") | ||
|
|
||
| if goose.system_prompt: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure the naming here makes sense. this is definitely not a system prompt
src/ai_migrate/migrate.py
Outdated
| The verification output may be large so pipe it to a file verification_output.txt and read it from there. | ||
| Keep trying until the migration passes verification. | ||
| """ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this works with goose the same way as an actual system prompt. Goose already has one, so this is being treated as a user prompt. Not sure if any ranking is assigned in the LLM
src/ai_migrate/migrate.py
Outdated
| Keep trying until the migration passes verification. | ||
| """ | ||
|
|
||
| if goose_extra: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah extra is definitely not the system prompt.
src/ai_migrate/migrate.py
Outdated
| target_dir_rel_path: Path | str | None = None, | ||
| target_basename: str = None, | ||
| tools: list[Tool] = None, | ||
| goose: Optional[GooseConfig] = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
src/ai_migrate/migrate.py
Outdated
| target_basename: str = "", | ||
| dont_create_evals: bool = False, | ||
| tools: list[Tool] = None, | ||
| goose: Optional[GooseConfig] = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we rename to goose config?
| verification_output = (stderr or stdout or b"").decode() | ||
| exit_code = verify_process.returncode | ||
|
|
||
| if exit_code > best_exit_code and best_exit_code != 0: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok I need some explanation here. how would code 127 be better than 128? Aren't we just hunting for 0 and anything else?
No description provided.