diff --git a/openhands-cli/openhands_cli/tui/settings/settings_screen.py b/openhands-cli/openhands_cli/tui/settings/settings_screen.py index 983af5a39a..4822555539 100644 --- a/openhands-cli/openhands_cli/tui/settings/settings_screen.py +++ b/openhands-cli/openhands_cli/tui/settings/settings_screen.py @@ -174,7 +174,7 @@ class SettingsScreen: model=model, api_key=api_key, base_url=base_url, - service_id='agent', + usage_id='agent', metadata=get_llm_metadata(model_name=model, llm_type='agent'), ) diff --git a/openhands-cli/tests/settings/test_settings_workflow.py b/openhands-cli/tests/settings/test_settings_workflow.py index 940a9a802d..192938380e 100644 --- a/openhands-cli/tests/settings/test_settings_workflow.py +++ b/openhands-cli/tests/settings/test_settings_workflow.py @@ -18,7 +18,7 @@ def read_json(path: Path) -> dict: def make_screen_with_conversation(model='openai/gpt-4o-mini', api_key='sk-xyz'): - llm = LLM(model=model, api_key=SecretStr(api_key), service_id='test-service') + llm = LLM(model=model, api_key=SecretStr(api_key), usage_id='test-service') # Conversation(agent) signature may vary across versions; adapt if needed: from openhands.sdk.agent import Agent @@ -31,7 +31,7 @@ def seed_file(path: Path, model: str = 'openai/gpt-4o-mini', api_key: str = 'sk- store = AgentStore() store.file_store = LocalFileStore(root=str(path)) agent = get_default_cli_agent( - llm=LLM(model=model, api_key=SecretStr(api_key), service_id='test-service') + llm=LLM(model=model, api_key=SecretStr(api_key), usage_id='test-service') ) store.save(agent) diff --git a/openhands-cli/tests/test_conversation_runner.py b/openhands-cli/tests/test_conversation_runner.py index cdedb3e552..7e39a6f0b0 100644 --- a/openhands-cli/tests/test_conversation_runner.py +++ b/openhands-cli/tests/test_conversation_runner.py @@ -50,7 +50,7 @@ class FakeAgent(AgentBase): @pytest.fixture() def agent() -> FakeAgent: - llm = LLM(**default_config(), service_id='test-service') + llm = LLM(**default_config(), usage_id='test-service') return FakeAgent(llm=llm, tools=[]) diff --git a/openhands-cli/tests/test_directory_separation.py b/openhands-cli/tests/test_directory_separation.py index 350c3925dc..e95e34aa86 100644 --- a/openhands-cli/tests/test_directory_separation.py +++ b/openhands-cli/tests/test_directory_separation.py @@ -37,7 +37,7 @@ class TestToolFix: """Test that entire tools list is replaced with default tools when loading agent.""" # Create a mock agent with different tools and working directories mock_agent = Agent( - llm=LLM(model='test/model', api_key='test-key', service_id='test-service'), + llm=LLM(model='test/model', api_key='test-key', usage_id='test-service'), tools=[ Tool(name='BashTool'), Tool(name='FileEditorTool'), diff --git a/openhands-cli/tests/test_mcp_config_validation.py b/openhands-cli/tests/test_mcp_config_validation.py index 2404e86270..b549768192 100644 --- a/openhands-cli/tests/test_mcp_config_validation.py +++ b/openhands-cli/tests/test_mcp_config_validation.py @@ -26,7 +26,7 @@ def _create_agent(mcp_config=None) -> Agent: if mcp_config is None: mcp_config = {} return Agent( - llm=LLM(model='test-model', api_key='test-key', service_id='test-service'), + llm=LLM(model='test-model', api_key='test-key', usage_id='test-service'), tools=[], mcp_config=mcp_config, )