Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Localhost link lint #16424

Merged
merged 13 commits into from
Aug 23, 2024
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/styles/cloudflare/RelativeLinks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@
#
# For a list of all options, see https://vale.sh/docs/topics/styles/
extends: existence
message: "**Warning**: When referring to another page in our docs, use the full relative link (`/1.1.1.1/check/`) instead of the full URL (`https://developers.cloudflare.com/1.1.1.1/check/`)."
message: "**Warning**: When referring to another page in our docs, use the full relative link (`/1.1.1.1/check/`) instead of the full URL (`https://developers.cloudflare.com/1.1.1.1/check/`) or a local development link (`http://localhost:1111`)."
level: warning
scope: raw
raw:
- '\[.+\]\(https?:\/\/developers\.cloudflare\.com\/.+\)'
- '\[.+\]\(https?:\/\/github\.cloudflare\.com\/.+\)'
- '\[.*?\]\(http:\/\/localhost:1111\/.*?\)'
- '\[[^\]]+\]\(https?:\/\/developers\.cloudflare\.com\/.*?\)'
1 change: 0 additions & 1 deletion .hyperlint/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,3 @@ authorized_users:
- RebeccaTamachiro
style_guide:
enabled: true
unmanaged_vale: true
9 changes: 6 additions & 3 deletions .vale.ini
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
StylesPath = .github/styles
MinAlertLevel = suggestion
IgnoredScopes = code, tt, img, url, a
IgnoredScopes = code, tt, img
SkippedScopes = script, style, pre, figure, code

[formats]
yml = yaml
mdx = md

[*]
# Ignore code surrounded by backticks or plus sign, parameters defaults, URLs, and angle brackets.
TokenIgnores = (<\/?[A-Z].+>), (\x60[^\n\x60]+\x60), ([^\n]+=[^\n]*), (\+[^\n]+\+), (http[^\n]+\[), (https[^\n]+\[)
# Ignore code surrounded by backticks or plus sign, parameters defaults, and angle brackets.
TokenIgnores = (<\/?[A-Z].+>), (\x60[^\n\x60]+\x60), ([^\n]+=[^\n]*), (\+[^\n]+\+)

[*.md]
BasedOnStyles = cloudflare

[*.mdx]
BasedOnStyles = cloudflare

[*.yaml]
BasedOnStyles = cloudflare
14 changes: 12 additions & 2 deletions src/content/docs/ai-gateway/configuration/caching.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,26 @@ description: Override caching settings on a per-request basis.

import { TabItem, Tabs } from "~/components";

And let's see whether it finds [the link](http://localhost:1111/rules/url-forwarding/single-redirects/settings/)
kodster28 marked this conversation as resolved.
Show resolved Hide resolved

Enable and customize your gateway cache to serve requests directly from Cloudflare’s cache, instead of the original model provider, for faster requests and cost savings.

Or [this link](https://github.com/cloudflare-docs).

Or [this one](https://developers.cloudflare.com/test/)

:::note

Currently caching is supported only for text and image responses, and it applies only to identical requests. This is helpful for use cases when there are limited prompt options - for example, a support bot that asks "How can I help you?" and lets the user select an answer from a limited set of options works well with the current caching configuration.
We plan on adding semantic search for caching in the future to improve cache hit rates.
:::

Okay, but you can catch this thing, i.e., the latin stuff.
kodster28 marked this conversation as resolved.
Show resolved Hide resolved

## Default configuration

<Tabs syncKey="dashPlusAPI"> <TabItem label="Dashboard">
<Tabs syncKey="dashPlusAPI">
<TabItem label="Dashboard">

To set the default caching configuration in the dashboard:

Expand All @@ -29,7 +38,8 @@ To set the default caching configuration in the dashboard:
4. Enable **Cache Responses**.
5. Change the default caching to whatever value you prefer.

</TabItem> <TabItem label="API">
</TabItem>
<TabItem label="API">

To set the default caching configuration using the API:

Expand Down
Loading