feat(#445): full Models tab parity — settings, aux tasks, MOA config
* feat(#445): full Models tab — settings panel, aux tasks, MOA config, model assignment Main features added: - Model Settings card at top of screen with main model, aux tasks, MOA summary - Main model assignment via /api/model/set with expensive model confirm flow - Auxiliary tasks dialog with per-task model override and reset-all - MOA config dialog with preset management and reference/aggregator model picker - Model picker dialog reused for main model, aux tasks, and MOA slot selection - Kept existing provider browse + pin/unpin/search New data models: AuxiliaryModelsResponse, MoaConfigResponse, ModelAssignmentRequest/Response New API endpoints: GET /api/model/auxiliary, GET/PUT /api/model/moa, POST /api/model/set * test(#445): add aux + MOA mock endpoints to E2eIntegrationTest testModelOptionsSelection_success was failing because the ViewModel's init block now calls getAuxiliaryModels() and getMoaConfig() which weren't mocked. Added proper mock returns + imports for the new types. * fix(#445): correct mock endpoint name in E2eIntegrationTest - getMoaConfig -> getMoaModels (matches API service method name) - Add explicit type parameter Response.success<MoaConfigResponse> to fix Kotlin type inference * fix(#445): add missing main param to AuxiliaryModelsResponse mock AuxiliaryModelsResponse requires a MainModelAssignment for its 'main' field. Added the parameter with a dummy value and the corresponding import. * fix(#445): update toast assertion in test to match new message format ViewModel now produces 'Successfully set profile model to ronia' instead of the old 'Successfully set model to ronia'. --------- Co-authored-by: M57 <hy4ri@users.noreply.github.com>
This commit is contained in:
1 parent
efb8e528ef
commit
dc808daee8
5 files changed
+1674
-397
No files matched your search
@@ -4,6 +4,7 @@ import com.google.gson.JsonElement
|
||||
import com.m57.hermescontrol.data.model.AchievementsResponse
|
||||
import com.m57.hermescontrol.data.model.ActiveProfileResponse
|
||||
import com.m57.hermescontrol.data.model.AgentPluginInstallBody
|
||||
import com.m57.hermescontrol.data.model.AuxiliaryModelsResponse
|
||||
import com.m57.hermescontrol.data.model.ConfigSchemaResponse
|
||||
import com.m57.hermescontrol.data.model.ConfigUpdateRequest
|
||||
import com.m57.hermescontrol.data.model.CreateCronJobRequest
|
||||
@@ -25,6 +26,9 @@ import com.m57.hermescontrol.data.model.McpServersResponse
|
||||
import com.m57.hermescontrol.data.model.MessagingPlatformResponse
|
||||
import com.m57.hermescontrol.data.model.MessagingPlatformTestResult
|
||||
import com.m57.hermescontrol.data.model.MessagingPlatformUpdate
|
||||
import com.m57.hermescontrol.data.model.MoaConfigResponse
|
||||
import com.m57.hermescontrol.data.model.ModelAssignmentRequest
|
||||
import com.m57.hermescontrol.data.model.ModelAssignmentResponse
|
||||
import com.m57.hermescontrol.data.model.ModelOptionsResponse
|
||||
import com.m57.hermescontrol.data.model.PairingApproveRequest
|
||||
import com.m57.hermescontrol.data.model.PairingResponse
|
||||
@@ -285,6 +289,22 @@ interface HermesApiService {
|
||||
@GET("api/model/options")
|
||||
suspend fun getModelOptions(): Response<ModelOptionsResponse>
|
||||
|
||||
@GET("api/model/auxiliary")
|
||||
suspend fun getAuxiliaryModels(): Response<AuxiliaryModelsResponse>
|
||||
|
||||
@GET("api/model/moa")
|
||||
suspend fun getMoaModels(): Response<MoaConfigResponse>
|
||||
|
||||
@PUT("api/model/moa")
|
||||
suspend fun saveMoaModels(
|
||||
@Body body: MoaConfigResponse,
|
||||
): Response<MoaConfigResponse>
|
||||
|
||||
@POST("api/model/set")
|
||||
suspend fun setModelAssignment(
|
||||
@Body body: ModelAssignmentRequest,
|
||||
): Response<ModelAssignmentResponse>
|
||||
|
||||
@GET("api/logs")
|
||||
suspend fun getLogs(
|
||||
@Query("limit") limit: Int? = null,
|
||||
|
||||
Reference in new issue
Block a user