mirror of
https://github.com/qdrant/landing_page.git
synced 2026-09-26 14:38:30 +02:00
Add Guides directory search and simplify guide banners
This commit is contained in:
@@ -12,8 +12,8 @@ build:
|
||||
render: always
|
||||
content:
|
||||
- partial: documentation/banners/banner-a
|
||||
title: Build Better Search
|
||||
description: Practical guidance for evaluating and tuning search, choosing models, and planning how your application grows.
|
||||
title: Qdrant Guides
|
||||
description: Practical guidance for search quality, embedding models, multitenancy, bulk uploads, and memory use.
|
||||
- partial: documentation/recent-publications
|
||||
kind: guides
|
||||
- partial: documentation/guides/topics
|
||||
|
||||
@@ -21,13 +21,6 @@ content:
|
||||
- partial: documentation/banners/banner-a
|
||||
title: Production & Operations
|
||||
description: Plan multitenancy, bulk uploads, and memory placement as your Qdrant application and vector collection grow.
|
||||
linkDescription: Choose the pattern that matches your workload and its constraints.
|
||||
cloudButton:
|
||||
text: Serve Many Tenants
|
||||
url: /documentation/production-operations/multitenant-search/
|
||||
localButton:
|
||||
text: Plan a Data Import
|
||||
url: /documentation/production-operations/bulk-data-import/
|
||||
- partial: documentation/guides/guide-cards
|
||||
section: /documentation/production-operations/
|
||||
worked_examples:
|
||||
|
||||
@@ -23,13 +23,6 @@ content:
|
||||
- partial: documentation/banners/banner-a
|
||||
title: Search Evaluation
|
||||
description: Build an evaluation baseline and measure whether your search system produces useful results.
|
||||
linkDescription: Choose the evaluation method that matches the result you need to judge.
|
||||
cloudButton:
|
||||
text: Measure Retrieval Relevance
|
||||
url: /documentation/search-evaluation/retrieval-relevance/
|
||||
localButton:
|
||||
text: Evaluate Pipeline Output
|
||||
url: /documentation/search-evaluation/pipeline-output-quality/
|
||||
- partial: documentation/guides/guide-cards
|
||||
section: /documentation/search-evaluation/
|
||||
---
|
||||
|
||||
@@ -16,13 +16,6 @@ content:
|
||||
- partial: documentation/banners/banner-a
|
||||
title: Search Patterns
|
||||
description: Choose how your search system represents data, handles questions, and narrows results.
|
||||
linkDescription: Choose the pattern that fits your application's search needs.
|
||||
cloudButton:
|
||||
text: Choose an Embedding Model
|
||||
url: /documentation/search-patterns/choose-embedding-model/
|
||||
localButton:
|
||||
text: Plan Your Filters
|
||||
url: /documentation/search-patterns/vector-search-filtering/
|
||||
- partial: documentation/guides/guide-cards
|
||||
section: /documentation/search-patterns/
|
||||
---
|
||||
|
||||
@@ -16,13 +16,6 @@ content:
|
||||
- partial: documentation/banners/banner-a
|
||||
title: Search Tuning
|
||||
description: Use evaluation results to decide what to change in your retrieval pipeline.
|
||||
linkDescription: Follow the tuning series in order, or open the part that matches your next decision.
|
||||
cloudButton:
|
||||
text: Start the Tuning Series
|
||||
url: /documentation/search-tuning/hybrid-search/
|
||||
localButton:
|
||||
text: Check Before Tuning
|
||||
url: /documentation/search-tuning/before-tuning-a-qdrant-collection/
|
||||
- partial: documentation/guides/guide-cards
|
||||
section: /documentation/search-tuning/
|
||||
guide_series_title: Tune Your Retrieval Pipeline
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
@use '../../helpers/functions' as *;
|
||||
|
||||
.example-library {
|
||||
.example-library,
|
||||
.guide-directory {
|
||||
scroll-margin-top: $spacer * 7;
|
||||
|
||||
&__filters {
|
||||
@@ -41,6 +42,8 @@
|
||||
}
|
||||
}
|
||||
|
||||
[hidden] { display: none !important; }
|
||||
|
||||
.docs-card__title a {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
const directory = document.querySelector('.guide-directory');
|
||||
if (directory) {
|
||||
const form = directory.querySelector('form');
|
||||
const query = form.elements.namedItem('q');
|
||||
const guides = [...directory.querySelectorAll('[data-guide]')];
|
||||
const topics = [...directory.querySelectorAll('[data-guide-topic]')];
|
||||
const count = directory.querySelector('[data-guide-count]');
|
||||
const empty = directory.querySelector('[data-guide-empty]');
|
||||
|
||||
function filter(updateURL = true) {
|
||||
const terms = query.value.toLowerCase().trim().split(/\s+/).filter(Boolean);
|
||||
let visible = 0;
|
||||
guides.forEach(guide => {
|
||||
guide.hidden = !terms.every(term => guide.dataset.search.includes(term));
|
||||
if (!guide.hidden) visible += 1;
|
||||
});
|
||||
topics.forEach(topic => {
|
||||
topic.hidden = !topic.querySelector('[data-guide]:not([hidden])');
|
||||
});
|
||||
count.textContent = `${visible} ${visible === 1 ? 'guide' : 'guides'}`;
|
||||
empty.hidden = visible !== 0;
|
||||
if (updateURL) {
|
||||
const url = new URL(window.location.href);
|
||||
if (query.value.trim()) url.searchParams.set('q', query.value.trim());
|
||||
else url.searchParams.delete('q');
|
||||
window.history.replaceState(null, '', url);
|
||||
}
|
||||
}
|
||||
|
||||
function readURL() {
|
||||
query.value = new URLSearchParams(window.location.search).get('q') || '';
|
||||
filter(false);
|
||||
}
|
||||
|
||||
form.hidden = count.hidden = false;
|
||||
readURL();
|
||||
form.addEventListener('submit', event => { event.preventDefault(); filter(); });
|
||||
query.addEventListener('input', () => filter());
|
||||
form.addEventListener('reset', event => {
|
||||
event.preventDefault();
|
||||
query.value = '';
|
||||
filter();
|
||||
query.focus();
|
||||
});
|
||||
window.addEventListener('popstate', readURL);
|
||||
}
|
||||
+13
-4
@@ -1,9 +1,18 @@
|
||||
<section class="docs-core__data guide-directory">
|
||||
<h2>Browse Guides by Topic</h2>
|
||||
<section class="docs-core__data guide-directory" aria-labelledby="guides-title">
|
||||
<h2 id="guides-title">Browse Guides by Topic</h2>
|
||||
<p>Open a guide directly, or explore a topic for related examples and references.</p>
|
||||
<form class="guide-directory__filters" role="search" aria-label="Find a Guide" hidden>
|
||||
<div>
|
||||
<label for="guide-query">Search Guides</label>
|
||||
<input id="guide-query" name="q" type="search" placeholder="Try reranking, multitenancy, or memory" autocomplete="off">
|
||||
</div>
|
||||
<button type="reset" class="button button_outlined button_sm">Clear Search</button>
|
||||
</form>
|
||||
<p data-guide-count role="status" aria-live="polite" aria-atomic="true" hidden></p>
|
||||
<p data-guide-empty hidden>No guides match your search. Try a broader term or clear the search.</p>
|
||||
<div class="row g-4 g-lg-3">
|
||||
{{ range where (site.GetPage "/documentation").Sections.ByWeight "Params.learning_kind" "guides" }}
|
||||
<div class="col-12 col-lg-6">
|
||||
<div class="col-12 col-lg-6" data-guide-topic>
|
||||
<div class="docs-card">
|
||||
{{ with .Params.guide_icon }}<img class="docs-card__icon" src="{{ . }}" alt="" />{{ end }}
|
||||
<h3 class="docs-card__title"><a href="{{ .RelPermalink }}">{{ .Title }}</a></h3>
|
||||
@@ -12,7 +21,7 @@
|
||||
<ul class="guide-directory__links" role="list">
|
||||
{{ range .RegularPages.ByWeight }}
|
||||
{{ if .Params.guide_series }}{{ $part = add $part 1 }}{{ end }}
|
||||
<li>
|
||||
<li data-guide data-search="{{ printf "%s %s" .Title (.Params.short_description | default .Description) | lower }}">
|
||||
<a href="{{ .RelPermalink }}">
|
||||
<span>{{ if .Params.guide_series }}<span class="guide-directory__part">Part {{ $part }}</span>{{ end }}{{ .Title }}</span>
|
||||
<span class="guide-directory__arrow" aria-hidden="true">→</span>
|
||||
|
||||
@@ -97,6 +97,11 @@
|
||||
<script src="{{ $catalogFiltersJs.RelPermalink }}"></script>
|
||||
{{ end }}
|
||||
|
||||
{{ if eq .Path "/documentation/guides-tab" }}
|
||||
{{ $guideDirectoryJs := resources.Get "js/guide-directory.js" | js.Build | minify | resources.Fingerprint "sha512" }}
|
||||
<script src="{{ $guideDirectoryJs.RelPermalink }}"></script>
|
||||
{{ end }}
|
||||
|
||||
{{ if eq .Layout "examples" }}
|
||||
{{ $exampleLibraryJs := resources.Get "js/example-library.js" | js.Build | minify | resources.Fingerprint "sha512" }}
|
||||
<script src="{{ $exampleLibraryJs.RelPermalink }}"></script>
|
||||
|
||||
Reference in New Issue
Block a user