feat(agent): redesign project_cli with module/method/input protocol
- Replace command/subcommand/args with module/method/input envelope - Calendar handler uses discriminated union (mode) for read operations - Strict Pydantic models with extra='forbid' for all calendar methods - Worker max_iters=7, router prompt simplified (removed project_cli_defaults) - Skill index cards + per-action files for progressive disclosure - Frontend/AG-UI aligned to module/method dispatch - Protocol docs updated to module/method/input contract WIP: action cards need envelope fix, 2 tests need update, memory handler needs Pydantic models.
This commit is contained in:
@@ -263,10 +263,10 @@ class ChatBloc extends Cubit<ChatState> implements ChatOrchestrator {
|
||||
if (args == null) {
|
||||
return false;
|
||||
}
|
||||
final command = (args['command'] as String?)?.trim().toLowerCase();
|
||||
final subcommand = (args['subcommand'] as String?)?.trim().toLowerCase();
|
||||
const mutationSubcommands = {'create', 'update', 'delete'};
|
||||
if (command != 'calendar' || !mutationSubcommands.contains(subcommand)) {
|
||||
final skill = (args['skill'] as String?)?.trim().toLowerCase();
|
||||
final action = (args['action'] as String?)?.trim().toLowerCase();
|
||||
const mutationActions = {'create_event', 'update_event', 'delete_event'};
|
||||
if (skill != 'calendar' || !mutationActions.contains(action)) {
|
||||
return false;
|
||||
}
|
||||
return status == 'success' || status == 'partial';
|
||||
|
||||
Reference in New Issue
Block a user