mirror of
https://github.com/openai/codex.git
synced 2026-09-09 15:58:47 +00:00
Simplify /context skill instruction label
Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
@@ -331,13 +331,7 @@ fn classify_content_item(
|
||||
fn classify_developer_text(text: &str) -> (ContextSectionKind, String) {
|
||||
let trimmed = text.trim_start();
|
||||
if starts_with_tag(trimmed, SKILLS_INSTRUCTIONS_OPEN_TAG) {
|
||||
return (
|
||||
ContextSectionKind::User,
|
||||
format!(
|
||||
"Skill instructions ({} skills)",
|
||||
count_catalog_entries(trimmed)
|
||||
),
|
||||
);
|
||||
return (ContextSectionKind::User, "Skill instructions".to_string());
|
||||
}
|
||||
if starts_with_tag(trimmed, APPS_INSTRUCTIONS_OPEN_TAG) {
|
||||
return (
|
||||
@@ -672,7 +666,7 @@ mod tests {
|
||||
"AGENTS.md instructions for /repo".to_string(),
|
||||
"Base instructions".to_string(),
|
||||
"Environment context".to_string(),
|
||||
"Skill instructions (1 skills)".to_string(),
|
||||
"Skill instructions".to_string(),
|
||||
"Reasoning".to_string(),
|
||||
"Skill: notify (/tmp/skills/notify/SKILL.md)".to_string(),
|
||||
"User message".to_string(),
|
||||
|
||||
@@ -403,7 +403,7 @@ mod tests {
|
||||
label: "User".to_string(),
|
||||
tokens: 12_000,
|
||||
details: vec![ThreadContextWindowDetail {
|
||||
label: "Skill instructions (42 skills)".to_string(),
|
||||
label: "Skill instructions".to_string(),
|
||||
tokens: 12_000,
|
||||
}],
|
||||
},
|
||||
|
||||
@@ -14,7 +14,7 @@ Context map
|
||||
■ Conversation 40.0%
|
||||
|
||||
■ User ~12,000 tokens 60.0% of used
|
||||
██████████ Skill instructions (42 skills) (~12,000 tokens)
|
||||
██████████ Skill instructions (~12,000 tokens)
|
||||
|
||||
■ Conversation ~8,000 tokens 40.0% of used
|
||||
██████░░░░ Tool output (~5,000 tokens)
|
||||
|
||||
Reference in New Issue
Block a user