[
https://issues.apache.org/jira/browse/TINKERPOP-3310?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Stephen Mallette updated TINKERPOP-3310:
----------------------------------------
Description:
Links from one docs book to another are written as absolute anchor URLs, such
as https://tinkerpop.apache.org/docs/x.y.z/reference/#addedge-step. In the HTML
the reference book is one page, so the anchor resolves. In the Markdown, each
book is split into many pages, and MarkdownSplitter only rewrites links within
a book. Links between books keep the site URL, which has no page path. A reader
following one from the Markdown (an agent using llms.txt, or gremlin-mcp's
get_gremlin_doc_page) lands on the whole HTML book, or fails, instead of
reaching the Markdown page with that anchor. The 3.8.2 reference and provider
pages alone have 124 of these links.
MarkdownSplitter already gets every book in one run. It should map each anchor
to the page that owns it across all books, and rewrite these URLs to relative
links to that page. Links to other versions, to docs/current, and to anchors no
page owns should stay unchanged. gremlin-mcp then needs no change, because it
already turns relative links between served pages into page ids. Versions whose
Markdown was already published can be fixed by republishing it.
was:
The Gremlin Semantics pages served by gremlin-mcp link into the reference docs
with HTML anchor URLs such as
https://tinkerpop.apache.org/docs/3.8.2/reference/#addedge-step. The installed
3.8.2 docs contain 232 of them. The reference book is split into multiple
Markdown pages, so the URL has no page path. get_gremlin_doc_page resolves it
to reference/.md, which doesn't exist, so an agent can't follow these links
even though the tool says it accepts site URLs.
These URLs should resolve to the page that owns the anchor. For example,
parsePage (or the page lookup in get_gremlin_doc_page) could rewrite
<site>/<version>/reference/#<anchor> to <page-id>#<anchor> using the section
anchors already parsed for each served page. An anchor no served page owns
should keep its site URL.
> gremlin-mcp tool cannot follow anchor-only references
> -----------------------------------------------------
>
> Key: TINKERPOP-3310
> URL: https://issues.apache.org/jira/browse/TINKERPOP-3310
> Project: TinkerPop
> Issue Type: Bug
> Components: mcp
> Affects Versions: 4.0.0
> Reporter: Stephen Mallette
> Priority: Major
>
> Links from one docs book to another are written as absolute anchor URLs, such
> as https://tinkerpop.apache.org/docs/x.y.z/reference/#addedge-step. In the
> HTML the reference book is one page, so the anchor resolves. In the Markdown,
> each book is split into many pages, and MarkdownSplitter only rewrites links
> within a book. Links between books keep the site URL, which has no page path.
> A reader following one from the Markdown (an agent using llms.txt, or
> gremlin-mcp's get_gremlin_doc_page) lands on the whole HTML book, or fails,
> instead of reaching the Markdown page with that anchor. The 3.8.2 reference
> and provider pages alone have 124 of these links.
>
> MarkdownSplitter already gets every book in one run. It should map each
> anchor to the page that owns it across all books, and rewrite these URLs to
> relative links to that page. Links to other versions, to docs/current, and to
> anchors no page owns should stay unchanged. gremlin-mcp then needs no change,
> because it already turns relative links between served pages into page ids.
> Versions whose Markdown was already published can be fixed by republishing it.
>
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)