Horse is a lightweight web framework for Delphi and Lazarus programs, providing tools for building HTTP servers and APIs. It is for developers who need routing, request handling, middleware, streaming, WebSockets, and related server features in those languages. Its catalogue skills support working with the framework.
Borrowing it
Nothing to install: this file belongs to HashLoad/horse. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/HashLoad/horse/master/.agents/skills/horse-advanced-routing/SKILL.mdgit clone --depth 1 https://github.com/HashLoad/horseWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/hashload/horse/horse-advanced-routing)<a href="https://agentmods.dev/skills/hashload/horse/horse-advanced-routing"><img src="https://agentmods.dev/badge/skills/hashload/horse/horse-advanced-routing/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/hashload/horse/horse-advanced-routing"><img src="https://agentmods.dev/badge/skills/hashload/horse/horse-advanced-routing.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00025 | $0.00503 |
| Opus 5 | $0.00013 | $0.00251 |
| Sonnet 5 | $0.00005 | $0.00101 |
| Haiku 4.5 | $0.00003 | $0.00050 |
Grade A, and why
horse-advanced-routing scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 42 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Horse Advanced Routing Skill
This skill guides AI agents in maintaining, expanding, and debugging Advanced Routing features (Regular Expression constraints and Optional path parameters) within the Horse framework.
💡 Syntax Reference
- Optional parameters:
:paramName?- Example:
/users/:id?
- Example:
- Regex constraints:
:paramName(regexPattern)- Example:
/users/:id(\d+)
- Example:
- Legacy segment Regex:
(regexPattern)(Keep for backwards compatibility only)- Example:
/users/(\d+)
- Example:
⚙️ Architecture and Execution Flow
1. Regex Helper (src/Horse.Core.Regex.pas)
Always use the unified THorseRegex abstraction. Do NOT import System.RegularExpressions (Delphi) or RegExpr (FPC) directly in routers to prevent cross-compilation breaks.
- Use
THorseRegex.Create(APattern)to instantiate. - Use
THorseRegex.Match(AContent)which returnsBooleanindicating if the exact string matches the pattern. - Always free the regex matcher instance inside the node destructions (
TRadixNode.Destroy/THorseRouterTree.Destroy).
2. Parameter Injection
When a path segment matches a route parameter, always ensure it is registered in THorseRequest.Params even if optional and empty:
- Optional parameter missing →
Params.Items['param'] = ''. - Ensure backtracking logic in
CallNextPath(Tree) andFindNode(Radix) clears parameters during path rejection to prevent parameters from bleeding into other matched paths.
3. Route Precedence
When routing, the engines prioritize matches as follows:
- Exact static segment matches (
/users/new) - Regular expression matched parameters (
/users/:id(\d+)) - Optional or general parameters (
/users/:id?)
🧪 Testing Guidelines
- Always write integration tests in
tests/src/tests/Tests.Integration.AdvancedRouting.pasverifying bothTHorseRadixRouterandTHorseRouterTree. - Test real network calls with
System.Net.HttpClientto confirm full transport compatibility. - Ensure ports are freed properly during TearDown using the
ClearGlobalStatehelper.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 10d ago First seen · 42 lines · 25 tokens per session scan A 9d56a43eb5a4
horse-advanced-routing is a skill published in the GitHub repository HashLoad/horse (1,373 stars, last pushed today), licensed MIT. It adds 25 tokens to every session and 503 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
api-design-patterns
Comprehensive API design patterns covering REST, GraphQL, gRPC, versioning, authentication, and modern API best practices.
api-design-patterns
Comprehensive API design patterns covering REST, GraphQL, gRPC, versioning, authentication, and modern API best practices.
api-design-patterns
Comprehensive API design patterns covering REST, GraphQL, gRPC, versioning, authentication, and modern API best practices.
hunt-wordpress
Use when an authorized target exposes WordPress core, plugin, theme, REST, or XML-RPC behavior.
mars-development
Develop REST APIs with MARS-Curiosity (Delphi REST library) - writing resources, REST attributes, parameter binding, JWT authentication and roles, FireDAC dataset publishing, server-sent events (SSE), WebStencils HTML templating, client components, configuration, serialization. Use this skill whenever the user is…
a0-development
Development guide for extending Agent Zero from current source and DOX. Use for framework architecture, tools, extensions, API/WebUI handlers, agent profiles, prompts, skills, projects, runtime boundaries, and contribution workflow. Load the focused reference files before giving implementation guidance.