Skip to content

Commit 8b54f78

Browse files
authored
fix: fixes CLI docs import order (#646)
Ensures the CLI args module imports only after the project root is added to sys.path so the docs generator keeps resolving project code reliably while silencing the linter warning.
1 parent 83b786e commit 8b54f78

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

docs/cli_reference.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -465,6 +465,7 @@ Controls text generation behavior for rollout.
465465
| `stop_token_ids` | list of integer | **Required** | Stop generation when encountering these token IDs. |
466466
| `stop` | list of string \| None | `None` | One or multiple stop words. Generation will stop if one of these words is sampled. |
467467
| `frequency_penalty` | float | `0.0` | Penalizes tokens based on their frequency in generation so far. Must be between -2 and 2 where negative numbers encourage repetition. |
468+
| `lora_name` | string | `""` | Lora name to be used for this generation. |
468469

469470
(section-inference-engine)=
470471

@@ -489,6 +490,7 @@ Configuration for inference servers, including offpolicyness control.
489490
| `pause_grace_period` | float | `0.0` | The grace period after calling /pause_generation. Wait until all requests have been dropped. |
490491
| `scheduling_spec` | `tuple` | **Required** | inference engine schedule specs. Can accept 1 or 2 SchedulingSpec: if 1 spec provided, it's used for both worker and engine, engine is embedded in the worker; if 2 specs provided, first one is for worker, second one is for engine. Currently only used by the RolloutController. |
491492
| `scheduling_strategy` | [`SchedulingStrategy`](section-scheduling-strategy) | **Required** | The scheduling strategy of this TrainEngine, either separation or colocation. Currently only used by the RolloutController. |
493+
| `use_lora` | boolean | `False` | Whether to use LoRA. Should be same as actors LORA option. |
492494

493495
(section-sg-lang)=
494496

@@ -585,6 +587,8 @@ https://docs.vllm.ai/en/stable/api/index.html for detailed documentation.
585587
| `worker_extension_cls` | string | `"areal.thirdparty.vllm.vllm_worker_extension.VLLMWorkerExtension"` | - |
586588
| `enable_sleep_mode` | boolean | `False` | - |
587589
| `uvicorn_log_level` | string | `"warning"` | - |
590+
| `enable_lora` | boolean | `False` | - |
591+
| `lora_modules` | string | `""` | - |
588592

589593
(section-train-dataset)=
590594

docs/generate_cli_docs.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@
1818
import mdformat
1919
from omegaconf import MISSING as OMEGACONF_MISSING
2020

21-
import areal.api.cli_args as cli_args_module
22-
2321
# Add the project root to the path so we can import areal
2422
project_root = Path(__file__).parent.parent
2523
sys.path.insert(0, str(project_root))
2624

25+
import areal.api.cli_args as cli_args_module # noqa: E402
26+
2727

2828
def discover_dataclasses() -> dict[str, Any]:
2929
"""Discover all dataclasses in the cli_args module."""

0 commit comments

Comments
 (0)