SaylorTwift HF Staff
vLLM: --enable-auto-tool-choice --tool-call-parser lfm2 (OpenCode sends tool_choice=auto)
f4740f8 verified Download serve_policy.sh from SaylorTwift/lfm-opencode-lora-rl-code: direct link, hf CLI and curl.
- Browser
- Download file 1.13 kB
-
https://huggingface.co/SaylorTwift/lfm-opencode-lora-rl-code/resolve/main/serve_policy.sh
- Command line
-
hf download hf://SaylorTwift/lfm-opencode-lora-rl-code/serve_policy.sh
-
curl -L -o serve_policy.sh https://huggingface.co/SaylorTwift/lfm-opencode-lora-rl-code/resolve/main/serve_policy.sh
1.13 kB
| # Policy server: vLLM serving LiquidAI/LFM2.5-2.6B on GPU 1. | |
| # | |
| # Flag provenance: | |
| # --return-tokens-as-token-ids capture proxy needs the exact sampled token ids | |
| # --logprobs-mode processed_logprobs proxy needs per-token logprobs that match the policy | |
| # --weight-transfer-config TRL AsyncGRPOTrainer pushes merged weights over NCCL | |
| # VLLM_SERVER_DEV_MODE=1 exposes the weight-update endpoint TRL posts to | |
| # | |
| # Deliberately NOT passed: | |
| # --enable-lora adapter sync rotates adapter names, which the | |
| # OpenEnv capture proxy cannot address; the trainer | |
| # merges the LoRA into the base and syncs full weights | |
| set -euo pipefail | |
| MODEL="${MODEL:-LiquidAI/LFM2.5-2.6B}" | |
| PORT="${PORT:-8001}" | |
| CUDA_VISIBLE_DEVICES=1 VLLM_SERVER_DEV_MODE=1 \ | |
| vllm serve "$MODEL" \ | |
| --port "$PORT" \ | |
| --max-model-len 32768 \ | |
| --return-tokens-as-token-ids \ | |
| --logprobs-mode processed_logprobs \ | |
| --enable-auto-tool-choice \ | |
| --tool-call-parser lfm2 \ | |
| --weight-transfer-config '{"backend":"nccl"}' | |