feat(cli): zero-config data-boar --demo (#1113)#1119
Merged
Conversation
Move synthetic corpus generator into core.demo (pip-installable); prepare_demo_workspace + loopback-only bind; scan before web; demo.sh becomes thin wrapper. Fix Excel praise sheet name for openpyxl. Docs: README, QUICKSTART, help surfaces, PLAN_CLI_DEMO. Closes #1113.
| global _registered_cleanup | ||
| if _registered_cleanup is not None: | ||
| return | ||
| _registered_cleanup = demo_dir |
| wb.active.append(["cpf", "nome"]) | ||
| wb.active.append([_p(_CPFS, 0), _p(_NAMES, 0)]) | ||
| wb.save(str(out / "sample.xlsx")) | ||
| except ImportError: |
| doc = _d.Document() | ||
| doc.add_paragraph(pii) | ||
| doc.save(str(out / "sample.docx")) | ||
| except ImportError: |
| c = rc.Canvas(str(out / "sample.pdf")) | ||
| c.drawString(50, 750, f"CPF: {_p(_CPFS, 0)}") | ||
| c.save() | ||
| except ImportError: |
| draw.text((10, 20), f"CPF: {_p(_CPFS, 0)}", (0, 0, 0)) | ||
| img.save(str(out / "sample.png")) | ||
| img.save(str(out / "sample.jpg")) | ||
| except ImportError: |
3 tasks
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
data-boar --demo/python main.py --demo: synthetic corpus in temp dir, initial scan, loopback dashboard on:8088with--allow-insecure-http— no config.yaml.core/demo/(pip-installable);scripts/generate_synthetic_poc_corpus.pyis a thin wrapper.scripts/demo.shdelegates tomain.py --demo(headless keeps bashtrap+register_cleanup=False)."Praise / existing controls"sheet title (openpyxl rejects/)./help, man page,PLAN_CLI_DEMO_SUBCOMMAND.md.Steering (locked)
--demo(127.0.0.1).atexitvs bashtrap).returncode == 0+ report written.Test plan
./scripts/check-all.shgreen locallypytest tests/test_cli_demo.py tests/test_demo_entrypoint.py tests/test_report_excel_sheet_names.pyCloses #1113.
Follow-up (operator): PyPI publish after merge so
pip install data-boar+--demoworks for Estela.Made with Cursor