Thank you for your interest in contributing to TSCG.
git clone https://github.com/SKZL-AI/tscg.git
cd tscg
npm install
npm run build
npm testRequirements: Node.js >= 18.0.0
src/
optimizer/ # Core transforms (TAS, CFL, CFO, SDM, DRO, CCP, CAS, SAD-F)
compiler/ # NL-to-TSCG compilation
core/ # Types, providers, rate-limiter
benchmark/ # Test case generators and runner
cli/ # Unified CLI entry point
packages/
core/ # @tscg/core npm package
tool-optimizer/# @tscg/tool-optimizer npm package
benchmark/ # TAB benchmark harness and analysis code
integrations/ # Framework integration examples
tests/ # 459 tests across 14 test files
docs/ # Technical documentation
# Run all tests
npm test
# Watch mode
npm run test:watch
# Type checking
npm run typecheck- TypeScript strict mode
- Zero external runtime dependencies in core
- ESM modules (ES2022 target)
- Deterministic transforms: same input must always produce same output
- Fork the repository
- Create a feature branch (
git checkout -b feature/my-change) - Make your changes
- Run
npm testand ensure all tests pass - Run
npm run typecheckwith no errors - Submit a pull request with a clear description
If you want to add a new compression principle:
- Add the transform function in
src/optimizer/transforms.ts - Register it in the optimizer pipeline (
src/optimizer/optimizer.ts) - Add test cases in
tests/ - Document the principle in the paper if applicable
Please use GitHub Issues to report bugs or suggest features. Include:
- Steps to reproduce
- Expected vs actual behavior
- Node.js version
- TSCG version
By contributing, you agree that your contributions will be licensed under the MIT License.