Skip to content

Tighten finetuning HTTP API reference#10

Merged
EthanReid merged 1 commit into
mainfrom
ethan/lens_docs_http
Apr 1, 2026
Merged

Tighten finetuning HTTP API reference#10
EthanReid merged 1 commit into
mainfrom
ethan/lens_docs_http

Conversation

@EthanReid
Copy link
Copy Markdown
Contributor

Summary

This trims the finetuning HTTP API reference back toward Vik's tighter version while keeping the real API additions we still want to document.

A lot of the previous edits had drifted into a more verbose, overly detailed style. This PR rolls much of that back so the page reads like an HTTP reference again instead of a trainer/SDK handoff doc.

What changed

  • Removed verbose or non-contract-heavy sections that did not need to be exposed in the HTTP docs
  • Removed mention of checkpoint download from the HTTP reference
  • Removed the extra metrics/train-log sections that were added later
  • Restored the finetuned inference section closer to Vik's original structure
  • Simplified the rollouts section and kept only the rollout metadata note that clients need for RL round-tripping
  • Updated POST /train_step so the RL example clearly shows both request and rollouts
  • Added a compact Targets subsection for SFT with a small table and concrete snippets for query, point, and detect

Accuracy fixes

  • Fixed GET /finetunes/:finetuneId to show the actual wrapped response shape: { "finetune": { ... } }
  • Fixed the point/detect settings docs to match the current API
  • Removed the incorrect max_objects: 50 default
  • Restored max_tokens for point/detect in the request examples where that had been documented incorrectly
  • Kept max_objects as detect-only in the settings table
  • Updated wording like slower -> slower training
  • Removed misplaced notes like the query SFT note from the ground-truth section

Verification

  • Cross-checked the doc against tuna/src/tuna/rl/api_types.py
  • Cross-checked the control-plane routes/response shapes against md-api
  • Rendered locally with the Docusaurus dev server and reviewed the updated page

Copilot AI review requested due to automatic review settings April 1, 2026 00:21
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR tightens the finetuning HTTP API reference to be more “contract-focused” while updating several endpoint schemas/examples to reflect the current API (notably /finetunes/:finetuneId, /rollouts, and /train_step).

Changes:

  • Corrects GET /finetunes/:finetuneId to show the wrapped response shape ({ "finetune": { ... } }).
  • Updates /rollouts docs/examples (e.g., num_rollouts, spatial_refs, max_tokens defaults, rollout metadata note).
  • Expands /train_step documentation to cover both RL and SFT modes, adds a “Targets” subsection, and documents a non-empty response shape with metrics.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/finetuning/http-api-reference.mdx
Comment thread docs/finetuning/http-api-reference.mdx
Comment thread docs/finetuning/http-api-reference.mdx
Comment thread docs/finetuning/http-api-reference.mdx
Comment thread docs/finetuning/http-api-reference.mdx
@EthanReid EthanReid force-pushed the ethan/lens_docs_http branch from 9768b72 to 36115db Compare April 1, 2026 00:27
@EthanReid EthanReid merged commit dbf5cc9 into main Apr 1, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants