[codex] add current time reminder delivery mode config (#30031)

```python
delivery_mode = "any_inference" # default
delivery_mode = "after_user_or_tool_output" # new mode
``` 

## Validation
- just test -p codex-core load_config_resolves_current_time_reminder
- just test -p codex-core
lock_contains_prompts_and_materializes_features
This commit is contained in:
rka-oai
2026-06-25 12:06:43 -07:00
committed by GitHub
Unverified
parent c65cfeab14
commit e8d4a1a411
6 changed files with 45 additions and 0 deletions
+13
View File
@@ -141,6 +141,17 @@ pub enum CurrentTimeSource {
External,
}
/// Which inference boundaries may receive current-time reminders.
#[derive(Serialize, Deserialize, Debug, Clone, Copy, Default, PartialEq, Eq, JsonSchema)]
#[serde(rename_all = "snake_case")]
pub enum CurrentTimeReminderDeliveryMode {
/// Allow a reminder before any inference request once the interval is due.
#[default]
AnyInference,
/// Allow reminders after user input or tool output; new context windows still force one.
AfterUserOrToolOutput,
}
#[derive(Serialize, Deserialize, Debug, Clone, Default, PartialEq, Eq, JsonSchema)]
#[serde(deny_unknown_fields)]
pub struct CurrentTimeReminderConfigToml {
@@ -150,6 +161,8 @@ pub struct CurrentTimeReminderConfigToml {
pub reminder_interval_seconds: Option<u64>,
#[serde(skip_serializing_if = "Option::is_none")]
pub clock_source: Option<CurrentTimeSource>,
#[serde(skip_serializing_if = "Option::is_none")]
pub delivery_mode: Option<CurrentTimeReminderDeliveryMode>,
/// Expose the input-interruptible `clock.sleep` tool.
#[serde(skip_serializing_if = "Option::is_none")]
pub sleep_tool: Option<bool>,
+1
View File
@@ -18,6 +18,7 @@ mod feature_configs;
mod legacy;
pub use feature_configs::CodeModeConfigToml;
pub use feature_configs::CurrentTimeReminderConfigToml;
pub use feature_configs::CurrentTimeReminderDeliveryMode;
pub use feature_configs::CurrentTimeSource;
pub use feature_configs::MultiAgentV2ConfigToml;
pub use feature_configs::NetworkProxyConfigToml;