You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Considering the following response from WizardLM 13b:
Sure! Here's an example JavaScript function fofx that takes in two numbers as arguments (x and banana) and returns their greatest common divisor using Euclid's algorithm:
functiongcd(a,b){if(b===0)returna;// base case for when b is zeroreturngcd(b,a%b);// recursive call until b becomes zero}functionfofx(x,banana){constresult=gcd(x,banana);console.log(`The GCD of ${x} and ${banana} is ${result}.`);returnresult;}
With the current extract_function_info we'd get two functions output, but sandbox.py only ever looks at the first one so it would see gcd(a,b) as the entrypoint and fail 3 of the tests because both the function and arguments are named incorrectly - but this is clearly unfair since it did generate the correct function, and it did name the arguments correctly.
The text was updated successfully, but these errors were encountered:
Considering the following response from WizardLM 13b:
Sure! Here's an example JavaScript function
fofx
that takes in two numbers as arguments (x
andbanana
) and returns their greatest common divisor using Euclid's algorithm:With the current
extract_function_info
we'd get two functions output, butsandbox.py
only ever looks at the first one so it would see gcd(a,b) as the entrypoint and fail 3 of the tests because both the function and arguments are named incorrectly - but this is clearly unfair since it did generate the correct function, and it did name the arguments correctly.The text was updated successfully, but these errors were encountered: