Commit graph

52 commits

Author SHA1 Message Date
Andreas Koepf (aider)
dd6fc96891 feat: Add letter counting algorithmic task with configurable text span generation 2025-01-23 19:11:15 +01:00
Andreas Koepf
f78bb85a85 add plaintext of book In the year 2889 by Michel & Jules Verne (project Gutenberg eBook #19362) 2025-01-23 19:01:44 +01:00
Andreas Koepf (aider)
746e05aa3d feat: Add data file loading utilities to reasoning_gym.data 2025-01-23 18:58:58 +01:00
Andreas Koepf (aider)
22538be4c5 feat: Add data file packaging configuration and __init__.py for reasoning_gym.data 2025-01-23 18:57:34 +01:00
Andreas Koepf (aider)
b73c466392 docs: Add documentation for PropositionalLogicDataset to README 2025-01-23 14:50:02 +01:00
Andreas Koepf (aider)
d0444f3546 feat: Add logic module to reasoning_gym package imports 2025-01-23 14:41:44 +01:00
Andreas Koepf (aider)
fa68760784 feat: Add propositional logic dataset generator with comprehensive logical reasoning tasks 2025-01-23 14:38:56 +01:00
Andreas Koepf (aider)
03a3bcf059 feat: Add configurable whitespace option to ArithmeticDataset 2025-01-23 14:25:54 +01:00
Andreas Koepf (aider)
6dbb5b39ee refactor: Reorder parameters of _format_question to match other methods 2025-01-23 14:22:46 +01:00
Andreas Koepf (aider)
f12e3788d1 refactor: Pass item_rng to _format_question() method in ArithmeticDataset 2025-01-23 14:20:22 +01:00
Andreas Koepf (aider)
1c0a7e9a7c docs: Add comprehensive documentation for existing generators in README 2025-01-23 14:15:12 +01:00
Andreas Koepf (aider)
9fb1798b48 fix: Correct rule composition in PatternRule to properly chain subrules 2025-01-23 14:07:18 +01:00
Andreas Koepf (aider)
0e9bc68776 feat: Add rule composition support to PatternRule 2025-01-23 14:04:36 +01:00
Andreas Koepf (aider)
7f27a2285c fix: Correct sequence generation and pattern rule application logic 2025-01-23 14:00:33 +01:00
Andreas Koepf (aider)
46601a2b8a fix: Correct sequence generation by using previous number in PatternRule 2025-01-23 13:54:11 +01:00
Andreas Koepf (aider)
985bded9e8 fix: Correct PatternRule.apply() to use current sequence element 2025-01-23 13:53:30 +01:00
Andreas Koepf (aider)
432c9436f7 fix: Correct PatternRule.apply() method to properly handle sequence operations
This commit message captures the essence of the change: fixing the implementation of the apply() method in the PatternRule class to correctly handle sequence operations and indexing.

The key changes are:
1. Use `sequence[position]` instead of `sequence[position - 1]`
2. Adjust PREV_PLUS condition to use `position > 0`
3. Use `sequence[position - 1]` for previous element reference

Would you like me to elaborate on the specific changes or rationale?
2025-01-23 13:52:47 +01:00
Andreas Koepf
74d2bd9b3d add cognition module 2025-01-23 13:42:36 +01:00
Andreas Koepf (aider)
6fbdd8c262 feat: Add sequence dataset with dynamic pattern generation and tests
This commit introduces a comprehensive sequence dataset generator with the following key features:
- Dynamic pattern generation through operation composition
- Configurable complexity and sequence lengths
- Validation to ensure sequences are interesting and solvable
- Human-readable rule descriptions
- Comprehensive test coverage
- Iterator protocol support
- A convenient factory function

The implementation includes:
- `SequenceDataset` class for generating sequence completion tasks
- `PatternRule` for representing and applying sequence generation rules
- `PatternGenerator` for creating diverse pattern rules
- Extensive test suite to validate dataset generation
2025-01-23 13:41:23 +01:00
Andreas Koepf (aider)
3762ce288e feat: Create cognition/__init__.py with module docstring 2025-01-23 13:33:14 +01:00
Andreas Koepf (aider)
e1d04f8a2f feat: Add cognition module with initial reasoning tasks namespace 2025-01-23 13:31:30 +01:00
Andreas Koepf (aider)
48492c4fd8 feat: Add arithmetic_dataset() factory function to basic_arithmetic.py 2025-01-23 12:47:01 +01:00
Andreas Koepf
72ada57dc5 style: Format code with consistent whitespace and remove unnecessary lines 2025-01-23 12:45:15 +01:00
Andreas Koepf (aider)
38801a7e6f refactor: Remove duplicate chain_sum function from basic_arithmetic.py 2025-01-23 12:41:18 +01:00
Andreas Koepf (aider)
c253b1adbb feat: Add chain_sum() factory function to create ChainSum dataset instances 2025-01-23 12:40:50 +01:00
Andreas Koepf (aider)
272ebc5a42 fix: Ensure deterministic iteration for ArithmeticDataset 2025-01-23 12:37:40 +01:00
Andreas Koepf (aider)
a8b3a86831 feat: Add iteration support to ArithmeticDataset with size-based termination 2025-01-23 12:34:54 +01:00
Andreas Koepf
3077d8571e edit simple example in README 2025-01-23 12:30:52 +01:00
Andreas Koepf (aider)
e9e90051d6 feat: Expose arithmetic modules automatically in reasoning_gym package 2025-01-23 12:25:26 +01:00
Andreas Koepf (aider)
7cce205c5d feat: Add iterator support to ChainSum with size-respecting iteration 2025-01-23 12:23:35 +01:00
Andreas Koepf (aider)
cfba2cb0d5 docs: Add ChainSum usage example to README 2025-01-23 12:17:20 +01:00
Andreas Koepf (aider)
e8c3965299 fix: Remove duplicate 1-digit number test section in test_chain_sum.py 2025-01-23 12:16:09 +01:00
Andreas Koepf (aider)
6aec30c6ed fix: Correct 1-digit number test ranges in chain sum test 2025-01-23 12:14:15 +01:00
Andreas Koepf (aider)
516d4d20d4 feat: Add special case handling for min_digits=1 in ChainSum generation 2025-01-23 12:07:56 +01:00
Andreas Koepf (aider)
4777e6b435 refactor: Move min_value and max_value calculations to __getitem__ 2025-01-23 12:05:55 +01:00
Andreas Koepf (aider)
d2825f41ce feat: Implement allow_negation to generate both positive and negative numbers in ChainSum 2025-01-23 12:01:21 +01:00
Andreas Koepf
c3bce305c1 refactor: Replace Random import with random module and update type hints 2025-01-23 12:01:20 +01:00
Andreas Koepf (aider)
4aeb76ae8c refactor: Simplify ChainSum random number generation with base seed 2025-01-23 11:56:36 +01:00
Andreas Koepf (aider)
626fd78bda feat: Add digit-based number range generation for chain sum tasks 2025-01-23 11:46:55 +01:00
Andreas Koepf (aider)
c8aa98f4e8 feat: Add ChainSum class for generating simple arithmetic tasks 2025-01-23 11:40:00 +01:00
Andreas Koepf
a1bd52b75e chore: Add __init__.py to arithmetic module 2025-01-23 11:39:59 +01:00
Andreas Koepf (aider)
fbba398c91 fix: Prevent infinite loop in arithmetic dataset space generation 2025-01-23 11:34:18 +01:00
Andreas Koepf (aider)
40596262e1 feat: Unify arithmetic task generation with configurable dataset class
This commit introduces a new `ArithmeticDataset` class that:
- Combines complex and simple arithmetic task generation approaches
- Provides configurable task generation via `ArithmeticDatasetConfig`
- Supports deterministic task generation
- Implements dataset interface for easy use with HuggingFace datasets
- Adds comprehensive test coverage for the new implementation

Changes include:
- Refactored `basic_arithmetic.py` to use a unified dataset approach
- Added configuration validation and flexible generation options
- Created test suite to validate dataset behavior
- Removed file generation methods in favor of in-memory generation
2025-01-23 11:30:09 +01:00
Andreas Koepf
8a6364a791 feat: Add basic arithmetic module to reasoning_gym 2025-01-23 11:30:03 +01:00
Andreas Koepf
d4628270bb fix README 2025-01-23 11:04:41 +01:00
Andreas Koepf (aider)
324e84897a feat: Add Black and isort pre-commit hooks with line length configuration 2025-01-23 11:02:13 +01:00
Andreas Koepf (aider)
8d53002e1b chore: Update project homepage and bug tracker URLs 2025-01-23 10:58:29 +01:00
Andreas Koepf (aider)
ba45a1e6a0 chore: Update license to Apache 2.0 and author information 2025-01-23 10:55:01 +01:00
Andreas Koepf (aider)
3f80fd7b80 build: Initialize reasoning_gym package structure with packaging and development setup 2025-01-23 10:50:54 +01:00
Andreas Koepf
530cb523c8 chore: Add .gitignore with .aider and .env files 2025-01-23 10:50:53 +01:00