diff --git a/scripts/mma_exec.py b/scripts/mma_exec.py index 9c8cc1a..b2a6155 100644 --- a/scripts/mma_exec.py +++ b/scripts/mma_exec.py @@ -198,10 +198,10 @@ def execute_agent(role: str, prompt: str, docs: list[str]) -> str: command_text += f"\n\nTASK: {prompt}\n\n" # Use subprocess with input to pipe the prompt via stdin, avoiding WinError 206. - # We use -p '-' to read from stdin if supported, otherwise just a placeholder that stdin appends to. + # We use -p 'mma_task' to ensure non-interactive (headless) mode and valid parsing. ps_command = ( f"if (Test-Path 'C:\\projects\\misc\\setup_gemini.ps1') {{ . 'C:\\projects\\misc\\setup_gemini.ps1' }}; " - f"gemini -p '---' --output-format json --model {model}" + f"gemini -p 'mma_task' --output-format json --model {model}" ) cmd = ['powershell.exe', '-NoProfile', '-Command', ps_command]