@@ -1015,18 +1121,12 @@ const handleDetailsScroll = () => {
+
+
+
diff --git a/frontend/src/components/knowledge-processing-timeline.vue b/frontend/src/components/knowledge-processing-timeline.vue
index 9e665192..7c9677b8 100644
--- a/frontend/src/components/knowledge-processing-timeline.vue
+++ b/frontend/src/components/knowledge-processing-timeline.vue
@@ -6,6 +6,7 @@ import { getKnowledgeSpans, reparseKnowledge } from '@/api/knowledge-base/index'
interface SpanNode {
span_id?: string
+ parent_span_id?: string
name: string
kind: string
status: string
@@ -31,6 +32,7 @@ interface SpansResponse {
knowledge_id: string
attempt: number
latest_attempt: number
+ current_attempt?: number
parse_status: string
current_stage?: string
trace: SpanNode
@@ -44,21 +46,27 @@ const props = defineProps<{
compact?: boolean
}>()
+const emit = defineEmits<{
+ (e: 'update:hasSpans', has: boolean): void
+ (e: 'update:summary', summary: { totalMs: number; status: string; stageIndex: number; stageTotal: number; stageLabel: string }): void
+}>()
+
const { t } = useI18n()
const STAGES = ['docreader', 'chunking', 'embedding', 'multimodal', 'postprocess'] as const
+const POLL_INTERVAL_MS = 2000
const data = ref
(null)
const loading = ref(false)
+const refreshing = ref(false)
const selectedAttempt = ref(undefined)
const expandedRows = ref>(new Set(['__root__']))
const selectedSpanId = ref(null)
const expandedJsonKeys = ref>(new Set())
const nowTick = ref(Date.now())
+const detailTab = ref<'overview' | 'input' | 'output' | 'metadata' | 'raw'>('overview')
+const lastFetchedAt = ref(0)
-// Per-attempt status cache for the tab strip. Lazy-fetched: when the strip
-// first becomes visible, we hit /spans?attempt=n once per missing tab so we
-// can colour the chip without polling all of them indefinitely.
const attemptStatuses = reactive