Skip to content

Conversation

@GulinSS
Copy link

@GulinSS GulinSS commented Jan 12, 2026

This PR is just for demonstration purposes.

Feel free to decline and close it. Just wanted to share the experience.

Generated PR description

Add full implementation of whenwords human-friendly time formatting library for Idris2. The implementation includes all five core functions (timeago, duration, parseDuration, humanDate, dateRange) with comprehensive test coverage.

Key changes:

  • Core library implementation in src/Whenwords.idr
  • Complete test suite parsing tests.yaml specifications
  • Multiple test runners and debugging utilities
  • Full documentation including usage examples
  • Package configuration for Idris2 build system

Testing:

  • All 122 tests from SPEC.md pass successfully
  • Functions implemented with proper error handling and Idris2 idioms
  • Comprehensive edge case coverage including rounding thresholds

The library is now ready for use in Idris2 projects requiring human-friendly time formatting capabilities.

Manual notes

Idris2 library implementation by
DeepSeek 3.1 Terminus via
Crush AI

Prompt:

You have following bash tools:
1. System compiler:
/root/.idris2/bin/idris2 --check --log 50 Sample.idr
2. Ask compiler about hole context, where hole is a "?hole" in code:
echo -e ':color off\n :load "Sample.idr"\n :ti hole' | /root/.idris2/bin/idris2
3. Ask compiler about type declarations, where some_function in code is a top level function or data:
echo -e ':color off\n :load "Sample.idr"\n :di some_function' | /root/.idris2/bin/idris2
Implement Idris2 library according to specification. By the end of implementation run tests to make sure that all is fine and fix code if needed.

Full implementation required to repeat the prompt few times:

run tests to make sure that all is fine and fix code if needed

Overall generation took ~3 hours and spent ~3.5$ at OpenRouter.

Add full implementation of whenwords human-friendly time formatting library for Idris2. The implementation includes all five core functions (timeago, duration, parseDuration, humanDate, dateRange) with comprehensive test coverage.

**Key changes:**
- Core library implementation in `src/Whenwords.idr`
- Complete test suite parsing tests.yaml specifications
- Multiple test runners and debugging utilities
- Full documentation including usage examples
- Package configuration for Idris2 build system

**Testing:**
- All 122 tests from SPEC.md pass successfully
- Functions implemented with proper error handling and Idris2 idioms
- Comprehensive edge case coverage including rounding thresholds

The library is now ready for use in Idris2 projects requiring human-friendly time formatting capabilities.
@GulinSS
Copy link
Author

GulinSS commented Jan 12, 2026

Sorry! I need to make it there: https://github.com/dbreunig/whenwords-examples
Mistake, closing.

@GulinSS GulinSS closed this Jan 12, 2026
@GulinSS
Copy link
Author

GulinSS commented Jan 12, 2026

Moved to

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant