- Wrapped one example in
\\dontrun{}instead of\\donttest{}to prevent blackswan CRAN check notes when running tests wrapped in\\donttest{}
- Added
keep_stem_before_txt()function to process Coh-Metrix and GAMET filenames that appear as paths - integrated
keep_stem_before_txt()intoimport_coh()import_gamet()andimport_merge_gamet_rb()functions
- Added new vignette that details scoring model development
- Added a
pkgdown()site to host documentation on GitHub
- Fixed
predict_quality()example to run deterministically whenoptions(writeAlizer.offline = TRUE). - Example now seeds a local
'example'model withwa_seed_example_models("example", dir = tempdir())and restores prior options after cleanup. - Offline runs now fully skip remote file downloads, avoiding spurious errors during
R CMD check --as-cran --run-donttest. - No user-facing API changes.
- Introduced structured errors via
rlang::abort():writeAlizer_registry_missing– missing/invalidartifacts.csv.writeAlizer_unknown_model– unknown/unsupported model key (raised bypreprocess()/predict_quality()).writeAlizer_download_failed– offline/bad URL/checksum fetch failures.writeAlizer_internal_mismatch– expected submodel count ≠ preprocessing splits..wa_ensure_file- added classed errors and download retries
.wa_ensure_file():- Honors
options(writeAlizer.mock_dir=)(preserves subdirs). - Supports
file://URLs; clearer offline guidance. - Warns on cached checksum mismatch; hard-errors if post-download checksum mismatches.
- Honors
.wa_parts_for()validates inputs and uses canonicalized model keys..wa_load_model_rdas()/.wa_load_fits_list():- Prefer
mock_dirartifacts; load via temp env; pick sensible object (fit,model, etc.). - Legacy → v2 name mapping; special-case
example.
- Prefer
.wa_require_pkgs_for_fits()collects deps from model classes andtrain$modelInfo$library; errors with install hint..wa_validate_import()- checks ID column for duplicates and character type
- Reports
requiredvsmissingfromSuggests+ overrideoptions(writeAlizer.required_pkgs=). - Preserves version qualifiers in
required; strips qualifiers formissing. - Emits copy-paste
install.packages()command. - Tests updated to capture output/messages cleanly (no stray console prints).
- Better validation for swapped args and
NA/invalidmodelwith actionable messages. predict_quality()surfaces unknown model keys (includes canonicalized key).- Preprocessing preserves row counts/
ID; supports v2 varlists and consolidated-split behavior.
- Added
wa_sample_path()to reliably findinst/extdatain dev/install contexts. - Network helper hardened; integration tests force offline via
options(writeAlizer.offline=TRUE)and avoid HEAD probes. - Introduced
.quiet_eval()to silence messages/warnings in targeted assertions.
- Integration test now mocks the registry (RDS + RDA) for all exercised models:
- RB:
rb_mod1,rb_mod2,rb_mod3narr_v2,rb_mod3exp_v2,rb_mod3per_v2,rb_mod3all_v2 - Coh:
coh_mod1,coh_mod2,coh_mod3narr,coh_mod3exp,coh_mod3per,coh_mod3all - GAMET:
gamet_cws1
- RB:
- Writes matching varlists/fits into
mock_dir; verifies prediction columns and mean-column rules. rb_mod3allsmoke test made offline-only with mocked varlists.
- Coverage for:
import_rb()path withSEP=,+read.table(text=readLines()).NaN→NAin character columns; guarded numeric-like conversion (accepts integer where appropriate).- Name-based keep/drop assertions driven by sample header.
- Skips only when assets truly missing (via
wa_sample_path()).
- Added a package vignette
- switch to MIT license
- Added/updated tests for:
- Mismatched expected submodels.
- Bad registry columns.
- Checksum errors.
- Legacy → v2 artifact-name mapping.
- CRAN policy: ensure graceful failure when Internet resources are unavailable or have changed.
- Hardened internal downloader to respect offline environments and provide informative messages
instead of low-level
download.fileerrors. - Tests that require remote artifacts now skip when the concrete URLs/paths are unavailable, while example assets use a seeded mock directory for deterministic, network-free runs.
- Hardened internal downloader to respect offline environments and provide informative messages
instead of low-level
- No user-facing API changes.
-
Replaced
writeAlizer:::wa_seed_example_models()withwriteAlizer::wa_seed_example_models()in examples and documentation, per CRAN’s guidance to avoid accessing unexported objects. -
Exported
wa_seed_example_models()with full documentation:- Added
@return(returns the created temp path invisibly). - Added a small, runnable example that writes only to
tempdir()and cleans up; it also restores any prior option value. - Documented the temporary side effect of setting
options(writeAlizer.mock_dir = <path>).
- Added
- DESCRIPTION: acronyms expanded (e.g., CBM), software/package names single-quoted, and method references added with CRAN auto-link format (DOIs).
- Documentation:
@returnadded toimport_coh(),import_rb(),import_gamet(),import_merge_gamet_rb(). - Examples:
\\dontrun{}replaced with\\donttest{}where needed; fast examples unwrapped;predict_quality()uses a tiny offline'example'model seeded intempdir()with cleanup. - File I/O: no writes to home by default; examples/tests use
tempdir(); caching standardized viatools::R_user_dir("writeAlizer","cache"). - New helpers:
wa_cache_dir()andwa_cache_clear(ask=)for cache discovery/cleanup. - Optional deps: new
model_deps()reports (does not install) optional packages and prints an install hint;install_model_deps()deprecated. - Tests: self-cleaning with
withrfixtures; no temp detritus; removed deprecated global teardown.
- Stabilized example/test behavior when offline by mocking artifacts via
writeAlizer.mock_dir. - Suppressed noisy pre-processing variance warnings in integration tests.
- Simplified
install_model_deps():- Removed unused
modelargument. - Standardized on the
options(writeAlizer.require_pkgs_for_fits = function() ...)hook; dropped internal helper. - Single
Suggestsdiscovery path viautils::packageDescription(..., fields = "Suggests"). dry_run = TRUEnow returns tokens visibly (character vector); version qualifiers are stripped only for checks/installs.
- Removed unused
- Tests updated
- Test coverage raised to ~82% overall.
artifact_registry: prefer CSV (inst/metadata/artifacts.csv) and remove legacy in-code fallback table; tighter input validation.- Quieter tests by silencing download/file messages and using local cache paths during tests.
- More robust
install_model_deps():- Clear dry-run behavior (returns Suggests tokens or helper-provided list).
- Strips version qualifiers before installation; installs only truly missing packages.
- New helper hook via
options(writeAlizer.require_pkgs_for_fits = function(model, install, return_pkgs) {...}).
- Documentation: examples added for
install_model_deps(); tidied roxygen. - Stabilized artifact fetching in tests (
.wa_ensure_file) with explicit cache dirs and checksum paths. - Eliminated intermittent warnings from
download.file()and file URLs during tests. - Added/expanded tests for registry filtering, checksum guards, loader utilities, and package-requirement collection.
- Removed unused/legacy code paths exercised only by fallback artifact table.
- Replaced the ReaderBench mod3 models with their v2 counterparts (e.g.,
rb_mod3allnow calls therb_mod3all_v2models). - Optimized model artifact downloads and added SHA-256 checksum verification (auto re-download on mismatch).
predict_quality()now returns per-submodel scores and the overall mean columnpred_<model>_mean(where applicable).import_rb()now keeps ReaderBench features by name using the packagedsample_rb.csvheader (first 404), dropping 405+. It falls back to the legacy positional selection if the header is unavailable, reducing brittleness to column reordering.- Added
install_model_deps()helper to install Suggests for a given model. - CI: wired up GitHub Actions R-CMD-check (Windows/macOS/Linux).
- Added new genre-specific scoring models for ReaderBench (
rb_mod3narr_v2,rb_mod3exp_v2,rb_mod3per_v2,rb_mod3all_v2) and Coh-Metrix (coh_mod3narr,coh_mod3exp,coh_mod3per,coh_mod3all).
- Added new ReaderBench genre-specific scoring models (
rb_mod3narr,rb_mod3exp,rb_mod3per,rb_mod3all).
- Replaced RB/Coh model 2s with trimmed versions of model 1s with improved data pre-processing.
- Moved model artifacts to OSF hosting.
- Added RB/Coh model 2s (trimmed versions of model 1 ensembles).
- Model artifacts now download during first
predict_quality()call.
- Fixed ReaderBench file import.
- Now accepts ReaderBench output files as
.csv.
predict_quality()now also returns anIDvariable.
- Added model fit objects to package and test data.
- Initial version.