Repository navigation
Conversation
Add spaces/domux-demo, a Gradio app that turns a smart-home command into the 7-field slots and shows the raw output, a format check and latency. It loads iFlytekOpenSource/Domux with transformers at the revision used by cases/domux-4057-full-eval (ZeroGPU on Spaces), or calls an OpenAI-compatible vLLM/SGLang endpoint when DOMUX_API_BASE is set. Add a workflow that syncs the directory to the Space when HF_TOKEN is configured, and a PR check for the demo. Closes #10 Signed-off-by: FenjuFu <fufenjupku@gmail.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
Adds
spaces/domux-demo, a Gradio demo that can run as a Hugging Face Space so people can try Domux without deploying it, as #10 asks (in the spirit ofbaidu/Unlimited-OCR).action|device|attribute|value|unit|room|floorslots as a table, the raw model output, whether every line has 7 fields (same rule aseval/run_eval.py, including the&separator), and the latency.iFlytekOpenSource/Domuxwith transformers in BF16, pinned to revision6c71a32f. This mirrorscases/domux-4057-full-eval/eval_direct.py(transformers 5.15.1,AutoModelForCausalLM, greedy decoding, 256 new tokens), which scored 97.58% on the full test set. On a ZeroGPU Space each request is wrapped in@spaces.GPU.DOMUX_API_BASEis set. It calls a vLLM or SGLang server with the same request aseval/run_eval.py, so the Space can run on free CPU hardware..github/workflows/sync-space.ymluploads the directory to the Space on changes tomainor on manual dispatch. It targetsiFlytekOpenSource/Domux-Demounless theHF_SPACE_IDvariable says otherwise, and skips with a notice when theHF_TOKENsecret is not configured..github/workflows/space-check.ymlruns the demo tests on PRs.Closes #10
Maintainer setup
iFlytekOpenSource/Domux-Demo) and pick ZeroGPU hardware, or CPU withDOMUX_API_BASE.HF_TOKENsecret (andHF_SPACE_IDif the name differs).Testing
pytest spaces/domux-demo/tests: 9 passed. Covers slot splitting and format flags, input limits, the endpoint request shape, backend selection, and building the Gradio app with gradio 6.28.0.app.pylocally against a stub OpenAI-compatible server and used the UI in a browser. The multi-room example rendered as 4 slot rows with a valid-format badge, and an empty submit shows the validation message.spaces/domux-demo/README.md) parses withhuggingface_hub.SpaceCard, andzero-a10gis a validSpaceHardwarevalue.cases/domux-4057-full-evalline for line, and the first Space build will exercise it.