Commit graph

334 commits

Author SHA1 Message Date
Andreas Köpf
52b44c47d5 reasoning-gym-server & cli tool (#154)
* feat: Add initial server structure with configuration, registry, and middleware

* feat: Add chain_sum dataset to experiment registry test

* fix: Update test_registry to use DatasetSpec for composite config validation

* refactor: Update Pydantic config to use json_schema_extra and ConfigDict

* feat: Add Pydantic models for API request/response data

* feat: Implement basic experiment management endpoints with tests

* feat: Implement composite configuration endpoints for experiments

* fix: Add missing DatasetConfigUpdate import in server.py

* refactor: Update dataset config update method to properly merge config updates

* fix: Correctly retrieve current dataset config in composite endpoint

* feat: Add basic CLI structure with experiments and config commands

* feat: Add initial CLI tool with basic experiment management commands

* refactor: Reorganize CLI package structure and fix import paths

* refactor: Implement initial CLI commands for experiment management

* feat: Implement HTTP client for Reasoning Gym server in RGC CLI tool

* fix: Move print statements inside try block to resolve SyntaxError

* fix: Resolve SyntaxError in edit_config function by adding missing except block

* feat: Add default app instance in server module for easier uvicorn startup

* docs: Add README.md with server and RGC tool documentation

* remove unused files

* refactor: Remove unsupported type annotation in registry.py

* refactor: Move ExperimentRegistry to coaching module and add Experiment class

* fix: Add missing CompositeDataset import in test_registry.py

* refactor: Implement lazy ASGI app creation for server initialization

* feat: Add health check command to RGC CLI for server connection

* feat: Add version tracking support to CompositeDataset

* feat: Add DatasetVersionManager for tracking dataset versions

* feat: Add entry_id metadata and score_answer_with_id method to CompositeDataset

* feat: Add entry_id metadata combining version and index

* fix: Resolve undefined variable by storing version_id before use

* test: Add comprehensive unit tests for score_answer_with_id() function

* test: Add comprehensive version tracking test for dataset config updates

* feat: Validate dataset weights are positive in CompositeDataset initialization

* feat: Add weight update and normalization methods to CompositeDataset

* refactor: Centralize weight normalization in CompositeDataset and allow zero-weight datasets

* feat: Add negative weight validation to CompositeDataset constructor

* feat: Add duplicate dataset name check in CompositeDataset and update test

* refactor: Move duplicate dataset name check inside dataset iteration loop

* refactor: Update CompositeDataset weight management to use config as source of truth

* refactor: Move duplicate dataset name check to CompositeConfig.validate()

* test: Update composite dataset weight test assertions and validation

* feat: Add methods to add and remove datasets in CompositeDataset

* refactor: Remove weight normalization and use unnormalized weights directly

* refactor: Remove redundant total weight check in update_dataset_weights

* feat: Add batch generation and scoring endpoints to server

* fix: Import BatchEntry in server.py to resolve undefined name error

* refactor: Update ReasoningGymDataset to use server for batch generation and scoring

* fix: Add missing List and Dict type imports

* feat: Add get_batch() and score_outputs() methods to RGClient

* test: Add unit tests for generate_batch and score_outputs endpoints

* refactor: Add DatasetVersionManager to Experiment class and CompositeDataset constructor

* feat: Add validation for base_index and batch_size in generate_batch endpoint

* refactor: Remove unused BatchRequest type from imports

* refactor: Convert models to use Pydantic exclusively

* test: Update scoring endpoint tests to use correct request model format

* refactor: Rename ScoreItem to AnswerItem and update related code

* feat: Update scoring endpoint to return ordered ScoringResponse with scores and entry_ids

* fix: Add missing ScoringResponse import in server.py

* move verl ppo sample with server into own file

* refactor: Use Pydantic models for get_batch() and score_outputs() in RGClient

* refactor: Update client methods to use Pydantic models for type safety

* refactor: Use Pydantic models for experiment and dataset config operations

* refactor: Clean up duplicate methods and improve error handling in main.py

* first bits of rg server use for verl

* refactor: Optimize scoring with single HTTP request in _score_output

* fix: Correct experiment creation with ExperimentCreate object

* grpo tests with server
2025-02-19 22:41:33 +01:00
Zafir Stojanovski
fec058d905 number format 2025-02-19 11:41:06 +01:00
Zafir Stojanovski
ed606631bb Merge branch 'main' of https://github.com/open-thought/reasoning-gym into env/palindrome-partitioning 2025-02-18 14:08:00 +01:00
Andreas Köpf
54d52ef6ae Merge pull request #147 from Adefioye/koko/question-template-tinkering
Tweaking some question templates
2025-02-17 18:22:49 +01:00
Andreas Koepf
aa794253fe minor formatting changes 2025-02-17 18:20:18 +01:00
Andreas Köpf
5654f300b9 Merge pull request #106 from tohskai/multivariate-polynomial-multiplication
Better support for multivariate polynomials in PolynomialMultiplicationDataset
2025-02-17 18:08:36 +01:00
tohskai
28fcf4d481 Refactor PolynomialMultiplicationDataset and fix issues with score_answer 2025-02-17 17:04:48 +01:00
abdulhakeem
ff8cd11a2d Fix unit test 2025-02-17 03:13:06 -06:00
Andreas Köpf
79758a31de Merge pull request #105 from open-thought/circuit_logic
initial draft for circuit_logic dataset generator
2025-02-16 22:54:43 +01:00
Andreas Koepf (aider)
0051c266d4 feat: Add scoring method & unit tests for circuit logic dataset 2025-02-16 22:48:51 +01:00
Zafir Stojanovski
a27704b44e fix template 2025-02-16 19:51:24 +01:00
Andreas Köpf
33f888dce7 Merge pull request #140 from theblackcat102/cryptarithm
New task : Verbal arithmetic
2025-02-16 16:41:44 +01:00
Andreas Koepf
839c830c2a formatting 2025-02-16 16:30:28 +01:00
Andreas Köpf
66ddb41bbd Merge pull request #141 from joesharratt1229/feat/score-answer-impl
Added score answer implementations `spell_backward` and `sentence reordering`
2025-02-16 16:24:48 +01:00
Andreas Koepf
6bf2dfa36c formatting 2025-02-16 16:18:39 +01:00
Zafir Stojanovski
1a3e4372ef update prompt and score answer 2025-02-16 15:18:45 +01:00
Andreas Koepf
5803a2962e more tolerant parsing of futoshiki answers 2025-02-16 14:23:40 +01:00
joesharratt1229
d2d4b3a644 added another assertion to test 2025-02-16 13:10:43 +00:00
theblackcat102
9fe04f7c16 [feat] add include example params 2025-02-16 20:45:19 +08:00
Andreas Koepf (aider)
5c786eb7fe test: Add comprehensive unit tests for FutoshikiDataset 2025-02-16 13:28:36 +01:00
joesharratt1229
cc7d422d78 merged remoted
Merge remote-tracking branch 'origin/main' into feat/score-answer-impl
2025-02-16 12:03:25 +00:00
joesharratt1229
569517664f corrected failing airthmetic test 2025-02-16 12:01:54 +00:00
Andreas Koepf
c7b41acf14 add configuration option for ArcAgiDataset 2025-02-16 12:49:21 +01:00
Andreas Köpf
a409cf3778 Merge pull request #134 from zafstojano/fix/string-insertion
fix(env): String Insertion
2025-02-15 21:20:05 +01:00
Andreas Köpf
53bb55c26c Merge pull request #133 from zafstojano/fix/binary-matrix
fix(env): Binary Matrix
2025-02-15 21:19:23 +01:00
Zafir Stojanovski
467300f7f9 fix score function 2025-02-15 17:40:37 +01:00
Zafir Stojanovski
6c3b5a8ad2 pre-commit 2025-02-15 16:15:09 +01:00
Zafir Stojanovski
815b3c4ee5 test for parsing answer as python list 2025-02-15 16:14:13 +01:00
Zafir Stojanovski
95d367bc17 fix score function and add test 2025-02-15 16:09:08 +01:00
Zafir Stojanovski
84ca05b8f5 update tests for min_n 2025-02-15 15:34:48 +01:00
Andreas Köpf
2c56960ff8 Merge pull request #113 from Iron-Bound/rush_hour
Rush Hour Gym
2025-02-14 23:32:51 +01:00
Andreas Koepf
14f67cb7e7 fix handling of walls, add unit test 2025-02-14 23:29:17 +01:00
Zafir Stojanovski
cb763bc043 add seed for knight swap 2025-02-14 22:08:46 +01:00
Zafir Stojanovski
ed4f9dee13 remove template from test 2025-02-14 21:58:45 +01:00
Zafir Stojanovski
7cf8b9c512 Merge branch 'main' of https://github.com/open-thought/reasoning-gym into env/string-splitting 2025-02-14 21:55:23 +01:00
Andreas Koepf
9a21e6776d adapt unit tests to partial match changes 2025-02-14 21:30:50 +01:00
Zafir Stojanovski
f9e846871b Merge branch 'main' of https://github.com/open-thought/reasoning-gym into env/string-splitting 2025-02-14 17:51:18 +01:00
Zafir Stojanovski
60ebb1329d string splitting 2025-02-14 17:50:07 +01:00
Andreas Koepf (aider)
d5ce2bfdf5 feat: Add score_answer method to RushHourDataset with input validation 2025-02-14 17:33:01 +01:00
Andreas Koepf (aider)
8278a9521c test: Add comprehensive unit tests for RushHourDataset 2025-02-14 17:29:43 +01:00
Andreas Koepf
819cab53d0 test: Add partial move sequence test for Rush Hour board 2025-02-14 17:27:19 +01:00
Andreas Koepf
417e71cd17 add unit test for RushHour Board::perform_moves() 2025-02-14 16:59:19 +01:00
Andreas Köpf
2d38493a55 Merge pull request #128 from open-thought/rich/scorefixes
[Ongoing] Eval Template and Score Fixes
2025-02-14 16:15:37 +01:00
Andreas Koepf
2726caf2fe ignore single whitespace at beginning and end of answer, use reward = len(oracle_answer) / len(answer) 2025-02-14 15:40:12 +01:00
Rich Jones
28d89df935 word sorting score func 2025-02-14 12:57:31 +01:00
Rich Jones
b3438d9976 fix letter jumble 2025-02-14 12:21:56 +01:00
Rich Jones
f945bc5d88 lint 2025-02-14 12:17:50 +01:00
Rich Jones
ab51228f35 clean up ransom note 2025-02-14 12:15:55 +01:00
Andreas Koepf (aider)
e24093c9f0 feat: Add comprehensive unit tests for Game of Life dataset 2025-02-14 07:28:41 +01:00
Andreas Koepf
80719c7201 move game_of_life from games to algorithmic 2025-02-14 07:26:47 +01:00