协作头脑风暴
brainstorming
在实现前澄清需求、探索设计选择,并形成清晰的开发方向。
inference-and-serving【开发与工程】Use this sub-skill for LlamaFactory inference, ChatModel usage, chat/webchat/api commands, OpenAI-compatible serving, backend selection, streaming, score evaluation, API auth, and batch vLLM prediction workflows.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use this sub-skill when an agent needs to run or debug LlamaFactory inference and serving flows for version 0.9.6.dev0 source behavior.
ChatModel from Python for chat, stream_chat, get_scores, and their async variants.llamafactory-cli chat, lmf chat, llamafactory-cli webchat, llamafactory-cli api, or lmf api./v1/models, /v1/chat/completions, and /v1/score/evaluation.infer_backend: huggingface, infer_backend: vllm, or infer_backend: sglang for inference configs.model-loading-and-export sub-skill.data-and-templates unless the failure is specific to API request payload handling.webui-and-ops.model_name_or_path, template, and infer_backend; the default architecture is v0 unless USE_V1=1 is explicitly set.llamafactory-cli chat CONFIG.yaml or lmf chat CONFIG.yaml.API_PORT=8000 llamafactory-cli api CONFIG.yaml and call http://HOST:PORT/v1/... endpoints.API_KEY only when bearer-token auth is desired; clients must send Authorization: Bearer $API_KEY when it is set.infer_backend: huggingface for broad compatibility and score evaluation; use vllm or sglang for faster generation when those optional packages and GPU resources are available.references/chat-and-api.md covers ChatModel, CLI commands, API routes, request shapes, streaming, auth, env vars, and native verification candidates.references/backend-selection.md compares Hugging Face, vLLM, and SGLang inference backends and includes batch vLLM metric flow notes.references/troubleshooting.md maps common serving failures to likely causes and fixes.scripts/openai_api_smoke.py is a standalone OpenAI-compatible smoke client for model listing, chat, optional streaming, optional score evaluation, and API-key verification.scripts/vllm_batch_infer.py is a safe wrapper that prints or optionally runs a LlamaFactory batch vLLM command only when the caller supplies concrete model/config arguments.