Skip to content

Commit 8df3260

Browse files
authored
DEV: fix image links on AI landing page (#1923)
* DEV: fix image links on AI landing page * 1st attempt to fix URL issues * 2nd attempt to fix URL issues
1 parent 63a9de0 commit 8df3260

File tree

2 files changed

+46
-6
lines changed

2 files changed

+46
-6
lines changed

content/develop/ai/_index.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,11 @@ hideListLinks: true
1313
---
1414
Redis stores and indexes vector embeddings that semantically represent unstructured data including text passages, images, videos, or audio. Store vectors and the associated metadata within [hashes]({{< relref "/develop/data-types/hashes" >}}) or [JSON]({{< relref "/develop/data-types/json" >}}) documents for [indexing]({{< relref "/develop/ai/search-and-query/indexing" >}}) and [querying]({{< relref "/develop/ai/search-and-query/query" >}}).
1515

16-
| Vector | RAG | RedisVL |
17-
| :-- | :-- | :-- |
18-
| {{<image filename="images/ai-cube.svg" alt="AI Redis icon.">}}[Redis vector database quick start guide]({{< relref "/develop/get-started/vector-database" >}}) |{{<image filename="images/ai-brain.svg" alt="AI Redis icon.">}} [Retrieval-Augmented Generation quick start guide]({{< relref "/develop/get-started/rag" >}}) | {{<image filename="images/ai-lib.svg" alt="AI Redis icon.">}}[Redis vector Python client library documentation]({{< relref "/develop/ai/redisvl/" >}}) |
16+
<div class="grid grid-cols-1 md:grid-cols-3 gap-6 my-8">
17+
{{< image-card image="images/ai-cube.svg" alt="AI Redis icon" title="Redis vector database quick start guide" url="/develop/get-started/vector-database" >}}
18+
{{< image-card image="images/ai-brain.svg" alt="AI Redis icon" title="Retrieval-Augmented Generation quick start guide" url="/develop/get-started/rag" >}}
19+
{{< image-card image="images/ai-lib.svg" alt="AI Redis icon" title="Redis vector Python client library documentation" url="/develop/ai/redisvl/" >}}
20+
</div>
1921

2022
#### Overview
2123

@@ -46,9 +48,13 @@ This page is organized into a few sections depending on what you're trying to do
4648

4749
Learn to perform vector search and use gateways and semantic caching in your AI/ML projects.
4850

49-
| Search | LLM memory | Semantic caching | Semantic routing | AI Gateways |
50-
| :-- | :-- | :-- | :-- | :-- |
51-
| {{<image filename="images/ai-search.svg" alt="AI Redis icon.">}}[Vector search guide]({{< relref "/develop/ai/search-and-query/query/vector-search" >}}) | {{<image filename="images/ai-LLM-memory.svg" alt="LLM memory icon.">}}[Store memory for LLMs](https://redis.io/blog/level-up-rag-apps-with-redis-vector-library/) | {{<image filename="images/ai-brain-2.svg" alt="AI Redis icon.">}}[Semantic caching for faster, smarter LLM apps](https://redis.io/blog/what-is-semantic-caching) | {{<image filename="images/ai-semantic-routing.svg" alt="Semantic routing icon.">}}[Semantic routing chooses the best tool](https://redis.io/blog/level-up-rag-apps-with-redis-vector-library/) | {{<image filename="images/ai-model.svg" alt="AI Redis icon.">}}[Deploy an enhanced gateway with Redis](https://redis.io/blog/ai-gateways-what-are-they-how-can-you-deploy-an-enhanced-gateway-with-redis/) |
51+
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-5 gap-4 my-8">
52+
{{< image-card image="images/ai-search.svg" alt="AI Redis icon" title="Vector search guide" url="/develop/ai/search-and-query/query/vector-search" >}}
53+
{{< image-card image="images/ai-LLM-memory.svg" alt="LLM memory icon" title="Store memory for LLMs" url="https://redis.io/blog/level-up-rag-apps-with-redis-vector-library/" >}}
54+
{{< image-card image="images/ai-brain-2.svg" alt="AI Redis icon" title="Semantic caching for faster, smarter LLM apps" url="https://redis.io/blog/what-is-semantic-caching" >}}
55+
{{< image-card image="images/ai-semantic-routing.svg" alt="Semantic routing icon" title="Semantic routing chooses the best tool" url="https://redis.io/blog/level-up-rag-apps-with-redis-vector-library/" >}}
56+
{{< image-card image="images/ai-model.svg" alt="AI Redis icon" title="Deploy an enhanced gateway with Redis" url="https://redis.io/blog/ai-gateways-what-are-they-how-can-you-deploy-an-enhanced-gateway-with-redis/" >}}
57+
</div>
5258

5359
## Quickstarts
5460

layouts/shortcodes/image-card.html

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{{/*
2+
Image card shortcode - creates a clickable card with image and title
3+
4+
Usage:
5+
{{< image-card image="images/ai-cube.svg" alt="AI Redis icon" title="Redis vector database quick start guide" url="/develop/get-started/vector-database" >}}
6+
7+
Parameters:
8+
- image: Path to the image file (required)
9+
- alt: Alt text for the image (required)
10+
- title: Title text to display below the image (required)
11+
- url: URL to link to when clicked (required)
12+
- class: Optional CSS class for the card container
13+
*/}}
14+
15+
{{ $image := .Get "image" }}
16+
{{ $alt := .Get "alt" }}
17+
{{ $title := .Get "title" }}
18+
{{ $url := .Get "url" }}
19+
{{ $class := .Get "class" | default "" }}
20+
21+
{{/* Handle internal vs external URLs */}}
22+
{{ $finalUrl := $url }}
23+
{{ if and (not (hasPrefix $url "http")) (not (hasPrefix $url "//")) }}
24+
{{ $finalUrl = relref . $url }}
25+
{{ end }}
26+
27+
<a href="{{ $finalUrl }}" class="image-card-link block no-underline hover:no-underline text-inherit hover:text-inherit h-full">
28+
<div class="image-card flex flex-col items-center text-center p-4 border border-redis-pen-300 rounded-lg hover:border-redis-red-500 hover:shadow-md transition-all duration-200 h-full {{ $class }}">
29+
<div class="image-card-img-container mb-4 flex-shrink-0">
30+
<img src="{{ relURL $image }}" alt="{{ $alt }}" class="image-card-img w-28 h-28 object-contain">
31+
</div>
32+
<span class="image-card-title text-sm font-medium text-redis-ink-900 hover:text-redis-red-500 transition-colors flex-grow flex items-end">{{ $title }}</span>
33+
</div>
34+
</a>

0 commit comments

Comments
 (0)