Observed since 21 Oct, 10:01 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
aibaton
An agent automation framework based on Codex/Claude Code
Headless Agent Automation — Python wrapper for codex/claude CLI, enabling arbitrarily complex agent automation/workflows through programmable prompts.
loop_max)parse(options)Install the aibaton SKILL using codex, then enter the following prompt:
$aibaton Find Go code files over 300 lines in the project and optimize them, extract redundant code into sub-functions following DRY principles, and update references in other files.
Output executable script:
from aibaton import run, set_default
import os
set_default(provider="codex", dangerous_permissions=True)
prompt = """Review the current file code and optimize, extract redundant code into sub-functions following DRY principles, and update references in other files."""
def get_go_files(root_dir: str, min_lines: int = 0) -> list[str]:
go_files = []
for dirpath, _, filenames in os.walk(root_dir):
for f in filenames:
if f.endswith('.go'):
fpath = os.path.join(dirpath, f)
if min_lines <= 0 or sum(1 for _ in open(fpath)) > min_lines:
go_files.append(fpath)
return go_files
if __name__ == '__main__':
par_dir = '/app/banbot'
for fpath in get_go_files(par_dir, min_lines=300):
run(f"File path: {fpath}\n\n{prompt}", cwd=par_dir, add_dirs=[par_dir], stream=True)
Run the script as prompted.
After codex uses aibaton skill, output executable script: work_flow.py
pip install aibaton
# or
uv pip install aibaton
Apache 2.0
Download counts and popularity will appear here as the collector receives them.
Declarations describe requirements; they are not a resolved dependency graph.
bdist_wheel · 24.94 KB · Python py3
sdist · 23.27 KB · Python source
Observed since 21 Oct, 10:01 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package_version:bcd218d0c2571e0128e2d9e4607ece2b8949c5bb5f8a65047f39f4e5889ed00f