{% extends "base.html" %} {% set active = 'search' %} {% block title %}Chunk 证据 · DocGraph{% endblock %} {% block content %}

搜索 / L1 chunk

Chunk 证据

chunk
{{ chunk.id }}
kind
{{ chunk.kind }}
doc
{{ chunk.doc_id | short_id }}
page
{% if chunk.page_start and chunk.page_end and chunk.page_start != chunk.page_end %} {{ chunk.page_start }}-{{ chunk.page_end }} {% else %} {{ chunk.page or chunk.page_start or '—' }} {% endif %}
section
{{ chunk.section_id or '—' }}
section node
{{ chunk.section_node_id or '—' }}
L0 blocks
{{ blocks|length }}

L1 文本

{{ chunk.text | pretty_text }}

L0 Blocks

{% if blocks %} {% for b in blocks %}
{{ b.kind }} {{ b.id }} p.{{ b.page }}
{% if b.text %}
{{ b.text | pretty_text }}
{% endif %} {% if b.table %} {% set t = b.table %} {% if t.caption %}

{{ t.caption }}

{% endif %} {% if chunk.kind == 'table' and chunk.attrs and chunk.attrs.table_profile %} {% set p = chunk.attrs.table_profile %}

table profile: {{ p.kind }} {% if p.continued %}continued{% endif %} {% for flag in p.quality_flags or [] %}{{ flag }}{% endfor %}

{% endif %}
{% if t.headers %} {% for h in t.headers %}{% endfor %} {% endif %} {% for row in t.rows %} {% for cell in row %}{% endfor %} {% endfor %}
{{ h }}
{{ cell }}
{% if t.html %}
原始 HTML
{{ t.html }}
{% endif %} {% endif %} {% if b.image_path %}

image: {{ b.image_path }}

{% endif %}
{% endfor %} {% else %}

这个 chunk 没有关联的 L0 block。

{% endif %}
{% endblock %}