feat: polish web master-agent controls and dispatch recovery
This commit is contained in:
@@ -11,6 +11,7 @@ import type {
|
||||
ProjectAgentControls,
|
||||
UserMasterPrompt,
|
||||
} from "@/lib/boss-data";
|
||||
import type { MasterAgentChatPageAnchors } from "@/lib/master-agent-chat-menu";
|
||||
import { formatTimestampLabel } from "@/lib/boss-projections";
|
||||
|
||||
type MemoryDraft = {
|
||||
@@ -146,6 +147,7 @@ export function MasterAgentPromptMemoryClient({
|
||||
projectControls,
|
||||
globalMemories,
|
||||
projectMemories,
|
||||
anchors,
|
||||
}: {
|
||||
isAdmin: boolean;
|
||||
promptPolicy: MasterAgentPromptPolicy | null;
|
||||
@@ -153,6 +155,7 @@ export function MasterAgentPromptMemoryClient({
|
||||
projectControls: ProjectAgentControls | null;
|
||||
globalMemories: MasterAgentMemory[];
|
||||
projectMemories: MasterAgentMemory[];
|
||||
anchors: MasterAgentChatPageAnchors;
|
||||
}) {
|
||||
const router = useRouter();
|
||||
const [busyKey, setBusyKey] = useState<string | null>(null);
|
||||
@@ -326,7 +329,7 @@ export function MasterAgentPromptMemoryClient({
|
||||
|
||||
return (
|
||||
<div className="flex flex-col gap-4 px-[18px] pb-6">
|
||||
<div id="prompt-section" className="rounded-2xl border border-[#E5E5EA] bg-white px-4 py-4 scroll-mt-4">
|
||||
<div id={anchors.prompt.split("#")[1]} className="rounded-2xl border border-[#E5E5EA] bg-white px-4 py-4 scroll-mt-4">
|
||||
<div className="text-[16px] font-semibold text-[#111111]">主 Agent 提示词</div>
|
||||
<div className="mt-2 text-[12px] leading-6 text-[#8C8C8C]">
|
||||
管理员全局主提示词不可被覆盖;用户提示词和当前对话提示词只会追加在后面。
|
||||
@@ -400,7 +403,7 @@ export function MasterAgentPromptMemoryClient({
|
||||
</span>
|
||||
</div>
|
||||
<div className="grid gap-3 md:grid-cols-2">
|
||||
<label className="space-y-1">
|
||||
<label id={anchors.model.split("#")[1]} className="space-y-1 scroll-mt-4">
|
||||
<div className="text-[12px] text-[#8C8C8C]">模型</div>
|
||||
<select
|
||||
value={modelOverride}
|
||||
@@ -413,7 +416,7 @@ export function MasterAgentPromptMemoryClient({
|
||||
<option value="gpt-4.1-mini">gpt-4.1-mini</option>
|
||||
</select>
|
||||
</label>
|
||||
<label className="space-y-1">
|
||||
<label id={anchors.reasoningEffort.split("#")[1]} className="space-y-1 scroll-mt-4">
|
||||
<div className="text-[12px] text-[#8C8C8C]">推理强度</div>
|
||||
<select
|
||||
value={reasoningEffortOverride}
|
||||
@@ -453,7 +456,7 @@ export function MasterAgentPromptMemoryClient({
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="memory-section" className="rounded-2xl border border-[#E5E5EA] bg-white px-4 py-4 scroll-mt-4">
|
||||
<div id={anchors.memory.split("#")[1]} className="rounded-2xl border border-[#E5E5EA] bg-white px-4 py-4 scroll-mt-4">
|
||||
<div className="text-[16px] font-semibold text-[#111111]">新增记忆</div>
|
||||
<div className="mt-2 text-[12px] leading-6 text-[#8C8C8C]">
|
||||
支持自动沉淀后的手动增补、编辑和归档。项目记忆需要绑定到真实项目,而不是 master-agent 会话本身。
|
||||
|
||||
Reference in New Issue
Block a user