diff --git a/frontend/src/pages/ChatWorkspacePage.tsx b/frontend/src/pages/ChatWorkspacePage.tsx index 6a82d58..d31d730 100644 --- a/frontend/src/pages/ChatWorkspacePage.tsx +++ b/frontend/src/pages/ChatWorkspacePage.tsx @@ -25,6 +25,7 @@ import { reviewCheckpoint, } from '../api/client'; import type { Artifact, ChatSession, Commit, CompareResponse, CheckpointReviewResponse, HeadState, TurnEvent, Repo, ProviderStatus } from '../types'; +import { normalizeTask } from '../types'; import { Check, Copy, @@ -626,7 +627,7 @@ function CheckpointDetailPanel({ )} {rows(commit.decisions ?? [], 'Decisions')} {rows(commit.assumptions ?? [], 'Assumptions')} - {rows(commit.tasks ?? [], 'Tasks')} + {rows((commit.tasks ?? []).map(t => normalizeTask(t).text), 'Tasks')} {rows(commit.open_questions ?? [], 'Open Questions')} {rows(commit.entities ?? [], 'Entities')} diff --git a/frontend/src/pages/CommitDetailPage.tsx b/frontend/src/pages/CommitDetailPage.tsx index 10ef7e1..a158c19 100644 --- a/frontend/src/pages/CommitDetailPage.tsx +++ b/frontend/src/pages/CommitDetailPage.tsx @@ -267,7 +267,7 @@ export function CommitDetailPage() { {commit.metadata?.notes && commit.metadata.notes.length > 0 && (
- {commit.metadata.notes.map((n: any, i: number) => ( + {commit.metadata.notes.map((n, i) => (
{n.kind && n.kind !== 'note' && ( diff --git a/frontend/src/types/index.ts b/frontend/src/types/index.ts index d8a6962..059fceb 100644 --- a/frontend/src/types/index.ts +++ b/frontend/src/types/index.ts @@ -98,6 +98,22 @@ export interface Artifact { content: string; } +/** An additive founder/agent annotation on a checkpoint. */ +export interface Note { + id: string; + author: string; + text: string; + kind: string; + created_at: string; +} + +/** Commit metadata blob. `notes` are additive annotations; the open index + * signature preserves room for other backend-written keys (e.g. session_id). */ +export interface CommitMetadata { + notes?: Note[]; + [key: string]: unknown; +} + export interface Commit { id: string; repo_id: string; @@ -117,7 +133,7 @@ export interface Commit { artifacts: Artifact[]; context_blob: Record; raw_source_text: string | null; - metadata: Record; + metadata: CommitMetadata; created_at: string; } /** Delta between a commit and its parent, used for the diff view on CommitDetailPage */