action_preprocessor
Module Contents
Classes
The ActionPreprocessor is a hook that preprocesses the action message |
|
The ActionPreprocessor is a hook that preprocesses the action message |
- class lagent.hooks.action_preprocessor.ActionPreprocessor
Bases:
lagent.hooks.hook.HookThe ActionPreprocessor is a hook that preprocesses the action message and postprocesses the action return message.
- before_action(executor, message, session_id)
- after_action(executor, message, session_id)
- class lagent.hooks.action_preprocessor.InternLMActionProcessor(code_parameter='command')
Bases:
ActionPreprocessorThe ActionPreprocessor is a hook that preprocesses the action message and postprocesses the action return message.
- 参数:
code_parameter (str) –
- code_parameter = 'command'
- before_action(executor, message, session_id)