Spaces:
Running
on
T4
Running
on
T4
Update auditqa/utils.py
Browse files- auditqa/utils.py +3 -3
auditqa/utils.py
CHANGED
@@ -77,16 +77,16 @@ def make_html_source(source,i):
|
|
77 |
meta = source.metadata
|
78 |
content = source.page_content.strip()
|
79 |
|
80 |
-
name = meta['
|
81 |
card = f"""
|
82 |
<div class="card" id="doc{i}">
|
83 |
<div class="card-content">
|
84 |
-
<h2>Doc {i} - {meta['
|
85 |
<p>{content}</p>
|
86 |
</div>
|
87 |
<div class="card-footer">
|
88 |
<span>{name}</span>
|
89 |
-
<a href="{meta['
|
90 |
<span role="img" aria-label="Open PDF">🔗</span>
|
91 |
</a>
|
92 |
</div>
|
|
|
77 |
meta = source.metadata
|
78 |
content = source.page_content.strip()
|
79 |
|
80 |
+
name = meta['filename']
|
81 |
card = f"""
|
82 |
<div class="card" id="doc{i}">
|
83 |
<div class="card-content">
|
84 |
+
<h2>Doc {i} - {meta['filename']} - Page {int(meta['page'])}</h2>
|
85 |
<p>{content}</p>
|
86 |
</div>
|
87 |
<div class="card-footer">
|
88 |
<span>{name}</span>
|
89 |
+
<a href="{meta['filename']}#page={int(meta['page'])}" target="_blank" class="pdf-link">
|
90 |
<span role="img" aria-label="Open PDF">🔗</span>
|
91 |
</a>
|
92 |
</div>
|