Instructions to use josephmayo/gemma-4-E4B-it-coding-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use josephmayo/gemma-4-E4B-it-coding-lora with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("google/gemma-4-E4B-it") model = PeftModel.from_pretrained(base_model, "josephmayo/gemma-4-E4B-it-coding-lora") - Notebooks
- Google Colab
- Kaggle
| phase,id,latency_s,score,chars,preview | |
| before,HumanEval_0,35.316,0.8,536,"```python | |
| from typing import List | |
| def has_close_elements(numbers: List[float], threshold: float) -> bool: | |
| """""" Check if in given list of numbers, are any two numbers closer to each other than | |
| given threshold. | |
| >>> has_close_elements([1.0, 2.0, 3.0], 0.5) | |
| False | |
| >>> has_close_eleme" | |
| before,HumanEval_1,33.612,0.8,755,"```python | |
| from typing import List | |
| def separate_paren_groups(paren_string: str) -> List[str]: | |
| """""" Input to this function is a string containing multiple groups of nested parentheses. Your goal is to | |
| separate those group into separate strings and return the list of those. | |
| Separate groups" | |
| before,HumanEval_2,17.675,0.8,377,"```python | |
| def truncate_number(number: float) -> float: | |
| """""" Given a positive floating point number, it can be decomposed into | |
| and integer part (largest integer smaller than given number) and decimals | |
| (leftover part always smaller than 1). | |
| Return the decimal part of the number. | |
| >>" | |
| before,HumanEval_3,30.553,0.8,610,"```python | |
| from typing import List | |
| def below_zero(operations: List[int]) -> bool: | |
| """""" You're given a list of deposit and withdrawal operations on a bank account that starts with | |
| zero balance. Your task is to detect if at any point the balance of account fallls below zero, and | |
| at that po" | |
| before,HumanEval_4,33.594,0.8,648,"```python | |
| from typing import List | |
| def mean_absolute_deviation(numbers: List[float]) -> float: | |
| """""" For a given list of input numbers, calculate Mean Absolute Deviation | |
| around the mean of this dataset. | |
| Mean Absolute Deviation is the average absolute difference between each | |
| element an" | |
| before,HumanEval_5,29.098,0.8,500,"```python | |
| from typing import List | |
| def intersperse(numbers: List[int], delimeter: int) -> List[int]: | |
| """""" Insert a number 'delimeter' between every two consecutive elements of input list `numbers' | |
| >>> intersperse([], 4) | |
| [] | |
| >>> intersperse([1, 2, 3], 4) | |
| [1, 4, 2, 4, 3] | |
| """""" | |
| " | |
| before,HumanEval_6,33.787,0.55,702,"```python | |
| from typing import List | |
| def parse_nested_parens(paren_string: str) -> List[int]: | |
| """""" Input to this function is a string represented multiple groups for nested parentheses separated by spaces. | |
| For each of the group, output the deepest level of nesting of parentheses. | |
| E.g. (()(" | |
| before,HumanEval_7,21.317,0.8,396,"```python | |
| from typing import List | |
| def filter_by_substring(strings: List[str], substring: str) -> List[str]: | |
| """""" Filter an input list of strings only for ones that contain given substring | |
| >>> filter_by_substring([], 'a') | |
| [] | |
| >>> filter_by_substring(['abc', 'bacd', 'cde', 'array'], 'a" | |
| after,HumanEval_0,53.709,0.8,568,"```python | |
| from typing import List | |
| def has_close_elements(numbers: List[float], threshold: float) -> bool: | |
| """""" Check if in given list of numbers, are any two numbers closer to each other than | |
| given threshold. | |
| >>> has_close_elements([1.0, 2.0, 3.0], 0.5) | |
| False | |
| >>> has_close_eleme" | |
| after,HumanEval_1,53.466,0.8,763,"```python | |
| from typing import List | |
| def separate_paren_groups(paren_string: str) -> List[str]: | |
| paren_string = paren_string.replace("" "", """") | |
| groups = [] | |
| balance = 0 | |
| start = 0 | |
| for i, char in enumerate(paren_string): | |
| if char == '(': | |
| balance += 1 | |
| elif char" | |
| after,HumanEval_2,53.294,0.8,824,"```python | |
| def truncate_number(number: float) -> float: | |
| """""" Given a positive floating point number, it can be decomposed into | |
| and an integer part (largest integer smaller than given number) and decimals | |
| (leftover part always smaller than 1). | |
| Return the decimal part of the number. | |
| " | |
| after,HumanEval_3,53.551,0.8,770,"```python | |
| from typing import List | |
| def below_zero(operations: List[int]) -> bool: | |
| """""" You're given a list of deposit and withdrawal operations on a bank account that starts with | |
| zero balance. Your task is to detect if at any point the balance of account fallls below zero, and | |
| at that po" | |
| after,HumanEval_4,53.816,0.8,736,"```python | |
| from typing import List | |
| def mean_absolute_deviation(numbers: List[float]) -> float: | |
| """""" For a given list of input numbers, calculate Mean Absolute Deviation | |
| around the mean of this dataset. | |
| Mean Absolute Deviation is the average absolute difference between each | |
| element an" | |
| after,HumanEval_5,53.518,0.8,643,"```python | |
| from typing import List | |
| def intersperse(numbers: List[int], delimeter: int) -> List[int]: | |
| """""" Insert a number 'delimeter' between every two consecutive elements of input list `numbers' | |
| >>> intersperse([], 4) | |
| [] | |
| >>> intersperse([1, 2, 3], 4) | |
| [1, 4, 2, 4, 3] | |
| """""" | |
| " | |
| after,HumanEval_6,53.528,0.55,701,"```python | |
| from typing import List | |
| def parse_nested_parens(paren_string: str) -> List[int]: | |
| """""" Input to this function is a string represented multiple groups for nested parentheses separated by spaces. | |
| For each of the group, output the deepest level of nesting of parentheses. | |
| E.g. (()(" | |
| after,HumanEval_7,53.317,0.8,739,"```python | |
| from typing import List | |
| def filter_by_substring(strings: List[str], substring: str) -> List[str]: | |
| """""" Filter an input list of strings only for ones that contain given substring | |
| >>> filter_by_substring([], 'a') | |
| [] | |
| >>> filter_by_substring(['abc', 'bacd', 'cde', 'array'], 'a" | |