diff --git a/bin/disinto b/bin/disinto index 45875b4..7a15de4 100755 --- a/bin/disinto +++ b/bin/disinto @@ -373,6 +373,7 @@ check_pipeline_stall = false # roles = ["dev"] # forge_user = "dev-qwen" # compact_pct = 60 +# poll_interval = 60 # [mirrors] # github = "git@github.com:user/repo.git" diff --git a/lib/generators.sh b/lib/generators.sh index c9aea55..96bccb8 100644 --- a/lib/generators.sh +++ b/lib/generators.sh @@ -50,6 +50,7 @@ _generate_local_model_services() { API_KEY) api_key="$value" ;; FORGE_USER) forge_user="$value" ;; COMPACT_PCT) compact_pct="$value" ;; + POLL_INTERVAL) poll_interval_val="$value" ;; ---) if [ -n "$service_name" ] && [ -n "$base_url" ]; then cat >> "$temp_file" </dev/null) done diff --git a/lib/hire-agent.sh b/lib/hire-agent.sh index d6e6fe8..91d1fc8 100644 --- a/lib/hire-agent.sh +++ b/lib/hire-agent.sh @@ -417,6 +417,7 @@ EOF local model="${model_name:-local-model}" # Write [agents.] section to the project TOML + local interval="${poll_interval:-60}" echo " Writing [agents.${section_name}] to ${toml_file}..." python3 -c ' import sys, re, pathlib @@ -427,7 +428,7 @@ base_url = sys.argv[3] model = sys.argv[4] agent_name = sys.argv[5] role = sys.argv[6] -compact_pct = sys.argv[7] +poll_interval = sys.argv[7] p = pathlib.Path(toml_path) text = p.read_text() @@ -440,7 +441,8 @@ model = "{model}" api_key = "sk-no-key-required" roles = ["{role}"] forge_user = "{agent_name}" -compact_pct = {compact_pct} +compact_pct = 60 +poll_interval = {poll_interval} """ # Check if section already exists and replace it @@ -463,7 +465,7 @@ else: text = text.rstrip() + "\n" + new_section p.write_text(text) -' "$toml_file" "$section_name" "$local_model" "$model" "$agent_name" "$role" "${poll_interval:-60}" +' "$toml_file" "$section_name" "$local_model" "$model" "$agent_name" "$role" "$interval" echo " Agent config written to TOML" diff --git a/projects/disinto.toml.example b/projects/disinto.toml.example index 8721545..04e99e5 100644 --- a/projects/disinto.toml.example +++ b/projects/disinto.toml.example @@ -34,6 +34,7 @@ check_pipeline_stall = false # roles = ["dev"] # forge_user = "dev-qwen" # compact_pct = 60 +# poll_interval = 60 # [mirrors] # github = "git@github.com:johba/disinto.git"