mirror of
https://github.com/openai/codex.git
synced 2026-09-05 15:18:41 +00:00
Expand thread source taxonomy
This commit is contained in:
@@ -3795,9 +3795,12 @@
|
||||
"type": "string"
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -4575,9 +4575,12 @@
|
||||
"type": "object"
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -18017,9 +18017,12 @@
|
||||
"type": "string"
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -15834,9 +15834,12 @@
|
||||
"type": "string"
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -73,9 +73,12 @@
|
||||
"type": "string"
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1790,9 +1790,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1605,9 +1605,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1605,9 +1605,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1605,9 +1605,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1790,9 +1790,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1605,9 +1605,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -107,9 +107,12 @@
|
||||
"type": "string"
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1790,9 +1790,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1605,9 +1605,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -1605,9 +1605,12 @@
|
||||
]
|
||||
},
|
||||
"ThreadSource": {
|
||||
"description": "Optional caller-supplied classification of who or what owns a thread's execution.",
|
||||
"enum": [
|
||||
"user",
|
||||
"subagent",
|
||||
"system",
|
||||
"automation",
|
||||
"memory_consolidation"
|
||||
],
|
||||
"type": "string"
|
||||
|
||||
@@ -2,4 +2,7 @@
|
||||
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type ThreadSource = "user" | "subagent" | "memory_consolidation";
|
||||
/**
|
||||
* Optional caller-supplied classification of who or what owns a thread's execution.
|
||||
*/
|
||||
export type ThreadSource = "user" | "subagent" | "system" | "automation" | "memory_consolidation";
|
||||
|
||||
@@ -61,12 +61,20 @@ impl From<SessionSource> for CoreSessionSource {
|
||||
}
|
||||
}
|
||||
|
||||
/// Optional caller-supplied classification of who or what owns a thread's execution.
|
||||
#[derive(Serialize, Deserialize, Debug, Clone, Copy, PartialEq, Eq, JsonSchema, TS)]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
#[ts(rename_all = "snake_case", export_to = "v2/")]
|
||||
pub enum ThreadSource {
|
||||
// Primary work attributed to an active user workflow.
|
||||
User,
|
||||
// Work delegated by an agent into a child or worker thread.
|
||||
Subagent,
|
||||
// Product-owned helper, safety, repair, or auxiliary work.
|
||||
System,
|
||||
// Top-level work started by a schedule or autonomous trigger.
|
||||
Automation,
|
||||
// Internal memory-consolidation work.
|
||||
MemoryConsolidation,
|
||||
}
|
||||
|
||||
@@ -75,6 +83,8 @@ impl From<CoreThreadSource> for ThreadSource {
|
||||
match value {
|
||||
CoreThreadSource::User => ThreadSource::User,
|
||||
CoreThreadSource::Subagent => ThreadSource::Subagent,
|
||||
CoreThreadSource::System => ThreadSource::System,
|
||||
CoreThreadSource::Automation => ThreadSource::Automation,
|
||||
CoreThreadSource::MemoryConsolidation => ThreadSource::MemoryConsolidation,
|
||||
}
|
||||
}
|
||||
@@ -85,6 +95,8 @@ impl From<ThreadSource> for CoreThreadSource {
|
||||
match value {
|
||||
ThreadSource::User => CoreThreadSource::User,
|
||||
ThreadSource::Subagent => CoreThreadSource::Subagent,
|
||||
ThreadSource::System => CoreThreadSource::System,
|
||||
ThreadSource::Automation => CoreThreadSource::Automation,
|
||||
ThreadSource::MemoryConsolidation => CoreThreadSource::MemoryConsolidation,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2495,12 +2495,20 @@ pub enum SessionSource {
|
||||
Unknown,
|
||||
}
|
||||
|
||||
/// Optional caller-supplied classification of who or what owns a thread's execution.
|
||||
#[derive(Serialize, Deserialize, Clone, Copy, Debug, PartialEq, Eq, JsonSchema, TS)]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
#[ts(rename_all = "snake_case")]
|
||||
pub enum ThreadSource {
|
||||
// Primary work attributed to an active user workflow.
|
||||
User,
|
||||
// Work delegated by an agent into a child or worker thread.
|
||||
Subagent,
|
||||
// Product-owned helper, safety, repair, or auxiliary work.
|
||||
System,
|
||||
// Top-level work started by a schedule or autonomous trigger.
|
||||
Automation,
|
||||
// Internal memory-consolidation work.
|
||||
MemoryConsolidation,
|
||||
}
|
||||
|
||||
@@ -2509,6 +2517,8 @@ impl ThreadSource {
|
||||
match self {
|
||||
ThreadSource::User => "user",
|
||||
ThreadSource::Subagent => "subagent",
|
||||
ThreadSource::System => "system",
|
||||
ThreadSource::Automation => "automation",
|
||||
ThreadSource::MemoryConsolidation => "memory_consolidation",
|
||||
}
|
||||
}
|
||||
@@ -2527,6 +2537,8 @@ impl FromStr for ThreadSource {
|
||||
match value {
|
||||
"user" => Ok(ThreadSource::User),
|
||||
"subagent" => Ok(ThreadSource::Subagent),
|
||||
"system" => Ok(ThreadSource::System),
|
||||
"automation" => Ok(ThreadSource::Automation),
|
||||
"memory_consolidation" => Ok(ThreadSource::MemoryConsolidation),
|
||||
other => Err(format!("unknown thread source: {other}")),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user