Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update versions #15

Merged
merged 1 commit into from
Jan 21, 2024
Merged

chore: update versions #15

merged 1 commit into from
Jan 21, 2024

Conversation

zaripych
Copy link
Owner

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

[email protected]

Patch Changes

  • #14 05da890 Thanks @zaripych! - feat: evaluate refactor outcomes using LLM to make decision of whether file edit should be accepted or discarded

    This is a big change which adds extra steps to the refactor process. Every time an LLM produces a file edit - we will pass that edit through evaluation algorithm to asses whether it should be accepted or discarded. Previously, this logic was only affected by the existence or absence of eslint errors. This will make the final result higher quality and more reliable.

    The new behavior can be disabled by setting evaluate: false in the goal.md file.

    In addition to that, this change also adds a new CLI command for internal use which allows us to compare results of multiple refactor runs. This is useful for benchmarking purposes.

    To run the benchmark, use the following command:

    pnpm benchmark --config .refactor-bot/benchmarks/test-benchmark.yaml

    Where the config:

    refactorConfig:
        name: test-refactoring
        ref: 8f1a3da55caeee3df75853042e57978c45513f18
        budgetCents: 100
        model: gpt-4-1106-preview
        objective: Replace all usages of `readFile` from `fs/promises` module with `readFileSync` from `fs` module in `packages/refactor-bot/src/refactor/planTasks.ts`, `packages/refactor-bot/src/refactor/loadRefactors.ts` and `packages/refactor-bot/src/refactor/discoverDependencies.ts`.
    
    numberOfRuns: 2
    
    variants:
        - name: 'A'
          ids: # ids of refactor runs to save mooney on
              - VRixXEwC
              - k0FmgQjU
              - IpSOtP7d
              - xqydSrSU
        - name: 'B'

    This will run multiple refactor runs and compare the results. At this moment no statistical analysis is performed as I'm not convinced we can reach statistical significance with the number of runs that also doesn't make you poor.

@zaripych zaripych merged commit 4a201ba into main Jan 21, 2024
2 checks passed
@zaripych zaripych deleted the changeset-release/main branch January 21, 2024 08:27
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