docs: migrate to VitePress and overhaul documentation#164
Merged
Conversation
- Replace Documenter.HTML with DocumenterVitepress.MarkdownVitepress - Add DocumenterInterLinks for cross-package links to CTBase and CTModels - Add package.json, .vitepress/ config, theme, and Vue components (copied from CTModels) - Refactor api_reference.jl to canonical CTModels pattern: modules_config array, one public page per module, single Internals page for all private symbols + extensions - Add getting-started.md (quick start, options, mental model) - Replace all 17 Mermaid diagrams with ASCII text blocks - Update index.md as VitePress landing page - Remove DocumenterMermaid dependency Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- error_messages.md: CTBase.Options.NotProvided → CTBase.Core.NotProvided - implementing_a_modeler.md: convert metadata/constructor @example blocks to julia blocks — these require ADNLPModels extension not in docs deps - implementing_an_optimization_problem.md: full rewrite — the guide described a fictional Builder API; real DiscretizedModel is {ocp, discretizer, cache} with build_model/build_solution dispatch Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Per Handbook philosophy (docstrings.md): every exported symbol carries a docstring; all @ref use the full module path (CTSolvers.Module.symbol). - Optimization/building.jl: add docstrings to build_model/build_solution generic function declarations (were missing despite being exported) - docs/api_reference.jl: add building.jl to Optimization page file list so build_model/build_solution appear in the generated API reference - Optimization/built_model.jl: qualify all @ref (BuiltModel, NoCache, build_model, build_solution) - Modelers/contract.jl: qualify all @ref (Optimization.BuiltModel → CTSolvers.Optimization.BuiltModel, etc.) - Integrators/abstract_integrator.jl: qualify AbstractIntegrationResult, merge, options_point, options_trajectory @ref - Integrators/contract.jl: qualify AbstractIntegrationResult @ref Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Intro: clarify CTSolvers provides infrastructure consumed by CTDirect (direct methods) and CTFlows (flows for indirect methods) - Module table: update Optimization row (remove "builder pattern"), add CTDirect link in DOCP row - Guide links: replace "builder interaction" / "builder pattern" with accurate descriptions of the dispatch-based contract Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The guides described pre-refactor code: callable modelers with get_*_builder
lookups (removed in v0.4.21-beta) and non-parameterized solver/modeler
constructors. Rewrite them to match the current API.
- implementing_a_modeler: modelers are options-carrying strategies; build_model/
build_solution are dispatched on the (problem, modeler) pair by the package
providing the problem (e.g. CTDirect). Parameterized structs, real ADNLP/Exa
snippets, BuiltModel/cache flow.
- implementing_a_solver: parameterized {P} constructor chain and tag-dispatch
(tag and parameter passed as types); extension signatures matched to
ext/CTSolversIpopt.jl; added a Parameterization {P} section.
- architecture: type hierarchy with {P}, corrected Strategy Parameters and Tag
Dispatch sections, added Solvers.Uno to the module table.
- implementing_an_optimization_problem: real discretize (get_docp + DOCPCache),
realistic build_model/build_solution example, full-path @ref links.
- error_messages: the build_model NotImplemented demo now runs against a fake
problem+modeler in an isolated block label instead of passing an abstract type.
- index: drop the stale "callable contracts" mention.
Docs build clean (julia --project=docs docs/make.jl): no @ref or example warnings.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documenter.HTMLparDocumenterVitepress.MarkdownVitepress, ajouteDocumenterInterLinks(CTBase + CTModels),sidebar_drawer, guardbases_filepour le déploiementapi_reference.jl: patron canonique CTModels —modules_configarray, une page publique par module, une seule page Internals pour tous les symboles privés + toutes les extensions (au lieu de 12 pages extension séparées)getting-started.md: installation, mental model, quick start, options, next stepstextdansarchitecture.mdet les quatre guides, sans dépendance npmpackage.json,.vitepress/config.mts,mathjax-plugin.ts,julia-repl-transformer.ts,theme/,components/(4 fichiers Vue) — copiés depuis CTModelsindex.mdmise à jour comme landing page VitePress propredocs/Project.toml: retireDocumenterMermaid, ajouteDocumenterVitepress,DocumenterInterLinks,LiveServerTest plan
julia --project=docs docs/make.jls'exécute sans erreurcd docs && npm install && npm run docs:buildréussitnpx serve docs/build/1 --listen 5173: navigation correcte, 5 pages API publiques + Internals, aucun diagramme Mermaid cassé@replaffichent les erreurs colorées correctement (viajulia-repl-transformer.ts)🤖 Generated with Claude Code