feat: add managed system prompt optimization
Add an opt-in OpenCode plugin that replaces the built-in provider behavioral prompt with a minimal identity while preserving environment, project, MCP, skill, history, and tool context. Track the active agent per session and apply the transform only to build and plan. Keep plan/build mode reminders and permission enforcement owned by OpenCode, leave all other agents untouched, and fail safely when the expected prompt boundary is absent. Expose the feature in Behavior settings with localized guidance, explicit Save + Reload application, settings search integration, persisted boolean validation, and managed-runtime lifecycle composition that does not load the plugin while disabled or on external OpenCode servers. Document the runtime contract and cover plugin materialization, config preservation, build/plan selection, agent switching, unknown prompt formats, and settings sanitization.
This commit is contained in:
@@ -546,6 +546,11 @@ export const settingsDict = {
|
||||
'settings.behavior.page.warning.title': '전역 규칙은 프로젝트 규칙과 함께 사용됩니다',
|
||||
'settings.behavior.page.warning.description': '여기에서 변경한 내용은 {path}를 업데이트합니다. 프로젝트 수준의 AGENTS.md가 있으면 OpenCode도 함께 포함합니다.',
|
||||
'settings.behavior.page.section.systemPrompt': '전역 AGENTS.md',
|
||||
'settings.behavior.page.section.systemPromptOptimization': '시스템 프롬프트 최적화',
|
||||
'settings.behavior.page.systemPromptOptimization.enable': '시스템 프롬프트 크기 최적화',
|
||||
'settings.behavior.page.systemPromptOptimization.enableAria': 'OpenCode 시스템 프롬프트 크기 최적화',
|
||||
'settings.behavior.page.systemPromptOptimization.info': 'build 및 plan 에이전트의 시스템 프롬프트를 약 40% 줄입니다. 다른 에이전트는 변경되지 않습니다. build 또는 plan을 재정의하는 사용자 지정 정의가 제거될 수 있으므로 이러한 워크플로에서는 활성화하지 마세요. OpenCode를 다시 시작하면 변경 사항이 적용됩니다.',
|
||||
'settings.behavior.page.systemPromptOptimization.restarting': '시스템 프롬프트 최적화를 적용하기 위해 OpenCode를 다시 시작하는 중…',
|
||||
'settings.behavior.page.field.systemPromptPlaceholder': '당신은 유용한 AI 어시스턴트입니다...\n\n모든 세션과 공급자에서 AI가 어떻게 행동해야 하는지에 대한 절대적인 규칙을 정의할 수 있습니다.',
|
||||
'settings.behavior.page.section.responseStyle': '응답 스타일',
|
||||
'settings.behavior.page.responseStyle.tooltip': '활성화하면 이 지침이 새 대화에서 어시스턴트의 응답 방식을 안내합니다. 첫 메시지와 함께 전송되며 전역 AGENTS.md 규칙은 변경하지 않습니다.',
|
||||
|
||||
Reference in New Issue
Block a user