11"""Redis OSS Release Automation CLI."""
22
33import asyncio
4- import json
54import logging
65import os
76from typing import Dict , List , Optional
1514from .bht .tree import TreeInspector , async_tick_tock , initialize_tree_and_state
1615from .config import load_config
1716from .conversation_models import ConversationArgs , InboxMessage
18- from .github_client_async import GitHubClientAsync
1917from .logging_config import setup_logging
2018from .models import ReleaseArgs , ReleaseType , SlackArgs
2119from .state_display import print_state_table
@@ -133,8 +131,9 @@ def release_print(
133131
134132@app .command ()
135133def conversation_print () -> None :
134+ """Print and render (using graphviz) the conversation behaviour tree."""
136135 setup_logging ()
137- tree , state = initialize_conversation_tree (
136+ tree , _ = initialize_conversation_tree (
138137 ConversationArgs (
139138 inbox = InboxMessage (message = "test" , context = []), openai_api_key = "dummy"
140139 )
@@ -143,37 +142,6 @@ def conversation_print() -> None:
143142 print (unicode_tree (tree .root ))
144143
145144
146- @app .command ()
147- def conversation (
148- message : str = typer .Option (
149- ..., "--message" , "-m" , help = "Natural language release command"
150- ),
151- config : Optional [str ] = typer .Option (
152- None , "--config" , "-c" , help = "Path to config file (default: config.yaml)"
153- ),
154- openai_api_key : Optional [str ] = typer .Option (
155- None ,
156- "--openai-api-key" ,
157- help = "OpenAI API key (if not provided, uses OPENAI_API_KEY env var)" ,
158- ),
159- tree_cutoff : int = typer .Option (
160- 5000 , "--tree-cutoff" , help = "Max number of ticks to run the tree for"
161- ),
162- ) -> None :
163- setup_logging ()
164- if not openai_api_key :
165- openai_api_key = os .getenv ("OPENAI_API_KEY" )
166-
167- args = ConversationArgs (
168- inbox = InboxMessage (message = message , context = []),
169- openai_api_key = openai_api_key ,
170- config_path = config ,
171- )
172- tree , _ = initialize_conversation_tree (args )
173- tree .tick ()
174- print (unicode_tree (tree .root ))
175-
176-
177145@app .command ()
178146def release (
179147 release_tag : str = typer .Argument (..., help = "Release tag (e.g., 8.4-m01-int1)" ),
0 commit comments