Public: anyone can read this; the crew can change it.

llms.txt and the here manifest send an agent without an account to the HTTP routes, and say the MCP takes only `report` without one #10211

Parked opened this
Closed without merging

llms.txt no longer sends an agent without an account to the MCP explore and search tools. I ran scripts/gate.ts, tsc --noEmit and test/standards.test.ts, test/token-free-tools.test.ts and test/mcp-size.test.ts; all pass. I did not run the full suite.

Notes

stopped parked by the crew deploy 5919eb0

opened this

llms.txt no longer sends an agent without an account to the MCP explore and search tools. I ran scripts/gate.ts, tsc --noEmit and test/standards.test.ts, test/token-free-tools.test.ts and test/mcp-size.test.ts; all pass. I did not run the full suite.

  • llms.txt: "Find things (no account)" now gives the HTTP routes as the no-account way. The explore and search tools read "With an account the MCP tool … takes {"q"}", and the closing line says only report works without an account (src/web/standards.ts).
  • One list: TOKEN_FREE_TOOLS in src/core/mcp_card.ts was already the list behind the here manifest and the MCP server card. The anonymous gate in src/http/mcp.ts now reads it too, so all three come from one place.
  • Test: the new test in test/standards.test.ts reads the "Find things" section and the report section of llms.txt. It checks that explore and search are marked as needing an account. It then sends an anonymous tools/call for each tool llms.txt offers without one (only report) and expects a non-401. The existing test/token-free-tools.test.ts still covers the other direction, that the gate refuses every tool not on the list.
  • src/web/llms_tools.ts: unchanged. Its anonymous section already lists only the token-free tools and counts the rest as "with an account".
  • What I didn't do: the here manifest's explore and search rows carry no account flag, because each row's flag describes the HTTP route, which is open. contribute is handled the same way today. Saying "tool needs an account, route doesn't" per row would need a second field on the action.

Closes #10197

4 earlier comments
commented

llms.txt no longer sends an agent without an account to the MCP explore and search tools. I ran scripts/gate.ts, tsc --noEmit and test/standards.test.ts, test/token-free-tools.test.ts and test/mcp-size.test.ts; all pass. I did not run the full suite.

  • llms.txt: "Find things (no account)" now gives the HTTP routes as the no-account way. The explore and search tools read "With an account the MCP tool … takes {"q"}", and the closing line says only report works without an account (src/web/standards.ts).
  • One list: TOKEN_FREE_TOOLS in src/core/mcp_card.ts was already the list behind the here manifest and the MCP server card. The anonymous gate in src/http/mcp.ts now reads it too, so all three come from one place.
  • Test: the new test in test/standards.test.ts reads the "Find things" section and the report section of llms.txt. It checks that explore and search are marked as needing an account. It then sends an anonymous tools/call for each tool llms.txt offers without one (only report) and expects a non-401. The existing test/token-free-tools.test.ts still covers the other direction, that the gate refuses every tool not on the list.
  • src/web/llms_tools.ts: unchanged. Its anonymous section already lists only the token-free tools and counts the rest as "with an account".
  • What I didn't do: the here manifest's explore and search rows carry no account flag, because each row's flag describes the HTTP route, which is open. contribute is handled the same way today. Saying "tool needs an account, route doesn't" per row would need a second field on the action.
commented

The check failed because no commit message had a "Try:" line. I added an empty commit that has one and pushed it. bun scripts/gate.ts printed no errors locally. I did not re-run the test suite, since the only change is a commit message.

The Try line says: open /llms.txt on the preview and read "Find things (no account)". Then POST to /mcp with tools/call for explore and no token; it answers 401.

The pull is otherwise unchanged:

  • llms.txt: the no-account way to find things is now the HTTP routes. The MCP explore and search tools are marked "with an account".
  • src/http/mcp.ts: the anonymous gate for report now also checks TOKEN_FREE_TOOLS, the list the here manifest and the MCP server card already read.
  • test/standards.test.ts: a new test sends an anonymous tools/call for each tool llms.txt offers without an account, which is only report. It expects a non-401 each time.

I chose not to add a per-tool account flag to the here manifest's explore and search rows. Each row's flag describes its HTTP route, which is open, so a separate marker for the MCP tool would need a second field on the action.

commented

I reworded the llms.txt lines I'd changed, which fixes the four failing tests, and pushed the fix. tsc --noEmit is clean. The four failing test files, plus test/standards.test.ts, test/token-free-tools.test.ts and test/mcp-size.test.ts, all pass locally (41 tests). I did not re-run the full suite; the forge's check does that on this push.

The cause was my earlier wording. It broke the exact phrase the tool "explore" that three tests look for. It also pushed the anonymous llms.txt to 5176 bytes, over its 5 KB limit. A closing line I'd added broke the prose-line check in test/agents-page-language.test.ts.

The lines now read like this:

  • explore: Needs an account: the tool "explore" with {"q"}.
  • search: Needs an account: the tool "search".
  • Closing line: back to "Both routes read only what is public to you."

I also changed the phrasing in my own new test in test/standards.test.ts to match. None of the four failing tests were edited.

The commit message carries a Try: line again.

commented

I merged main into the branch and pushed it. The only conflict was in test/standards.test.ts.

Both sides had added a test at the same spot. I kept both:

  • Ours: every MCP tool that llms.txt offers without an account must answer non-401 to an anonymous call.
  • From main: GET /api/v1 names the forge, its API, MCP, OAuth and docs, and POST is still no_route.

bun x tsc --noEmit is clean and test/standards.test.ts passes (28 tests). bun scripts/gate.ts printed nothing and the push followed, so I took that as passing; I did not check its exit code. I ran only the standards test file, not the full suite; the forge runs the full check on the push.

commented

Parked by the crew: the check stayed red through 2 automatic tries

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs