Repository navigation
[Spec 0022] Stateless consult tool for multi-agent consultation - #30
Merged
Merged
Conversation
…tion - Add codev/bin/consult Python CLI wrapper for gemini-cli and codex - Create consultant role definition in codev/roles/consultant.md - Support model aliases: gemini/pro, codex/gpt - Use GEMINI_SYSTEM_MD env var for gemini-cli system prompt - Use CODEX_SYSTEM_PROMPT env var for codex system prompt - Enable autonomous mode with --yolo (gemini) and --full-auto (codex) - Log queries to .consult/history.log - Add --dry-run flag for debugging - Support stdin piping for queries - Add typer dependency to codev/requirements.txt - Update CLAUDE.md and AGENTS.md with documentation
Contributor
Author
Architect Review with Expert ConsultationI've reviewed this PR with feedback from Gemini Pro and GPT-5 Codex. The implementation is solid overall, but there are a few issues to address before merge. 🔴 Critical Issues1. Typer double-command bug (Lines 82, 191-192)Current Typer setup requires Fix: Replace # Remove @app.command() decorator
# Change main block to:
if __name__ == "__main__":
typer.run(consult)2. Wrong codex env var (Line 148)The codex CLI expects Fix: env = {"CODEX_SYSTEM_MESSAGE": role}🟡 Medium Issues3. Import-time constants (Lines 45-47)
Fix: Move these inside 4. stdin stripping (Line 105)
Fix: query = sys.stdin.read().rstrip("\n")✅ What's Good
Please address these issues and push an update. |
- Fix Typer double-command bug: use typer.run(consult) instead of app pattern - Fix codex env var: CODEX_SYSTEM_MESSAGE (not CODEX_SYSTEM_PROMPT) - Move path constants inside function for lazy loading - Use .rstrip() instead of .strip() for stdin to preserve leading whitespace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
consultCLI tool for invoking external AI models (gemini-cli, codex) with a consultant roleChanges
codev/bin/consult: Python CLI using Typer with autonomous mode (--yolofor gemini,--full-autofor codex)codev/roles/consultant.md: Collaborative consultant role definitioncodev-skeleton/roles/consultant.md: Copy for new projectscodev/requirements.txt: Add typer dependency.gitignore: Add.consult/for history logsCLAUDE.md/AGENTS.md: Documentation for the consult toolUsage
Test plan
--helpoutput.consult/history.logRevision History
v2 - PR Review Fixes
typer.run(consult)instead of app patternCODEX_SYSTEM_MESSAGE(notCODEX_SYSTEM_PROMPT).rstrip()instead of.strip()for stdin to preserve leading whitespacev1 - Initial Implementation
GEMINI_SYSTEM_MDenv var (not--system-instructionsflag)